memorysafety / rav1d

An AV1 decoder in Rust.
BSD 2-Clause "Simplified" License
346 stars 22 forks source link

`build.rs`: Fix windows cross compilation #1323

Closed kkysen closed 2 weeks ago

kkysen commented 4 months ago

@thedataking, I only noticed after you merged #1295 a few things.

This should let us cross-compile from windows, cross-compile to *-windows-gnu (I think; the linker wasn't installed so I couldn't test all the way), and print a clear error when trying to cross-compile to *-windows-msvc. It also lets us do full cross-compilation on rav1d, as the snprintf stuff for windows is only for rav1d-cli.