lede-packages-rs

git clone git://archive.git.mtrnord.blog/MTRNord/lede-packages-rs.git
Log | Files | Refs | README | LICENSE

0010-platform.patch (804B)


      1 --- a/pico/lib/picopltf.h
      2 +++ b/pico/lib/picopltf.h
      3 @@ -39,6 +39,8 @@
      4  #define PICO_MacOSX     5   /* Macintosh OS X */
      5  #define PICO_Linux      7   /* Linux */
      6  
      7 +#define PICO_GENERIC    99  /* Generic */
      8 +
      9  /* * definition of current platform ***/
     10  #if !defined(PICO_PLATFORM)
     11  #if defined(_WIN32)
     12 @@ -48,7 +50,7 @@
     13  #elif defined(linux) || defined(__linux__) || defined(__linux)
     14  #define PICO_PLATFORM    PICO_Linux
     15  #else
     16 -#error PICO_PLATFORM not defined
     17 +#define PICO_PLATFORM    PICO_GENERIC
     18  #endif
     19  #endif /* !defined(PICO_PLATFORM) */
     20  
     21 @@ -64,7 +66,8 @@
     22  #define PICO_PLATFORM_STRING "UnknownPlatform"
     23  #endif
     24  
     25 -#if (PICO_PLATFORM == PICO_MacOSX)
     26 +#include <endian.h>
     27 +#if __BYTE_ORDER == __BIG_ENDIAN
     28  #define PICO_ENDIANNESS ENDIANNESS_BIG
     29  #else
     30  #define PICO_ENDIANNESS ENDIANNESS_LITTLE