mirror of https://github.com/qpdf/qpdf.git
Add CI build for next C++ version
This commit is contained in:
parent
db4ec7a9db
commit
762f232146
|
@ -147,3 +147,11 @@ jobs:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
- name: 'Unsigned Char Tests'
|
- name: 'Unsigned Char Tests'
|
||||||
run: build-scripts/test-unsigned-char
|
run: build-scripts/test-unsigned-char
|
||||||
|
CxxNext:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
# Build after Fuzzers to save concurrent runners
|
||||||
|
needs: Fuzzers
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- name: 'Build with Next C++ standard'
|
||||||
|
run: build-scripts/test-c++-next
|
||||||
|
|
|
@ -106,6 +106,7 @@ option(INSTALL_CMAKE_PACKAGE "Install cmake package files" ON)
|
||||||
option(INSTALL_EXAMPLES "Install example files" ON)
|
option(INSTALL_EXAMPLES "Install example files" ON)
|
||||||
|
|
||||||
option(FUTURE "Include ABI-breaking changes CONSIDERED for the next major release" OFF)
|
option(FUTURE "Include ABI-breaking changes CONSIDERED for the next major release" OFF)
|
||||||
|
option(CXX_NEXT "Build with next C++ standard version" OFF)
|
||||||
|
|
||||||
# *** END OPTIONS ***
|
# *** END OPTIONS ***
|
||||||
|
|
||||||
|
@ -166,7 +167,11 @@ Please build with cmake in a subdirectory, e.g.
|
||||||
Please remove CMakeCache.txt and the CMakeFiles directories.")
|
Please remove CMakeCache.txt and the CMakeFiles directories.")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
set(CMAKE_CXX_STANDARD 17)
|
if(CXX_NEXT)
|
||||||
|
set(CMAKE_CXX_STANDARD 20)
|
||||||
|
else()
|
||||||
|
set(CMAKE_CXX_STANDARD 17)
|
||||||
|
endif()
|
||||||
set(CMAKE_CXX_EXTENSIONS OFF)
|
set(CMAKE_CXX_EXTENSIONS OFF)
|
||||||
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||||||
set(CMAKE_C_VISIBILITY_PRESET hidden)
|
set(CMAKE_C_VISIBILITY_PRESET hidden)
|
||||||
|
|
|
@ -0,0 +1,14 @@
|
||||||
|
#!/bin/bash
|
||||||
|
set -e
|
||||||
|
sudo apt-get update
|
||||||
|
sudo apt-get -y install \
|
||||||
|
build-essential cmake \
|
||||||
|
zlib1g-dev libjpeg-dev libgnutls28-dev libssl-dev
|
||||||
|
cmake -S . -B build \
|
||||||
|
-DCXX_NEXT=ON \
|
||||||
|
-DCI_MODE=1 -DBUILD_STATIC_LIBS=0 -DCMAKE_BUILD_TYPE=Release \
|
||||||
|
-DREQUIRE_CRYPTO_OPENSSL=1 -DREQUIRE_CRYPTO_GNUTLS=1 \
|
||||||
|
-DENABLE_QTC=1
|
||||||
|
cmake --build build --verbose -j$(nproc) -- -k
|
||||||
|
cd build
|
||||||
|
ctest --verbose
|
Loading…
Reference in New Issue