[ntpsec commit] Remove detection and inclusion of net/if_var.h and netinet /in_var.h.

Eric S. Raymond esr at ntpsec.org
Tue Oct 20 05:00:52 UTC 2015


Module:    ntpsec
Branch:    master
Commit:    8094238d4e2c29d370ad09c80cbeb52b1d7a644b
Changeset: http://git.ntpsec.org/ntpsec/commit/?id=8094238d4e2c29d370ad09c80cbeb52b1d7a644b

Author:    Eric S. Raymond <esr at thyrsus.com>
Date:      Tue Oct 20 00:55:15 2015 -0400

Remove detection and inclusion of net/if_var.h and netinet/in_var.h.

(Yes, this commit message looks a lot like my last. Read carefully, they
are not duplicates! Together these commits clean up some annoying port
warnings under FreeBSD.)

These are not in the Open Group standard, and not required under Linux
or FreeBSD.  No code was conditioned on HAVE_NET_IF_VAR_H or
HAVE_NETINET_IN_VAR_H, just the inclusions.  So if this breaks
anyting on any target platform it should cause simple compile-time
errors due to missing definitions.

Google searches hint that these may once have been required on older
Unixes, but the definitions we require have been absorbed into other
standardized headers.  Note however that this change has *not* been
tested under Mac OS X.

---

 include/ntp_net.h  | 6 ------
 pylib/configure.py | 2 --
 2 files changed, 8 deletions(-)

diff --git a/include/ntp_net.h b/include/ntp_net.h
index 3efe753..a5f1c38 100644
--- a/include/ntp_net.h
+++ b/include/ntp_net.h
@@ -9,12 +9,6 @@
 #include <sys/socket.h>
 #include <net/if.h>
 #include <netinet/in.h>
-#ifdef HAVE_NET_IF_VAR_H
-#include <net/if_var.h>
-#endif
-#ifdef HAVE_NETINET_IN_VAR_H
-#include <netinet/in_var.h>
-#endif
 
 #include "ntp_rfc2553.h"
 #include "ntp_malloc.h"
diff --git a/pylib/configure.py b/pylib/configure.py
index 4d9f606..ac745fb 100644
--- a/pylib/configure.py
+++ b/pylib/configure.py
@@ -246,9 +246,7 @@ def cmd_configure(ctx):
 		"machine/soundcard.h",
 		("md5.h", ["sys/types.h"]),
 		"net/if6.h",
-		"net/if_var.h",
 		("net/route.h", ["sys/socket.h","net/if.h","net/route.h"]),
-		"netinet/in_var.h",
 		"netinfo/ni.h",
 		"priv.h",
 		("readline/readline.h",["stdio.h"]),



More information about the vc mailing list