Saulius Krasuckas : ntdll: Check __WINE_PE_BUILD instead of compiler macros.

Alexandre Julliard julliard at winehq.org
Tue Mar 1 15:45:31 CST 2022


Module: wine
Branch: master
Commit: f72978ad0751159c00283406856b0c02d2b3cfca
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=f72978ad0751159c00283406856b0c02d2b3cfca

Author: Saulius Krasuckas <saulius2 at ar-fi.lt>
Date:   Tue Mar  1 02:42:05 2022 +0200

ntdll: Check __WINE_PE_BUILD instead of compiler macros.

Fixes compilation on Cygwin, undeclared identifiers: _alldiv, _allmul,
_allrem, _aulldiv, _aullrem.

Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=52607
Signed-off-by: Saulius Krasuckas <saulius2 at ar-fi.lt>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/ntdll/large_int.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dlls/ntdll/large_int.c b/dlls/ntdll/large_int.c
index 20ffd646a3e..b38074158c8 100644
--- a/dlls/ntdll/large_int.c
+++ b/dlls/ntdll/large_int.c
@@ -520,7 +520,7 @@ NTSTATUS WINAPI RtlInt64ToUnicodeString(
 #ifdef __i386__
 
 /* those builtin functions use stdcall calling convention, but compilers reference them without stdcall declarations */
-#if defined(__MINGW32__) || defined(_MSC_VER)
+#ifdef __WINE_PE_BUILD
 LONGLONG WINAPI _alldiv( LONGLONG a, LONGLONG b ) asm(__ASM_NAME("_alldiv"));
 LONGLONG WINAPI _allmul( LONGLONG a, LONGLONG b ) asm(__ASM_NAME("_allmul"));
 LONGLONG WINAPI _allrem( LONGLONG a, LONGLONG b ) asm(__ASM_NAME("_allrem"));




More information about the wine-cvs mailing list