Ticket #64083: 1003-typedef.patch

File 1003-typedef.patch, 1.3 KB (added by RobK88, 2 years ago)

Renumbered Patch File -- Needed for working Portfile

  • main.c

    old new  
    7474#include <string.h>
    7575#include <assert.h>
    7676#include <math.h>
     77#include <stdint.h>
    7778
    7879#ifndef USE_FD
    7980#include <unistd.h>
     
    103104        #define unlikely(x) (x)
    104105#endif
    105106
    106 // user defined types
    107 //typedef unsigned int          uint;
    108 typedef unsigned char           uint8;
    109 typedef unsigned short          uint16;
    110 typedef unsigned int            uint32;
    111 #ifdef WIN
    112 typedef __int64                         uint64;
    113 #else
    114 typedef unsigned long long      uint64;
    115 #endif
    116 
    117 typedef char                            int8;
    118 typedef short                           int16;
    119 typedef int                                     int32;
    120 #ifdef WIN
    121 typedef __int64                         int64;
    122 #else
    123 typedef long long                       int64;
    124 #endif
    125 
    126 
    127 typedef signed int                      sint;
    128 typedef signed char                     sint8;
    129 typedef signed short            sint16;
    130 typedef signed int                      sint32;
    131 #ifdef WIN
    132 typedef __int64                         sint64;
    133 #else
    134 typedef signed long long        sint64;
    135 #endif
     107typedef unsigned int uint;
     108typedef uint8_t uint8;
     109typedef uint16_t uint16;
     110typedef uint32_t uint32;
     111typedef uint64_t uint64;
     112
     113typedef int8_t                          int8;
     114typedef int16_t                         int16;
     115typedef int32_t                         int32;
     116typedef int64_t                     int64;
     117
     118typedef signed int              sint;
     119typedef int8_t                  sint8;
     120typedef int16_t                 sint16;
     121typedef int32_t                 sint32;
     122typedef int64_t                 sint64;
    136123
    137124#define BITS_IN_BUF (8)
    138125