Skip to content

Commit

Permalink
Enable CI build for Ubuntu 24 ARM (#3233)
Browse files Browse the repository at this point in the history
* Enable CI build for Ubuntu 24 ARM

* Trigger re-building Docker images

* Use virtualenv

* WIP: Debug

* WIP: Debug

* WIP: Debug

* WIP: Debug fix

* WIP: Debug

* WIP: Debug

* WIP: Debug

* WIP: Debug

* WIP: Disable other builds

* WIP: Disable other builds

* WIP: Debug

* WIP: Debug

* WIP: Debug

* WIP: Debug

* WIP: Debug

* WIP: Debug

* WIP: Debug

* WIP: Debug

* WIP: Debug

* WIP: Debug

* Revert debug changes

* Work-around custom runners' bug

* Update release table

* Fix Python tests

* Update .github/workflows/build-test-ubuntu-arm64.yml

Co-authored-by: Maxim Rayskiy <max.raiskii@meshinspector.com>

---------

Co-authored-by: Maxim Rayskiy <max.raiskii@meshinspector.com>
  • Loading branch information
oitel and MaxRayskiy authored Sep 4, 2024
1 parent a602f5a commit 7b9ca5c
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 5 deletions.
26 changes: 22 additions & 4 deletions .github/workflows/build-test-ubuntu-arm64.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ ubuntu20, ubuntu22 ]
os: [ ubuntu20, ubuntu22, ubuntu24 ]
config: [ Release ]
compiler: [ clang ]
include:
Expand All @@ -44,6 +44,11 @@ jobs:
cxx-compiler: /usr/bin/clang++-14
c-compiler: /usr/bin/clang-14
use-cpp-23: "OFF"
- os: ubuntu24
docker-image: meshlib/meshlib-ubuntu24-arm64:${{inputs.docker_image_tag}}
cxx-compiler: /usr/bin/clang++-18
c-compiler: /usr/bin/clang-18
use-cpp-23: "ON"
permissions:
id-token: write # This is required for requesting the JWT
contents: read # This is required for actions/checkout
Expand Down Expand Up @@ -73,8 +78,17 @@ jobs:
ln -s /usr/local/lib/meshlib-thirdparty-lib/lib ./lib
ln -s /usr/local/lib/meshlib-thirdparty-lib/include ./include
- name: Create virtualenv
run: |
python3 -m venv .venv
# FIXME: self-hosted (on vm) runners are unable to process custom PATH correctly
#. .venv/bin/activate
#echo PATH=$PATH >> $GITHUB_ENV
- name: Setup python requirements
run: python3 -m pip install -r ./requirements/python.txt
run: |
. .venv/bin/activate
python3 -m pip install -r ./requirements/python.txt
- name: Build
run: ./scripts/build_source.sh
Expand Down Expand Up @@ -108,7 +122,9 @@ jobs:

- name: Python Sanity Tests
working-directory: ./build/${{ matrix.config }}/bin
run: python3 ./../../../scripts/run_python_test_script.py -d '../test_python'
run: |
. ./../../../.venv/bin/activate
python3 ./../../../scripts/run_python_test_script.py -d '../test_python'
- name: Configure AWS Credentials
if: ${{ env.UPLOAD_TEST_ARTIFACTS == 'true' && env.INTERNAL_BUILD == 'true' }}
Expand All @@ -135,7 +151,9 @@ jobs:
SMOKE: ${{ env.INTERNAL_BUILD == 'true' && inputs.full_config_build == false && matrix.config == 'Debug' }}
if: ${{ env.INTERNAL_BUILD == 'true' }}
working-directory: ./build/${{ matrix.config }}/bin
run: python3 ./../../../scripts/run_python_test_script.py -d '../test_regression' -s ${{env.SMOKE}}
run: |
. ./../../../.venv/bin/activate
python3 ./../../../scripts/run_python_test_script.py -d '../test_regression' -s ${{env.SMOKE}}
- name: Copy test artifacts to S3
if: ${{ env.UPLOAD_TEST_ARTIFACTS == 'true' && env.INTERNAL_BUILD == 'true' && !cancelled() }}
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/prepare-images.yml
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,7 @@ jobs:
{\"dockerfile\":\"ubuntu24Dockerfile\", \"image\":\"ubuntu24\", \"os\":\"ubuntu-latest\"}, \
{\"dockerfile\":\"ubuntu20Dockerfile\", \"image\":\"ubuntu-arm64\", \"os\":[\"self-hosted\", \"linux-arm64\"]}, \
{\"dockerfile\":\"ubuntu22Dockerfile\", \"image\":\"ubuntu22-arm64\", \"os\":[\"self-hosted\", \"linux-arm64\"]}, \
{\"dockerfile\":\"ubuntu24Dockerfile\", \"image\":\"ubuntu24-arm64\", \"os\":[\"self-hosted\", \"linux-arm64\"]}, \
{\"dockerfile\":\"fedora39Dockerfile\", \"image\":\"fedora39\", \"os\":\"ubuntu-latest\"}, \
{\"dockerfile\":\"emscriptenDockerfile\", \"image\":\"emscripten\", \"os\":\"ubuntu-latest\"}, \
]}"
Expand Down
6 changes: 6 additions & 0 deletions scripts/devops/release_table.txt
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,12 @@
<a href="RELEASE_PATH/meshlib_SHORT_VERSION_ubuntu24-dev.deb">deb</a>
</td>
</tr>
<tr>
<td align="center">Ubuntu 24 LTS arm64</td>
<td align="center">
<a href="RELEASE_PATH/meshlib_SHORT_VERSION_ubuntu24-arm64-dev.deb">deb</a>
</td>
</tr>
<tr>
<td align="center">Fedora 39 x64</td>
<td align="center">
Expand Down
2 changes: 1 addition & 1 deletion thirdparty/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# to force update thirdparty touch this line
# to force update thirdparty touch this line
cmake_minimum_required(VERSION 3.16 FATAL_ERROR)
set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
Expand Down

0 comments on commit 7b9ca5c

Please sign in to comment.