Build errors
The most common reasons a build fails, and the message that identifies each one.
OpenSSL library directory does not exist
Message: OpenSSL library directory does not exist: ["…\openssl-3.6.0\win\bin\lib"]
Cause: The Windows form looks for OpenSSL at the default path from win/.cargo/config.toml because
OPENSSL_DIR isn't set.
Fix: Set OPENSSL_DIR to your OpenSSL; see Use your own OpenSSL build.
could not find native static library or unresolved OpenSSL symbols
Cause: The OpenSSL directory contains only static libraries but the build expects dynamic ones, or the other way around.
Fix: For static libraries, set OPENSSL_STATIC=1. Also check that the libraries and the Rust target
have the same architecture.
The OpenSSL build fails on Windows
Message: an error from openssl-src, often with perl or Configure in the text.
Cause: The L4Re form's bundled OpenSSL build needs Strawberry Perl and the MSVC compiler. The Perl from Git for Windows or MSYS2 is often first on the path, and it fails.
Fix: Put Strawberry Perl at the front of the path, for example
$env:PATH = "C:\Strawberry\perl\bin;" + $env:PATH, and build from a console in which the MSVC
compiler is found. Alternatively, link a prebuilt OpenSSL with openssl-system.
linker 'aarch64-linux-gnu-gcc' not found
Cause: The cross-compiler for the aarch64-unknown-linux-gnu target is missing.
Fix: On Debian or Ubuntu, install gcc-aarch64-linux-gnu and run
rustup target add aarch64-unknown-linux-gnu.
Building from the repository root finds nothing
Message: could not find Cargo.toml
Cause: The root isn't a Cargo workspace. Each form is a package of its own with its own
.cargo/config.toml.
Fix: Change to l4re or win and build there.
The test_pqc_availability test fails
Message: linked OpenSSL provides no ML-DSA
Cause: The linked OpenSSL is older than 3.5.
Fix: Link OpenSSL 3.5 or later. Without this test, the problem would surface only in production, as failing post-quantum requests.