1 INCLUDE(FeatureSummary)
3 CHECK_STRUCT_HAS_MEMBER ("struct stat" st_mtim "sys/types.h;sys/stat.h"
4 HAVE_STRUCT_STAT_ST_MTIM LANGUAGE C)
5 CHECK_STRUCT_HAS_MEMBER ("struct stat" st_mtimespec "sys/types.h;sys/stat.h"
6 HAVE_STRUCT_STAT_ST_MTIMESPEC LANGUAGE C)
7 CHECK_STRUCT_HAS_MEMBER("struct stat" st_mtime_nsec sys/stat.h
8 HAVE_STRUCT_STAT_MTIME_NSEC LANGUAGE C)
10 IF (HAVE_STRUCT_STAT_ST_MTIM)
11 CHECK_STRUCT_HAS_MEMBER("struct stat" st_mtim.tv_nsec sys/stat.h
12 HAVE_STRUCT_STAT_NSEC LANGUAGE C)
13 ELSEIF (HAVE_STRUCT_STAT_ST_MTIMESPEC)
14 CHECK_STRUCT_HAS_MEMBER("struct stat" st_mtimespec.tv_nsec sys/stat.h
15 HAVE_STRUCT_STAT_NSEC LANGUAGE C)
17 SET( HAVE_STRUCT_STAT_NSEC ON )
20 IF (HAVE_STRUCT_STAT_NSEC OR WIN32)
21 OPTION( USE_NSEC "Care about sub-second file mtimes and ctimes" ON )
26 ADD_FEATURE_INFO(nanoseconds USE_NSEC "whether to use sub-second file mtimes and ctimes")