Package: ntp
Severity: normal
Tags: patch

When building 'ntp' on amd64 with gcc-4.0,
I get the following error:

if gcc -DHAVE_CONFIG_H -I. -I../../ntpd -I.. -I../../include -I../include  
-I/usr/include  -g -O2 -Wall -Wcast-qual -Wmissing-prototypes -Wpointer-arith 
-Wshadow -Wstrict-prototypes -MT ntp_control.o -MD -MP -MF 
".deps/ntp_control.Tpo" \
  -c -o ntp_control.o `test -f '../../ntpd/ntp_control.c' || echo 
'../../ntpd/'`../../ntpd/ntp_control.c; \
then mv -f ".deps/ntp_control.Tpo" ".deps/ntp_control.Po"; \
else rm -f ".deps/ntp_control.Tpo"; exit 1; \
fi
In file included from ../../ntpd/ntp_control.c:8:
../../include/ntpd.h:229: error: array type has incomplete element type
make[1]: *** [ntp_control.o] Error 1
make[1]: Leaving directory `/ntp-4.2.0a+stable/build-refclock/ntpd'
make: *** [build-stamp] Error 2

With the attached patch 'ntp' can be compiled
on amd64 using gcc-4.0.

The attached patch also changes the Build-Depends from libreadline4-dev
to libreadline5-dev.

Regards
Andreas Jochens

diff -urN ../tmp-orig/ntp-4.2.0a+stable/include/ntp_stdlib.h 
./include/ntp_stdlib.h
--- ../tmp-orig/ntp-4.2.0a+stable/include/ntp_stdlib.h  2003-05-04 
16:50:25.000000000 +0200
+++ ./include/ntp_stdlib.h      2005-03-09 12:59:45.000000000 +0100
@@ -135,7 +135,7 @@
 
 /* clocktypes.c */
 struct clktype;
-extern struct clktype clktypes[];
+extern struct clktype *clktypes;
 
 /* getopt.c */
 extern char *  ntp_optarg;             /* global argument pointer */
diff -urN ../tmp-orig/ntp-4.2.0a+stable/include/ntpd.h ./include/ntpd.h
--- ../tmp-orig/ntp-4.2.0a+stable/include/ntpd.h        2004-05-04 
07:01:25.000000000 +0200
+++ ./include/ntpd.h    2005-03-09 12:56:03.000000000 +0100
@@ -226,7 +226,6 @@
 
 /* ntp_control.c */
 struct ctl_trap;
-extern struct ctl_trap ctl_trap[];
 extern int     num_ctl_traps;
 extern keyid_t ctl_auth_keyid;         /* keyid used for authenticating write 
requests */
 
diff -urN ../tmp-orig/ntp-4.2.0a+stable/libntp/clocktypes.c 
./libntp/clocktypes.c
--- ../tmp-orig/ntp-4.2.0a+stable/libntp/clocktypes.c   2002-07-19 
19:15:54.000000000 +0200
+++ ./libntp/clocktypes.c       2005-03-09 13:05:42.000000000 +0100
@@ -9,7 +9,7 @@
 #include "ntp_refclock.h"
 #include "ntp_stdlib.h"
 
-struct clktype clktypes[] = {
+struct clktype *clktypes = {
        { REFCLK_NONE,          "unspecified type (0)",
          "UNKNOWN" },
        { REFCLK_LOCALCLOCK,    "Undisciplined local clock (1)",
diff -urN ../tmp-orig/ntp-4.2.0a+stable/debian/control ./debian/control
--- ../tmp-orig/ntp-4.2.0a+stable/debian/control        2005-03-09 
13:11:24.276933990 +0100
+++ ./debian/control    2005-03-09 12:48:06.000000000 +0100
@@ -2,7 +2,7 @@
 Section: net
 Priority: optional
 Maintainer: Debian NTP Team <[EMAIL PROTECTED]>
-Build-Depends: debhelper (>> 4.1.0), libreadline4-dev, lynx, libcap-dev | 
not+linux-gnu, libssl-dev (>= 0.9), binutils (>= 2.14.90.0.7)
+Build-Depends: debhelper (>> 4.1.0), libreadline5-dev, lynx, libcap-dev | 
not+linux-gnu, libssl-dev (>= 0.9), binutils (>= 2.14.90.0.7)
 Standards-Version: 3.6.1
 Uploaders: Bruce Walker <[EMAIL PROTECTED]>, Bdale Garbee <[EMAIL PROTECTED]>, 
Matthias Urlichs <[EMAIL PROTECTED]>
 



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to