diff --git a/Externals/AGS_SDK b/Externals/AGS_SDK index dbeff30568a..7d2d1a293da 160000 --- a/Externals/AGS_SDK +++ b/Externals/AGS_SDK @@ -1 +1 @@ -Subproject commit dbeff30568aa1494d6f520232ea79cdaa1a2398f +Subproject commit 7d2d1a293dae2aed39af8b1248f6ac27a554d974 diff --git a/src/xrCore/CMakeLists.txt b/src/xrCore/CMakeLists.txt index 556742ef956..5db2beab9db 100644 --- a/src/xrCore/CMakeLists.txt +++ b/src/xrCore/CMakeLists.txt @@ -12,8 +12,6 @@ set(SRC_FILES "_color.h" "_compressed_normal.cpp" "_compressed_normal.h" - "cpuid.cpp" - "cpuid.h" "crc32.cpp" "_cylinder.h" "dump_string.cpp" @@ -91,6 +89,8 @@ set(SRC_FILES "xrDebug.cpp" "xrDebug.h" "xrDebug_macros.h" + "xr_cpuid.cpp" + "xr_cpuid.h" "xr_ini.cpp" "xr_ini.h" "xrMemory.cpp" diff --git a/src/xrCore/_math.h b/src/xrCore/_math.h index e2a4c98d401..956c9c5a43e 100644 --- a/src/xrCore/_math.h +++ b/src/xrCore/_math.h @@ -1,7 +1,7 @@ #pragma once #include "_types.h" -#include "cpuid.h" +#include "xr_cpuid.h" namespace FPU { diff --git a/src/xrCore/xrCore.vcxproj b/src/xrCore/xrCore.vcxproj index ec12a77a4dd..4e9fbc2b3bf 100644 --- a/src/xrCore/xrCore.vcxproj +++ b/src/xrCore/xrCore.vcxproj @@ -53,7 +53,7 @@ call .GitInfo.cmd - + @@ -152,7 +152,7 @@ call .GitInfo.cmd - + diff --git a/src/xrCore/xrCore.vcxproj.filters b/src/xrCore/xrCore.vcxproj.filters index 7e7b8a9b27b..fedde81e6a9 100644 --- a/src/xrCore/xrCore.vcxproj.filters +++ b/src/xrCore/xrCore.vcxproj.filters @@ -147,7 +147,7 @@ Math - + Math\CPU @@ -431,7 +431,7 @@ Math - + Math\CPU diff --git a/src/xrCore/cpuid.cpp b/src/xrCore/xr_cpuid.cpp similarity index 96% rename from src/xrCore/cpuid.cpp rename to src/xrCore/xr_cpuid.cpp index 11c0ae1aee9..e3dfa7e17fc 100644 --- a/src/xrCore/cpuid.cpp +++ b/src/xrCore/xr_cpuid.cpp @@ -1,7 +1,11 @@ #include "stdafx.h" #pragma hdrstop -#include "cpuid.h" +#if (defined(XR_PLATFORM_LINUX) || defined(XR_PLATFORM_FREEBSD)) && defined(XR_COMPILER_GCC) +#include +#endif + +#include "xr_cpuid.h" #include #include @@ -25,8 +29,8 @@ void nativeCpuId(int regs[4], int i) { #ifdef XR_PLATFORM_WINDOWS __cpuid((int *)regs, (int)i); -#elif (defined(XR_PLATFORM_LINUX) || defined(XR_PLATFORM_FREEBSD)) && defined(GCC) - __cpuid((int)i, (int *)regs); +#elif (defined(XR_PLATFORM_LINUX) || defined(XR_PLATFORM_FREEBSD)) && defined(XR_COMPILER_GCC) + __cpuid((int)i, regs[0], regs[1], regs[2], regs[3]); #elif defined(XR_PLATFORM_LINUX) || defined(XR_PLATFORM_FREEBSD) #if defined(XR_ARCHITECTURE_X86) || defined(XR_ARCHITECTURE_X64) asm volatile("cpuid" : diff --git a/src/xrCore/cpuid.h b/src/xrCore/xr_cpuid.h similarity index 100% rename from src/xrCore/cpuid.h rename to src/xrCore/xr_cpuid.h