Skip to content

LLD doesn't handle --warn-unresolved-symbols the same as GNU LD #147707

@el-yawd

Description

@el-yawd

While upgrading tursodb to rust 1.90 I got this linker error on CI:

Running unittests src/lib.rs (target/debug/deps/turso_sync_js-5f98d3f835f912a1) /home/runner/_work/turso/turso/target/debug/deps/turso_sync_js-5f98d3f835f912a1: symbol lookup error: /home/runner/_work/turso/turso/target/debug/deps/turso_sync_js-5f98d3f835f912a1: undefined symbol: napi_typeof error: test failed, to rerun pass `-p turso_sync_js --lib` 

As David pointed out, the --warn-unresolved-symbols flag is enabled and the error only happens during runtime.

Using the old linker fix the issue. I do not know how to properly debug this so any help would be appreciated :)

Version it worked on

It most recently worked on: 1.88

Version with regression

rustc --version --verbose:

rustc 1.90.0 (1159e78c4 2025-09-14) binary: rustc commit-hash: 1159e78c4747b02ef996e55082b704c09b970588 commit-date: 2025-09-14 host: x86_64-unknown-linux-gnu release: 1.90.0 LLVM version: 20.1.8 

@rustbot modify labels: +regression-from-stable-to-stable -regression-untriaged

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-linkersArea: linkers... you gotta love linkersA-lldArea: Linkage issues specific to rust-lldC-discussionCategory: Discussion or questions that doesn't represent real issues.P-mediumMedium priorityT-compilerRelevant to the compiler team, which will review and decide on the PR/issue.regression-from-stable-to-stablePerformance or correctness regression from one stable version to another.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions