Skip to content

Commit

Permalink
Remove GitHub actions that do not work anymore and simplyfy our CMake…
Browse files Browse the repository at this point in the history
… one

Windows was not removed to keep testing the qmake version
  • Loading branch information
dantti committed Nov 9, 2023
1 parent 52dd746 commit b79e535
Show file tree
Hide file tree
Showing 7 changed files with 65 additions and 305 deletions.
56 changes: 0 additions & 56 deletions .github/workflows/android.yml

This file was deleted.

125 changes: 45 additions & 80 deletions .github/workflows/cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ on:
- 'ToUpgrade.md'
- 'Vision.md'
- 'LICENSE'
branches:
- master

pull_request:
paths-ignore:
- 'Example.md'
Expand All @@ -25,95 +28,57 @@ on:
- 'ToUpgrade.md'
- 'Vision.md'
- 'LICENSE'

env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
BUILD_TYPE: Release
branches:
- master

jobs:
build:
runs-on: ubuntu-${{ matrix.ubuntu_version }}
name: Ubuntu-${{ matrix.ubuntu_version }}-Qt-${{ matrix.qt_version }}-shared-${{ matrix.shared }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
fail-fast: true
matrix:
ubuntu_version: [20.04, 22.04]
qt_version: [5.12.12, 5.15.2, 6.4.0]
shared: [ON, OFF]

steps:
- name: Checkout
uses: actions/checkout@v3

- name: Install Qt
uses: jurplel/install-qt-action@v3
with:
version: ${{ matrix.qt_version }}
cache: 'true'
cache-key-prefix: ${{ runner.os }}-Qt-Cache-${{ matrix.qt_version }}
dir: ${{ github.workspace }}/Qt
os:
- ubuntu-latest
- windows-latest
- macos-latest

- name: Install packages
run: sudo apt-get install -y libxkbcommon-dev libxcb-xkb-dev
build_type:
- Debug
- Release

- name: Configure CMake
run: cmake -DCMAKE_BUILD_TYPE="${{env.BUILD_TYPE}}" -DBUILD_SHARED_LIBS=${{ matrix.shared }} -B "${{github.workspace}}/build" -S "QXlsx"
link_type:
- static
- shared

- name: Build
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}

MSVC:
name: windows-${{ matrix.win_version }}-Qt-${{ matrix.qt_version }}-shared-${{ matrix.shared }}
runs-on: windows-${{ matrix.win_version }}
strategy:
fail-fast: false
matrix:
win_version: [2019, 2022]
qt_version: [5.12.12, 5.15.2, 6.4.0]
shared: [ON, OFF]
config:
- qt_version: "5.12"
- qt_version: "6.6.0"

steps:
- name: Checkout
uses: actions/checkout@v3

- name: Install Qt
- name: Install Qt with options and default aqtversion
uses: jurplel/install-qt-action@v3
with:
version: ${{ matrix.qt_version }}
cache: 'true'
cache-key-prefix: ${{ runner.os }}-Qt-Cache-${{ matrix.qt_version }}
dir: ${{ github.workspace }}/Qt

- name: Configure CMake
run: cmake -DCMAKE_BUILD_TYPE="${{env.BUILD_TYPE}}" -DBUILD_SHARED_LIBS=${{ matrix.shared }} -B "${{github.workspace}}/build" -S "QXlsx"

- name: Build
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}

macos:
runs-on: macos-${{ matrix.macos_version }}
name: macos-${{ matrix.macos_version }}-Qt-${{ matrix.qt_version }}-shared-${{ matrix.shared }}
strategy:
fail-fast: false
matrix:
macos_version: [11, 12]
qt_version: [5.15.2, 6.4.0]
shared: [ON, OFF]

steps:
- name: Checkout
uses: actions/checkout@v3

- name: Install Qt
uses: jurplel/install-qt-action@v3
with:
version: ${{ matrix.qt_version }}
cache: 'true'
cache-key-prefix: ${{ runner.os }}-Qt-Cache-${{ matrix.qt_version }}
dir: ${{ github.workspace }}/Qt

- name: Configure CMake
run: cmake -DCMAKE_BUILD_TYPE="${{env.BUILD_TYPE}}" -DBUILD_SHARED_LIBS=${{ matrix.shared }} -B "${{github.workspace}}/build" -S "QXlsx"

- name: Build
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}
aqtversion: null # use whatever the default is
modules: ${{ matrix.config.modules }}
version: ${{ matrix.config.qt_version }}
cache: true

- name: Checkout sources
uses: actions/checkout@v4

- name: Install ninja-build tool (must be after Qt due PATH changes)
uses: turtlesec-no/get-ninja@main

- name: Make sure MSVC is found when Ninja generator is in use
uses: ilammy/msvc-dev-cmd@v1

- name: Configure project
run: >
cmake -S QXlsx -B ./build -G Ninja
-DCMAKE_BUILD_TYPE=${{ matrix.build_type }}
--warn-uninitialized
-Werror=dev
-DBUILD_SHARED_LIBS=${{ matrix.link_type == 'shared' }}
- name: Build Project
run: cmake --build ./build
52 changes: 0 additions & 52 deletions .github/workflows/ios.yml

This file was deleted.

53 changes: 0 additions & 53 deletions .github/workflows/macos.yml

This file was deleted.

50 changes: 0 additions & 50 deletions .github/workflows/ubuntu.yml

This file was deleted.

Loading

0 comments on commit b79e535

Please sign in to comment.