mirror of
https://git.h3cjp.net/H3cJP/yuzu.git
synced 2024-12-14 06:45:17 +00:00
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; ^ [...]
This commit is contained in:
parent
26af2b644c
commit
3d801be97d
|
@ -13,8 +13,10 @@ namespace Common {
|
|||
#ifndef _MSC_VER
|
||||
|
||||
#ifdef __FreeBSD__
|
||||
#include <machine/cpufunc.h>
|
||||
// clang-format off
|
||||
#include <sys/types.h>
|
||||
#include <machine/cpufunc.h>
|
||||
// clang-format on
|
||||
#endif
|
||||
|
||||
static inline void __cpuidex(int info[4], int function_id, int subfunction_id) {
|
||||
|
|
Loading…
Reference in a new issue