cmake: add check for suseconds_t
And fix the HAVE_LONGLONG define Ref: #11964 Closes #11977
This commit is contained in:
parent
a8c773845f
commit
290622cea6
@ -1071,6 +1071,7 @@ check_type_size("long" SIZEOF_LONG)
|
|||||||
check_type_size("int" SIZEOF_INT)
|
check_type_size("int" SIZEOF_INT)
|
||||||
check_type_size("__int64" SIZEOF___INT64)
|
check_type_size("__int64" SIZEOF___INT64)
|
||||||
check_type_size("time_t" SIZEOF_TIME_T)
|
check_type_size("time_t" SIZEOF_TIME_T)
|
||||||
|
check_type_size("suseconds_t" SIZEOF_SUSECONDS_T)
|
||||||
if(NOT HAVE_SIZEOF_SSIZE_T)
|
if(NOT HAVE_SIZEOF_SSIZE_T)
|
||||||
if(SIZEOF_LONG EQUAL SIZEOF_SIZE_T)
|
if(SIZEOF_LONG EQUAL SIZEOF_SIZE_T)
|
||||||
set(ssize_t long)
|
set(ssize_t long)
|
||||||
@ -1081,9 +1082,12 @@ if(NOT HAVE_SIZEOF_SSIZE_T)
|
|||||||
endif()
|
endif()
|
||||||
# off_t is sized later, after the HAVE_FILE_OFFSET_BITS test
|
# off_t is sized later, after the HAVE_FILE_OFFSET_BITS test
|
||||||
|
|
||||||
if(HAVE_SIZEOF_LONG_LONG)
|
if(SIZEOF_LONG_LONG)
|
||||||
set(HAVE_LONGLONG 1)
|
set(HAVE_LONGLONG 1)
|
||||||
endif()
|
endif()
|
||||||
|
if(SIZEOF_SUSECONDS_T)
|
||||||
|
set(HAVE_SUSECONDS_T 1)
|
||||||
|
endif()
|
||||||
|
|
||||||
if(NOT CMAKE_CROSSCOMPILING)
|
if(NOT CMAKE_CROSSCOMPILING)
|
||||||
find_file(RANDOM_FILE urandom /dev)
|
find_file(RANDOM_FILE urandom /dev)
|
||||||
|
|||||||
@ -370,6 +370,9 @@
|
|||||||
/* Define to 1 if the compiler supports the 'long long' data type. */
|
/* Define to 1 if the compiler supports the 'long long' data type. */
|
||||||
#cmakedefine HAVE_LONGLONG 1
|
#cmakedefine HAVE_LONGLONG 1
|
||||||
|
|
||||||
|
/* Define to 1 if you have the 'suseconds_t' data type. */
|
||||||
|
#cmakedefine HAVE_SUSECONDS_T 1
|
||||||
|
|
||||||
/* Define to 1 if you have the MSG_NOSIGNAL flag. */
|
/* Define to 1 if you have the MSG_NOSIGNAL flag. */
|
||||||
#cmakedefine HAVE_MSG_NOSIGNAL 1
|
#cmakedefine HAVE_MSG_NOSIGNAL 1
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user