2 Description: This patch fixes FTBFS for x86_x32 architecture (x86_64
3 with 32-bit integers, longs and pointers). HiPE still doesn't work
4 and probably never will.
5 Last-Modified: Sun, 27 Dec 2015 12:39:07 +0300
7 --- a/erts/lib_src/pthread/ethread.c
8 +++ b/erts/lib_src/pthread/ethread.c
11 ethr_x86_cpuid__(int *eax, int *ebx, int *ecx, int *edx)
13 -#if ETHR_SIZEOF_PTR == 4
14 +#if ETHR_SIZEOF_PTR == 4 && (!defined(__x86_64__) || !(__x86_64__ && __ILP32__))
17 * If it is possible to toggle eflags bit 21,
22 -#if ETHR_SIZEOF_PTR == 4 && defined(__PIC__) && __PIC__
23 +#if ETHR_SIZEOF_PTR == 4 && (!defined(__x86_64__) || !(__x86_64__ && __ILP32__)) && defined(__PIC__) && __PIC__
25 * When position independet code is used in 32-bit mode, the B register
26 * is used for storage of global offset table address, and we may not