diff options
author | Lucio Andrés Illanes Albornoz <lucio@lucioillanes.de> | 2020-03-11 17:37:15 +0000 |
---|---|---|
committer | Lucio Andrés Illanes Albornoz <lucio@lucioillanes.de> | 2020-03-11 17:37:15 +0000 |
commit | 5f8a1589af2cb737566fc44fbb29f95b478e2e8c (patch) | |
tree | efa258f6c989beaf341f49119f168f8620fee049 | |
parent | f243bed357feef6e7554767c44a6b6c97b11c3ec (diff) | |
download | midipix_build-5f8a1589af2cb737566fc44fbb29f95b478e2e8c.tar.bz2 midipix_build-5f8a1589af2cb737566fc44fbb29f95b478e2e8c.tar.xz |
subr/build_init.subr:buildp_init_getopts(): --dump-on-abort excludes -R.
etc/{build.usage,README.md}: updated.
-rw-r--r-- | etc/README.md | 2 | ||||
-rw-r--r-- | etc/build.usage | 2 | ||||
-rw-r--r-- | subr/build_init.subr | 26 |
3 files changed, 17 insertions, 13 deletions
diff --git a/etc/README.md b/etc/README.md index 31bbaff2..e501b355 100644 --- a/etc/README.md +++ b/etc/README.md @@ -229,7 +229,7 @@ usage: ./build.sh [-a nt32|nt64] [-b debug|release] [-C dir[,..]] [-d] [-D kind[ new commits.
--debug-minipix Don't strip(1) minipix binaries to facilitate debugging minipix.
--dump-on-abort Produce package environment dump files on build failure to be
- used in conjuction with pkg_shell.sh script.
+ used in conjuction with pkg_shell.sh script (excludes -R.)
<group>[ ..] One of: dev_packages, dist, host_deps, host_deps_rpm,
host_toolchain, host_tools, minipix, native_packages,
native_runtime, native_toolchain, native_tools.
diff --git a/etc/build.usage b/etc/build.usage index d9453177..f287b98c 100644 --- a/etc/build.usage +++ b/etc/build.usage @@ -48,7 +48,7 @@ usage: ./build.sh [-a nt32|nt64] [-b debug|release] [-C dir[,..]] [-d] [-D kind[ new commits. --debug-minipix Don't strip(1) minipix binaries to facilitate debugging minipix. --dump-on-abort Produce package environment dump files on build failure to be - used in conjuction with pkg_shell.sh script. + used in conjuction with pkg_shell.sh script (excludes -R.) <group>[ ..] One of: dev_packages, dist, host_deps, host_deps_rpm, host_toolchain, host_tools, minipix, native_packages, native_runtime, native_toolchain, native_tools. diff --git a/subr/build_init.subr b/subr/build_init.subr index e07facaf..c5f91174 100644 --- a/subr/build_init.subr +++ b/subr/build_init.subr @@ -162,18 +162,22 @@ buildp_init_getopts() { fi; done; if [ "${_rc}" -eq 0 ]; then - while [ ${#} -gt 0 ]; do - if [ "${1#\*}" != "${1}" ]; then - BUILD_GROUPS_INHIBIT_DEPS=1; _arg="${1#\*}"; - else - _arg="${1}"; + if [ "${ARG_DUMP_ON_ABORT:-0}" -eq 1 ]\ + && [ "${ARG_RELAXED:-0}" -eq 1 ]; then + _rc=1; _status="Error: --dump-on-abort excludes -R."; + else while [ ${#} -gt 0 ]; do + if [ "${1#\*}" != "${1}" ]; then + BUILD_GROUPS_INHIBIT_DEPS=1; _arg="${1#\*}"; + else + _arg="${1}"; + fi; + case "${_arg}" in + *=*) rtl_set_var_unsafe "${_arg%%=*}" "${_arg#*=}"; ;; + [^a-zA-Z]*) _rc=1; _status="Error: build group names must start with [a-zA-Z] (in argument \`${_arg}'.)"; ;; + *[^_a-zA-Z]*) _rc=1; _status="Error: build group names must not contain [^_a-zA-Z] (in argument \`${_arg}'.)"; ;; + *) BUILD_GROUPS="$(rtl_lconcat "${BUILD_GROUPS}" "${_arg}")"; ;; + esac; shift; done; fi; - case "${_arg}" in - *=*) rtl_set_var_unsafe "${_arg%%=*}" "${_arg#*=}"; ;; - [^a-zA-Z]*) _rc=1; _status="Error: build group names must start with [a-zA-Z] (in argument \`${_arg}'.)"; ;; - *[^_a-zA-Z]*) _rc=1; _status="Error: build group names must not contain [^_a-zA-Z] (in argument \`${_arg}'.)"; ;; - *) BUILD_GROUPS="$(rtl_lconcat "${BUILD_GROUPS}" "${_arg}")"; ;; - esac; shift; done; fi; return "${_rc}"; }; |