bytecodealliance / rustix

Safe Rust bindings to POSIX-ish APIs
Other
1.4k stars 139 forks source link

Use manual inits in tests to avoid dev-dependeing on the ctor crate. #1081

Closed sunfishcode closed 3 weeks ago

sunfishcode commented 3 weeks ago

The ctor crate recently started to cause link errors:

= note: symbols.o : error LNK2001: unresolved external symbol _ZN3net34windows_shutdown_rustdtormod13dtor_export17h23ee8b3200f4e26dE symbols.o : error LNK2001: unresolved external symbol _ZN3net34windowsstartuprust_ctor___ctor17hd7d3fdaa3ef2ca94E D:\a\rustix\rustix\target\release\deps\net-f008608c7b4f9589.exe : fatal error LNK1120: 2 unresolved externals

so add manual inits to the net tests so that we don't need to depend on the ctor crate.