Skip to content

Commit

Permalink
deps: fix V8 architecture detection for s390x/ppc64
Browse files Browse the repository at this point in the history
  • Loading branch information
richardlau committed Jul 11, 2022
1 parent ceba89d commit 4bc623f
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion deps/v8/include/v8config.h
Original file line number Diff line number Diff line change
Expand Up @@ -674,6 +674,11 @@ V8 shared library set USING_V8_SHARED.
#if __riscv_xlen == 64
#define V8_TARGET_ARCH_RISCV64 1
#endif
#elif defined(__s390__)
#define V8_TARGET_ARCH_S390 1
#if defined(__s390x__)
#define V8_TARGET_ARCH_S390X 1
#endif
#else
#error Target architecture was not detected as supported by v8
#endif
Expand Down Expand Up @@ -770,7 +775,7 @@ V8 shared library set USING_V8_SHARED.
#else
#define V8_TARGET_LITTLE_ENDIAN 1
#endif
#elif __BIG_ENDIAN__ // FOR PPCGR on AIX
#elif defined(__BIG_ENDIAN__) // FOR PPCGR on AIX
#define V8_TARGET_BIG_ENDIAN 1
#elif V8_TARGET_ARCH_PPC_LE
#define V8_TARGET_LITTLE_ENDIAN 1
Expand All @@ -784,6 +789,12 @@ V8 shared library set USING_V8_SHARED.
#endif
#elif V8_TARGET_ARCH_RISCV64
#define V8_TARGET_LITTLE_ENDIAN 1
#elif defined(__BYTE_ORDER__)
#if __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
#define V8_TARGET_BIG_ENDIAN 1
#else
#define V8_TARGET_LITTLE_ENDIAN 1
#endif
#else
#error Unknown target architecture endianness
#endif
Expand Down

0 comments on commit 4bc623f

Please sign in to comment.