build.yml: Test CMake builds
This commit is contained in:
parent
42022bdfd2
commit
8cb79ee671
|
@ -33,7 +33,27 @@ jobs:
|
|||
|
||||
- name: make
|
||||
run: make build/kristall
|
||||
|
||||
|
||||
build_cmake:
|
||||
runs-on: ubuntu-20.04
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- uses: jurplel/install-qt-action@v2
|
||||
with:
|
||||
version: "5.12.8"
|
||||
|
||||
- name: Install OpenSSL
|
||||
run: sudo apt install -y libssl-dev
|
||||
|
||||
- name: Configure the project
|
||||
uses: threeal/cmake-action@v1.3.0
|
||||
with:
|
||||
build-dir: build
|
||||
|
||||
- name: Build the project
|
||||
run: cmake --build build
|
||||
|
||||
# Disabled until both aqinstall and install-qt-action support the fixes…
|
||||
# build_windows:
|
||||
# runs-on: windows-latest
|
||||
|
|
|
@ -7,11 +7,19 @@ if(NOT KRISTALL_VERSION)
|
|||
OUTPUT_STRIP_TRAILING_WHITESPACE
|
||||
)
|
||||
|
||||
if(NOT KRISTALL_CMAKE_VERSION)
|
||||
set(KRISTALL_CMAKE_VERSION "0.0.0")
|
||||
endif()
|
||||
|
||||
execute_process(COMMAND git describe --tags
|
||||
WORKING_DIRECTORY ${CMAKE_CURRENT_LIST_DIR}
|
||||
OUTPUT_VARIABLE KRISTALL_VERSION
|
||||
OUTPUT_STRIP_TRAILING_WHITESPACE
|
||||
)
|
||||
|
||||
if(NOT KRISTALL_VERSION)
|
||||
set(KRISTALL_VERSION "development")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# CMake requires the following format for versions:
|
||||
|
@ -170,7 +178,7 @@ if(QT_VERSION_MAJOR EQUAL 6)
|
|||
qt_finalize_executable(${PROJECT_NAME})
|
||||
endif()
|
||||
|
||||
find_package(OpenSSL 3.0 REQUIRED)
|
||||
find_package(OpenSSL 1.1 REQUIRED)
|
||||
target_link_libraries(${PROJECT_NAME} PRIVATE OpenSSL::SSL)
|
||||
|
||||
if(NOT UNIX)
|
||||
|
|
Loading…
Reference in New Issue