File tree Expand file tree Collapse file tree 2 files changed +21
-21
lines changed
Expand file tree Collapse file tree 2 files changed +21
-21
lines changed Original file line number Diff line number Diff line change @@ -31,6 +31,7 @@ INCLUDE(CheckStructHasMember)
3131INCLUDE (AddCFlagIfSupported)
3232INCLUDE (FindPkgConfig)
3333INCLUDE (FindThreads)
34+ INCLUDE (FindStatNsec)
3435INCLUDE (FeatureSummary)
3536
3637# Build options
@@ -94,27 +95,6 @@ IF(MSVC)
9495 OPTION (MSVC_CRTDBG "Enable CRTDBG memory leak reporting" OFF )
9596ENDIF ()
9697
97- CHECK_STRUCT_HAS_MEMBER ("struct stat" st_mtim "sys/types.h;sys/stat.h"
98- HAVE_STRUCT_STAT_ST_MTIM LANGUAGE C)
99- CHECK_STRUCT_HAS_MEMBER ("struct stat" st_mtimespec "sys/types.h;sys/stat.h"
100- HAVE_STRUCT_STAT_ST_MTIMESPEC LANGUAGE C)
101- CHECK_STRUCT_HAS_MEMBER("struct stat" st_mtime_nsec sys/stat.h
102- HAVE_STRUCT_STAT_MTIME_NSEC LANGUAGE C)
103-
104- IF (HAVE_STRUCT_STAT_ST_MTIM)
105- CHECK_STRUCT_HAS_MEMBER("struct stat" st_mtim.tv_nsec sys/stat.h
106- HAVE_STRUCT_STAT_NSEC LANGUAGE C)
107- ELSEIF (HAVE_STRUCT_STAT_ST_MTIMESPEC)
108- CHECK_STRUCT_HAS_MEMBER("struct stat" st_mtimespec.tv_nsec sys/stat.h
109- HAVE_STRUCT_STAT_NSEC LANGUAGE C)
110- ELSE ()
111- SET ( HAVE_STRUCT_STAT_NSEC ON )
112- ENDIF ()
113-
114- IF (HAVE_STRUCT_STAT_NSEC OR WIN32 )
115- OPTION ( USE_NSEC "Care about sub-second file mtimes and ctimes" ON )
116- ENDIF ()
117-
11898# This function splits the sources files up into their appropriate
11999# subdirectories. This is especially useful for IDEs like Xcode and
120100# Visual Studio, so that you can navigate into the libgit2_clar project,
Original file line number Diff line number Diff line change 1+ CHECK_STRUCT_HAS_MEMBER ("struct stat" st_mtim "sys/types.h;sys/stat.h"
2+ HAVE_STRUCT_STAT_ST_MTIM LANGUAGE C)
3+ CHECK_STRUCT_HAS_MEMBER ("struct stat" st_mtimespec "sys/types.h;sys/stat.h"
4+ HAVE_STRUCT_STAT_ST_MTIMESPEC LANGUAGE C)
5+ CHECK_STRUCT_HAS_MEMBER("struct stat" st_mtime_nsec sys/stat.h
6+ HAVE_STRUCT_STAT_MTIME_NSEC LANGUAGE C)
7+
8+ IF (HAVE_STRUCT_STAT_ST_MTIM)
9+ CHECK_STRUCT_HAS_MEMBER("struct stat" st_mtim.tv_nsec sys/stat.h
10+ HAVE_STRUCT_STAT_NSEC LANGUAGE C)
11+ ELSEIF (HAVE_STRUCT_STAT_ST_MTIMESPEC)
12+ CHECK_STRUCT_HAS_MEMBER("struct stat" st_mtimespec.tv_nsec sys/stat.h
13+ HAVE_STRUCT_STAT_NSEC LANGUAGE C)
14+ ELSE ()
15+ SET ( HAVE_STRUCT_STAT_NSEC ON )
16+ ENDIF ()
17+
18+ IF (HAVE_STRUCT_STAT_NSEC OR WIN32 )
19+ OPTION ( USE_NSEC "Care about sub-second file mtimes and ctimes" ON )
20+ ENDIF ()
You can’t perform that action at this time.
0 commit comments