summaryrefslogtreecommitdiffstats
path: root/win
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2015-09-14 08:57:03 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2015-09-14 08:57:03 (GMT)
commit939adaec382ce7257869e18efa3ab353edda0ed5 (patch)
tree50b33044dd56b63633e734e9bf0725cdd7ba7e4c /win
parentdfde3458e7bc27e3eef496b2b65d38a93092b9aa (diff)
parent4b62f1fb163792e9cc42e12ee5e803ae187cb609 (diff)
downloadtk-939adaec382ce7257869e18efa3ab353edda0ed5.zip
tk-939adaec382ce7257869e18efa3ab353edda0ed5.tar.gz
tk-939adaec382ce7257869e18efa3ab353edda0ed5.tar.bz2
merge core-8-5-branch
Diffstat (limited to 'win')
-rwxr-xr-xwin/configure20
-rw-r--r--win/makefile.vc13
-rw-r--r--win/tcl.m420
3 files changed, 47 insertions, 6 deletions
diff --git a/win/configure b/win/configure
index 35f57ca..57e0453 100755
--- a/win/configure
+++ b/win/configure
@@ -3827,6 +3827,13 @@ echo "${ECHO_T}using shared flags" >&6
EXESUFFIX="\${DBGX}.exe"
LIBRARIES="\${SHARED_LIBRARIES}"
SHLIB_LD_LIBS='${LIBS}'
+ case "x`echo \${VisualStudioVersion}`" in
+ x14*)
+ lflags="${lflags} -nodefaultlib:libucrt.lib"
+ ;;
+ *)
+ ;;
+ esac
fi
# DLLSUFFIX is separate because it is the building block for
# users of tclConfig.sh that may build shared or static.
@@ -3864,6 +3871,15 @@ echo "${ECHO_T} Using 64-bit $MACHINE mode" >&6
fi
LIBS="user32.lib advapi32.lib ws2_32.lib"
+
+ case "x`echo \${VisualStudioVersion}`" in
+ x14*)
+ LIBS="$LIBS ucrt.lib"
+ ;;
+ *)
+ ;;
+ esac
+
if test "$do64bit" != "no" ; then
# The space-based-path will work for the Makefile, but will
# not work if AC_TRY_COMPILE is called. TEA has the
@@ -3938,7 +3954,7 @@ fi
CFLAGS_DEBUG="-nologo -Zi -Od ${runtime}d"
# Do not use -O2 for Win64 - this has proved buggy in code gen.
CFLAGS_OPTIMIZE="-nologo -O1 ${runtime}"
- lflags="-nologo -MACHINE:${MACHINE} -LIBPATH:\"${MSSDK}/Lib/${MACHINE}\""
+ lflags="${lflags} -nologo -MACHINE:${MACHINE} -LIBPATH:\"${MSSDK}/Lib/${MACHINE}\""
LINKBIN="\"${PATH64}/link.exe\""
# Avoid 'unresolved external symbol __security_cookie' errors.
# c.f. http://support.microsoft.com/?id=894573
@@ -3950,7 +3966,7 @@ fi
CFLAGS_DEBUG="-nologo -Z7 -Od -WX ${runtime}d"
# -O2 - create fast code (/Og /Oi /Ot /Oy /Ob2 /Gs /GF /Gy)
CFLAGS_OPTIMIZE="-nologo -O2 ${runtime}"
- lflags="-nologo"
+ lflags="${lflags} -nologo"
LINKBIN="link"
fi
diff --git a/win/makefile.vc b/win/makefile.vc
index 4b9475f..d2795c9 100644
--- a/win/makefile.vc
+++ b/win/makefile.vc
@@ -42,7 +42,7 @@ the build instructions.
# turn on the 64-bit compiler, if your SDK has it.
#
# 3) Targets are:
-# release -- Builds the core, the shell. (default)
+# release -- Builds the core, the shell and the dlls. (default)
# dlls -- Just builds the windows extensions.
# shell -- Just builds the shell and the core.
# core -- Only builds the core [tkXX.(dll|lib)].
@@ -443,7 +443,7 @@ cdebug = $(OPTIMIZATIONS)
cdebug =
!endif
!if $(SYMBOLS)
-cdebug = $(cdebug) -Zi
+cdebug = $(cdebug) -Zi
!endif
!else if "$(MACHINE)" == "IA64" || "$(MACHINE)" == "AMD64"
### Warnings are too many, can't support warnings into errors.
@@ -476,6 +476,7 @@ CON_CFLAGS = $(cdebug) $(cflags) $(crt) -DCONSOLE
WISH_CFLAGS = $(BASE_CFLAGS) $(TK_DEFINES)
STUB_CFLAGS = $(cflags) $(cdebug) $(TK_DEFINES)
+
#---------------------------------------------------------------------
# Link flags
#---------------------------------------------------------------------
@@ -496,6 +497,10 @@ lflags = -nologo -machine:$(MACHINE) $(LINKERFLAGS) $(ldebug)
lflags = $(lflags) -profile
!endif
+!if $(MSVCRT) && !($(DEBUG) && !$(UNCHECKED)) && $(VCVERSION) >= 1900
+lflags = $(lflags) -nodefaultlib:libucrt.lib
+!endif
+
!if $(ALIGN98_HACK) && !$(STATIC_BUILD)
### Align sections for PE size savings.
lflags = $(lflags) -opt:nowin98
@@ -520,6 +525,10 @@ baselibs = kernel32.lib user32.lib
baselibs = $(baselibs) bufferoverflowU.lib
!endif
!endif
+!if $(MSVCRT) && !($(DEBUG) && !$(UNCHECKED)) && $(VCVERSION) >= 1900
+baselibs = $(baselibs) ucrt.lib
+!endif
+
guilibs = $(baselibs) gdi32.lib
diff --git a/win/tcl.m4 b/win/tcl.m4
index 44fd47e..6f10a96 100644
--- a/win/tcl.m4
+++ b/win/tcl.m4
@@ -783,6 +783,13 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [
EXESUFFIX="\${DBGX}.exe"
LIBRARIES="\${SHARED_LIBRARIES}"
SHLIB_LD_LIBS='${LIBS}'
+ case "x`echo \${VisualStudioVersion}`" in
+ x14*)
+ lflags="${lflags} -nodefaultlib:libucrt.lib"
+ ;;
+ *)
+ ;;
+ esac
fi
# DLLSUFFIX is separate because it is the building block for
# users of tclConfig.sh that may build shared or static.
@@ -817,6 +824,15 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [
fi
LIBS="user32.lib advapi32.lib ws2_32.lib"
+
+ case "x`echo \${VisualStudioVersion}`" in
+ x14*)
+ LIBS="$LIBS ucrt.lib"
+ ;;
+ *)
+ ;;
+ esac
+
if test "$do64bit" != "no" ; then
# The space-based-path will work for the Makefile, but will
# not work if AC_TRY_COMPILE is called. TEA has the
@@ -831,7 +847,7 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [
CFLAGS_DEBUG="-nologo -Zi -Od ${runtime}d"
# Do not use -O2 for Win64 - this has proved buggy in code gen.
CFLAGS_OPTIMIZE="-nologo -O1 ${runtime}"
- lflags="-nologo -MACHINE:${MACHINE} -LIBPATH:\"${MSSDK}/Lib/${MACHINE}\""
+ lflags="${lflags} -nologo -MACHINE:${MACHINE} -LIBPATH:\"${MSSDK}/Lib/${MACHINE}\""
LINKBIN="\"${PATH64}/link.exe\""
# Avoid 'unresolved external symbol __security_cookie' errors.
# c.f. http://support.microsoft.com/?id=894573
@@ -843,7 +859,7 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [
CFLAGS_DEBUG="-nologo -Z7 -Od -WX ${runtime}d"
# -O2 - create fast code (/Og /Oi /Ot /Oy /Ob2 /Gs /GF /Gy)
CFLAGS_OPTIMIZE="-nologo -O2 ${runtime}"
- lflags="-nologo"
+ lflags="${lflags} -nologo"
LINKBIN="link"
fi