#bug https://bugs.gentoo.org/715776 #bug https://bugs.gentoo.org/919876 and general port to C23 --- a/configure +++ b/configure @@ -134,6 +100,7 @@ echo -n 'Checking for BSD signal semantics... ' cat <<EOF >__conftest.c +#define _DEFAULT_SOURCE #include <unistd.h> #include <signal.h> int count=0; --- a/timed/lib/cksum.c +++ b/timed/lib/cksum.c @@ -41,6 +41,7 @@ #ident "$Revision: 1.4 $" #endif +#define _DEFAULT_SOURCE #include <sys/types.h> #include <sys/time.h> #include "timed-extern.h" --- a/timed/timed/globals.h +++ b/timed/timed/globals.h @@ -37,6 +37,7 @@ #ident "$Revision: 1.5 $" #endif +#define _DEFAULT_SOURCE #include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> --- a/timed/timedc/cmds.c +++ b/timed/timedc/cmds.c @@ -41,6 +41,7 @@ #ident "$Revision: 1.11 $" #endif +#define _DEFAULT_SOURCE #include "timedc.h" #include <string.h> #include <sys/file.h> --- a/timed/timedc/timedc.c +++ b/timed/timedc/timedc.c @@ -45,6 +45,7 @@ #ident "$Revision: 1.8 $" #endif +#define _DEFAULT_SOURCE #include "timedc.h" #include <string.h> #include <signal.h> --- a/timed/timed/networkdelta.c +++ b/timed/timed/networkdelta.c @@ -40,8 +40,8 @@ #ifdef sgi #ident "$Revision: 1.4 $" #endif -#include <math.h> #include "globals.h" +#include <math.h> static long median(float, float*, long*, long*, unsigned int);