Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(183)

Side by Side Diff: include/share/compat.h

Issue 2866623002: Include limits.h on Android to work around NDK deficiency (Closed)
Patch Set: Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « README.chromium ('k') | src/libFLAC/md5.c » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* libFLAC - Free Lossless Audio Codec library 1 /* libFLAC - Free Lossless Audio Codec library
2 * Copyright (C) 2012-2014 Xiph.org Foundation 2 * Copyright (C) 2012-2014 Xiph.org Foundation
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * - Redistributions of source code must retain the above copyright 8 * - Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 10 *
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after
168 #endif 168 #endif
169 169
170 #ifdef _WIN32 170 #ifdef _WIN32
171 #define flac_stat_s __stat64 /* stat struct */ 171 #define flac_stat_s __stat64 /* stat struct */
172 #define flac_fstat _fstat64 172 #define flac_fstat _fstat64
173 #else 173 #else
174 #define flac_stat_s stat /* stat struct */ 174 #define flac_stat_s stat /* stat struct */
175 #define flac_fstat fstat 175 #define flac_fstat fstat
176 #endif 176 #endif
177 177
178 #ifdef ANDROID
179 #include <limits.h>
180 #endif
181
178 #ifndef M_LN2 182 #ifndef M_LN2
179 #define M_LN2 0.69314718055994530942 183 #define M_LN2 0.69314718055994530942
180 #endif 184 #endif
181 #ifndef M_PI 185 #ifndef M_PI
182 #define M_PI 3.14159265358979323846 186 #define M_PI 3.14159265358979323846
183 #endif 187 #endif
184 188
185 /* FLAC needs to compile and work correctly on systems with a normal ISO C99 189 /* FLAC needs to compile and work correctly on systems with a normal ISO C99
186 * snprintf as well as Microsoft Visual Studio which has an non-standards 190 * snprintf as well as Microsoft Visual Studio which has an non-standards
187 * conformant snprint_s function. 191 * conformant snprint_s function.
188 * 192 *
189 * This function wraps the MS version to behave more like the the ISO version. 193 * This function wraps the MS version to behave more like the the ISO version.
190 */ 194 */
191 #include <stdarg.h> 195 #include <stdarg.h>
192 #ifdef __cplusplus 196 #ifdef __cplusplus
193 extern "C" { 197 extern "C" {
194 #endif 198 #endif
195 int flac_snprintf(char *str, size_t size, const char *fmt, ...); 199 int flac_snprintf(char *str, size_t size, const char *fmt, ...);
196 int flac_vsnprintf(char *str, size_t size, const char *fmt, va_list va); 200 int flac_vsnprintf(char *str, size_t size, const char *fmt, va_list va);
197 #ifdef __cplusplus 201 #ifdef __cplusplus
198 }; 202 };
199 #endif 203 #endif
200 204
201 #endif /* FLAC__SHARE__COMPAT_H */ 205 #endif /* FLAC__SHARE__COMPAT_H */
OLDNEW
« no previous file with comments | « README.chromium ('k') | src/libFLAC/md5.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698