Skip to content
Snippets Groups Projects
Commit 1c92afaf authored by Oliver Breitwieser's avatar Oliver Breitwieser
Browse files

Streamline BUILD_THIS modifiers

Since currently not many people (except for obreitwi) are using the
build cache api, take the opportunity to streamline parameter names and
have all modifiers for `BUILD_THIS` start with `WITH`:
    * `WITH_CACHE_NAME` (renamed from `USE_CACHE_NAME`)
    * `WITHOUT_FAILED_CACHE` (renamed from `NO_FAILED_CACHE`)
    * `WITH_DEBUG`
    * `WITH_SPACK_CHANGE`

Change-Id: Ibecdd8e93516a8297373c7a0763b0d9827791dfe
parent d371edb7
No related branches found
No related tags found
No related merge requests found
......@@ -35,9 +35,9 @@ SOURCE_DIR="$(dirname "$(readlink -m "${BASH_SOURCE[0]}")")"
source "${SOURCE_DIR}/commons.sh"
# For testing changesets, see if user supplied a custom build cache with
# `USE_CACHE_NAME=<name>`. If not, check if there is a saved build cache from a
# `WITH_CACHE_NAME=<name>`. If not, check if there is a saved build cache from a
# previous build of this changeset and use that as build cache. If the comment
# contains `NO_FAILED_CACHE` we do nothing, i.e. we use the default cache.
# contains `WITHOUT_FAILED_CACHE` we do nothing, i.e. we use the default cache.
#
# Also we check if the gerrit comment message contains a spack change with
# which we should build specified via `WITH_SPACK_CHANGE=<change-id>`.
......@@ -55,11 +55,11 @@ if [ "${CONTAINER_BUILD_TYPE}" = "testing" ] \
set_debug_output_from_env
fi
if ! grep -q "\bNO_FAILED_CACHE\b" "${tmpfile_comment}"; then
if grep -q "\bUSE_CACHE_NAME=" "${tmpfile_comment}"; then
if ! grep -q "\bWITHOUT_FAILED_CACHE\b" "${tmpfile_comment}"; then
if grep -q "\bWITH_CACHE_NAME=" "${tmpfile_comment}"; then
# use specified cache
BUILD_CACHE_NAME="$(sed -nE \
-e "s:.*\<USE_CACHE_NAME=(\S*)\>.*:\1:gp" \
-e "s:.*\<WITH_CACHE_NAME=(\S*)\>.*:\1:gp" \
"${tmpfile_comment}")"
export BUILD_CACHE_NAME
else
......
......@@ -9,21 +9,21 @@ Visionary "containering"…
Start a yashicki build with this change as toplevel.
### `NO_FAILED_CACHE`
### `WITHOUT_FAILED_CACHE`
If a testing build fails, link all preserved packages and the current build
cache to a new temporary build cache under `failed/c<num>p<num>_<num>`.
Behaviour for testing builds triggered from gerrit:
* Unless the user specifies `NO_FAILED_CACHE` in the gerrit commit,
* Unless the user specifies `WITHOUT_FAILED_CACHE` in the gerrit commit,
check if there is a failed build cache for this changeset that was
created as described above and use the latest one as build cache for
the current build.
* The user can also supply `USE_CACHE_NAME=<name>` to specify a
* The user can also supply `WITH_CACHE_NAME=<name>` to specify a
different build cache to be used for this build.
### `USE_CACHE_NAME=<name>`
### `WITH_CACHE_NAME=<name>`
Use `/home/vis_jenkins/build_caches/<name>` on `conviz` as buildcache instead
of the default one. Can also be used for failed caches.
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment