@@ -11,8 +11,8 @@ cfg_if! {
1111 mod custom;
1212 pub use custom:: * ;
1313 } else if #[ cfg( getrandom_backend = "linux_getrandom" ) ] {
14- mod linux_android ;
15- pub use linux_android :: * ;
14+ mod getrandom ;
15+ pub use getrandom :: * ;
1616 } else if #[ cfg( getrandom_backend = "rdrand" ) ] {
1717 mod rdrand;
1818 pub use rdrand:: * ;
@@ -51,17 +51,6 @@ cfg_if! {
5151 ) ) ] {
5252 mod getentropy;
5353 pub use getentropy:: * ;
54- } else if #[ cfg( any(
55- target_os = "dragonfly" ,
56- target_os = "freebsd" ,
57- target_os = "hurd" ,
58- target_os = "illumos" ,
59- // Check for target_arch = "arm" to only include the 3DS. Does not
60- // include the Nintendo Switch (which is target_arch = "aarch64").
61- all( target_os = "horizon" , target_arch = "arm" ) ,
62- ) ) ] {
63- mod getrandom;
64- pub use getrandom:: * ;
6554 } else if #[ cfg( any(
6655 // Rust supports Android API level 19 (KitKat) [0] and the next upgrade targets
6756 // level 21 (Lollipop) [1], while `getrandom(2)` was added only in
@@ -102,9 +91,19 @@ cfg_if! {
10291 mod use_file;
10392 mod linux_android_with_fallback;
10493 pub use linux_android_with_fallback:: * ;
105- } else if #[ cfg( any( target_os = "android" , target_os = "linux" ) ) ] {
106- mod linux_android;
107- pub use linux_android:: * ;
94+ } else if #[ cfg( any(
95+ target_os = "android" ,
96+ target_os = "linux" ,
97+ target_os = "dragonfly" ,
98+ target_os = "freebsd" ,
99+ target_os = "hurd" ,
100+ target_os = "illumos" ,
101+ // Check for target_arch = "arm" to only include the 3DS. Does not
102+ // include the Nintendo Switch (which is target_arch = "aarch64").
103+ all( target_os = "horizon" , target_arch = "arm" ) ,
104+ ) ) ] {
105+ mod getrandom;
106+ pub use getrandom:: * ;
108107 } else if #[ cfg( target_os = "solaris" ) ] {
109108 mod solaris;
110109 pub use solaris:: * ;
0 commit comments