summaryrefslogtreecommitdiff
path: root/src/common/x64/cpu_detect.cpp
diff options
context:
space:
mode:
authorGravatar Jan Beich2016-10-10 03:26:27 +0000
committerGravatar Jan Beich2016-10-27 23:28:30 +0000
commit3d801be97d82b69ff800f939dd92d97ff012a868 (patch)
tree963b7bb82fda6f1d1b7f5d84c54d44bb797827a6 /src/common/x64/cpu_detect.cpp
parentcommon: convert to standard stat()/fstat() interfaces (diff)
downloadyuzu-3d801be97d82b69ff800f939dd92d97ff012a868.tar.gz
yuzu-3d801be97d82b69ff800f939dd92d97ff012a868.tar.xz
yuzu-3d801be97d82b69ff800f939dd92d97ff012a868.zip
common: some FreeBSD headers are incomplete to avoid namespace pollution
In file included from src/common/x64/cpu_detect.cpp:16: /usr/include/machine/cpufunc.h:66:17: error: unknown type name 'u_int' static __inline u_int ^ /usr/include/machine/cpufunc.h:67:6: error: unknown type name 'u_int' bsfl(u_int mask) ^ /usr/include/machine/cpufunc.h:69:2: error: unknown type name 'u_int' u_int result; ^ /usr/include/machine/cpufunc.h:75:17: error: unknown type name 'u_long'; did you mean 'long'? static __inline u_long ^ /usr/include/machine/cpufunc.h:76:6: error: unknown type name 'u_long'; did you mean 'long'? bsfq(u_long mask) ^ /usr/include/machine/cpufunc.h:78:2: error: use of undeclared identifier 'u_long'; did you mean 'long'? u_long result; ^ [...]
Diffstat (limited to 'src/common/x64/cpu_detect.cpp')
-rw-r--r--src/common/x64/cpu_detect.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/common/x64/cpu_detect.cpp b/src/common/x64/cpu_detect.cpp
index 6ddf9b70c..4abbdb96a 100644
--- a/src/common/x64/cpu_detect.cpp
+++ b/src/common/x64/cpu_detect.cpp
@@ -13,8 +13,10 @@ namespace Common {
13#ifndef _MSC_VER 13#ifndef _MSC_VER
14 14
15#ifdef __FreeBSD__ 15#ifdef __FreeBSD__
16#include <machine/cpufunc.h> 16// clang-format off
17#include <sys/types.h> 17#include <sys/types.h>
18#include <machine/cpufunc.h>
19// clang-format on
18#endif 20#endif
19 21
20static inline void __cpuidex(int info[4], int function_id, int subfunction_id) { 22static inline void __cpuidex(int info[4], int function_id, int subfunction_id) {