diff --git a/Source/Core/Common/WindowsRegistry.cpp b/Source/Core/Common/WindowsRegistry.cpp index 2eb1ae9b9ce..60674206698 100644 --- a/Source/Core/Common/WindowsRegistry.cpp +++ b/Source/Core/Common/WindowsRegistry.cpp @@ -46,6 +46,11 @@ bool ReadValue(std::string* value, const std::string& subkey, const std::string& return true; } +// These explicit instantiations are needed to prevent linker errors when calling +// ReadValue in WinUpdater/Platform.cpp (for u32) and ArmCPUDetect.cpp (for u64) +template bool ReadValue(u32* value, const std::string& subkey, const std::string& name); +template bool ReadValue(u64* value, const std::string& subkey, const std::string& name); + OSVERSIONINFOW GetOSVersion() { // PEB may have faked data if the binary is launched with "compatibility mode" enabled. diff --git a/Source/Core/Common/WindowsRegistry.h b/Source/Core/Common/WindowsRegistry.h index ef789a98ca2..7dc3a52f914 100644 --- a/Source/Core/Common/WindowsRegistry.h +++ b/Source/Core/Common/WindowsRegistry.h @@ -9,8 +9,6 @@ namespace WindowsRegistry { template bool ReadValue(T* value, const std::string& subkey, const std::string& name); -template bool ReadValue(u32* value, const std::string& subkey, const std::string& name); -template bool ReadValue(u64* value, const std::string& subkey, const std::string& name); template <> bool ReadValue(std::string* value, const std::string& subkey, const std::string& name);