From a0f5214d3cd0d9f27f450a6842e14ebce42f6023 Mon Sep 17 00:00:00 2001 From: Lucio Andrés Illanes Albornoz (arab, vxp) Date: Apr 15 2017 13:19:43 +0000 Subject: build.sh, etc/build.usage: adds -R: [i]gnore build failures and continue building (relaxed mode) (via midipix.) --- diff --git a/build.sh b/build.sh index e88c2e5..c7e3c0b 100755 --- a/build.sh +++ b/build.sh @@ -13,6 +13,7 @@ case ${1} in -C) ARG_CHECK_UPDATES=1; ;; -N) ARG_OFFLINE=1; ;; -i) ARG_IGNORE_SHA256SUMS=1; ;; +-R) ARG_RELAXED=1; ;; -t*) ARG_TARBALL=1; [ "${1#-t.}" != "${1}" ] && TARBALL_SUFFIX="${1#-t.}"; ;; -v) ARG_VERBOSE=1; ;; -x) ARG_XTRACE=1; set -o xtrace; ;; @@ -113,7 +114,8 @@ for BUILD_TARGET_LC in $(subst_tgts invariants ${BUILD_TARGETS_META:-world}); do 0) log_msg succ "Finished \`${PKG_NAME}' build."; : $((BUILD_NFINI+=1)); continue; ;; *) log_msg fail "Build failed in \`${PKG_NAME}' (last return code ${BUILD_SCRIPT_RC}.)."; - : $((BUILD_NFAIL+=1)); break; ;; + : $((BUILD_NFAIL+=1)); + [ ${ARG_RELAXED:-0} -eq 0 ] && break || continue; ;; esac; done; if [ "${BUILD_SCRIPT_RC:-0}" -ne 0 ]; then diff --git a/etc/build.usage b/etc/build.usage index 7f2d737..4afb450 100644 --- a/etc/build.usage +++ b/etc/build.usage @@ -1,5 +1,5 @@ usage: ./build.sh [-x] [-a nt32|nt64] [-b debug|release] [-c] [-C] [-h] - [-i] [-N] [-r package[,...][:step]] [-t[.gz|.bz2|.xz] + [-i] [-N] [-r package[,...][:step]] [-R] [-t[.gz|.bz2|.xz] [-v] [[ ...]] -x Set the xtrace sh(1)ell option for debugging purposes. -a nt32|nt64 Selects 32-bit or 64-bit architecture; defaults to nt64. @@ -14,6 +14,7 @@ usage: ./build.sh [-x] [-a nt32|nt64] [-b debug|release] [-c] [-C] [-h] the optionally specified step. Currently defined steps are: fetch extract build_dir patch_pre autoconf patch configure clean build install. + -R Ignore build failures and continue building (relaxed mode.) -t[.gz|.bz2|.xz] Produce binary distribution and source tarballs containing ${PREFIX} sans ${WORKDIR} and ${PREFIX}/src/midipix_build and ${WORKDIR} sans top- level regular files at the end of a build with zero failures. The