--- libc/nptl/sysdeps/unix/sysv/linux/smp.h.no-sysctl~ 2006-08-08 00:08:05.000000000 +0200 +++ libc/nptl/sysdeps/unix/sysv/linux/smp.h 2006-08-08 00:53:41.000000000 +0200 @@ -20,9 +20,14 @@ /* Test whether the machine has more than one processor. This is not the best test but good enough. More complicated tests would require `malloc' which is not available at that time. */ + +#include <sys/utsname.h> + static inline int is_smp_system (void) { - /* Assume all machines are SMP and/or CMT and/or SMT. */ - return 1; + struct utsname uts; + if(uname(&uts)<0) + uts.version[0] = '\0'; + return strcasestr(uts.version, "SMP") != NULL; }