Diff

Differences From Artifact [e672e78acf]:

To Artifact [5c91dc1965]:


148
149
150
151
152
153
154


155
156
157
158
159
160
161
...
170
171
172
173
174
175
176
177
178
179


180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
...
221
222
223
224
225
226
227
228




















229
230
231
232
233
234
235
...
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263

function configure() {
	local tryopts tryopt
	local staticpkg staticpkgvar
	local isshared
	local save_cflags
	local base_var kc_var



	# Determine if the user decided this should be static or not
	staticpkgvar="$(echo "STATIC${internalpkgname}" | dd conv=ucase 2>/dev/null)"
	staticpkg="$(eval "echo \"\$${staticpkgvar}\"")"

	# Determine if the build script overrides this
	if [ "${pkg_always_static}" = '1' ]; then
................................................................................
		if [ -n "${kc_var_val}" ]; then
			eval "${base_var}=\"\$${base_var} \$${kc_var}\"; export ${base_var}"
		fi
	done

	# Determine if we should enable shared or not
	if [ "${staticpkg}" = "0" ]; then
		tryopts="--enable-shared --disable-shared"
	elif [ "${staticpkg}" = "-1" ]; then
		tryopts="--enable-shared"


	else
		tryopts="--disable-shared"
	fi

	save_cflags="${CFLAGS}"
	for tryopt in $tryopts __fail__; do
		if [ "${tryopt}" = "__fail__" ]; then
			return 1
		fi

		# Clean up, if needed
		make distclean >/dev/null 2>/dev/null
		if [ "${tryopt}" == "--enable-shared" ]; then
			isshared="1"
		else
			isshared="0"
		fi

		# If build a static package for KitDLL, ensure that we use PIC
		# so that it can be linked into the shared object
................................................................................
				sed 's@XXX_TCL_STUBS@USE_TCL_STUBS@g' configure > configure.new
			fi

			cat configure.new > configure
			rm -f configure.new
		fi

		./configure $tryopt --prefix="${installdir}" --exec-prefix="${installdir}" --libdir="${installdir}/lib" --with-tcl="${TCLCONFIGDIR}" "${configure_extra[@]}" ${CONFIGUREEXTRA} && break




















	done

	return 0
}

function postconfigure() {
	:
................................................................................

function preinstall() {
	:
}

function install() {
	mkdir -p "${installdir}/lib" || return 1
	${MAKE:-make} tcllibdir="${installdir}/lib" "${make_extra[@]}" install || return 1
}

function postinstall() {
	:
}

function createruntime() {







>
>







 







|

|
>
>

|



|






|







 







|
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







 







|







148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
...
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
...
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
...
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287

function configure() {
	local tryopts tryopt
	local staticpkg staticpkgvar
	local isshared
	local save_cflags
	local base_var kc_var
	local configure_opt configure_opts configure_opts_new
	local ignore_opt ignore_this_opt

	# Determine if the user decided this should be static or not
	staticpkgvar="$(echo "STATIC${internalpkgname}" | dd conv=ucase 2>/dev/null)"
	staticpkg="$(eval "echo \"\$${staticpkgvar}\"")"

	# Determine if the build script overrides this
	if [ "${pkg_always_static}" = '1' ]; then
................................................................................
		if [ -n "${kc_var_val}" ]; then
			eval "${base_var}=\"\$${base_var} \$${kc_var}\"; export ${base_var}"
		fi
	done

	# Determine if we should enable shared or not
	if [ "${staticpkg}" = "0" ]; then
		tryopts=("--enable-shared" "--disable-shared")
	elif [ "${staticpkg}" = "-1" ]; then
		tryopts=("--enable-shared")
	elif [ "${pkg_no_support_for_static}" = '1' ]; then
		tryopts=('')
	else
		tryopts=("--disable-shared")
	fi

	save_cflags="${CFLAGS}"
	for tryopt in "${tryopts[@]}" __fail__; do
		if [ "${tryopt}" = "__fail__" ]; then
			return 1
		fi

		# Clean up, if needed
		make distclean >/dev/null 2>/dev/null
		if [ "${tryopt}" = "--enable-shared" -o "${tryopt}" = '' ]; then
			isshared="1"
		else
			isshared="0"
		fi

		# If build a static package for KitDLL, ensure that we use PIC
		# so that it can be linked into the shared object
................................................................................
				sed 's@XXX_TCL_STUBS@USE_TCL_STUBS@g' configure > configure.new
			fi

			cat configure.new > configure
			rm -f configure.new
		fi

		configure_opts=($tryopt --prefix="${installdir}" --exec-prefix="${installdir}" --libdir="${installdir}/lib" --with-tcl="${TCLCONFIGDIR}" "${configure_extra[@]}" ${CONFIGUREEXTRA})
		configure_opts_new=()
		for configure_opt in "${configure_opts[@]}"; do
			ignore_this_opt='0'
			for ignore_opt in "${pkg_ignore_opts[@]}"; do
				case "${configure_opt}" in
					"${ignore_opt}"|"${ignore_opt}"=*)
						ignore_this_opt='1'
						;;
				esac
			done

			if [ "${ignore_this_opt}" = '1' ]; then
				continue
			fi

			configure_opts_new+=("${configure_opt}")
		done
		configure_opts=("${configure_opts_new[@]}")

		"${pkg_path_to_configure:-./configure}" "${configure_opts[@]}" && break
	done

	return 0
}

function postconfigure() {
	:
................................................................................

function preinstall() {
	:
}

function install() {
	mkdir -p "${installdir}/lib" || return 1
	${MAKE:-make} tcllibdir="${installdir}/lib" TCL_PACKAGE_PATH="${installdir}/lib" "${make_extra[@]}" install || return 1
}

function postinstall() {
	:
}

function createruntime() {