diff options
| author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-01-07 15:20:49 (GMT) |
|---|---|---|
| committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-01-07 15:20:49 (GMT) |
| commit | 14b5289e4aa4945dd080d1d3d2dad7f54537eec8 (patch) | |
| tree | 8f683aa0cbf8062ba81931b49f3731abbccd0a8f /unix | |
| parent | bb09dba8c07eb42beccc0249f53dc2ca25bb01ed (diff) | |
| parent | 49a7184962b241204447d10cb9546f514237c344 (diff) | |
| download | tcl-14b5289e4aa4945dd080d1d3d2dad7f54537eec8.zip tcl-14b5289e4aa4945dd080d1d3d2dad7f54537eec8.tar.gz tcl-14b5289e4aa4945dd080d1d3d2dad7f54537eec8.tar.bz2 | |
Merge 8.7
Diffstat (limited to 'unix')
| -rw-r--r-- | unix/Makefile.in | 4 | ||||
| -rwxr-xr-x | unix/configure | 6 | ||||
| -rw-r--r-- | unix/configure.ac | 2 | ||||
| -rw-r--r-- | unix/tcl.m4 | 4 | ||||
| -rw-r--r-- | unix/tclSelectNotfy.c | 3 | ||||
| -rw-r--r-- | unix/tclUnixInit.c | 3 | ||||
| -rw-r--r-- | unix/tclUnixPort.h | 11 |
7 files changed, 23 insertions, 10 deletions
diff --git a/unix/Makefile.in b/unix/Makefile.in index c971ab6..3876f1f 100644 --- a/unix/Makefile.in +++ b/unix/Makefile.in @@ -277,8 +277,8 @@ VALGRINDARGS = --tool=memcheck --num-callers=24 \ # modify it and you shouldn't need to modify it either. #-------------------------------------------------------------------------- -STUB_CC_SWITCHES = ${CFLAGS} ${CFLAGS_WARNING} ${SHLIB_CFLAGS} \ - -I"${BUILD_DIR}" -I${UNIX_DIR} -I${GENERIC_DIR} -I${TOMMATH_DIR} \ +STUB_CC_SWITCHES = -I"${BUILD_DIR}" -I${UNIX_DIR} -I${GENERIC_DIR} -I${TOMMATH_DIR} \ + ${CFLAGS} ${CFLAGS_WARNING} ${SHLIB_CFLAGS} \ ${AC_FLAGS} ${PROTO_FLAGS} ${ENV_FLAGS} ${EXTRA_CFLAGS} \ @EXTRA_CC_SWITCHES@ diff --git a/unix/configure b/unix/configure index e87e0d0..59f2c5d 100755 --- a/unix/configure +++ b/unix/configure @@ -4661,7 +4661,7 @@ if test "${with_system_libtommath+set}" = set; then : withval=$with_system_libtommath; libtommath_ok=${withval} fi -if test x"${libtommath_ok}" == x -o x"${libtommath_ok}" != xno; then +if test x"${libtommath_ok}" = x -o x"${libtommath_ok}" != xno; then ac_fn_c_check_header_mongrel "$LINENO" "tommath.h" "ac_cv_header_tommath_h" "$ac_includes_default" if test "x$ac_cv_header_tommath_h" = xyes; then : @@ -5053,7 +5053,7 @@ fi if test "$GCC" = yes; then : CFLAGS_OPTIMIZE=-O2 - CFLAGS_WARNING="-Wall -Wwrite-strings -Wsign-compare -Wpointer-arith -Wunused-parameter" + CFLAGS_WARNING="-Wall -Wextra -Wwrite-strings -Wsign-compare -Wpointer-arith" else @@ -5845,7 +5845,6 @@ fi SHLIB_SUFFIX=".so" DL_OBJS="tclLoadDl.o" DL_LIBS="" - LDFLAGS="" if test $doRpath = yes; then : CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' @@ -6049,6 +6048,7 @@ fi $as_echo "#define MODULE_SCOPE __private_extern__" >>confdefs.h + tcl_cv_cc_visibility_hidden=yes fi CC_SEARCH_FLAGS="" diff --git a/unix/configure.ac b/unix/configure.ac index a5cb12b..f0ba688 100644 --- a/unix/configure.ac +++ b/unix/configure.ac @@ -175,7 +175,7 @@ AC_ARG_WITH(system-libtommath, AC_HELP_STRING([--with-system-libtommath], [use external libtommath (default: true if available, false otherwise)]), libtommath_ok=${withval}) -if test x"${libtommath_ok}" == x -o x"${libtommath_ok}" != xno; then +if test x"${libtommath_ok}" = x -o x"${libtommath_ok}" != xno; then AC_CHECK_HEADER([tommath.h],[ AC_CHECK_TYPE([mp_int],[],[libtommath_ok=no],[#include <tommath.h>])],[ libtommath_ok=no]) diff --git a/unix/tcl.m4 b/unix/tcl.m4 index 1233cd2..e45042d 100644 --- a/unix/tcl.m4 +++ b/unix/tcl.m4 @@ -989,7 +989,7 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [ CFLAGS_DEBUG=-g AS_IF([test "$GCC" = yes], [ CFLAGS_OPTIMIZE=-O2 - CFLAGS_WARNING="-Wall -Wwrite-strings -Wsign-compare -Wpointer-arith -Wunused-parameter" + CFLAGS_WARNING="-Wall -Wextra -Wwrite-strings -Wsign-compare -Wpointer-arith" ], [ CFLAGS_OPTIMIZE=-O CFLAGS_WARNING="" @@ -1385,7 +1385,6 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [ SHLIB_SUFFIX=".so" DL_OBJS="tclLoadDl.o" DL_LIBS="" - LDFLAGS="" AS_IF([test $doRpath = yes], [ CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}']) @@ -1476,6 +1475,7 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [ AS_IF([test "$tcl_cv_cc_visibility_hidden" != yes], [ AC_DEFINE(MODULE_SCOPE, [__private_extern__], [Compiler support for module scope symbols]) + tcl_cv_cc_visibility_hidden=yes ]) CC_SEARCH_FLAGS="" LD_SEARCH_FLAGS="" diff --git a/unix/tclSelectNotfy.c b/unix/tclSelectNotfy.c index 2d60429..a7788a6 100644 --- a/unix/tclSelectNotfy.c +++ b/unix/tclSelectNotfy.c @@ -236,6 +236,9 @@ typedef struct { const void *lpszClassName; } WNDCLASSW; +#ifdef __clang__ +#pragma clang diagnostic ignored "-Wignored-attributes" +#endif extern void __stdcall CloseHandle(void *); extern void *__stdcall CreateEventW(void *, unsigned char, unsigned char, void *); diff --git a/unix/tclUnixInit.c b/unix/tclUnixInit.c index a3a64a9..0e61e85 100644 --- a/unix/tclUnixInit.c +++ b/unix/tclUnixInit.c @@ -34,6 +34,9 @@ #ifdef __cplusplus extern "C" { #endif +#ifdef __clang__ +#pragma clang diagnostic ignored "-Wignored-attributes" +#endif DLLIMPORT extern __stdcall unsigned char GetVersionExW(void *); DLLIMPORT extern __stdcall void *GetModuleHandleW(const void *); DLLIMPORT extern __stdcall void FreeLibrary(void *); diff --git a/unix/tclUnixPort.h b/unix/tclUnixPort.h index a86319c..4b79677 100644 --- a/unix/tclUnixPort.h +++ b/unix/tclUnixPort.h @@ -99,6 +99,10 @@ extern "C" { # define SOCKET unsigned int # define WSAEWOULDBLOCK 10035 typedef unsigned short WCHAR; +#ifdef __clang__ +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wignored-attributes" +#endif __declspec(dllimport) extern __stdcall int GetModuleHandleExW(unsigned int, const void *, void *); __declspec(dllimport) extern __stdcall int GetModuleFileNameW(void *, const void *, int); __declspec(dllimport) extern __stdcall int WideCharToMultiByte(int, int, const void *, int, @@ -106,12 +110,15 @@ extern "C" { __declspec(dllimport) extern __stdcall int MultiByteToWideChar(int, int, const char *, int, WCHAR *, int); __declspec(dllimport) extern __stdcall void OutputDebugStringW(const WCHAR *); - __declspec(dllimport) extern __stdcall int IsDebuggerPresent(); - __declspec(dllimport) extern __stdcall int GetLastError(); + __declspec(dllimport) extern __stdcall int IsDebuggerPresent(void); + __declspec(dllimport) extern __stdcall int GetLastError(void); __declspec(dllimport) extern __stdcall int GetFileAttributesW(const WCHAR *); __declspec(dllimport) extern __stdcall int SetFileAttributesW(const WCHAR *, int); __declspec(dllimport) extern int cygwin_conv_path(int, const void *, void *, int); +#ifdef __clang__ +#pragma clang diagnostic pop +#endif /* On Cygwin, the environment is imported from the Cygwin DLL. */ #ifndef __x86_64__ # define environ __cygwin_environ |
