File tree Expand file tree Collapse file tree 1 file changed +1
-10
lines changed
Expand file tree Collapse file tree 1 file changed +1
-10
lines changed Original file line number Diff line number Diff line change @@ -13,15 +13,6 @@ use uucore::error::{UResult, USimpleError};
1313use uucore:: format_usage;
1414use uucore:: translate;
1515
16- #[ cfg( any( target_os = "linux" , target_os = "android" ) ) ]
17- pub const _SC_NPROCESSORS_CONF: libc:: c_int = 83 ;
18- #[ cfg( target_vendor = "apple" ) ]
19- pub const _SC_NPROCESSORS_CONF: libc:: c_int = libc:: _SC_NPROCESSORS_CONF;
20- #[ cfg( target_os = "freebsd" ) ]
21- pub const _SC_NPROCESSORS_CONF: libc:: c_int = 57 ;
22- #[ cfg( target_os = "netbsd" ) ]
23- pub const _SC_NPROCESSORS_CONF: libc:: c_int = 1001 ;
24-
2516static OPT_ALL : & str = "all" ;
2617static OPT_IGNORE : & str = "ignore" ;
2718
@@ -122,7 +113,7 @@ pub fn uu_app() -> Command {
122113 target_os = "netbsd"
123114) ) ]
124115fn num_cpus_all ( ) -> usize {
125- let nprocs = unsafe { libc:: sysconf ( _SC_NPROCESSORS_CONF) } ;
116+ let nprocs = unsafe { libc:: sysconf ( libc :: _SC_NPROCESSORS_CONF) } ;
126117 if nprocs == 1 {
127118 // In some situation, /proc and /sys are not mounted, and sysconf returns 1.
128119 // However, we want to guarantee that `nproc --all` >= `nproc`.
You can’t perform that action at this time.
0 commit comments