Fails to compile on x86_64-unknown-linux-musl target
Created by: svend
Here is the failure.
cargo build
Compiling termion v1.1.1 (file:///src)
src/size.rs:40:33: 40:45 error: mismatched types [E0308]
src/size.rs:40 if ioctl(STDOUT_FILENO, tiocgwinsz(), &mut size as *mut _) == 0 {
^~~~~~~~~~~~
src/size.rs:40:33: 40:45 help: run `rustc --explain E0308` to see a detailed explanation
src/size.rs:40:33: 40:45 note: expected type `i32`
src/size.rs:40:33: 40:45 note: found type `u64`
error: aborting due to previous error
error: Could not compile `termion`.
I noticed that rust-libc's ioctl is different for linux/other and linux/musl. I'm not sure how to fix this.
linux/other:
pub fn ioctl(fd: ::c_int, request: ::c_ulong, ...) -> ::c_int;
linux/musl:
pub fn ioctl(fd: ::c_int, request: ::c_int, ...) -> ::c_int;