From b0026e1f5f9defa5861e24aa463a1c93de6ed9ef Mon Sep 17 00:00:00 2001 From: Jiri Appl Date: Tue, 9 Oct 2018 16:56:41 -0700 Subject: [PATCH] Enable building of ARM32 (#4349) Summary: The original logic was assuming that the only architectures that the code would build for on Windows were x86 and x64. This change will enable building for arm32 on Windows as well. Pull Request resolved: https://github.com/facebook/rocksdb/pull/4349 Differential Revision: D10280887 Pulled By: sagar0 fbshipit-source-id: 9ca0bede25505d22e13acf916d38aeeaaf5d981a --- util/thread_local.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/util/thread_local.cc b/util/thread_local.cc index dea2002a0..7346eff11 100644 --- a/util/thread_local.cc +++ b/util/thread_local.cc @@ -204,7 +204,7 @@ extern "C" { // The linker must not discard thread_callback_on_exit. (We force a reference // to this variable with a linker /include:symbol pragma to ensure that.) If // this variable is discarded, the OnThreadExit function will never be called. -#ifdef _WIN64 +#ifndef _X86_ // .CRT section is merged with .rdata on x64 so it must be constant data. #pragma const_seg(".CRT$XLB") @@ -219,7 +219,7 @@ const PIMAGE_TLS_CALLBACK p_thread_callback_on_exit = #pragma comment(linker, "/include:_tls_used") #pragma comment(linker, "/include:p_thread_callback_on_exit") -#else // _WIN64 +#else // _X86_ #pragma data_seg(".CRT$XLB") PIMAGE_TLS_CALLBACK p_thread_callback_on_exit = wintlscleanup::WinOnThreadExit; @@ -229,7 +229,7 @@ PIMAGE_TLS_CALLBACK p_thread_callback_on_exit = wintlscleanup::WinOnThreadExit; #pragma comment(linker, "/INCLUDE:__tls_used") #pragma comment(linker, "/INCLUDE:_p_thread_callback_on_exit") -#endif // _WIN64 +#endif // _X86_ #else // https://github.com/couchbase/gperftools/blob/master/src/windows/port.cc