Skip to content

Commit af5b556

Browse files
committed
ninja
1 parent 40975f3 commit af5b556

3 files changed

Lines changed: 10 additions & 6 deletions

File tree

.github/workflows/webassembly-build.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,11 @@ on:
1818
required: false
1919
default: "ubuntu-latest"
2020
type: string
21+
generator:
22+
description: "CMake generator"
23+
required: false
24+
default: "Ninja"
25+
type: string
2126

2227
defaults:
2328
run:
@@ -44,6 +49,7 @@ jobs:
4449
- name: Configure CMake (Emscripten)
4550
run: |
4651
cmake -S . -B build/wasm \
52+
-G "${{ inputs.generator }}" \
4753
-DCMAKE_TOOLCHAIN_FILE=$EM_TOOLCHAIN \
4854
-DCMAKE_BUILD_TYPE=${{ inputs.build_type }} \
4955
-DVR_EMU_LCD_BUILD_WASM=ON

.github/workflows/webassembly-windows.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,3 +15,4 @@ jobs:
1515
emsdk_version: latest
1616
build_type: Release
1717
runner: windows-latest
18+
generator: Ninja

CMakeLists.txt

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -43,12 +43,9 @@ message(STATUS "VR_EMU_LCD_USING_EMSDK=${VR_EMU_LCD_USING_EMSDK} VR_EMU_LCD_BUIL
4343
# that MSVC cannot parse (e.g., -Wextra) from the toolchain-provided defaults.
4444
if (VR_EMU_LCD_USING_EMSDK AND (MSVC OR CMAKE_C_SIMULATE_ID STREQUAL "MSVC"))
4545
foreach(lang C CXX)
46-
if (DEFINED CMAKE_${lang}_FLAGS)
47-
string(REPLACE "-Wall" "" CMAKE_${lang}_FLAGS "${CMAKE_${lang}_FLAGS}")
48-
string(REPLACE "-Wextra" "" CMAKE_${lang}_FLAGS "${CMAKE_${lang}_FLAGS}")
49-
string(REPLACE "-Wpedantic" "" CMAKE_${lang}_FLAGS "${CMAKE_${lang}_FLAGS}")
50-
set(CMAKE_${lang}_FLAGS "${CMAKE_${lang}_FLAGS}" CACHE STRING "" FORCE)
51-
endif()
46+
foreach(cfg "" _DEBUG _RELEASE _RELWITHDEBINFO _MINSIZEREL)
47+
set(CMAKE_${lang}_FLAGS${cfg} "" CACHE STRING "" FORCE)
48+
endforeach()
5249
endforeach()
5350
endif()
5451

0 commit comments

Comments
 (0)