Diff

Differences From Artifact [1bf5b7b587]:

To Artifact [6ef99f6477]:


    59     59   	# Apply patch scripts if needed
    60     60   	for patchscript in "${PATCHSCRIPTDIR}"/*.sh; do
    61     61   		if [ -f "${patchscript}" ]; then
    62     62   			echo "Running patch script: ${patchscript}"
    63     63   			. "${patchscript}"
    64     64   		fi
    65     65   	done
           66  +
           67  +	# Patch Win32 builds to always provide DllMain if we are building KitDLL
           68  +	if [ "${KITTARGET}" = "kitdll" ]; then
           69  +		## DllMain is needed when building KitDLL
           70  +		for filetopatch in win/tclWin32Dll.c win/tclWinInit.c; do
           71  +			echo "Undefining STATIC_BUILD in \"${filetopatch}\""
           72  +
           73  +			sed 's@STATIC_BUILD@NEVER_STATIC_BUILD@g' "${filetopatch}" > "${filetopatch}.new" && cat "${filetopatch}.new" > "${filetopatch}"
           74  +			rm -f "${filetopatch}.new"
           75  +		done
           76  +	fi
    66     77   
    67     78   	for dir in unix win macosx __fail__; do
    68     79   		if [ "${dir}" = "__fail__" ]; then
    69     80   			# If we haven't figured out how to build it, reject.
    70     81   
    71     82   			exit 1
    72     83   		fi