diff options
author | dgp <dgp@users.sourceforge.net> | 2018-06-12 19:14:47 (GMT) |
---|---|---|
committer | dgp <dgp@users.sourceforge.net> | 2018-06-12 19:14:47 (GMT) |
commit | 9e3e0498e7809842960b810cbad933f8f6679231 (patch) | |
tree | 653dfd51eed2dfef7f77de94ba81dc02d3a250f8 /unix | |
parent | 38be8d3de6482550ac70bbb23c6e7f260b01d9ab (diff) | |
parent | b5e61d9f54b0a0579e07552cbca1e7b7a13444f8 (diff) | |
download | tcl-9e3e0498e7809842960b810cbad933f8f6679231.zip tcl-9e3e0498e7809842960b810cbad933f8f6679231.tar.gz tcl-9e3e0498e7809842960b810cbad933f8f6679231.tar.bz2 |
merge 8.7
Diffstat (limited to 'unix')
-rw-r--r-- | unix/Makefile.in | 2 | ||||
-rwxr-xr-x | unix/configure | 34 | ||||
-rw-r--r-- | unix/tcl.m4 | 11 | ||||
-rw-r--r-- | unix/tclConfig.h.in | 3 | ||||
-rw-r--r-- | unix/tclUnixPort.h | 13 |
5 files changed, 56 insertions, 7 deletions
diff --git a/unix/Makefile.in b/unix/Makefile.in index 0d6c664..cb98773 100644 --- a/unix/Makefile.in +++ b/unix/Makefile.in @@ -903,7 +903,7 @@ install-libraries: libraries else true; \ fi; \ done; - @for i in opt0.4 encoding ../tcl8 ../tcl8/8.4 ../tcl8/8.4/platform ../tcl8/8.5 ../tcl8/8.6; \ + @for i in opt0.4 encoding ../tcl8 ../tcl8/8.4 ../tcl8/8.4/platform ../tcl8/8.5 ../tcl8/8.6 ../tcl8/8.7; \ do \ if [ ! -d "$(SCRIPT_INSTALL_DIR)"/$$i ] ; then \ echo "Making directory $(SCRIPT_INSTALL_DIR)/$$i"; \ diff --git a/unix/configure b/unix/configure index bdbf809..6800261 100755 --- a/unix/configure +++ b/unix/configure @@ -6884,6 +6884,40 @@ $as_echo "#define HAVE_STRUCT_DIRENT64 1" >>confdefs.h fi + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIR64" >&5 +$as_echo_n "checking for DIR64... " >&6; } +if ${tcl_cv_DIR64+:} false; then : + $as_echo_n "(cached) " >&6 +else + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <sys/types.h> +#include <dirent.h> +int +main () +{ +struct dirent64 *p; DIR64 d = opendir64("."); + p = readdir64(d); rewinddir64(d); closedir64(d); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + tcl_cv_DIR64=yes +else + tcl_cv_DIR64=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_DIR64" >&5 +$as_echo "$tcl_cv_DIR64" >&6; } + if test "x${tcl_cv_DIR64}" = "xyes" ; then + +$as_echo "#define HAVE_DIR64 1" >>confdefs.h + + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct stat64" >&5 $as_echo_n "checking for struct stat64... " >&6; } if ${tcl_cv_struct_stat64+:} false; then : diff --git a/unix/tcl.m4 b/unix/tcl.m4 index 2d2f190..d705480 100644 --- a/unix/tcl.m4 +++ b/unix/tcl.m4 @@ -2413,7 +2413,7 @@ AC_DEFUN([SC_TCL_EARLY_FLAGS],[ # Might define the following vars: # TCL_WIDE_INT_IS_LONG # TCL_WIDE_INT_TYPE -# HAVE_STRUCT_DIRENT64 +# HAVE_STRUCT_DIRENT64, HAVE_DIR64 # HAVE_STRUCT_STAT64 # HAVE_TYPE_OFF64_T # @@ -2449,6 +2449,15 @@ AC_DEFUN([SC_TCL_64BIT_FLAGS], [ AC_DEFINE(HAVE_STRUCT_DIRENT64, 1, [Is 'struct dirent64' in <sys/types.h>?]) fi + AC_CACHE_CHECK([for DIR64], tcl_cv_DIR64,[ + AC_TRY_COMPILE([#include <sys/types.h> +#include <dirent.h>],[struct dirent64 *p; DIR64 d = opendir64("."); + p = readdir64(d); rewinddir64(d); closedir64(d);], + tcl_cv_DIR64=yes,tcl_cv_DIR64=no)]) + if test "x${tcl_cv_DIR64}" = "xyes" ; then + AC_DEFINE(HAVE_DIR64, 1, [Is 'DIR64' in <sys/types.h>?]) + fi + AC_CACHE_CHECK([for struct stat64], tcl_cv_struct_stat64,[ AC_TRY_COMPILE([#include <sys/stat.h>],[struct stat64 p; ], diff --git a/unix/tclConfig.h.in b/unix/tclConfig.h.in index b9d0059..21c3bef 100644 --- a/unix/tclConfig.h.in +++ b/unix/tclConfig.h.in @@ -196,6 +196,9 @@ /* Is 'struct dirent64' in <sys/types.h>? */ #undef HAVE_STRUCT_DIRENT64 +/* Is 'DIR64' in <sys/types.h>? */ +#undef HAVE_DIR64 + /* Define to 1 if the system has the type `struct in6_addr'. */ #undef HAVE_STRUCT_IN6_ADDR diff --git a/unix/tclUnixPort.h b/unix/tclUnixPort.h index e4277a3..a90b471 100644 --- a/unix/tclUnixPort.h +++ b/unix/tclUnixPort.h @@ -57,16 +57,19 @@ */ #ifdef HAVE_STRUCT_DIRENT64 -typedef DIR64 TclDIR; -typedef struct dirent64 Tcl_DirEntry; +typedef struct dirent64 Tcl_DirEntry; # define TclOSreaddir readdir64 +#else +typedef struct dirent Tcl_DirEntry; +# define TclOSreaddir readdir +#endif +#ifdef HAVE_DIR64 +typedef DIR64 TclDIR; # define TclOSopendir opendir64 # define TclOSrewinddir rewinddir64 # define TclOSclosedir closedir64 #else -typedef DIR TclDIR; -typedef struct dirent Tcl_DirEntry; -# define TclOSreaddir readdir +typedef DIR TclDIR; # define TclOSopendir opendir # define TclOSrewinddir rewinddir # define TclOSclosedir closedir |