27 lines
1.9 KiB
Bash
27 lines
1.9 KiB
Bash
#!/usr/bin/env bash
|
|||
|
|
# Build original algorithms in isolated prefixes. Never installs a device SDK.
|
||
|
|
set -eo pipefail
|
||
|
|
BR_SIM_REPO=$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")/../.." && pwd)
|
||
|
|
cd "$BR_SIM_REPO"
|
||
|
|
BR_SIM_JOBS=${BR_SIM_BUILD_JOBS:-2}
|
||
|
|
[[ "$BR_SIM_JOBS" =~ ^[1-9][0-9]*$ ]] || { echo 'BR_SIM_BUILD_JOBS must be a positive integer' >&2; exit 2; }
|
||
|
|
source /opt/ros/humble/setup.bash
|
||
|
|
export PATH="/usr/bin:$PATH" MAKEFLAGS="-j$BR_SIM_JOBS" CMAKE_BUILD_PARALLEL_LEVEL="$BR_SIM_JOBS"
|
||
|
|
BR_SIM_CMAKE=(-DPython3_EXECUTABLE=/usr/bin/python3 -DCMAKE_BUILD_TYPE=Release)
|
||
|
|
colcon --log-base sim_ws/log/build_interfaces build --base-paths minco_ws/src/perception/livox_ros_driver2 \
|
||
|
|
--packages-select livox_ros_driver2 --build-base sim_ws/build/localization --install-base sim_ws/install/localization \
|
||
|
|
--executor sequential --cmake-args "${BR_SIM_CMAKE[@]}" -DLIVOX_INTERFACES_ONLY=ON -DBUILD_TESTING=OFF
|
||
|
|
source sim_ws/install/localization/setup.bash
|
||
|
|
colcon --log-base sim_ws/log/build_localization build --base-paths minco_ws/src/perception/Point-LIO \
|
||
|
|
--packages-select point_lio --build-base sim_ws/build/localization --install-base sim_ws/install/localization \
|
||
|
|
--executor sequential --cmake-args "${BR_SIM_CMAKE[@]}" -DBUILD_TESTING=OFF
|
||
|
|
source sim_ws/install/localization/setup.bash
|
||
|
|
colcon --log-base sim_ws/log/build_navigation build --base-paths minco_ws/src/scan \
|
||
|
|
--packages-up-to scan_planner step_blocker --build-base sim_ws/build/navigation --install-base sim_ws/install/navigation \
|
||
|
|
--executor sequential --cmake-args "${BR_SIM_CMAKE[@]}" -DBUILD_TESTING=ON
|
||
|
|
source sim_ws/install/navigation/setup.bash
|
||
|
|
colcon --log-base sim_ws/log/build_classic build --base-paths sim_ws/src \
|
||
|
|
--packages-select robocon_gazebo r2027_robot_description br_sim_bringup \
|
||
|
|
--build-base sim_ws/build/classic --install-base sim_ws/install/classic --symlink-install \
|
||
|
|
--executor sequential --cmake-args "${BR_SIM_CMAKE[@]}" -DBUILD_TESTING=OFF
|