]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
runtime: Check for CPU_COUNT itself, don't check glibc version.
authorIan Lance Taylor <ian@gcc.gnu.org>
Fri, 3 Oct 2014 05:04:59 +0000 (05:04 +0000)
committerIan Lance Taylor <ian@gcc.gnu.org>
Fri, 3 Oct 2014 05:04:59 +0000 (05:04 +0000)
Fixes issue 38.

From-SVN: r215832

libgo/runtime/getncpu-linux.c

index 0122b77c9ffcd75302e62e8eb33354060e40f436..de6606ff47cb2eee4ae943b28200fb9bb60d77fb 100644 (file)
@@ -6,7 +6,7 @@
 #include <sched.h>
 
 // CPU_COUNT is only provided by glibc 2.6 or higher
-#if !defined(__GLIBC_PREREQ) || !__GLIBC_PREREQ(2, 6)
+#ifndef CPU_COUNT
 #define CPU_COUNT(set) _CPU_COUNT((unsigned int *)(set), sizeof(*(set))/sizeof(unsigned int))
 static int _CPU_COUNT(unsigned int *set, size_t len) {
        int cnt;