[libpng17] Check for CLOCK_PROCESS_CPUTIME_ID in /contrib/libtests/timepng.

Otherwise it does not build on platforms that don't supply clock_gettime().
This commit is contained in:
Glenn Randers-Pehrson
2016-05-16 18:59:47 -05:00
parent ba356b4e4d
commit f05407d292
3 changed files with 11 additions and 5 deletions

View File

@@ -44,8 +44,10 @@
# define voidcast(type, value) (value)
#endif /* __cplusplus */
#if ((defined(PNG_SEQUENTIAL_READ_SUPPORTED)) && defined(PNG_STDIO_SUPPORTED)\
&& defined(PNG_EASY_ACCESS_SUPPORTED) && defined(PNG_INFO_IMAGE_SUPPORTED))
#if (defined (CLOCK_PROCESS_CPUTIME_ID) &&
defined (PNG_SEQUENTIAL_READ_SUPPORTED) && defined(PNG_STDIO_SUPPORTED)\
&& defined(PNG_EASY_ACCESS_SUPPORTED) && defined(PNG_INFO_IMAGE_SUPPORTED)
typedef struct
{
FILE *input;