Skip to content

Commit d46fb3e

Browse files
authored
Merge pull request #925 from Cyan4973/aix
fix include for AIX
2 parents da79cc1 + 681dc1d commit d46fb3e

File tree

1 file changed

+17
-5
lines changed

1 file changed

+17
-5
lines changed

xxhash.h

+17-5
Original file line numberDiff line numberDiff line change
@@ -589,7 +589,11 @@ typedef uint32_t XXH32_hash_t;
589589
#elif !defined (__VMS) \
590590
&& (defined (__cplusplus) \
591591
|| (defined (__STDC_VERSION__) && (__STDC_VERSION__ >= 199901L) /* C99 */) )
592-
# include <stdint.h>
592+
# ifdef _AIX
593+
# include <inttypes.h>
594+
# else
595+
# include <stdint.h>
596+
# endif
593597
typedef uint32_t XXH32_hash_t;
594598

595599
#else
@@ -863,7 +867,11 @@ typedef uint64_t XXH64_hash_t;
863867
#elif !defined (__VMS) \
864868
&& (defined (__cplusplus) \
865869
|| (defined (__STDC_VERSION__) && (__STDC_VERSION__ >= 199901L) /* C99 */) )
866-
# include <stdint.h>
870+
# ifdef _AIX
871+
# include <inttypes.h>
872+
# else
873+
# include <stdint.h>
874+
# endif
867875
typedef uint64_t XXH64_hash_t;
868876
#else
869877
# include <limits.h>
@@ -2479,10 +2487,14 @@ static void* XXH_memcpy(void* dest, const void* src, size_t size)
24792487
#if !defined (__VMS) \
24802488
&& (defined (__cplusplus) \
24812489
|| (defined (__STDC_VERSION__) && (__STDC_VERSION__ >= 199901L) /* C99 */) )
2482-
# include <stdint.h>
2483-
typedef uint8_t xxh_u8;
2490+
# ifdef _AIX
2491+
# include <inttypes.h>
2492+
# else
2493+
# include <stdint.h>
2494+
# endif
2495+
typedef uint8_t xxh_u8;
24842496
#else
2485-
typedef unsigned char xxh_u8;
2497+
typedef unsigned char xxh_u8;
24862498
#endif
24872499
typedef XXH32_hash_t xxh_u32;
24882500

0 commit comments

Comments
 (0)