summaryrefslogtreecommitdiff
path: root/configure.cmake
diff options
context:
space:
mode:
authorVladislav Vaintroub <vvaintroub@macbook.local>2009-12-05 16:15:17 +0100
committerVladislav Vaintroub <vvaintroub@macbook.local>2009-12-05 16:15:17 +0100
commit92642d06397557e279cb377b1db4619de5ed199c (patch)
treec9f640b2306ce433340e8f5a32eaef7a6e29b758 /configure.cmake
parentf03eed15364ea7e219f457a1b36918255c1107b1 (diff)
downloadmariadb-git-92642d06397557e279cb377b1db4619de5ed199c.tar.gz
fdatasync is not documented on Snow Leopard and is not in unistd.h
CMake finds it as it is expored by system libraries, though attempts to use it will result bring a warning. Fix by using CHECK_SYMBOL_EXISTS instead of CHECK_FUNCTION_EXISTS
Diffstat (limited to 'configure.cmake')
-rw-r--r--configure.cmake5
1 files changed, 3 insertions, 2 deletions
diff --git a/configure.cmake b/configure.cmake
index d16e19166d5..b34d5b070d2 100644
--- a/configure.cmake
+++ b/configure.cmake
@@ -21,6 +21,7 @@ INCLUDE (CheckLibraryExists)
INCLUDE (CheckFunctionExists)
INCLUDE (CheckCCompilerFlag)
INCLUDE (CheckCSourceRuns)
+INCLUDE (CheckSymbolExists)
# Sometimes it is handy to know if PIC option
@@ -521,7 +522,7 @@ ENDIF()
CHECK_FUNCTION_EXISTS_UNIX (fchmod HAVE_FCHMOD)
CHECK_FUNCTION_EXISTS_UNIX (fcntl HAVE_FCNTL)
CHECK_FUNCTION_EXISTS_UNIX (fconvert HAVE_FCONVERT)
-CHECK_FUNCTION_EXISTS_UNIX (fdatasync HAVE_FDATASYNC)
+CHECK_SYMBOL_EXISTS_UNIX(fdatasync "unistd.h" HAVE_FDATASYNC)
CHECK_FUNCTION_EXISTS_UNIX (fesetround HAVE_FESETROUND)
CHECK_FUNCTION_EXISTS_UNIX (fpsetmask HAVE_FPSETMASK)
CHECK_FUNCTION_EXISTS_UNIX (fseeko HAVE_FSEEKO)
@@ -657,7 +658,7 @@ CHECK_FUNCTION_EXISTS_UNIX(rdtscll HAVE_RDTSCLL)
#
# Tests for symbols
#
-INCLUDE (CheckSymbolExists)
+
CHECK_SYMBOL_EXISTS_UNIX(sys_errlist "stdio.h" HAVE_SYS_ERRLIST)
CHECK_SYMBOL_EXISTS_UNIX(madvise "sys/mman.h" HAVE_DECL_MADVISE)
CHECK_SYMBOL_EXISTS_UNIX(tzname "time.h" HAVE_TZNAME)