Skip to content

Build on Windows

Build on Windows #10

Workflow file for this run

name: Build on Windows
on:
push:
branches: [master]
pull_request:
branches: [master]
workflow_dispatch:
jobs:
windows_build:
runs-on: windows-2019
strategy:
matrix:
platform:
- x86
- x64
config:
- Release
- Debug
include:
- platform: x86
cmake_generator: '-G "Visual Studio 16 2019" -A Win32'
- platform: x64
cmake_generator: '-G "Visual Studio 16 2019" -A x64'
- fmt-header-only: 'ON'
- platform: x64
config: Release
fmt-header-only: 'OFF'
steps:
- name: explicitly disable autocrlf
run: git config --global core.autocrlf false
- uses: actions/[email protected]
- name: install fmtlib
run: |
git clone https://github.com/fmtlib/fmt.git
mkdir fmt/build
cd fmt/build
cmake -DFMT_TEST=OFF \
-DFMT_DOC=OFF \
-DCMAKE_BUILD_TYPE=Release \
${{ matrix.cmake_generator }} \
..
cmake --build . --config Release --target install
shell: bash
# - name: build lfp
# run: |
# mkdir build
# cd build
# cmake -DCMAKE_CXX_FLAGS="/D_CRT_SECURE_NO_WARNINGS" \
# -DLFP_FMT_HEADER_ONLY=${{ matrix.fmt-header-only }} \
# -DCMAKE_BUILD_TYPE=${{ matrix.config }} \
# ${{ matrix.cmake_generator }} \
# ..
# cmake --build . --config ${{ matrix.config }} --target install
# ctest -C ${{ matrix.config }} --verbose
# shell: bash
- name: Install Layered File Protocols
shell: bash
run: |
cmake \
-S build \
-B build \
-DCMAKE_POSITION_INDEPENDENT_CODE=ON \
-DLFP_FMT_HEADER_ONLY=ON \
-DBUILD_TESTING=OFF \
${{ matrix.cmake_generator }}
cmake \
--build build \
--target install \
--config ${{ matrix.config }}