Bigfoot / Build & Test Debug with ./ConanProfiles/host/clang (Unity Build: OFF, Variant: game) (push) Successful in 44s
Bigfoot / Build & Test Debug with ./ConanProfiles/host/clang (Unity Build: ON, Variant: game) (push) Successful in 29s
Bigfoot / Build & Test Debug with ./ConanProfiles/host/clang (Unity Build: OFF, Variant: toolmode) (push) Successful in 46s
Bigfoot / Build & Test Debug with ./ConanProfiles/host/clang (Unity Build: ON, Variant: toolmode) (push) Successful in 30s
Bigfoot / Build & Test Debug with ./ConanProfiles/host/clang_asan (Unity Build: OFF, Variant: game) (push) Successful in 1m21s
Bigfoot / Build & Test Debug with ./ConanProfiles/host/clang_asan (Unity Build: ON, Variant: game) (push) Successful in 1m3s
Bigfoot / Build & Test Debug with ./ConanProfiles/host/clang_asan (Unity Build: OFF, Variant: toolmode) (push) Successful in 1m25s
Bigfoot / Build & Test Debug with ./ConanProfiles/host/clang_asan (Unity Build: ON, Variant: toolmode) (push) Successful in 1m8s
Bigfoot / Build & Test RelWithDebInfo with ./ConanProfiles/host/clang_asan (Unity Build: ON, Variant: game) (push) Successful in 1m9s
Bigfoot / Build & Test RelWithDebInfo with ./ConanProfiles/host/clang_asan (Unity Build: OFF, Variant: toolmode) (push) Successful in 1m34s
Bigfoot / Build & Test RelWithDebInfo with ./ConanProfiles/host/clang_asan (Unity Build: ON, Variant: toolmode) (push) Successful in 1m13s
Bigfoot / Build & Test Release with ./ConanProfiles/host/clang (Unity Build: OFF, Variant: game) (push) Successful in 37s
Bigfoot / Build & Test Release with ./ConanProfiles/host/clang (Unity Build: ON, Variant: game) (push) Successful in 28s
Bigfoot / Build & Test Release with ./ConanProfiles/host/clang (Unity Build: OFF, Variant: toolmode) (push) Successful in 57s
Bigfoot / Sonarqube (push) Successful in 6m0s
sonarqube ERROR
Bigfoot / Build & Test RelWithDebInfo with ./ConanProfiles/host/clang (Unity Build: OFF, Variant: game) (push) Successful in 49s
Bigfoot / Build & Test RelWithDebInfo with ./ConanProfiles/host/clang (Unity Build: ON, Variant: game) (push) Successful in 30s
Bigfoot / Build & Test RelWithDebInfo with ./ConanProfiles/host/clang (Unity Build: OFF, Variant: toolmode) (push) Successful in 52s
Bigfoot / Build & Test RelWithDebInfo with ./ConanProfiles/host/clang (Unity Build: ON, Variant: toolmode) (push) Successful in 36s
Bigfoot / Build & Test RelWithDebInfo with ./ConanProfiles/host/clang_asan (Unity Build: OFF, Variant: game) (push) Successful in 1m23s
Bigfoot / Build & Test Release with ./ConanProfiles/host/clang (Unity Build: ON, Variant: toolmode) (push) Successful in 44s
Bigfoot / Build & Test Release with ./ConanProfiles/host/clang_asan (Unity Build: OFF, Variant: game) (push) Successful in 59s
Bigfoot / Build & Test Release with ./ConanProfiles/host/clang_asan (Unity Build: ON, Variant: game) (push) Successful in 51s
Bigfoot / Build & Test Release with ./ConanProfiles/host/clang_asan (Unity Build: OFF, Variant: toolmode) (push) Successful in 1m5s
Bigfoot / Build & Test Release with ./ConanProfiles/host/clang_asan (Unity Build: ON, Variant: toolmode) (push) Successful in 56s
Bigfoot / Clang Format Checks (push) Successful in 13s
Bigfoot / Sonarqube (pull_request) Failing after 5m14s
Implementing an asset management system BigFile is a sqlite database, for toolmode Sasquatch is a custom binary file, for gamemode Assets are built from flatbuffers References allow to get an Asset, from an UUID, from anywhere in the code HardReference refcount the asset and allow automatic removal Reviewed-on: #1 Co-authored-by: Romain BOULLARD <romain.boullard@protonmail.com>
124 lines
4.7 KiB
Bash
124 lines
4.7 KiB
Bash
#!/usr/bin/env bash
|
|
set -euo pipefail
|
|
|
|
# ─── Validate arguments ───────────────────────────────────────────────────────
|
|
if [[ $# -lt 1 ]]; then
|
|
echo "Usage: $(basename "$0") [force|missing] [Release|RelWithDebInfo|Debug]"
|
|
echo " force - Rebuild all packages from source"
|
|
echo " missing - Only build packages not already cached"
|
|
echo " build_type (optional) - One of: Release, RelWithDebInfo, Debug"
|
|
echo " If omitted, all build types are processed"
|
|
exit 1
|
|
fi
|
|
|
|
case "${1:-}" in
|
|
force) build_option="--build=*" ;;
|
|
missing) build_option="--build=missing" ;;
|
|
*)
|
|
echo "Usage: $(basename "$0") [force|missing] [Release|RelWithDebInfo|Debug]"
|
|
echo " force - Rebuild all packages from source"
|
|
echo " missing - Only build packages not already cached"
|
|
exit 1
|
|
;;
|
|
esac
|
|
|
|
# ─── Validate optional build_type argument ────────────────────────────────────
|
|
all_build_types=(Release RelWithDebInfo Debug)
|
|
|
|
if [[ -n "${2:-}" ]]; then
|
|
case "${2}" in
|
|
Release|RelWithDebInfo|Debug)
|
|
build_types=("${2}")
|
|
;;
|
|
*)
|
|
echo "ERROR: Invalid build type '${2}'. Must be one of: Release, RelWithDebInfo, Debug"
|
|
exit 1
|
|
;;
|
|
esac
|
|
else
|
|
build_types=("${all_build_types[@]}")
|
|
fi
|
|
|
|
# ─── Register remote (skip if already registered) ─────────────────────────────
|
|
if conan remote list 2>/dev/null | grep -qi "bigfootpackages"; then
|
|
echo "Conan remote 'bigfootpackages' already registered, skipping."
|
|
else
|
|
echo "Adding Conan remote: bigfootpackages"
|
|
if ! conan remote add bigfootpackages https://conan.romainboullard.com/artifactory/api/conan/BigfootPackages; then
|
|
echo "ERROR: Failed to add Conan remote."
|
|
exit 1
|
|
fi
|
|
fi
|
|
|
|
# ─── Shared flags ─────────────────────────────────────────────────────────────
|
|
conan_common_toolmode=(
|
|
--remote=bigfootpackages
|
|
-pr:h=./ConanProfiles/host/clang
|
|
-pr:b=./ConanProfiles/build/clang
|
|
-of build-linux-toolmode
|
|
-o "bigfoot/*:build_tests=True"
|
|
-o "bigfoot/*:build_benchmarks=True"
|
|
-o "bigfoot/*:tracy=True"
|
|
-o "bigfoot/*:vulkan=True"
|
|
-o "bigfoot/*:toolmode=True"
|
|
)
|
|
|
|
conan_common_game=(
|
|
--remote=bigfootpackages
|
|
-pr:h=./ConanProfiles/host/clang
|
|
-pr:b=./ConanProfiles/build/clang
|
|
-of build-linux-game
|
|
-o "bigfoot/*:build_tests=True"
|
|
-o "bigfoot/*:build_benchmarks=True"
|
|
-o "bigfoot/*:tracy=True"
|
|
-o "bigfoot/*:vulkan=True"
|
|
-o "bigfoot/*:toolmode=False"
|
|
)
|
|
|
|
# ─── Install dependencies for each build type ─────────────────────────────────
|
|
for build_type in "${build_types[@]}"; do
|
|
echo
|
|
echo "[${build_type}] Installing dependencies..."
|
|
if ! conan install . "${conan_common_toolmode[@]}" ${build_option} -s:h "build_type=${build_type}"; then
|
|
echo "ERROR: conan install failed for build type ${build_type}"
|
|
exit 1
|
|
fi
|
|
if ! conan install . "${conan_common_game[@]}" ${build_option} -s:h "build_type=${build_type}"; then
|
|
echo "ERROR: conan install failed for build type ${build_type}"
|
|
exit 1
|
|
fi
|
|
echo "[${build_type}] Done."
|
|
done
|
|
|
|
echo
|
|
echo "All build types installed successfully."
|
|
|
|
# ─── Configure CMake for each build type ─────────────────────────────────────
|
|
echo
|
|
echo "Configuring CMake for each build type..."
|
|
|
|
for build_type in "${build_types[@]}"; do
|
|
echo
|
|
echo "[${build_type}] Activating build environment..."
|
|
|
|
for variant in toolmode game; do
|
|
# shellcheck disable=SC1090
|
|
source "build-linux-${variant}/build/${build_type}/generators/conanbuild.sh"
|
|
|
|
mkdir -p "graphviz-linux-${variant}/${build_type}"
|
|
|
|
echo "[${build_type}] Running CMake (${variant})..."
|
|
if ! cmake -S . -B "build-linux-${variant}/${build_type}" \
|
|
--toolchain "build-linux-${variant}/build/${build_type}/generators/conan_toolchain.cmake" \
|
|
-DCMAKE_BUILD_TYPE="${build_type}" \
|
|
-G "Ninja" \
|
|
--graphviz="graphviz-linux-${variant}/${build_type}/graph.dot"; then
|
|
echo "ERROR: CMake configuration failed for build type ${build_type} (${variant})."
|
|
exit 1
|
|
fi
|
|
done
|
|
echo "[${build_type}] Done."
|
|
done
|
|
|
|
echo
|
|
echo "CMake configuration successful." |