Fix CI build and add Linux builds (x86, aarch64, armv7)#25
Merged
twlite merged 55 commits intowebviewjs:mainfrom Jan 15, 2026
Merged
Fix CI build and add Linux builds (x86, aarch64, armv7)#25twlite merged 55 commits intowebviewjs:mainfrom
twlite merged 55 commits intowebviewjs:mainfrom
Conversation
- Switch package manager from yarn to bun - Upgrade napi-rs from v2 to v3 with updated native bindings - Update tao from 0.30.8 to 0.34.5 and wry from 0.47.0 to 0.48.0 - Update CI workflows to use bun for installation and caching - Regenerate type definitions and JavaScript bindings for napi-rs v3 - Update development documentation with bun prerequisites - Remove yarn, taplo configurations and add bun-specific ignores - Add new build scripts: build:all, build:prebuilds, clean, check, clippy - Improve native binding loading with better error handling and platform support
Replace yarn with bun across CI/CD workflows, husky hooks, and development scripts. Refactor Rust code to use more idiomatic patterns including unwrap_or_default, map instead of match expressions, and simplified callback handling.
Add new methods for application lifecycle management and window control: - Application.exit() for graceful shutdown with resource cleanup - BrowserWindow.hide() and show() for window visibility control - Webview.reload() for reloading webview content - ApplicationCloseRequested event for handling close events - Application.bind() as an alias for on_event() Updated CI workflow to install required system dependencies for Linux. Added documentation and examples for the new closing functionality.
Add window identification, management methods, and application lifecycle control. Windows now have unique IDs for tracking, with new methods for closing specific windows. The Application can now prevent automatic exit when all windows are closed, requiring explicit exit() call. BREAKING CHANGE: package.json type changed from commonjs to module, affecting import syntax for consumers of this package
This reverts commit 7a4c37e.
Remove manual cross-compiler and system library installations for aarch64 and armv7 targets, relying instead on the zig toolchain for cross-compilation. This reduces CI complexity and build time. Also fix package name typo for libgdk-pixbuf-2.0-dev.
Remove i686-unknown-linux-gnu from the CI build not work in hardware modern or modern linux versions (unsupported) the workflow. Consolidated cross-compilation environment variable configuration into the Build step using conditional expressions, eliminating the need for separate setup steps.
Remove architecture-specific pkg-config paths and system dependencies for ARM64 and ARMv7 builds when using Zig for cross-compilation. Set GLIB_NO_PKG_CONFIG, GOBJECT_NO_PKG_CONFIG, GIO_NO_PKG_CONFIG, and WEBKIT2GTK_NO_PKG_CONFIG environment variables to prevent pkg-config usage during cross-compilation. Simplify the system dependency installation step by splitting generic Linux deps from architecture-specific ones.
…e toolchains and install required dependencies.
twlite
reviewed
Jan 15, 2026
.github/workflows/CI.yml
Outdated
| mkdir -p npm/linux-arm64-gnu | ||
| mkdir -p npm/linux-arm-gnueabihf | ||
| mkdir -p npm/android-arm64 | ||
| mkdir -p npm/android-arm-eabi |
Contributor
Author
There was a problem hiding this comment.
You're right, that's wrong; it throws an error in the publish command, so I only did that to avoid it. I recommend redoing the publish section.
Contributor
Author
There was a problem hiding this comment.
This is managed by napi-rs
can you review or fix
Run bun run artifacts
$ napi artifacts
INFO Read [/home/runner/work/webview-1/webview-1/artifacts/bindings-aarch64-apple-darwin/webview.darwin-arm64.node]
INFO Read [/home/runner/work/webview-1/webview-1/artifacts/bindings-aarch64-linux-android/webview.android-arm64.node]
INFO Read [/home/runner/work/webview-1/webview-1/artifacts/bindings-aarch64-pc-windows-msvc/webview.win32-arm64-msvc.node]
INFO Read [/home/runner/work/webview-1/webview-1/artifacts/bindings-aarch64-unknown-linux-gnu/webview.linux-arm64-gnu.node]
INFO Read [/home/runner/work/webview-1/webview-1/artifacts/bindings-armv7-linux-androideabi/webview.android-arm-eabi.node]
INFO Read [/home/runner/work/webview-1/webview-1/artifacts/bindings-armv7-unknown-linux-gnueabihf/webview.linux-arm-gnueabihf.node]
INFO Read [/home/runner/work/webview-1/webview-1/artifacts/bindings-i686-pc-windows-msvc/webview.win32-ia32-msvc.node]
INFO Read [/home/runner/work/webview-1/webview-1/artifacts/bindings-x86_64-apple-darwin/webview.darwin-x64.node]
INFO Read [/home/runner/work/webview-1/webview-1/artifacts/bindings-x86_64-pc-windows-msvc/webview.win32-x64-msvc.node]
INFO Read [/home/runner/work/webview-1/webview-1/artifacts/bindings-x86_64-unknown-linux-gnu/webview.linux-x64-gnu.node]
INFO Write file content to [/home/runner/work/webview-1/webview-1/npm/win32-ia32-msvc/webview.win32-ia32-msvc.node]
INFO Write file content to [/home/runner/work/webview-1/webview-1/npm/win32-arm64-msvc/webview.win32-arm64-msvc.node]
INFO Write file content to [/home/runner/work/webview-1/webview-1/npm/linux-arm64-gnu/webview.linux-arm64-gnu.node]
INFO Write file content to [/home/runner/work/webview-1/webview-1/npm/darwin-arm64/webview.darwin-arm64.node]
INFO Write file content to [/home/runner/work/webview-1/webview-1/npm/android-arm-eabi/webview.android-arm-eabi.node]
INFO Write file content to [/home/runner/work/webview-1/webview-1/npm/win32-x64-msvc/webview.win32-x64-msvc.node]
INFO Write file content to [/home/runner/work/webview-1/webview-1/npm/linux-arm-gnueabihf/webview.linux-arm-gnueabihf.node]
Internal Error: ENOENT: no such file or directory, open '/home/runner/work/webview-1/webview-1/npm/linux-arm64-gnu/webview.linux-arm64-gnu.node'
at async open (node:internal/fs/promises:642:25)
at async writeFile (node:internal/fs/promises:1249:14)
at async file:///home/runner/work/webview-1/webview-1/node_modules/@napi-rs/cli/dist/cli.js:588:3
at async Promise.all (index 3)
at async collectArtifacts (file:///home/runner/work/webview-1/webview-1/node_modules/@napi-rs/cli/dist/cli.js:569:2)
at async ArtifactsCommand.execute (file:///home/runner/work/webview-1/webview-1/node_modules/@napi-rs/cli/dist/cli.js:3482:3)
at async ArtifactsCommand.validateAndExecute (file:///home/runner/work/webview-1/webview-1/node_modules/clipanion/lib/advanced/Command.mjs:49:26)
at async Cli.run (file:///home/runner/work/webview-1/webview-1/node_modules/clipanion/lib/advanced/Cli.mjs:227:24)
at async Cli.runExit (file:///home/runner/work/webview-1/webview-1/node_modules/clipanion/lib/advanced/Cli.mjs:236:28)
INFO Write file content to [/home/runner/work/webview-1/webview-1/npm/linux-x64-gnu/webview.linux-x64-gnu.node]
INFO Write file content to [/home/runner/work/webview-1/webview-1/npm/darwin-x64/webview.darwin-x64.node]
INFO Write file content to [/home/runner/work/webview-1/webview-1/npm/android-arm64/webview.android-arm64.node]
INFO Write file content to [/home/runner/work/webview-1/webview-1/webview.win32-ia32-msvc.node]
INFO Write file content to [/home/runner/work/webview-1/webview-1/webview.win32-arm64-msvc.node]
INFO Write file content to [/home/runner/work/webview-1/webview-1/webview.darwin-arm64.node]
INFO Write file content to [/home/runner/work/webview-1/webview-1/webview.android-arm-eabi.node]
INFO Write file content to [/home/runner/work/webview-1/webview-1/webview.linux-x64-gnu.node]
INFO Write file content to [/home/runner/work/webview-1/webview-1/webview.win32-x64-msvc.node]
INFO Write file content to [/home/runner/work/webview-1/webview-1/webview.darwin-x64.node]
INFO Write file content to [/home/runner/work/webview-1/webview-1/webview.android-arm64.node]
error: script "artifacts" exited with code 1
Error: Process completed with exit code 1.
``
Contributor
Author
There was a problem hiding this comment.
❯ bunx napi prepublish -t npm
WARNING /home/pc/Documentos/GitHub/webview-1/npm/win32-x64-msvc/webview.win32-x64-msvc.node doesn't exist
WARNING /home/pc/Documentos/GitHub/webview-1/npm/win32-ia32-msvc/webview.win32-ia32-msvc.node doesn't exist
WARNING /home/pc/Documentos/GitHub/webview-1/npm/win32-arm64-msvc/webview.win32-arm64-msvc.node doesn't exist
WARNING /home/pc/Documentos/GitHub/webview-1/npm/darwin-x64/webview.darwin-x64.node doesn't exist
WARNING /home/pc/Documentos/GitHub/webview-1/npm/darwin-arm64/webview.darwin-arm64.node doesn't exist
WARNING /home/pc/Documentos/GitHub/webview-1/npm/linux-x64-gnu/webview.linux-x64-gnu.node doesn't exist
WARNING /home/pc/Documentos/GitHub/webview-1/npm/linux-ia32-gnu/webview.linux-ia32-gnu.node doesn't exist
WARNING /home/pc/Documentos/GitHub/webview-1/npm/linux-arm64-gnu/webview.linux-arm64-gnu.node doesn't exist
WARNING /home/pc/Documentos/GitHub/webview-1/npm/linux-arm-gnueabihf/webview.linux-arm-gnueabihf.node doesn't exist
WARNING /home/pc/Documentos/GitHub/webview-1/npm/android-arm64/webview.android-arm64.node doesn't exist
WARNING /home/pc/Documentos/GitHub/webview-1/npm/android-arm-eabi/webview.android-arm-eabi.node doesn't exist
WARNING /home/pc/Documentos/GitHub/webview-1/npm/freebsd-x64/webview.freebsd-x64.node doesn't exist
Contributor
Author
|
@twlite can you review again, I fixed the Linux implementation, and I'd like to make another pull request for this. |
twlite
approved these changes
Jan 15, 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.

implement build for linux ci.yaml