Check-in [e143e5ef08]
Overview
SHA1:e143e5ef08903c542a624bdeb9bb6812f8d460fd
Date: 2010-10-02 08:39:55
User: rkeene
Comment:Updated Minkit build scripts to support buildint KitDLL

Added fix for building KitDLL on platforms without working "strtod"

Updated to support compiling TclVFS extension with "-fPIC" when building KitDLL

Timelines: family | ancestors | descendants | both | trunk
Downloads: Tarball | ZIP archive
Other Links: files | file ages | folders | manifest
Tags And Properties
Context
2010-10-02
08:40
[d08ab67dfd] Added missing file from previous commit (user: rkeene, tags: trunk)
08:39
[e143e5ef08] Updated Minkit build scripts to support buildint KitDLL

Added fix for building KitDLL on platforms without working "strtod"

Updated to support compiling TclVFS extension with "-fPIC" when building KitDLL (user: rkeene, tags: trunk)

06:58
[015d254dbe] Fixed determination of encoding from system in KitDLL (user: rkeene, tags: trunk)
Changes

Modified build/make-minkit from [fd8671763c] to [440fcc9f64].

1
2
3



4

5
6
7
8
9
#! /bin/sh

# Build minimalistic tclkit



KITCREATOR_PKGS=" "

KITCREATOR_MINENCODINGS='true' 
KITCREATOR_MINBUILD='true' 
export KITCREATOR_PKGS KITCREATOR_MINENCODINGS KITCREATOR_MINBUILD

./kitcreator "$@"



>
>
>
|
>





1
2
3
4
5
6
7
8
9
10
11
12
13
#! /bin/sh

# Build minimalistic tclkit
if echo " ${KITCREATOR_PKGS} " | grep ' kitdll ' >/dev/null; then
	KITCREATOR_PKGS="kitdll"
else
	KITCREATOR_PKGS=" "
fi
KITCREATOR_MINENCODINGS='true' 
KITCREATOR_MINBUILD='true' 
export KITCREATOR_PKGS KITCREATOR_MINENCODINGS KITCREATOR_MINBUILD

./kitcreator "$@"

Modified build/make-minkit-static from [05272e8f15] to [5ddd33e2a4].

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#! /bin/sh

# Set C compiler to diet libc
CC='diet gcc'
export CC

rm -rf tcl/patchscripts
mkdir tcl/patchscripts || exit 1

cat << \__EOF__ > tcl/patchscripts/dietlibc.sh
sed 's@^# *include *<string.h>$@&@;T s;p;s@string.h@strings.h@;:s' generic/tclInt.h > generic/tclInt.h.new && cat generic/tclInt.h.new > generic/tclInt.h
rm -f generic/tclInt.h.new
__EOF__

./build/make-minkit "$@" --disable-load --disable-threads

rm -rf tcl/patchscripts

exit 0






<
<
<







|


1
2
3
4
5
6



7
8
9
10
11
12
13
14
15
16
#! /bin/sh

# Set C compiler to diet libc
CC='diet gcc'
export CC




cat << \__EOF__ > tcl/patchscripts/dietlibc.sh
sed 's@^# *include *<string.h>$@&@;T s;p;s@string.h@strings.h@;:s' generic/tclInt.h > generic/tclInt.h.new && cat generic/tclInt.h.new > generic/tclInt.h
rm -f generic/tclInt.h.new
__EOF__

./build/make-minkit "$@" --disable-load --disable-threads

rm -f tcl/patchscripts/dietlibc.sh

exit 0

Modified tcl/build.sh from [6ef99f6477] to [0f3c234f4e].

56
57
58
59
60
61
62


63

64
65
66
67
68
69
70

	cd "${BUILDDIR}" || exit 1

	# Apply patch scripts if needed
	for patchscript in "${PATCHSCRIPTDIR}"/*.sh; do
		if [ -f "${patchscript}" ]; then
			echo "Running patch script: ${patchscript}"


			. "${patchscript}"

		fi
	done

	# Patch Win32 builds to always provide DllMain if we are building KitDLL
	if [ "${KITTARGET}" = "kitdll" ]; then
		## DllMain is needed when building KitDLL
		for filetopatch in win/tclWin32Dll.c win/tclWinInit.c; do







>
>
|
>







56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73

	cd "${BUILDDIR}" || exit 1

	# Apply patch scripts if needed
	for patchscript in "${PATCHSCRIPTDIR}"/*.sh; do
		if [ -f "${patchscript}" ]; then
			echo "Running patch script: ${patchscript}"

			(
				. "${patchscript}"
			)
		fi
	done

	# Patch Win32 builds to always provide DllMain if we are building KitDLL
	if [ "${KITTARGET}" = "kitdll" ]; then
		## DllMain is needed when building KitDLL
		for filetopatch in win/tclWin32Dll.c win/tclWinInit.c; do

Modified tclvfs/build.sh from [708db71e5e] to [d1e2c23178].

66
67
68
69
70
71
72






73
74
75
76
77
78
79
	if [ "${BUILDTYPE}" = "win" ]; then
		TEA_PLATFORM="windows"
		export TEA_PLATFORM

		CFLAGS="${CFLAGS} -I${TCLCONFIGDIR}"
		export CFLAGS
	fi







	# Build static version
	echo "Running: ./configure --disable-shared --prefix=\"${INSTDIR}\" --exec-prefix=\"${INSTDIR}\" --with-tcl=\"${TCLCONFIGDIR}\" ${CONFIGUREEXTRA}"
	./configure --disable-shared --prefix="${INSTDIR}" --exec-prefix="${INSTDIR}" --with-tcl="${TCLCONFIGDIR}" ${CONFIGUREEXTRA}

	echo "Running: ${MAKE:-make}"
	${MAKE:-make} || exit 1







>
>
>
>
>
>







66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
	if [ "${BUILDTYPE}" = "win" ]; then
		TEA_PLATFORM="windows"
		export TEA_PLATFORM

		CFLAGS="${CFLAGS} -I${TCLCONFIGDIR}"
		export CFLAGS
	fi

	# If we are building for KitDLL, compile with '-fPIC'
	if [ "${KITTARGET}" = "kitdll" ]; then
		CFLAGS="${CFLAGS} -fPIC"
		export CFLAGS
	fi

	# Build static version
	echo "Running: ./configure --disable-shared --prefix=\"${INSTDIR}\" --exec-prefix=\"${INSTDIR}\" --with-tcl=\"${TCLCONFIGDIR}\" ${CONFIGUREEXTRA}"
	./configure --disable-shared --prefix="${INSTDIR}" --exec-prefix="${INSTDIR}" --with-tcl="${TCLCONFIGDIR}" ${CONFIGUREEXTRA}

	echo "Running: ${MAKE:-make}"
	${MAKE:-make} || exit 1