File tree Expand file tree Collapse file tree 5 files changed +24
-131
lines changed
Expand file tree Collapse file tree 5 files changed +24
-131
lines changed Original file line number Diff line number Diff line change 1- name : Linux
1+ name : Build
22
33on :
44 push :
55 branches : [ "main" ]
66
77jobs :
88 build-and-test :
9- runs-on : ubuntu-latest
109 strategy :
1110 fail-fast : false
1211 matrix :
12+ os : [ubuntu-latest, windows-latest, macos-latest]
1313 build_type : [Release, Debug]
1414 cpp_standard : [20, 23]
15+ runs-on : ${{ matrix.os }}
1516 env :
1617 VCPKG_ROOT : ${{ github.workspace }}/vcpkg
1718 BUILD_DIR : ${{ github.workspace }}/build
4142 key : ${{ runner.os }}-${{ matrix.build_type }}-cmake-${{ hashFiles('CMakeLists.txt', '**/CMakeLists.txt') }}
4243 restore-keys : |
4344 ${{ runner.os }}-${{ matrix.build_type }}-cmake-
45+
46+ - name : Set VCPKG Triplet
47+ shell : bash
48+ run : |
49+ if [ "$RUNNER_OS" == "Windows" ]; then
50+ echo "VCPKG_TARGET_TRIPLET=x64-windows" >> $GITHUB_ENV
51+ elif [ "$RUNNER_OS" == "Linux" ]; then
52+ echo "VCPKG_TARGET_TRIPLET=x64-linux" >> $GITHUB_ENV
53+ else
54+ if [ "$(uname -m)" == "arm64" ]; then
55+ echo "VCPKG_TARGET_TRIPLET=arm64-osx" >> $GITHUB_ENV
56+ else
57+ echo "VCPKG_TARGET_TRIPLET=x64-osx" >> $GITHUB_ENV
58+ fi
59+ fi
4460
4561 - name : Configure CMake
4662 shell : bash
5167 -DITCH_CXX_STANDARD=${{ matrix.cpp_standard }} \
5268 -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \
5369 -DCMAKE_TOOLCHAIN_FILE=$VCPKG_ROOT/scripts/buildsystems/vcpkg.cmake \
54- -DVCPKG_TARGET_TRIPLET=x64-linux
70+ -DVCPKG_TARGET_TRIPLET=$VCPKG_TARGET_TRIPLET
5571
5672 - name : Build
5773 shell : bash
Load Diff This file was deleted.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 11
22# High-Performance NASDAQ ITCH 5.0 Parser
33
4- [ ![ Linux] ( https://github.com/bbalouki/itchcpp/actions/workflows/linux.yml/badge.svg )] ( https://github.com/bbalouki/itchcpp/actions/workflows/linux.yml )
5- [ ![ macOS] ( https://github.com/bbalouki/itchcpp/actions/workflows/macos.yml/badge.svg )] ( https://github.com/bbalouki/itchcpp/actions/workflows/macos.yml )
6- [ ![ Windows] ( https://github.com/bbalouki/itchcpp/actions/workflows/windows.yml/badge.svg )] ( https://github.com/bbalouki/itchcpp/actions/workflows/windows.yml )
4+ [ ![ Build] ( https://github.com/bbalouki/itchcpp/actions/workflows/build.yml/badge.svg )] ( https://github.com/bbalouki/itchcpp/actions/workflows/build.yml )
5+ ![ Linux] ( https://img.shields.io/badge/Linux-FCC624?logo=linux&logoColor=black )
6+ ![ macOS] ( https://img.shields.io/badge/macOS-000000?logo=apple&logoColor=white )
7+ ![ Windows] ( https://img.shields.io/badge/Windows-0078D6?logo=windows&logoColor=white )
78[ ![ C++20] ( https://img.shields.io/badge/C++-20-blue.svg )] ( https://isocpp.org/std/the-standard )
89[ ![ CMake] ( https://img.shields.io/badge/CMake-3.20+-blue.svg )] ( https://cmake.org/ )
910[ ![ CodeFactor] ( https://www.codefactor.io/repository/github/bbalouki/itchcpp/badge )] ( https://www.codefactor.io/repository/github/bbalouki/itchcpp )
Original file line number Diff line number Diff line change @@ -183,7 +183,7 @@ function(apply_formating USE_PER_FILE_LOGIC)
183183 foreach (file ${ALL_FILES} )
184184 add_custom_command (
185185 TARGET format
186- POST_BUILD
186+ PRE_BUILD
187187 COMMAND ${CLANG_FORMAT_EXE} -i "${file} "
188188 COMMENT "Formatting ${file} "
189189 WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
You can’t perform that action at this time.
0 commit comments