From f4363cbf7f33cb4f448ec09602bcf3f2ba019b77 Mon Sep 17 00:00:00 2001 From: Alexander Neundorf Date: Tue, 7 Mar 2006 23:39:26 +0000 Subject: -prepare these two files for moving to cmake Alex svn path=/trunk/KDE/kdelibs/; revision=516651 --- modules/CheckPrototypeExists.cmake | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) (limited to 'modules/CheckPrototypeExists.cmake') 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() { -- cgit v1.2.1