mirror of
https://github.com/nemtrif/utfcpp.git
synced 2026-01-18 17:11:21 +01:00
Add CI workflow on Linux/Clang
This commit is contained in:
32
.github/workflows/ci-linux-clang.yml
vendored
Normal file
32
.github/workflows/ci-linux-clang.yml
vendored
Normal file
@@ -0,0 +1,32 @@
|
||||
name: CI Linux Clang
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ "master" ]
|
||||
pull_request:
|
||||
branches: [ "master" ]
|
||||
|
||||
jobs:
|
||||
build-and-test:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Install Clang
|
||||
run: sudo apt-get update && sudo apt-get install -y clang
|
||||
|
||||
- name: Configure CMake (with tests)
|
||||
run: >
|
||||
cmake -B build \
|
||||
-DCMAKE_C_COMPILER=clang \
|
||||
-DCMAKE_CXX_COMPILER=clang++ \
|
||||
-DCMAKE_BUILD_TYPE=Release \
|
||||
-DUTF8CPP_ENABLE_TESTS=ON \
|
||||
-S .
|
||||
|
||||
- name: Build
|
||||
run: cmake --build build --config Release
|
||||
|
||||
- name: Test
|
||||
working-directory: build
|
||||
run: ctest -VV
|
||||
@@ -1,6 +1,3 @@
|
||||
# This file is deprecated and will be removed in a future release
|
||||
# Please see the instructions for installation in README.md file
|
||||
|
||||
cmake_minimum_required (VERSION 3.14...3.27)
|
||||
project (utf8cpp
|
||||
VERSION 4.0.6
|
||||
@@ -51,3 +48,9 @@ install(FILES "${PROJECT_BINARY_DIR}/${PROJECT_NAME}Config.cmake"
|
||||
install(FILES ${PROJECT_SOURCE_DIR}/source/utf8.h DESTINATION include/utf8cpp)
|
||||
install(DIRECTORY ${PROJECT_SOURCE_DIR}/source/utf8 DESTINATION
|
||||
include/utf8cpp)
|
||||
|
||||
option(UTF8CPP_ENABLE_TESTS "Build and enable tests" OFF)
|
||||
if(UTF8CPP_ENABLE_TESTS)
|
||||
enable_testing()
|
||||
add_subdirectory(tests)
|
||||
endif()
|
||||
|
||||
Reference in New Issue
Block a user