[Git][NTPsec/ntpsec][master] 5 commits: Typo/grammar

Eric S. Raymond gitlab at mg.gitlab.com
Thu Dec 8 05:55:00 UTC 2016


Eric S. Raymond pushed to branch master at NTPsec / ntpsec


Commits:
14ec4dc3 by Matt Selsky at 2016-12-08T00:54:40-05:00
Typo/grammar

- - - - -
b2063e93 by Matt Selsky at 2016-12-08T00:54:40-05:00
Remove remaining references to libevent2

- - - - -
955151f2 by Matt Selsky at 2016-12-08T00:54:40-05:00
Remove unused imports

- - - - -
a7fed66f by Matt Selsky at 2016-12-08T00:54:40-05:00
Typos

- - - - -
3a4a0ac0 by Matt Selsky at 2016-12-08T00:54:40-05:00
ntpdig doesn't use warn() but sys.stderr.write()

- - - - -


7 changed files:

- INSTALL
- devel/release.nix
- devel/tour.txt
- docs/includes/ntpdig-body.txt
- docs/includes/ntpmon-body.txt
- ntpclients/ntpdig
- − wafhelpers/check_libevent2.py


Changes:

=====================================
INSTALL
=====================================
--- a/INSTALL
+++ b/INSTALL
@@ -229,7 +229,7 @@ operates.
 == Cross-compiling ==
 
 Set up a cross-compile environment for the target architecture.  At minimum
-it will need its own binaries for the OpenSSL and libevent2 libraries.
+it will need its own binaries for the OpenSSL library.
 
 Configure NTPSec with:
 


=====================================
devel/release.nix
=====================================
--- a/devel/release.nix
+++ b/devel/release.nix
@@ -51,7 +51,7 @@ in with derivationOptions; rec {
       name = "ntpsec";
       src = tarball;
 
-      buildInputs = with pkgs; [ python27 bison libevent openssl asciidoc ];
+      buildInputs = with pkgs; [ python27 bison openssl asciidoc ];
 
       configurePhase = ''
         runHook preConfigure


=====================================
devel/tour.txt
=====================================
--- a/devel/tour.txt
+++ b/devel/tour.txt
@@ -315,19 +315,6 @@ The process everything step sorts the contents of the FIFO, then discards
 outliers, roughly 1/3 of the samples, and then figures out the average and
 injects that into the peer buffer for the refclock.
 
-== ntpdig and libevent2 ==
-
-You may notice that ntpdig is written in a different style than the
-rest of the suite, and has a dependency on libevent2 that the rest of
-the code does not use.  This is because ntpdig, back when it was
-called sntp, was written separately from the rest of the NTP suite
-and incorporated wholesale after the fact.
-
-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.  Other NTP programs, notably ntpd and ntpq, could
-use it, but would require serious rewrites to do so.
-
 == Asynchronous DNS lookup ==
 
 There are great many complications in the code that arise from wanting


=====================================
docs/includes/ntpdig-body.txt
=====================================
--- a/docs/includes/ntpdig-body.txt
+++ b/docs/includes/ntpdig-body.txt
@@ -54,7 +54,7 @@ JSON record:
 In the JSON format, time is in ISO 8601 format; precision is the synch
 distance, with an unknown synch distance being reported as 0.  Host and
 IP are always emitted even if duplicate. The "adjusted" boolean
-reports whether ntpdig determined it should slewed or stepped the
+reports whether ntpdig determined it should have slewed or stepped the
 time. This may be shown as true even if time was not actually
 adjusted due to lack of clock-setting privileges.
 
@@ -207,7 +207,7 @@ been removed for security reasons or discarded as unnecessary in a modern
 environment.
 
 This version does not log to syslog.  Pipe standard output and
-standard error to logger(1) id you want this behavior.
+standard error to logger(1) if you want this behavior.
 
 The synchronization-distance formula used in this version is slightly
 different from that found in sntp(1), tracking the newer formula used
@@ -222,8 +222,6 @@ One of the following exit values will be returned:
   Successful program execution.
 1 (EXIT_FAILURE)::
   The operation failed or the command syntax was not valid.
-2::
-  Internal error - libevent failed to initialize properly.
 
 == AUTHORS ==
 


=====================================
docs/includes/ntpmon-body.txt
=====================================
--- a/docs/includes/ntpmon-body.txt
+++ b/docs/includes/ntpmon-body.txt
@@ -9,12 +9,12 @@
 == Description ==
 
 This program is a real-time status monitor for NTP.  It presents the
-same informartion as the 'peers' and 'mrulist' commands of {ntpqman},
+same information as the 'peers' and 'mrulist' commands of {ntpqman},
 but using a split-window display that also includes a status summary
 bar, and updates at intervals guaranteed to show status changes as
 soon as they occur.
 
-(Specifically, the display begins updating once per seconds and
+(Specifically, the display begins updating once per second and
 adjusts itself to poll at twice the frequency of the shortest
 polling interval reported in the last peers response.)
 


=====================================
ntpclients/ntpdig
=====================================
--- a/ntpclients/ntpdig
+++ b/ntpclients/ntpdig
@@ -38,7 +38,7 @@ from __future__ import print_function, division
 #
 # The one new option in this version is -p, borrowed from ntpdate.
 
-import sys, socket, select, struct, time, getopt, datetime, math
+import sys, socket, select, time, getopt, math
 
 try:
     import ntp.packet
@@ -341,7 +341,7 @@ if __name__ == '__main__':
             raise SystemExit(1)
 
     if not credentials and authkey and keyfile is None:
-        self.warn("-a option requires -k.\n")
+        sys.stderr.write("-a option requires -k.\n")
         raise SystemExit(1)
 
     gap /= 1000	# Scale gap to milliseconds


=====================================
wafhelpers/check_libevent2.py deleted
=====================================
--- a/wafhelpers/check_libevent2.py
+++ /dev/null
@@ -1,61 +0,0 @@
-from __future__ import print_function
-
-from waflib.Logs import pprint
-from wafhelpers.tool import check_sanity
-
-LIBEVENT2_FRAG = """
-#include <event2/thread.h>
-#include <event2/event.h>
-
-int main(void) {
-	struct event_config *   evcfg;
-
-	evthread_use_pthreads();
-	evcfg = event_config_new();
-	return 0;
-}
-"""
-
-
-def check_libevent2_header(ctx):
-	ctx.check(header_name="event2/event.h", includes=ctx.env.PLATFORM_INCLUDES, mandatory=False, comment="libevent2 main header")
-	ctx.check(header_name="event2/thread.h", includes=ctx.env.PLATFORM_INCLUDES, mandatory=False, comment="libevent2 thread support")
-
-	# XXX: On some systems (NetBSD) event_core doesn't exist.  libevent is pulled in with event_pthreads.
-	#      This results in a warning from check_sanity()
-	ctx.check(feature="c cshlib", lib="event_core", libpath=ctx.env.PLATFORM_LIBPATH, uselib_store="LIBEVENT_CORE", mandatory=False, comment="libevent core library")
-	ctx.check(feature="c cshlib", lib="event_pthreads", libpath=ctx.env.PLATFORM_LIBPATH, uselib_store="LIBEVENT_PTHREADS", use="LIBEVENT_CORE", mandatory=False, comment="libevent pthread library")
-
-	if ctx.get_define("HAVE_EVENT2_THREAD_H") and ctx.get_define("HAVE_EVENT2_EVENT_H") and ctx.env.LIB_LIBEVENT_PTHREADS and ctx.env.LIB_LIBEVENT_CORE:
-		ctx.env.EVENT2_HEADER = True
-
-def check_libevent2_run(ctx):
-	if ctx.env.ENABLE_CROSS:
-		if ctx.env.EVENT2_HEADER: # XXX Remove when variant builds exist
-			ctx.define("HAVE_LIBEVENT2", 1, comment="libevent2 support")
-			ctx.env.LIBEVENT2_ENABLE = True
-		return
-
-	ctx.check(
-		fragment	= LIBEVENT2_FRAG,
-		define_name = "HAVE_LIBEVENT2",
-		features	= "c",
-		use			= "LIBEVENT, LIBEVENT_CORE, LIBEVENT_PTHREADS",
-		msg         = "Checking if libevent2 works",
-		includes        = ctx.env.PLATFORM_INCLUDES,
-		export_includes = ctx.env.PLATFORM_INCLUDES,
-		mandatory	= False,
-		comment		= "libevent2 support"
-	)
-
-	check_sanity(ctx, ctx.env.EVENT2_HEADER, "libevent2")
-
-	if not ctx.get_define("HAVE_LIBEVENT2"):
-		print("")
-		pprint("RED", "Warning libevent2 does not work")
-		pprint("RED", "This means ntpdig will not be built")
-		pprint("RED", "While not necessary you will lose 'ntpdate' functionality.")
-		print("")
-	else:
-		ctx.env.LIBEVENT2_ENABLE = True
-		ctx.define("HAVE_LIBEVENT2", 1, comment="libevent2 support")



View it on GitLab: https://gitlab.com/NTPsec/ntpsec/compare/48597b1c10e3b482d30979a9c31f3d49b052b8fc...3a4a0ac076c625ff825948a653df7c5d286855e8
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ntpsec.org/pipermail/vc/attachments/20161208/2ef8e781/attachment.html>


More information about the vc mailing list