Skip to content

docs: regenerate example outputs against current master #1045

docs: regenerate example outputs against current master

docs: regenerate example outputs against current master #1045

Workflow file for this run

---
name: CMake MKL
on:
push:
pull_request:
workflow_dispatch:
schedule:
- cron: '0 6 * * 1'
jobs:
linux:
strategy:
fail-fast: false
matrix:
# BLAS64 requires DLONG for MKL: the ILP64 interface layer must match
# the pardiso_64 entry point (which needs 64-bit integer indices).
include:
- blas64: OFF
dlong: OFF
- blas64: OFF
dlong: ON
- blas64: ON
dlong: ON
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- name: Intel Apt repository
run: |
wget https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS-2023.PUB
sudo apt-key add GPG-PUB-KEY-INTEL-SW-PRODUCTS-2023.PUB
rm GPG-PUB-KEY-INTEL-SW-PRODUCTS-2023.PUB
echo "deb https://apt.repos.intel.com/oneapi all main" | sudo tee /etc/apt/sources.list.d/oneAPI.list
sudo apt-get update
- name: Install Intel oneAPI MKL
run: sudo apt-get install -y intel-oneapi-mkl-devel
- name: Setup Intel oneAPI environment
run: |
ONEAPI=/opt/intel/oneapi
echo "MKLROOT=$ONEAPI/mkl/latest" >> $GITHUB_ENV
# The compiler directory contains libiomp5 (Intel OpenMP runtime).
# Both the linker (-L) and runtime loader (LD_LIBRARY_PATH) need it.
echo "OMPROOT=$ONEAPI/compiler/latest" >> $GITHUB_ENV
echo "LD_LIBRARY_PATH=$ONEAPI/mkl/latest/lib/intel64:$ONEAPI/compiler/latest/lib:$LD_LIBRARY_PATH" >> $GITHUB_ENV
- name: checkout project code
uses: actions/checkout@v7
- name: Build SCS MKL and test
run: |
mkdir out
export INSTALL_DIR=$PWD/out
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$INSTALL_DIR/lib
mkdir build
cd build
cmake -DBUILD_TESTING=ON -DBLAS64=${{ matrix.blas64 }} -DDLONG=${{ matrix.dlong }} -DCMAKE_INSTALL_PREFIX:PATH=$INSTALL_DIR ..
make
make install
ctest --output-on-failure
# The qp.c example uses int (not scs_int) for matrix indices,
# so it only works with 32-bit ints (DLONG=OFF).
if [[ "${{ matrix.dlong }}" == "OFF" ]]; then
cd ../docs/src/examples/
gcc -I$INSTALL_DIR/include/scs -L$INSTALL_DIR/lib/ qp.c -o qp.out -lscsmkl
./qp.out
fi