Meta: Ensure BUILD_LAGOM is set when running serenity.sh test lagom

If the superbuild created the lagom binary directory, it won't set
BUILD_LAGOM=ON in the CMake cache for that binary directory. Insert a
check into build_target() to make sure that if the user explicitly asks
for the lagom target, we have all our ducks in a row.
This commit is contained in:
Andrew Kaster 2021-09-16 03:02:44 -06:00 committed by Brian Gianforcaro
parent 454a839f49
commit d0506730b8
Notes: sideshowbarker 2024-07-18 03:50:36 +09:00

View file

@ -199,6 +199,11 @@ run_tests() {
}
build_target() {
if [ "$TARGET" = "lagom" ]; then
# Ensure that all lagom binaries get built, in case user first
# invoked superbuild for serenity target that doesn't set -DBUILD_LAGOM=ON
cmake -S "$SERENITY_SOURCE_DIR/Meta/Lagom" -B "$BUILD_DIR" -DBUILD_LAGOM=ON
fi
# With zero args, we are doing a standard "build"
# With multiple args, we are doing an install/image/run
if [ $# -eq 0 ]; then