1 | cfg_if::cfg_if! { |
2 | if #[cfg(any( |
3 | target_os = "linux" , |
4 | target_os = "android" , |
5 | all(target_os = "emscripten" , target_feature = "atomics" ), |
6 | target_os = "freebsd" , |
7 | target_os = "openbsd" , |
8 | target_os = "dragonfly" , |
9 | ))] { |
10 | mod futex_mutex; |
11 | mod futex_rwlock; |
12 | mod futex_condvar; |
13 | pub(crate) use futex_mutex::Mutex; |
14 | pub(crate) use futex_rwlock::RwLock; |
15 | pub(crate) use futex_condvar::Condvar; |
16 | } else if #[cfg(target_os = "fuchsia" )] { |
17 | mod fuchsia_mutex; |
18 | mod futex_rwlock; |
19 | mod futex_condvar; |
20 | pub(crate) use fuchsia_mutex::Mutex; |
21 | pub(crate) use futex_rwlock::RwLock; |
22 | pub(crate) use futex_condvar::Condvar; |
23 | } else { |
24 | mod pthread_mutex; |
25 | mod pthread_rwlock; |
26 | mod pthread_condvar; |
27 | pub(crate) use pthread_mutex::Mutex; |
28 | pub(crate) use pthread_rwlock::RwLock; |
29 | pub(crate) use pthread_condvar::Condvar; |
30 | } |
31 | } |
32 | |