ppc64le-support.patch
branchesr24
changeset 698 8066b2bdabfb
equal deleted inserted replaced
690:9291d123ef2b 698:8066b2bdabfb
       
     1 Index: mozilla/js/src/jscpucfg.h
       
     2 ===================================================================
       
     3 --- mozilla.orig/js/src/jscpucfg.h
       
     4 +++ mozilla/js/src/jscpucfg.h
       
     5 @@ -35,7 +35,7 @@
       
     6  # define JS_BITS_PER_WORD_LOG2   5
       
     7  # define JS_ALIGN_OF_POINTER 4
       
     8  
       
     9 -#elif defined(__APPLE__)
       
    10 +#elif defined(__APPLE__) || defined(__powerpc__) || defined(__ppc__)
       
    11  # if __LITTLE_ENDIAN__
       
    12  #  define IS_LITTLE_ENDIAN 1
       
    13  #  undef  IS_BIG_ENDIAN
       
    14 @@ -97,8 +97,7 @@
       
    15  # endif
       
    16  
       
    17  #elif defined(__sparc) || defined(__sparc__) || \
       
    18 -      defined(_POWER) || defined(__powerpc__) || \
       
    19 -      defined(__ppc__) || defined(__hppa) || \
       
    20 +      defined(_POWER) || defined(__hppa) || \
       
    21        defined(_MIPSEB) || defined(_BIG_ENDIAN)
       
    22  /* IA64 running HP-UX will have _BIG_ENDIAN defined.
       
    23   * IA64 running Linux will have endian.h and be handled above.
       
    24 Index: mozilla/js/src/assembler/wtf/Platform.h
       
    25 ===================================================================
       
    26 --- mozilla.orig/js/src/assembler/wtf/Platform.h
       
    27 +++ mozilla/js/src/assembler/wtf/Platform.h
       
    28 @@ -165,16 +165,22 @@
       
    29      || defined(__POWERPC__) \
       
    30      || defined(_M_PPC)      \
       
    31      || defined(__PPC)
       
    32 +#if !defined(__ppc64__) && !defined(__PPC64__)
       
    33  #define WTF_CPU_PPC 1
       
    34 +#endif
       
    35 +#if !defined(__LITTLE_ENDIAN__)
       
    36  #define WTF_CPU_BIG_ENDIAN 1
       
    37  #endif
       
    38 +#endif
       
    39  
       
    40  /* WTF_CPU_PPC64 - PowerPC 64-bit */
       
    41  #if   defined(__ppc64__) \
       
    42      || defined(__PPC64__)
       
    43  #define WTF_CPU_PPC64 1
       
    44 +#if !defined(__LITTLE_ENDIAN__)
       
    45  #define WTF_CPU_BIG_ENDIAN 1
       
    46  #endif
       
    47 +#endif
       
    48  
       
    49  /* WTF_CPU_SH4 - SuperH SH-4 */
       
    50  #if defined(__SH4__)
       
    51 Index: mozilla/nsprpub/pr/include/md/_linux.cfg
       
    52 ===================================================================
       
    53 --- mozilla.orig/nsprpub/pr/include/md/_linux.cfg
       
    54 +++ mozilla/nsprpub/pr/include/md/_linux.cfg
       
    55 @@ -29,8 +29,13 @@
       
    56  
       
    57  #ifdef __powerpc64__
       
    58  
       
    59 +#ifdef __LITTLE_ENDIAN__
       
    60 +#define IS_LITTLE_ENDIAN 1
       
    61 +#undef  IS_BIG_ENDIAN
       
    62 +#else
       
    63  #undef  IS_LITTLE_ENDIAN
       
    64  #define IS_BIG_ENDIAN    1
       
    65 +#endif
       
    66  #define IS_64
       
    67  
       
    68  #define PR_BYTES_PER_BYTE   1
       
    69 @@ -75,8 +80,13 @@
       
    70  
       
    71  #elif defined(__powerpc__)
       
    72  
       
    73 +#ifdef __LITTLE_ENDIAN__
       
    74 +#define IS_LITTLE_ENDIAN 1
       
    75 +#undef  IS_BIG_ENDIAN
       
    76 +#else
       
    77  #undef  IS_LITTLE_ENDIAN
       
    78  #define IS_BIG_ENDIAN    1
       
    79 +#endif
       
    80  
       
    81  #define PR_BYTES_PER_BYTE   1
       
    82  #define PR_BYTES_PER_SHORT  2