aboutsummaryrefslogtreecommitdiffstats
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2008-01-11 06:01:51 -0800
committerChris Robinson <[email protected]>2008-01-11 06:01:51 -0800
commita97ecb8690c64a6007ad3f0e983cb8ef67b47795 (patch)
treedfc3b7c59098ac593c782b7ebe5a01610c43be8c /CMakeLists.txt
parentbc56c00a9a99ccbf2523ecb5f25a0e14922aed56 (diff)
Add a timing wrapper, using gettimeofday
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt5
1 files changed, 5 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index a35c5dea..86fc4fd1 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -132,6 +132,11 @@ ENDIF()
# Check if we have Windows headers
CHECK_INCLUDE_FILE(windows.h HAVE_WINDOWS_H)
IF(NOT "${HAVE_WINDOWS_H}")
+ CHECK_FUNCTION_EXISTS(gettimeofday HAVE_GETTIMEOFDAY)
+ IF(NOT "${HAVE_GETTIMEOFDAY}")
+ MESSAGE(FATAL_ERROR "No timing function found!")
+ ENDIF()
+
# We need pthreads outside of Windows
CHECK_INCLUDE_FILE(pthread.h HAVE_PTHREAD_H)
IF(NOT "${HAVE_PTHREAD_H}")