|
85 | 85 | * header and the script 'combine.sh' combines the whole zstd source code |
86 | 86 | * in a single file. |
87 | 87 | */ |
88 | | -#if defined(__linux) || defined(__linux__) || defined(linux) || defined(__gnu_linux__) || \ |
89 | | - defined(__CYGWIN__) || defined(__MSYS__) |
90 | | -#if !defined(_GNU_SOURCE) && !defined(__ANDROID__) /* NDK doesn't ship qsort_r(). */ |
| 88 | +#if (defined(__linux__) && !defined(__ANDROID__)) || defined(__CYGWIN__) || defined(__MSYS__) |
| 89 | +#ifndef _GNU_SOURCE |
91 | 90 | #define _GNU_SOURCE |
92 | 91 | #endif |
93 | 92 | #endif |
@@ -47866,10 +47865,12 @@ size_t ZSTD_decompressBlock(ZSTD_DCtx* dctx, |
47866 | 47865 | /*-************************************* |
47867 | 47866 | * Dependencies |
47868 | 47867 | ***************************************/ |
47869 | | -/* qsort_r is an extension. */ |
47870 | | -#if defined(__linux) || defined(__linux__) || defined(linux) || defined(__gnu_linux__) || \ |
47871 | | - defined(__CYGWIN__) || defined(__MSYS__) |
47872 | | -# if !defined(_GNU_SOURCE) && !defined(__ANDROID__) /* NDK doesn't ship qsort_r(). */ |
| 47868 | +/* qsort_r is an extension. |
| 47869 | + * |
| 47870 | + * Android NDK does not ship qsort_r(). |
| 47871 | + */ |
| 47872 | +#if (defined(__linux__) && !defined(__ANDROID__)) || defined(__CYGWIN__) || defined(__MSYS__) |
| 47873 | +# ifndef _GNU_SOURCE |
47873 | 47874 | # define _GNU_SOURCE |
47874 | 47875 | # endif |
47875 | 47876 | #endif |
@@ -48557,7 +48558,7 @@ void COVER_dictSelectionFree(COVER_dictSelection_t selection); |
48557 | 48558 | #ifndef ZDICT_QSORT |
48558 | 48559 | # if defined(__APPLE__) |
48559 | 48560 | # define ZDICT_QSORT ZDICT_QSORT_APPLE /* uses qsort_r() with a different order for parameters */ |
48560 | | -# elif defined(_GNU_SOURCE) |
| 48561 | +# elif (defined(__linux__) && !defined(__ANDROID__)) || defined(__CYGWIN__) || defined(__MSYS__) |
48561 | 48562 | # define ZDICT_QSORT ZDICT_QSORT_GNU /* uses qsort_r() */ |
48562 | 48563 | # elif defined(_WIN32) && defined(_MSC_VER) |
48563 | 48564 | # define ZDICT_QSORT ZDICT_QSORT_MSVC /* uses qsort_s() with a different order for parameters */ |
|
0 commit comments