Fix Windows/UWP CI build (MSVC C4875 + JSI include path)#185
Open
matthargett wants to merge 3 commits into
Open
Fix Windows/UWP CI build (MSVC C4875 + JSI include path)#185matthargett wants to merge 3 commits into
matthargett wants to merge 3 commits into
Conversation
…uild windows-latest's newer MSVC promotes C4875 (deprecated non-string [[gsl::suppress]] arg) from the vendored GSL headers to an error under /WX, breaking every Win32/UWP build (pre-existing on main). Suppress the dependency-side deprecation.
…ng JSI C1083) The JSI napi target only had its own include/ on the include path, but napi.h includes the shared <napi/js_native_api_types.h> from Core/Node-API/Include/Shared (not built when the engine is JSI). Add that directory so the JSI backend compiles. Pre-existing failure (JSI was red on main with the same C1083); unblocks Win32/UWP JSI.
Contributor
There was a problem hiding this comment.
Pull request overview
Note
Copilot was unable to run its full agentic suite in this review.
Update CMake configuration to fix JSI Node-API builds by adding missing shared header include paths and to keep Windows CI green by suppressing a new MSVC warning coming from vendored GSL headers.
Changes:
- Add
Core/Node-API/Include/Sharedto the include path for thenapitarget in the Node-API-JSI build. - Suppress MSVC warning C4875 globally to avoid warnings-as-errors failures on newer toolchains.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| Core/Node-API-JSI/CMakeLists.txt | Adds missing shared include directory so JSI builds can find js_native_api_types.h. |
| CMakeLists.txt | Adds MSVC compile option to suppress C4875 emitted by vendored GSL headers. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
…LIC for JSI includes
This was referenced Jun 5, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Two pre-existing build-config fixes that unbreak the Win32/UWP CI; no functional changes. We hit these
while expanding N-API version support (cf. #116, #183) but they're independent of that work.
C4875: a newer MSVC promotes the deprecated non-string-literal[[gsl::suppress]]argument(from the vendored GSL headers) to an error under
/WX, breaking every Win32/UWP build. Suppress it.Core/Node-API/Include/Sharedto the JSInapitarget sonapi.hcan find<napi/js_native_api_types.h>(was failing withC1083).Landing sequence
Inter-related N-API PRs; intended order (✅ done / ⏳ pending):
napi_*).napi_*via the sharedlibnapi.sofrom the step above).Motivating RFCs: rebeckerspecialties#6 (jsc-android → maintained JSC) · rebeckerspecialties#7 (WebWorker via N-API → Factotum into BabylonNative).