acados build script improvements for mac (#24634)

* add Darwin build w/ universal2 libs

* add rust for acados rebuilds

* just build script fixes

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
pull/24575/head
Andrew 3 years ago committed by GitHub
parent 0fce5d9045
commit 1dd52ba27b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 12
      third_party/acados/build.sh

@ -1,4 +1,5 @@
#!/usr/bin/bash -e #!/usr/bin/env bash
set -e
DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" >/dev/null && pwd)" DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" >/dev/null && pwd)"
@ -9,6 +10,13 @@ if [ -f /TICI ]; then
BLAS_TARGET="ARMV8A_ARM_CORTEX_A57" BLAS_TARGET="ARMV8A_ARM_CORTEX_A57"
fi fi
ACADOS_FLAGS="-DACADOS_WITH_QPOASES=ON -UBLASFEO_TARGET -DBLASFEO_TARGET=$BLAS_TARGET"
if [[ "$OSTYPE" == "darwin"* ]]; then
ACADOS_FLAGS="$ACADOS_FLAGS -DCMAKE_OSX_ARCHITECTURES=arm64;x86_64"
ARCHNAME="Darwin"
fi
if [ ! -d acados_repo/ ]; then if [ ! -d acados_repo/ ]; then
git clone https://github.com/acados/acados.git $DIR/acados_repo git clone https://github.com/acados/acados.git $DIR/acados_repo
# git clone https://github.com/commaai/acados.git $DIR/acados_repo # git clone https://github.com/commaai/acados.git $DIR/acados_repo
@ -21,7 +29,7 @@ git submodule update --recursive --init
# build # build
mkdir -p build mkdir -p build
cd build cd build
cmake -DACADOS_WITH_QPOASES=ON -UBLASFEO_TARGET -DBLASFEO_TARGET=$BLAS_TARGET .. cmake $ACADOS_FLAGS ..
make -j20 install make -j20 install
INSTALL_DIR="$DIR/$ARCHNAME" INSTALL_DIR="$DIR/$ARCHNAME"

Loading…
Cancel
Save