From 045051ba397a3e24e280415cfa5b7cb4bfb3f3da Mon Sep 17 00:00:00 2001 From: Tobias Fischer Date: Mon, 4 Oct 2021 11:13:24 +1000 Subject: [PATCH 1/5] Add RoboStack CI --- .github/workflows/cross_platform_ci.yml | 103 ++++++++++++++++++++++++ 1 file changed, 103 insertions(+) create mode 100644 .github/workflows/cross_platform_ci.yml diff --git a/.github/workflows/cross_platform_ci.yml b/.github/workflows/cross_platform_ci.yml new file mode 100644 index 0000000..e64e802 --- /dev/null +++ b/.github/workflows/cross_platform_ci.yml @@ -0,0 +1,103 @@ +name: OpenSLAM gmapping cross-platform RoboStack build + +on: + workflow_dispatch: + pull_request: + push: + branches: + - master + - "[kmn]*-devel" + +jobs: + run_openslam_gmapping_compilation: + runs-on: ${{ matrix.os }} + name: ${{ matrix.os }} + strategy: + fail-fast: false + matrix: + os: [ubuntu-latest, macos-latest, windows-latest] + + steps: + - uses: actions/checkout@v2 + + - name: Set up Build Dependencies + uses: mamba-org/provision-with-micromamba@main + with: + environment-file: .github/ci_cross_platform_env.yml + micromamba-version: latest + + - name: Set up OpenSLAM gmapping Dependencies on Unix + if: runner.os == 'Linux' || runner.os == 'macOS' + shell: bash -l -eo pipefail {0} + run: | + micromamba activate test + export PATH=$HOME/micromamba-bin:$PATH + rosdep init + rosdep update + rosdep install --from-paths . --ignore-src -r -y + + - name: Build OpenSLAM gmapping on Unix + if: runner.os == 'Linux' || runner.os == 'macOS' + shell: bash -l -eo pipefail {0} + run: | + export CTEST_OUTPUT_ON_FAILURE=1 + + mkdir build + cd build + + cmake .. -DCMAKE_PREFIX_PATH=$CONDA_PREFIX \ + -DCMAKE_INSTALL_PREFIX=$CONDA_PREFIX \ + -DCMAKE_BUILD_TYPE=Release \ + -DCATKIN_SKIP_TESTING=OFF \ + -G "Ninja" + + ninja + # ninja run_tests + + - name: Set up OpenSLAM gmapping on Windows + if: runner.os == 'Windows' + shell: cmd + run: | + echo "Activate environment, and use rosdep to install dependencies" + call C:\Users\runneradmin\micromamba\condabin\micromamba.bat activate test + + rosdep init + rosdep update + rosdep install --from-paths . --ignore-src -r -y + + - name: Build OpenSLAM gmapping on Windows + if: runner.os == 'Windows' + shell: cmd + run: | + + echo "Remove unnecessary / colliding things from PATH" + set "PATH=%PATH:C:\ProgramData\Chocolatey\bin;=%" + set "PATH=%PATH:C:\Program Files (x86)\sbt\bin;=%" + set "PATH=%PATH:C:\Rust\.cargo\bin;=%" + set "PATH=%PATH:C:\Program Files\Git\usr\bin;=%" + set "PATH=%PATH:C:\Program Files\Git\cmd;=%" + set "PATH=%PATH:C:\Program Files\Git\mingw64\bin;=%" + set "PATH=%PATH:C:\Program Files (x86)\Subversion\bin;=%" + set "PATH=%PATH:C:\Program Files\CMake\bin;=%" + set "PATH=%PATH:C:\Program Files\OpenSSL\bin;=%" + set "PATH=%PATH:C:\Strawberry\c\bin;=%" + set "PATH=%PATH:C:\Strawberry\perl\bin;=%" + set "PATH=%PATH:C:\Strawberry\perl\site\bin;=%" + set "PATH=%PATH:c:\tools\php;=%" + set "PATH=%PATH:ostedtoolcache=%" + + call C:\Users\runneradmin\micromamba\condabin\micromamba.bat activate test + + mkdir build + cd build + SET "CTEST_OUTPUT_ON_FAILURE=1" + + cmake .. -DCMAKE_PREFIX_PATH="%CONDA_PREFIX%\Library" ^ + -DCMAKE_INSTALL_PREFIX="%CONDA_PREFIX%\Library" ^ + -DCMAKE_BUILD_TYPE=Release ^ + -DCATKIN_SKIP_TESTING=OFF ^ + -DBoost_USE_STATIC_LIBS=OFF ^ + -G "Ninja" + + ninja + # ninja run_tests From 966b751e7dd53809f7a3e04549610b0a3f9dc36d Mon Sep 17 00:00:00 2001 From: Tobias Fischer Date: Mon, 4 Oct 2021 11:15:06 +1000 Subject: [PATCH 2/5] Create ci_cross_platform_env.yml --- .github/ci_cross_platform_env.yml | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 .github/ci_cross_platform_env.yml diff --git a/.github/ci_cross_platform_env.yml b/.github/ci_cross_platform_env.yml new file mode 100644 index 0000000..26cffa0 --- /dev/null +++ b/.github/ci_cross_platform_env.yml @@ -0,0 +1,15 @@ +name: test +channels: + - robostack + - conda-forge +dependencies: + - compilers + - ninja + - cmake + - catkin_pkg + - pkg-config + - rosdep + - rosdistro + - ros-distro-mutex 0.1 noetic + - ros-noetic-catkin + - ros-noetic-ros-environment From 4cdec86eb4d80f697b9db47d80450b58277ada10 Mon Sep 17 00:00:00 2001 From: Tobias Fischer Date: Mon, 4 Oct 2021 11:28:55 +1000 Subject: [PATCH 3/5] Update cross_platform_ci.yml --- .github/workflows/cross_platform_ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/cross_platform_ci.yml b/.github/workflows/cross_platform_ci.yml index e64e802..815cd81 100644 --- a/.github/workflows/cross_platform_ci.yml +++ b/.github/workflows/cross_platform_ci.yml @@ -7,6 +7,7 @@ on: branches: - master - "[kmn]*-devel" + - patch-2 jobs: run_openslam_gmapping_compilation: From 74605c1c27ae407a614efab75421ecb3da0e2635 Mon Sep 17 00:00:00 2001 From: Tobias Fischer Date: Mon, 4 Oct 2021 11:35:04 +1000 Subject: [PATCH 4/5] Fixes --- .github/workflows/cross_platform_ci.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/cross_platform_ci.yml b/.github/workflows/cross_platform_ci.yml index 815cd81..4bb0e55 100644 --- a/.github/workflows/cross_platform_ci.yml +++ b/.github/workflows/cross_platform_ci.yml @@ -53,7 +53,6 @@ jobs: -G "Ninja" ninja - # ninja run_tests - name: Set up OpenSLAM gmapping on Windows if: runner.os == 'Windows' @@ -101,4 +100,3 @@ jobs: -G "Ninja" ninja - # ninja run_tests From 3ad955936cde4deadb784d4557e6937cd4f81228 Mon Sep 17 00:00:00 2001 From: Tobias Fischer Date: Tue, 5 Oct 2021 16:05:23 +1000 Subject: [PATCH 5/5] Remove test branch --- .github/workflows/cross_platform_ci.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/cross_platform_ci.yml b/.github/workflows/cross_platform_ci.yml index 4bb0e55..3ea2fd3 100644 --- a/.github/workflows/cross_platform_ci.yml +++ b/.github/workflows/cross_platform_ci.yml @@ -7,7 +7,6 @@ on: branches: - master - "[kmn]*-devel" - - patch-2 jobs: run_openslam_gmapping_compilation: