source: packages/lang/perl/patches/101-fix-cross-compile-endianness-detection.patch @ 21465

Last change on this file since 21465 was 21465, checked in by juhosg, 7 years ago

packages/perl: fix target system endianness detection (closes #6900)

File size: 640 bytes
  • config_h.SH

    a b sed <<!GROK!THIS! >$CONFIG_H -e 's!^#und 
    5353#ifndef _config_h_ 
    5454#define _config_h_ 
    5555 
     56#if defined(USE_CROSS_COMPILE) && !defined(__LITTLE_ENDIAN__) && !defined(__BIG_ENDIAN__) 
     57#  include <endian.h> 
     58#  if defined(__BYTE_ORDER) && defined(__LITTLE_ENDIAN) && defined(__BIG_ENDIAN) 
     59#    if (__BYTE_ORDER == __LITTLE_ENDIAN) 
     60#      define __LITTLE_ENDIAN__ 
     61#    elif (__BYTE_ORDER == __BIG_ENDIAN) 
     62#      define __BIG_ENDIAN__ 
     63#    else 
     64#      error Unknown endianness 
     65#    endif 
     66#  endif 
     67#endif 
     68 
    5669/* LOC_SED: 
    5770 *      This symbol holds the complete pathname to the sed program. 
    5871 */ 
Note: See TracBrowser for help on using the repository browser.