openwrt-package/zip/patches/200-fix-build-for-gcc-14.patch
2025-05-29 15:07:58 +08:00

32 lines
752 B
Diff

--- a/timezone.c
+++ b/timezone.c
@@ -41,6 +41,7 @@
#include "timezone.h"
#include <ctype.h>
#include <errno.h>
+#include <time.h>
#ifdef IZTZ_DEFINESTDGLOBALS
long timezone = 0;
--- a/unix/configure
+++ b/unix/configure
@@ -505,7 +505,7 @@ done
echo Check for memset
echo "int main(){ char k; memset(&k,0,0); return 0; }" > conftest.c
$CC -o conftest conftest.c >/dev/null 2>/dev/null
-[ $? -ne 0 ] && CFLAGS="${CFLAGS} -DZMEM"
+[ $? -ne 0 ] && CFLAGS="${CFLAGS}"
echo Check for memmove
--- a/unix/unix.c
+++ b/unix/unix.c
@@ -67,7 +67,6 @@ local char *readd OF((DIR *));
#ifndef dirent
# define dirent direct
#endif
-typedef FILE DIR;
/*
** Apparently originally by Rich Salz.
** Cleaned up and modified by James W. Birdsall.