Skip to content

Fix Windows 11 build for Electron#10

Merged
repugraf merged 6 commits intomainfrom
fix/windows11-build
Nov 7, 2025
Merged

Fix Windows 11 build for Electron#10
repugraf merged 6 commits intomainfrom
fix/windows11-build

Conversation

@repugraf
Copy link
Owner

@repugraf repugraf commented Nov 7, 2025

When importing the binding inside Electron app in Windows 11 specifically there was this kind of error:

[15644:1106/173727.894:ERROR:third_party\crashpad\crashpad\client\crashpad_client_win.cc:869] not connected

When running using the package outside of electron app (via node.js direly) this issue wasn't happening

The root cause of this was missing win_delay_load_hook.cc file as a source in windows.

win_delay_load_hook.cc is a C++ file used in the Windows build process for native Node.js modules, particularly with frameworks like Electron and NW.js. It implements a delay-load hook to correctly redirect the loading of node.dll to the main executable (electron.exe or nw.exe), ensuring native modules can be loaded at runtime. This is necessary because these frameworks export the symbols from their executable, not a separate node.dll.

The fix was implemented in existing CMake file first but it required a lot of manual setting which is already node in node-gyp package. The decision was made to mode to gyp enterally to prevent future such issues.

@repugraf repugraf requested a review from Copilot November 7, 2025 10:08
@repugraf repugraf self-assigned this Nov 7, 2025
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR updates project dependencies and improves the CMake build configuration, focusing on better cross-platform support and modernizing the dependency stack.

  • Updated Vitest from 3.2.4 to 4.0.7 (major version upgrade)
  • Updated Vite override from 7.1.5 to 7.2.2
  • Reorganized CMakeLists.txt to set compiler flags before target creation and improved Windows-specific MSVC settings

Reviewed Changes

Copilot reviewed 2 out of 3 changed files in this pull request and generated 2 comments.

File Description
package.json Updated vitest to 4.0.7 and vite override to 7.2.2
package-lock.json Updated dependency tree to reflect vitest 4.x, including all transitive dependencies like esbuild, @vitest/* packages, and related tooling
CMakeLists.txt Reorganized build type and compiler flag settings, improved Windows-specific MSVC configuration with modern target-based options

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@repugraf repugraf requested a review from Copilot November 7, 2025 10:17
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Copilot reviewed 2 out of 3 changed files in this pull request and generated no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@repugraf repugraf requested a review from Copilot November 7, 2025 13:03
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Copilot reviewed 7 out of 9 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

repugraf and others added 2 commits November 7, 2025 15:05
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@repugraf repugraf merged commit c654bff into main Nov 7, 2025
4 checks passed
@repugraf repugraf deleted the fix/windows11-build branch November 7, 2025 13:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants