Nuxt fails to build on FreeBSD arm64 after v3.16.2
Trying to figure out if this is a nuxt issue or oxc-parser issue.
I'm trying to get a Nuxt app running on FreeBSD arm64, but after upgrading past Nuxt v3.16.2, the build fails with this error:
│ ERROR Failed to load native binding
│ at Object.<anonymous> (/root/site/node_modules/.pnpm/oxc-parser@0.76.0/node_modules/oxc-parser/bindings.js:380:11)
...
│ [cause]: [ { Error: Cannot find module './parser.freebsd-arm64.node'
Also created a thread on oxc-parser, but i haven't got any responses: https://github.com/oxc-project/oxc/issues/12866
Anyone here knows what I can do? Am i just forced to pin Nuxt to 3.16.2 forever and ever? 🙁
GitHub
Nuxt fails to build on FreeBSD arm64 after v3.16.2 – oxc-parser n...
I'm trying to get a Nuxt app running on FreeBSD arm64, but after upgrading past Nuxt v3.16.2, the build fails with this error: │ ERROR Failed to load native binding │ at Object.<anonymous>...
2 Replies
Hi @andreassoegaard93. I'm kapa.ai, your friendly support bot. I will try to answer your question by searching through the knowledge base. :wave:
----------------------
Short answer: this is an oxc-parser native binding availability issue on your target (FreeBSD arm64), not Nuxt-specific. Nuxt 3.17+ migrated more of its internal parsing to oxc-parser, so your builds now depend on oxc’s prebuilt/native bindings for your OS/arch. If that binding isn’t provided, you’ll see “Failed to load native binding … Cannot find module './parser.freebsd-arm64.node'”. [feat: use oxc-parser; migrate to AST-aware tree-shaking]
What you can do (from the knowledge sources):
- Pin to a Nuxt version before the oxc changes affect your build (e.g., 3.16.x) as a temporary workaround. Similar regressions tied to oxc-parser/platform bindings were observed on other platforms and resolved by staying on earlier Nuxt versions until fixes landed upstream. [Deployment on ARM64; Native binding load failure 3.17.6]
- Clean install (remove lockfile and node_modules) sometimes resolves binding resolution issues in affected versions. [Native binding load failure 3.17.6]
Limitations: The provided sources don’t mention FreeBSD arm64 support specifically or a Nuxt-side fix for that target, and there’s no documented workaround (like a specific package/binary) for FreeBSD arm64 in these docs. I recommend tracking the oxc issue you opened and Nuxt releases touching oxc-parser updates, as Nuxt has been iterating on oxc integration and dependency versions. [remove wasm fallback; update oxc versions] ---------------------- Note: you can ask me a follow up question by @ mentioning me again :speech_balloon: ----------------------
Limitations: The provided sources don’t mention FreeBSD arm64 support specifically or a Nuxt-side fix for that target, and there’s no documented workaround (like a specific package/binary) for FreeBSD arm64 in these docs. I recommend tracking the oxc issue you opened and Nuxt releases touching oxc-parser updates, as Nuxt has been iterating on oxc integration and dependency versions. [remove wasm fallback; update oxc versions] ---------------------- Note: you can ask me a follow up question by @ mentioning me again :speech_balloon: ----------------------
<@960793104271679499> Kapa.ai is still learning and improving, please let me know how I did by reacting below.