summaryrefslogtreecommitdiff
path: root/net/ntp
diff options
context:
space:
mode:
authorCy Schubert <cy@FreeBSD.org>2020-04-07 19:57:34 +0000
committerCy Schubert <cy@FreeBSD.org>2020-04-07 19:57:34 +0000
commit26ebd3a30a630cd10379fffa266673089d69210c (patch)
tree7547dcdc2e24c6a61e0a5b69f593fd8f117646b3 /net/ntp
parentdatabases/mroonga: Update version 9.12=>10.01 (diff)
ntpd: fix build with -fno-common
Only a small nit here: psl should be declared extern and defined exactly once. -fno-common will become the default in GCC10/LLVM11. Obtained from: src r359676 (kevans) MFH: 2020Q2
Diffstat (limited to 'net/ntp')
-rw-r--r--net/ntp/files/patch-include_ntp__config.h13
-rw-r--r--net/ntp/files/patch-ntpd_ntp__config.c13
2 files changed, 26 insertions, 0 deletions
diff --git a/net/ntp/files/patch-include_ntp__config.h b/net/ntp/files/patch-include_ntp__config.h
new file mode 100644
index 000000000000..a3ca6ffde001
--- /dev/null
+++ b/net/ntp/files/patch-include_ntp__config.h
@@ -0,0 +1,13 @@
+Index: include/ntp_config.h
+===================================================================
+--- include/ntp_config.h (revision 359675)
++++ include/ntp_config.h (revision 359676)
+@@ -280,7 +280,7 @@
+ * Poll Skew List
+ */
+
+-psl_item psl[17-3+1]; /* values for polls 3-17 */
++extern psl_item psl[17-3+1]; /* values for polls 3-17 */
+ /* To simplify the runtime code we */
+ /* don't want to have to special-case */
+ /* dealing with a default */
diff --git a/net/ntp/files/patch-ntpd_ntp__config.c b/net/ntp/files/patch-ntpd_ntp__config.c
new file mode 100644
index 000000000000..9ab435ca93af
--- /dev/null
+++ b/net/ntp/files/patch-ntpd_ntp__config.c
@@ -0,0 +1,13 @@
+Index: ntpd/ntp_config.c
+===================================================================
+--- ntpd/ntp_config.c (revision 359675)
++++ ntpd/ntp_config.c (revision 359676)
+@@ -202,6 +202,8 @@
+
+ extern char *stats_drift_file; /* name of the driftfile */
+
++psl_item psl[17-3+1];
++
+ #ifdef BC_LIST_FRAMEWORK_NOT_YET_USED
+ /*
+ * backwards compatibility flags