aboutsummaryrefslogtreecommitdiff
path: root/modules/CheckPrototypeExists.cmake
diff options
context:
space:
mode:
authorAlexander Neundorf <neundorf@kde.org>2006-03-07 23:39:26 +0000
committerAlexander Neundorf <neundorf@kde.org>2006-03-07 23:39:26 +0000
commitf4363cbf7f33cb4f448ec09602bcf3f2ba019b77 (patch)
treebaab2ee5729299594f41e913e53a34860f12c773 /modules/CheckPrototypeExists.cmake
parentbdb2d72ddf5a343bb16e0f6ce7ab28eb4fa0bfc4 (diff)
downloadextra-cmake-modules-f4363cbf7f33cb4f448ec09602bcf3f2ba019b77.tar.gz
extra-cmake-modules-f4363cbf7f33cb4f448ec09602bcf3f2ba019b77.tar.bz2
-prepare these two files for moving to cmake
Alex svn path=/trunk/KDE/kdelibs/; revision=516651
Diffstat (limited to 'modules/CheckPrototypeExists.cmake')
-rw-r--r--modules/CheckPrototypeExists.cmake16
1 files changed, 11 insertions, 5 deletions
diff --git a/modules/CheckPrototypeExists.cmake b/modules/CheckPrototypeExists.cmake
index 1c994ed4..ed0945df 100644
--- a/modules/CheckPrototypeExists.cmake
+++ b/modules/CheckPrototypeExists.cmake
@@ -5,16 +5,22 @@
# HEADER - the header(s) where the prototype should be declared
# VARIABLE - variable to store the result
#
+# The following variables may be set before calling this macro to
+# modify the way the check is run:
+#
+# CMAKE_REQUIRED_FLAGS = string of compile command line flags
+# CMAKE_REQUIRED_DEFINITIONS = list of macros to define (-DFOO=bar)
+# CMAKE_REQUIRED_INCLUDES = list of include directories
INCLUDE(CheckCXXSourceCompiles)
MACRO(CHECK_PROTOTYPE_EXISTS _SYMBOL _HEADER _RESULT)
- set(_INCLUDE_FILES)
- foreach(it ${_HEADER})
- set(_INCLUDE_FILES "${_INCLUDE_FILES}#include <${it}>\n")
- endforeach(it)
+ SET(_INCLUDE_FILES)
+ FOREACH(it ${_HEADER})
+ SET(_INCLUDE_FILES "${_INCLUDE_FILES}#include <${it}>\n")
+ ENDFOREACH(it)
- set(_CHECK_PROTO_EXISTS_SOURCE_CODE "
+ SET(_CHECK_PROTO_EXISTS_SOURCE_CODE "
${_INCLUDE_FILES}
int main()
{