diff options
author | Gregory M. Tuner <gmt@be-evil.net> | 2013-12-25 06:49:36 -0800 |
---|---|---|
committer | Gregory M. Tuner <gmt@be-evil.net> | 2013-12-25 06:49:36 -0800 |
commit | b861a126114e596db6d2de3914cfb85e4b90e99c (patch) | |
tree | 05311f5e69a007967fa816ad5aff6ec047b1918a /eclass/autotools-utils.eclass | |
parent | media-libs/cogl: refactor and sync with upstream (diff) | |
download | gmt-b861a126114e596db6d2de3914cfb85e4b90e99c.tar.gz gmt-b861a126114e596db6d2de3914cfb85e4b90e99c.tar.bz2 gmt-b861a126114e596db6d2de3914cfb85e4b90e99c.zip |
eclass/autotools-utils: new feature: AUTOTOOLS_TEST_MAKE variable
Signed-off-by: Gregory M. Tuner <gmt@be-evil.net>
Diffstat (limited to 'eclass/autotools-utils.eclass')
-rw-r--r-- | eclass/autotools-utils.eclass | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/eclass/autotools-utils.eclass b/eclass/autotools-utils.eclass index 645b809..a22b586 100644 --- a/eclass/autotools-utils.eclass +++ b/eclass/autotools-utils.eclass @@ -201,6 +201,18 @@ EXPORT_FUNCTIONS src_prepare src_configure src_compile src_install src_test # If set to 'none', no .la files will be pruned ever. Use in corner # cases only. +# @ECLASS-VARIABLE: AUTOTOOLS_TEST_MAKE +# @DEFAULT_UNSET +# @DESCRIPTION: +# Set this to the name of an executable or function to invoke +# instead of "emake" during the src_test phase. If unset, +# emake is used. +# +# Example: +# @CODE +# AUTOTOOLS_TEST_MAKE=Xemake +# @CODE + # Determine using IN or OUT source build _check_build_dir() { debug-print-function ${FUNCNAME} "$@" @@ -729,7 +741,7 @@ autotools-utils_src_test() { || die 'autotools-utils.eclass: myemaketestargs has to be an array.' _check_build_dir - local myemaketestargs=("${myemaketestargs[@]}") otheremaketestargs=("$@") _how="dont" + local myemaketestargs=("${myemaketestargs[@]}") otheremaketestargs=("$@") _how="dont" _what=emake pushd "${BUILD_DIR}" > /dev/null || die if make -n check "${myemaketestargs[@]}" "${otheremaketestargs[@]}" &>/dev/null 2>&1 ; then @@ -737,10 +749,11 @@ autotools-utils_src_test() { elif make -n test "${myemaketestargs[@]}" "${otheremaketestargs[@]}" &>/dev/null 2>&1 ; then _how="test" fi + [[ ${AUTOTOOLS_TEST_MAKE} ]] && _what="${AUTOTOOLS_TEST_MAKE}" [[ ${_how} != dont ]] && otheremaketestargs+=("${_how}") if ehook_fire autotools-utils-pre_src_test ; then [[ ${_how} != dont ]] && - emake "${myemaketestargs[@]}" "${otheremaketestargs[@]}" || die 'emake check failed.' + ${_what} "${myemaketestargs[@]}" "${otheremaketestargs[@]}" || die 'emake check failed.' fi ehook_fire autotools-utils-post_src_test -u popd > /dev/null || die |