From 508cff55f6a26fce3c2bc26b3d00de9c6f96c6e6 Mon Sep 17 00:00:00 2001 From: Brad King Date: Thu, 17 Feb 2005 11:27:15 -0500 Subject: ENH: Added try-compile KWSYS_STAT_HAS_ST_MTIM. This tests whether struct stat has the extra st_mtim member that has high resolution times. --- bootstrap | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/bootstrap b/bootstrap index 0cd0d06..afc23c6 100755 --- a/bootstrap +++ b/bootstrap @@ -189,7 +189,8 @@ cmake_kwsys_config_replace_string () s/@KWSYS_IOS_USE_SSTREAM@/${KWSYS_IOS_USE_SSTREAM}/g; s/@KWSYS_IOS_USE_STRSTREAM_H@/${KWSYS_IOS_USE_STRSTREAM_H}/g; s/@KWSYS_IOS_USE_STRSTREA_H@/${KWSYS_IOS_USE_STRSTREA_H}/g; - s/@KWSYS_STL_HAVE_STD@/${KWSYS_STL_HAVE_STD}/g;}" >> "${OUTFILE}.tmp" + s/@KWSYS_STL_HAVE_STD@/${KWSYS_STL_HAVE_STD}/g; + s/@KWSYS_STAT_HAS_ST_MTIM@/${KWSYS_STAT_HAS_ST_MTIM}/g;}" >> "${OUTFILE}.tmp" if [ -f "${OUTFILE}.tmp" ]; then if diff "${OUTFILE}" "${OUTFILE}.tmp" > /dev/null 2> /dev/null ; then #echo "Files are the same" @@ -695,6 +696,7 @@ KWSYS_IOS_HAVE_STD=0 KWSYS_IOS_USE_SSTREAM=0 KWSYS_IOS_USE_ANSI=0 KWSYS_STL_HAVE_STD=0 +KWSYS_STAT_HAS_ST_MTIM=0 if cmake_try_run "${cmake_cxx_compiler}" \ "${cmake_cxx_flags} -DTEST_KWSYS_STL_HAVE_STD" \ @@ -754,6 +756,15 @@ if [ "x$KWSYS_IOS_USE_SSTREAM" = "x0" ]; then fi fi +if cmake_try_run "${cmake_cxx_compiler}" \ + "${cmake_cxx_flags} -DTEST_KWSYS_STAT_HAS_ST_MTIM" \ + "${cmake_source_dir}/Source/kwsys/kwsysPlatformCxxTests.cxx" >> cmake_bootstrap.log 2>&1; then + KWSYS_STAT_HAS_ST_MTIM=1 + echo "${cmake_cxx_compiler} has struct stat with st_mtim member" +else + echo "${cmake_cxx_compiler} does not have struct stat with st_mtim member" +fi + # Just to be safe, let us store compiler and flags to the header file cmake_bootstrap_version='$Revision$' -- cgit v0.12