Rust 1.73 + emscripten 3.1.44 fails if using filesystem api #116655
Description
It builds fine with EMSDK 3.1.43.
use std::{fs::File, io::Read};
fn main() {
let mut file = File::open("Hello world!").unwrap();
let mut buf = Vec::new();
file.read_to_end(&mut buf);
}
= note: wasm-ld: error: C:\Users\Przemyslaw.rustup\toolchains\stable-x86_64-pc-windows-msvc\lib\rustlib\wasm32-unknown-emscripten\lib\libstd-330edb0856239641.rlib(std-330edb0856239641.std.fa9f9c7c191d43dc-cgu.0.rcgu.o): undefined symbol: open64
wasm-ld: error: C:\Users\Przemyslaw.rustup\toolchains\stable-x86_64-pc-windows-msvc\lib\rustlib\wasm32-unknown-emscripten\lib\libstd-330edb0856239641.rlib(std-330edb0856239641.std.fa9f9c7c191d43dc-cgu.0.rcgu.o): undefined symbol: fstat64
wasm-ld: error: C:\Users\Przemyslaw.rustup\toolchains\stable-x86_64-pc-windows-msvc\lib\rustlib\wasm32-unknown-emscripten\lib\libstd-330edb0856239641.rlib(std-330edb0856239641.std.fa9f9c7c191d43dc-cgu.0.rcgu.o): undefined symbol: lseek64
Meta
rustc --version --verbose
:
rustc 1.73.0 (cc66ad468 2023-10-03)
binary: rustc
commit-hash: cc66ad468955717ab92600c770da8c1601a4ff33
commit-date: 2023-10-03
host: x86_64-pc-windows-msvc
release: 1.73.0
LLVM version: 17.0.2
Backtrace
<backtrace>