diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-06-08 09:29:02 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-06-08 09:29:02 (GMT) |
commit | a51d1909f467d11adf3d095e1fa302f161929cbb (patch) | |
tree | a5f72ec63cfc4145468ead652db83318d71249ae /unix/tcl.m4 | |
parent | c9f936a48137826608f43e2c8a767b8ca4e3cc04 (diff) | |
download | tk-a51d1909f467d11adf3d095e1fa302f161929cbb.zip tk-a51d1909f467d11adf3d095e1fa302f161929cbb.tar.gz tk-a51d1909f467d11adf3d095e1fa302f161929cbb.tar.bz2 |
Add "-fno-common" to SHARED_CFLAGS on various platforms (e.g. Linux, CYGWIN). This is the default with gcc-10, so better make sure it doesn't cause problems.
Diffstat (limited to 'unix/tcl.m4')
-rw-r--r-- | unix/tcl.m4 | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/unix/tcl.m4 b/unix/tcl.m4 index 0a2920b..aed464f 100644 --- a/unix/tcl.m4 +++ b/unix/tcl.m4 @@ -968,7 +968,7 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [ CFLAGS_OPTIMIZE=-O2 CFLAGS_WARNING="-Wall -Wextra -Wwrite-strings -Wpointer-arith" case "${CC}" in - *++) + *++|*++-*) ;; *) CFLAGS_WARNING="${CFLAGS_WARNING} -Wc++-compat -Wdeclaration-after-statement" @@ -1084,7 +1084,7 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [ LD_SEARCH_FLAGS="" ;; CYGWIN_*) - SHLIB_CFLAGS="" + SHLIB_CFLAGS="-fno-common" SHLIB_LD='${CC} -shared' SHLIB_SUFFIX=".dll" DL_OBJS="tclLoadDl.o" @@ -1269,7 +1269,7 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [ ]) ;; Linux*|GNU*|NetBSD-Debian) - SHLIB_CFLAGS="-fPIC" + SHLIB_CFLAGS="-fPIC -fno-common" SHLIB_SUFFIX=".so" CFLAGS_OPTIMIZE="-O2" @@ -1364,7 +1364,6 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [ ;; DragonFly-*|FreeBSD-*) # This configuration from FreeBSD Ports. - SHLIB_CFLAGS="-fPIC" SHLIB_LD="${CC} -shared" SHLIB_LD_LIBS="${SHLIB_LD_LIBS} -Wl,-soname,\$[@]" SHLIB_SUFFIX=".so" @@ -1558,7 +1557,6 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [ QNX-6*) # QNX RTP # This may work for all QNX, but it was only reported for v6. - SHLIB_CFLAGS="-fPIC" SHLIB_LD="ld -Bshareable -x" SHLIB_LD_LIBS="" SHLIB_SUFFIX=".so" @@ -1786,9 +1784,12 @@ dnl # preprocessing tests use only CPPFLAGS. AIX-*) ;; BSD/OS*) ;; CYGWIN_*) ;; - IRIX*) ;; - NetBSD-*|DragonFly-*|FreeBSD-*|OpenBSD-*) ;; + HP_UX*) ;; Darwin-*) ;; + IRIX*) ;; + Linux*|GNU*) ;; + NetBSD-*|OpenBSD-*) ;; + OSF1-V*) ;; SCO_SV-3.2*) ;; *) SHLIB_CFLAGS="-fPIC" ;; esac]) |