mirror of
https://github.com/gulrak/filesystem.git
synced 2025-12-06 16:56:40 +08:00
Fix CI for Windows MinGW builds
This commit is contained in:
parent
6fe45fb536
commit
300d4e0135
32
.github/workflows/build_cmake.yml
vendored
32
.github/workflows/build_cmake.yml
vendored
@ -157,6 +157,7 @@ jobs:
|
|||||||
brew install ${{ matrix.config.packages }}
|
brew install ${{ matrix.config.packages }}
|
||||||
|
|
||||||
- name: Configure project
|
- name: Configure project
|
||||||
|
if: matrix.config.msystem == ''
|
||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
export CC=${{ matrix.config.cc }}
|
export CC=${{ matrix.config.cc }}
|
||||||
@ -171,12 +172,43 @@ jobs:
|
|||||||
args+=(-DCMAKE_INSTALL_PREFIX:PATH=install)
|
args+=(-DCMAKE_INSTALL_PREFIX:PATH=install)
|
||||||
cmake "${args[@]}"
|
cmake "${args[@]}"
|
||||||
|
|
||||||
|
- name: Configure project (MSYS2)
|
||||||
|
if: matrix.config.msystem != ''
|
||||||
|
shell: msys2 {0}
|
||||||
|
run: |
|
||||||
|
export CC=${{ matrix.config.cc }}
|
||||||
|
export CXX=${{ matrix.config.cxx }}
|
||||||
|
ninja --version
|
||||||
|
cmake --version
|
||||||
|
mkdir build
|
||||||
|
mkdir install
|
||||||
|
args=(-G "${{ matrix.config.generator }}" -S . -B build -DCMAKE_BUILD_TYPE=${{ matrix.config.build_type }})
|
||||||
|
[[ "${{ matrix.config.build_type }}" == "Debug" ]] && args+=(-DGHC_COVERAGE=ON)
|
||||||
|
[[ -n "${{ matrix.config.msystem }}" ]] && args+=(-DGHC_FILESYSTEM_BUILD_STD_TESTING=NO)
|
||||||
|
args+=(-DCMAKE_INSTALL_PREFIX:PATH=install)
|
||||||
|
cmake "${args[@]}"
|
||||||
|
|
||||||
- name: Build project
|
- name: Build project
|
||||||
|
if: matrix.config.msystem == ''
|
||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
cmake --build build --config ${{ matrix.config.build_type }}
|
cmake --build build --config ${{ matrix.config.build_type }}
|
||||||
|
|
||||||
|
- name: Build project (MSYS2)
|
||||||
|
if: matrix.config.msystem != ''
|
||||||
|
shell: msys2 {0}
|
||||||
|
run: |
|
||||||
|
cmake --build build --config ${{ matrix.config.build_type }}
|
||||||
|
|
||||||
- name: Run tests
|
- name: Run tests
|
||||||
|
if: matrix.config.msystem == ''
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
cd build && ctest -C ${{ matrix.config.build_type }}
|
||||||
|
|
||||||
|
- name: Run tests (MSYS2)
|
||||||
|
if: matrix.config.msystem != ''
|
||||||
|
shell: msys2 {0}
|
||||||
run: |
|
run: |
|
||||||
cd build && ctest -C ${{ matrix.config.build_type }}
|
cd build && ctest -C ${{ matrix.config.build_type }}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user