|
| 1 | +name: Build on Linux arm64 |
| 2 | + |
| 3 | +on: |
| 4 | + push: |
| 5 | + branches: [main] |
| 6 | + paths: |
| 7 | + - ".github/workflows/build-linux-arm64.yml" |
| 8 | + - "CMakeLists.txt" |
| 9 | + - "CefConfig.cmake" |
| 10 | + - "include/**" |
| 11 | + - "src/**" |
| 12 | + |
| 13 | + pull_request: |
| 14 | + branches: [main] |
| 15 | + paths: |
| 16 | + - "CMakeLists.txt" |
| 17 | + - "CefConfig.cmake" |
| 18 | + - "include/**" |
| 19 | + - "src/**" |
| 20 | + |
| 21 | +env: |
| 22 | + # Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.) |
| 23 | + BUILD_TYPE: Release |
| 24 | + |
| 25 | +jobs: |
| 26 | + build: |
| 27 | + # The CMake configure and build commands are platform agnostic and should work equally |
| 28 | + # well on Windows or Mac. You can convert this to a matrix build if you need |
| 29 | + # cross-platform coverage. |
| 30 | + # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix |
| 31 | + runs-on: ubuntu-22.04-arm |
| 32 | + |
| 33 | + steps: |
| 34 | + - name: Checkout Source |
| 35 | + uses: actions/checkout@v2 |
| 36 | + with: |
| 37 | + submodules: "true" |
| 38 | + |
| 39 | + - name: Cache CEF folders |
| 40 | + uses: actions/cache@v3 |
| 41 | + with: |
| 42 | + path: ${{github.workspace}}/dep |
| 43 | + key: ${{ runner.os }}-dep-cef |
| 44 | + |
| 45 | + - name: Install x11 |
| 46 | + run: | |
| 47 | + sudo apt-get install -y libc++-dev libc++abi-dev libx11-dev |
| 48 | +
|
| 49 | + - name: Configure CMake |
| 50 | + # Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make. |
| 51 | + # See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type |
| 52 | + run: | |
| 53 | + cmake \ |
| 54 | + -B ${{github.workspace}}/build \ |
| 55 | + -DCMAKE_C_COMPILER=clang \ |
| 56 | + -DCMAKE_CXX_COMPILER=clang++ \ |
| 57 | + -DCMAKE_CXX_FLAGS="-stdlib=libc++ -mno-outline-atomics" \ |
| 58 | + -DPROJECT_ARCH=arm64 \ |
| 59 | + -DTARGET_ARCH=arm64 \ |
| 60 | + -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} \ |
| 61 | + -DUSE_SANDBOX=ON \ |
| 62 | + -DCEFVIEW_WING_NAME=UCefViewHelper \ |
| 63 | + -DCEF_SDK_VERSION="126.2.18+g3647d39+chromium-126.0.6478.183" \ |
| 64 | + -DCMAKE_INSTALL_PREFIX:PATH=${{github.workspace}}/install |
| 65 | +
|
| 66 | + - name: Build |
| 67 | + # Build your program with the given configuration |
| 68 | + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} |
| 69 | + |
| 70 | + - name: Install |
| 71 | + # Collect the output |
| 72 | + run: cmake --install ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} |
| 73 | + |
| 74 | + - name: Create artifact |
| 75 | + uses: actions/upload-artifact@v4 |
| 76 | + # Upload artifact |
| 77 | + with: |
| 78 | + name: CefViewCore.Linux.Arm64 |
| 79 | + path: ${{github.workspace}}/install |
0 commit comments