Skip to content

Commit f93cf62

Browse files
committed
OpenBSD can't -lresolv, Android shouldn't need it
1 parent ef20ddb commit f93cf62

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

src/unix/mod.rs

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -210,8 +210,6 @@ cfg_if! {
210210
feature = "use_std",
211211
not(any(target_os = "macos",
212212
target_os = "ios",
213-
target_os = "android",
214-
target_os = "openbsd",
215213
target_os = "bitrig")
216214
)))] {
217215
// cargo build, don't pull in anything extra as the libstd dep
@@ -237,13 +235,16 @@ cfg_if! {
237235
extern {}
238236
} else if #[cfg(any(target_os = "macos",
239237
target_os = "ios",
240-
target_os = "android",
241-
target_os = "openbsd",
242238
target_os = "bitrig"))] {
243239
#[link(name = "c")]
244240
#[link(name = "m")]
245241
#[link(name = "resolv")]
246242
extern {}
243+
} else if #[cfg(any(target_os = "android",
244+
target_os = "openbsd"))] {
245+
#[link(name = "c")]
246+
#[link(name = "m")]
247+
extern {}
247248
} else if #[cfg(target_os = "haiku")] {
248249
#[link(name = "root")]
249250
#[link(name = "network")]

0 commit comments

Comments
 (0)