diff options
author | Ashkan Aliabadi <ashkanaliabadi@fb.com> | 2020-04-05 12:26:02 -0700 |
---|---|---|
committer | Ashkan Aliabadi <ashkanaliabadi@fb.com> | 2020-04-06 19:21:31 -0700 |
commit | 02fe981f781fff599d522cb61c3557e446c2bb28 (patch) | |
tree | eb3376471f680bc52c246971acbd6548aeafb74f /src | |
parent | 0cc563acb9baac39f2c1349bc42098c4a1da59e3 (diff) | |
download | cpuinfo-02fe981f781fff599d522cb61c3557e446c2bb28.tar.gz |
Fix a build error some users are experiencing wherein __NR_getcpu is not defined.
Diffstat (limited to 'src')
-rw-r--r-- | src/api.c | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -10,6 +10,9 @@ #include <unistd.h> #include <sys/syscall.h> + #if !defined(__NR_getcpu) + #include <asm-generic/unistd.h> + #endif #endif bool cpuinfo_is_initialized = false; |