Blame subr/pkg_configure_clean.subr

Lucio Andrés Illanes Albornoz 3e5303
#
Lucio Andrés Illanes Albornoz 3e5303
# set +o errexit -o noglob -o nounset is assumed.
Lucio Andrés Illanes Albornoz 3e5303
#
Lucio Andrés Illanes Albornoz 3e5303
Lucio Andrés Illanes Albornoz 3e5303
pkg_configure_clean() {
Lucio Andrés Illanes Albornoz 3e5303
	local _group_name="${1}" _pkg_name="${2}" _restart_at="${3}";
Lucio Andrés Illanes Albornoz 3e5303
Lucio Andrés Illanes Albornoz 3e5303
	if ex_pkg_state_test									\
Lucio Andrés Illanes Albornoz 3e5303
			"${_pkg_name}"								\
Lucio Andrés Illanes Albornoz 3e5303
			"configure_patch_pre,configure_autotools,configure_patch,configure"	\
Lucio Andrés Illanes Albornoz 3e5303
			"${_restart_at}"; then
Lucio Andrés Illanes Albornoz 3e5303
		if [ "${PKG_BUILD_DIR:-}" != "${PKG_SUBDIR:-}" ]; then
Lucio Andrés Illanes Albornoz 3e5303
			rtl_fileop rm "${PKG_BUILD_DIR}" || return 1;
Lucio Andrés Illanes Albornoz 3e5303
			rtl_fileop mkdir "${PKG_BUILD_DIR}" || return 1;
Lucio Andrés Illanes Albornoz 3e5303
			rtl_fileop cd "${PKG_BUILD_DIR}" || return 1;
Lucio Andrés Illanes Albornoz 3e5303
		fi;
Lucio Andrés Illanes Albornoz 3e5303
	fi;
Lucio Andrés Illanes Albornoz 3e5303
};
Lucio Andrés Illanes Albornoz 3e5303
Lucio Andrés Illanes Albornoz 3e5303
# vim:filetype=sh