ROS: update #681
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CONDA | |
| # This determines when this workflow is run | |
| on: | |
| push: | |
| paths-ignore: | |
| - 'doc/**' | |
| - '.gitlab-ci.yml' | |
| - '.gitignore' | |
| - '.pre-commit-config.yaml' | |
| - '*.md' | |
| - 'LICENSE' | |
| - 'pyproject.toml' | |
| - 'package.xml' | |
| - 'dependencies.rosintall' | |
| pull_request: | |
| paths-ignore: | |
| - 'doc/**' | |
| - '.gitlab-ci.yml' | |
| - '.gitignore' | |
| - '.pre-commit-config.yaml' | |
| - '*.md' | |
| - 'LICENSE' | |
| - 'pyproject.toml' | |
| - 'package.xml' | |
| - 'dependencies.rosintall' | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| crocoddyl-conda: | |
| name: (${{ matrix.os }}, ${{ matrix.compiler }}, codegen ${{ matrix.codegen_support }}, multi-threading, ipopt, ${{ matrix.build_type }}) | |
| runs-on: ${{ matrix.os }} | |
| env: | |
| CCACHE_BASEDIR: "${GITHUB_WORKSPACE}" | |
| CCACHE_DIR: "${GITHUB_WORKSPACE}/.ccache" | |
| CCACHE_COMPRESS: true | |
| CCACHE_COMPRESSLEVEL: 5 | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - os: ubuntu-latest | |
| compiler: gcc | |
| build_type: Release | |
| codegen_support: ON | |
| - os: ubuntu-latest | |
| compiler: gcc | |
| build_type: Debug | |
| codegen_support: OFF | |
| - os: macos-latest | |
| compiler: clang | |
| build_type: Release | |
| codegen_support: ON | |
| - os: macos-latest | |
| compiler: clang | |
| build_type: Debug | |
| codegen_support: OFF | |
| steps: | |
| - uses: actions/checkout@v5 | |
| with: | |
| submodules: recursive | |
| - uses: actions/cache@v4 | |
| with: | |
| path: ${{ env.CCACHE_DIR }} | |
| key: ccache-conda-${{ matrix.os }}-${{ matrix.build_type }}-${{ matrix.python-version }}-${{ github.run_id }} | |
| restore-keys: ccache-conda-${{ matrix.os }}-${{ matrix.build_type }}-${{ matrix.python-version }}- | |
| - uses: conda-incubator/setup-miniconda@v3 | |
| with: | |
| activate-environment: crocoddyl | |
| auto-update-conda: true | |
| environment-file: .github/workflows/conda/conda-env.yml | |
| python-version: ${{ matrix.python-version }} | |
| auto-activate-base: false | |
| - name: Install conda dependencies | |
| shell: bash -l {0} | |
| run: | | |
| conda activate crocoddyl | |
| conda install cmake ccache -c conda-forge | |
| conda install llvm-openmp libcxx -c conda-forge | |
| conda install ffmpeg -c conda-forge | |
| conda list | |
| - name: Install example-robot-data | |
| shell: bash -l {0} | |
| run: | | |
| conda activate crocoddyl | |
| mkdir third-party && cd third-party | |
| git clone --recursive https://github.com/Gepetto/example-robot-data.git | |
| cd example-robot-data && mkdir build && cd build | |
| cmake .. -DCMAKE_INSTALL_PREFIX=$CONDA_PREFIX | |
| make install | |
| - name: Build Crocoddyl | |
| shell: bash -l {0} | |
| run: | | |
| conda activate crocoddyl | |
| echo $CONDA_PREFIX | |
| mkdir build | |
| cd build | |
| cmake .. \ | |
| -DCMAKE_CXX_COMPILER_LAUNCHER=ccache \ | |
| -DCMAKE_CXX_FLAGS_DEBUG="" \ | |
| -DCMAKE_INSTALL_PREFIX=$CONDA_PREFIX -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \ | |
| -DBUILD_WITH_CODEGEN_SUPPORT=${{ matrix.codegen_support }} -DPYTHON_EXECUTABLE=$(which python3) \ | |
| -DBUILD_WITH_MULTITHREADS=ON -DINSTALL_DOCUMENTATION=ON -DGENERATE_PYTHON_STUBS=ON \ | |
| -DOpenMP_ROOT=$CONDA_PREFIX | |
| make | |
| make VERBOSE=1 | |
| - name: Run unit tests | |
| shell: bash -l {0} | |
| run: | | |
| conda activate crocoddyl | |
| cd build | |
| export CTEST_OUTPUT_ON_FAILURE=1 | |
| ctest --output-on-failure | |
| - name: Install Crocoddyl | |
| shell: bash -l {0} | |
| run: | | |
| cd build | |
| make install | |
| - name: Uninstall Crocoddyl | |
| shell: bash -l {0} | |
| run: | | |
| cd build | |
| make uninstall |