altomaltes / cross / slibtool

Forked from cross/slibtool 2 years ago
Clone

Blame project/config/cfgfini.sh

f3cd93
# cfgfini.sh: require slibtool's --dumpmachine output to be
f3cd93
#             both accurate and complete also during the
f3cd93
#             toolchain's initial bootstrapping phase.
f3cd93
# invoked from within the project-agnostic configure script.
f3cd93
f3cd93
# this file is covered by COPYING.SLIBTOOL.
f3cd93
f3cd93
slibtool_cfgfini_error_msg()
f3cd93
{
f3cd93
	printf '%s\n' "$@" >&2
f3cd93
	printf '%s\n' "$@" >&3
f3cd93
}
f3cd93
f3cd93
slibtool_cfgfini()
f3cd93
{
f3cd93
	if [ "${mb_cchost_set:-}" = 'yes' ]; then
f3cd93
		return 0;
f3cd93
f3cd93
	elif [ -n "$ccenv_host_dumpmachine_switch" ]; then
f3cd93
		return 0;
f3cd93
	fi
f3cd93
f3cd93
	slibtool_cfgfini_error_msg
f3cd93
	slibtool_cfgfini_error_msg "$mb_package: the host compiler, \`$ccenv_host_cc\`, does not provide a -dumpmachine switch."
f3cd93
	slibtool_cfgfini_error_msg "$mb_package: please specify the host manually either by passing the --cchost argument to"
f3cd93
	slibtool_cfgfini_error_msg "             $mb_package's configure script, or by setting the CCHOST environment variable."
f3cd93
	slibtool_cfgfini_error_msg "$mb_package: this requirement aims to ensure a complete and accurate \`slibtool --dumpmachine\`"
f3cd93
	slibtool_cfgfini_error_msg "             output also during the toolchain's initial bootstrapping phase."
f3cd93
	slibtool_cfgfini_error_msg
f3cd93
f3cd93
	config_failure
f3cd93
}
f3cd93
f3cd93
slibtool_cfgfini