#!/usr/bin/env bash # Eigen, the external find_package(Eigen3 3.4) dependency, into /opt/eigen-3.4. Header-only; # 3.4.x is required because Eigen's same-major-version rule rejects 5.x. # # Shared by all four build images (docker/*/Dockerfile). The build context is docker/, so each # Dockerfile reaches this with COPY common/. Version inputs come from that Dockerfile's ARGs. set -eux; \ cd /tmp; \ git clone --depth 1 --branch ${EIGEN_VERSION} https://gitlab.com/libeigen/eigen.git; \ cmake -G Ninja -S eigen -B eigen-build -DCMAKE_INSTALL_PREFIX=/opt/eigen-3.4 \ -DEIGEN_BUILD_BLAS=OFF -DEIGEN_BUILD_LAPACK=OFF -DEIGEN_BUILD_DOC=OFF -DBUILD_TESTING=OFF; \ cmake --install eigen-build; \ cd /; rm -rf /tmp/eigen /tmp/eigen-build