diff --git a/build.rs b/build.rs index f137ace6..661f2702 100644 --- a/build.rs +++ b/build.rs @@ -42,12 +42,12 @@ const fn clang_args() -> Vec { #[cfg(not(windows))] fn bindgen() { - #[cfg(target_os = "linux")] + #[cfg(any(target_os = "linux", target_os = "android"))] let bindings = bindgen::Builder::default() .header_contents("rtnetlink.h", "#include ") // Only generate bindings for the following types .allowlist_type("rtattr|rtmsg|ifinfomsg|nlmsghdr"); - #[cfg(not(target_os = "linux"))] + #[cfg(not(any(target_os = "linux", target_os = "android")))] let bindings = bindgen::Builder::default() .header_contents( "route.h",