Add GitHub action to test builds with precompiled headers disabled (#3327)

This commit is contained in:
pajlada 2021-10-30 14:24:43 +02:00 committed by GitHub
parent e24dffa961
commit 076152630a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 18 additions and 1 deletions

View file

@ -15,14 +15,21 @@ jobs:
os: [windows-latest, ubuntu-latest, macos-latest]
qt-version: [5.15.2, 5.12.10]
build-system: [qmake, cmake]
pch: [true]
exclude:
- os: windows-latest
qt-version: 5.12.10
build-system: cmake
pch: true
include:
- os: windows-2016
qt-version: 5.12.10
build-system: cmake
pch: true
- os: ubuntu-latest
qt-version: 5.15.2
build-system: cmake
pch: false
fail-fast: false
steps:
@ -158,7 +165,12 @@ jobs:
run: |
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX=appdir/usr/ -DCMAKE_BUILD_TYPE=Release -DPAJLADA_SETTINGS_USE_BOOST_FILESYSTEM=On ..
cmake \
-DCMAKE_INSTALL_PREFIX=appdir/usr/ \
-DCMAKE_BUILD_TYPE=Release \
-DPAJLADA_SETTINGS_USE_BOOST_FILESYSTEM=On \
-DUSE_PRECOMPILED_HEADERS=${{ matrix.pch }} \
..
make -j8
shell: bash
@ -214,6 +226,7 @@ jobs:
cmake \
-DCMAKE_BUILD_TYPE=Release \
-DOPENSSL_ROOT_DIR=/usr/local/opt/openssl \
-DUSE_PRECOMPILED_HEADERS=${{ matrix.pch }} \
..
make -j8
shell: bash

View file

@ -43,6 +43,7 @@
- Bugfix: Fixed being unable to disable `First Message` highlights (#3293)
- Bugfix: Fixed `First Message` custom sound not persisting through restart. (#3303)
- Bugfix: Fixed `First Message` scrollbar highlights not being disabled. (#3325)
- Dev: Add GitHub action to test builds without precompiled headers enabled. (#3327)
- Dev: Renamed CMake's build option `USE_SYSTEM_QT5KEYCHAIN` to `USE_SYSTEM_QTKEYCHAIN`. (#3103)
- Dev: Add benchmarks that can be compiled with the `BUILD_BENCHMARKS` CMake flag. Off by default. (#3038)

View file

@ -556,7 +556,10 @@ if (BUILD_APP)
endif ()
if (USE_PRECOMPILED_HEADERS)
message(STATUS "Building with precompiled headers")
target_precompile_headers(${LIBRARY_PROJECT} PRIVATE PrecompiledHeader.hpp)
else ()
message(STATUS "Building without precompiled headers")
endif ()
# Enable autogeneration of Qts MOC/RCC/UIC