Check-in [945dafb370]
Overview
Comment:Experimental version that makes it possible to only rebuild the previously failed parts.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 945dafb37084ff55c9b6a8716c3b2ea8026b875c
User & Date: schelte on 2013-08-21 21:14:25
Other Links: manifest | tags
Context
2013-09-11
13:36
Reflect the latest changes in the README file. check-in: a0175128eb user: schelte tags: trunk
2013-08-21
21:14
Experimental version that makes it possible to only rebuild the previously failed parts. check-in: 945dafb370 user: schelte tags: trunk
2013-08-18
10:20
Provide a build script for the dbus extension, making it available as an optional package that can be included when building a tclkit. check-in: 591a13879c user: schelte tags: trunk
Changes

Modified kitcreator from [35b0320bb7] to [f33d7d8aef].

1
2










3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33


34

35
36


37
38


39
40
41
42
43
44
45
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20













21
22
23
24
25
26
27
28
29
30
31
32
33
34


35
36
37

38
39
40
41
42
43
44
45
46


+
+
+
+
+
+
+
+
+
+








-
-
-
-
-
-
-
-
-
-
-
-
-










+
+

+
-
-
+
+

-
+
+







#! /usr/bin/env bash

# Determine appropriate mode
mode="build"
case "$1" in
	clean|distclean|build|retry)
		mode="$1"
		shift
		;;
esac

# Determine which Tcl version to build
TCLVERS="8.5.14"
if echo "$1" | grep '^[0-9][0-9]*\.' >/dev/null || echo "$1" | egrep '^(cvs|fossil)_' >/dev/null; then
	TCLVERS="$1"

	shift
fi
export TCLVERS

# Determine appropriate mode
mode="build"
if [ "$1" = "clean" ]; then
	shift

	mode="clean"
fi
if [ "$1" = "distclean" ]; then
	shift

	mode="distclean"
fi

# Verify that "pre.sh" has been run if this is a development snapshot of
# KitCreator
if [ -f 'build/pre.sh' ]; then
	if ! find 'kitsh/buildsrc/' -name configure -type f 2>/dev/null | grep configure >/dev/null; then
		echo "Please remember to run 'build/pre.sh' if you expect this build to work." >&2
	fi
fi

# Define the list of all packages, for cleaning purposes
KITCREATOR_ALLPKGS="kitsh tcl tclvfs zlib tk itcl mk4tcl thread dbus"
# Always rebuild kitsh
rm -f "kitsh/.success"
for pkg in ${KITCREATOR_ALLPKGS}; do
	if [ "${mode}" != "retry" -o ! -f "${pkg}/.success" ]; then
	rm -f "${pkg}/build.log"
	rm -rf "${pkg}/out" "${pkg}/inst" "${pkg}/build"
		rm -f "${pkg}/build.log" "${pkg}/.success"
		rm -rf "${pkg}/out" "${pkg}/inst" "${pkg}/build"

	rm -rf "${pkg}/src"/tmp-*
		rm -rf "${pkg}/src"/tmp-*
	fi

	if [ "${mode}" = "distclean" ]; then
		rm -rf "${pkg}/src"
	fi
done

# We're all done if we're in clean or distclean mode
126
127
128
129
130
131
132




133

134
135
136
137


138
139
140



141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158


159
160
161
162
163
164
165
127
128
129
130
131
132
133
134
135
136
137

138
139



140
141
142


143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172







+
+
+
+
-
+

-
-
-
+
+

-
-
+
+
+


















+
+







done
export TCLSH_NATIVE

# Do build
failedpkgs=""
buildfailed="0"
for pkg in tcl tclvfs zlib ${KITCREATOR_PKGS} kitsh; do
	failed="0"
	if [ -f "${pkg}/.success" ]; then
		echo -n "Skipping ${pkg} ..."
	else
	echo -n "Building ${pkg} ..."
		echo -n "Building ${pkg} ..."

	failed="0"
	(
		cd "${pkg}" >/dev/null 2>/dev/null || exit 1
		(
			cd "${pkg}" >/dev/null 2>/dev/null || exit 1

		./build.sh 3>&1 4>&2 > build.log 2>&1 || exit 1
	) || failed="1"
			./build.sh 3>&1 4>&2 > build.log 2>&1 || exit 1
		) || failed="1"
	fi

	if [ "${failed}" = "1" ]; then
		echo " failed."
		failedpkgs="${failedpkgs} ${pkg}"
	else
		echo " done."
	fi

	case "${pkg}" in
		tcl)
			TCLCONFIGDIR=$(find "$(pwd)/tcl/build" -name tclConfig.sh | head -1 | sed 's@/[^/]*$@@')
			TCLCONFIGDIRTAIL="$(basename "${TCLCONFIGDIR}")"
			export TCLCONFIGDIR TCLCONFIGDIRTAIL
			;;
	esac

	if [ "${failed}" = "1" ]; then
		buildfailed="1"
	else
		touch "${pkg}/.success"
	fi
done

if [ -n "${failedpkgs}" ]; then
	echo "Failed to build:${failedpkgs}"
fi