Skip to content

Windows ARM64 native: OpenTUI fails to initialize with bun:ffi dlopen TinyCC error #19130

@Carliquiss

Description

@Carliquiss

Description

On Windows 11 ARM64, the native ARM64 OpenCode binary works for non-interactive commands, but the TUI fails to initialize.

The native binary successfully runs commands like:

  • opencode.exe --version
  • opencode.exe --help
  • opencode.exe debug --help
  • opencode.exe debug paths

However, starting the interactive TUI does not start correctly and logs this error:

Failed to initialize OpenTUI render library: bun:ffi dlopen() is not available in this build (TinyCC is disabled)

Environment

  • OS: Windows 11 ARM64
  • Architecture: native ARM64
  • Installation method: npm global install
  • Native binary path:
    C:\Users\<user>\AppData\Roaming\npm\node_modules\opencode-ai\node_modules\opencode-windows-arm64\bin\opencode.exe

OpenCode version

Observed from direct ARM64 binary:

  • 1.3.0

Also noting that opencode from PATH reported 1.3.2 in my environment, so there may be version/path inconsistency locally. If needed, I can provide more details, but the native ARM64 binary issue below was reproduced directly from the ARM64 executable path.

Steps to reproduce

  1. Install OpenCode on Windows ARM64 via npm
  2. Run the native ARM64 binary directly:
    C:\Users\<user>\AppData\Roaming\npm\node_modules\opencode-ai\node_modules\opencode-windows-arm64\bin\opencode.exe
  3. Alternatively run:
    C:\Users\<user>\AppData\Roaming\npm\node_modules\opencode-ai\node_modules\opencode-windows-arm64\bin\opencode.exe --print-logs --log-level DEBUG
  4. Observe startup behavior

Expected behavior

The OpenCode TUI should initialize and start normally on the native Windows ARM64 build.

Actual behavior

The process does not start the TUI correctly and logs:

ERROR ... Failed to initialize OpenTUI render library: bun:ffi dlopen() is not available in this build (TinyCC is disabled)
ERROR ... Error: Failed to initialize OpenTUI render library: bun:ffi dlopen() is not available in this build (TinyCC is disabled)

In my testing, the process stayed alive until manually terminated / timed out, rather than exiting cleanly.

Additional notes

  • This seems different from the existing Windows OpenTUI DLL/path issues that fail with LoadLibrary / DLL error codes.
  • This also seems different from the existing Windows ARM64 x64-emulation crash report, since this was reproduced against the native ARM64 binary directly.
  • Non-interactive commands work, so the problem appears specific to OpenTUI initialization on Windows ARM64 native.
  • Related but possibly separate: I have also seen instability when using the x64 build under emulation on Windows ARM64, but this report is specifically about the native ARM64 binary failing to initialize OpenTUI.

If useful, I can provide the exact command output and more environment details.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions