From fce52d437088520993f5f0df591408aa7e8e6eb4 Mon Sep 17 00:00:00 2001 From: Alexander Neundorf Date: Tue, 7 Feb 2006 21:49:31 +0000 Subject: two new macros: macro_append_directory_properties() and macro_append_source_files_properties() don't use CMAKE_INCLUDE_PATH and CMAKE_LIBRARY_PATH in FindKDE4.cmake clean more files Alex svn path=/trunk/KDE/kdelibs/; revision=506927 --- modules/MacroAppendSourceFilesProperties.cmake | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 modules/MacroAppendSourceFilesProperties.cmake (limited to 'modules/MacroAppendSourceFilesProperties.cmake') diff --git a/modules/MacroAppendSourceFilesProperties.cmake b/modules/MacroAppendSourceFilesProperties.cmake new file mode 100644 index 00000000..4d387e20 --- /dev/null +++ b/modules/MacroAppendSourceFilesProperties.cmake @@ -0,0 +1,21 @@ +# - MACRO_APPEND_SOURCE_FILES_PROPERTIES( PROPERTIES key values...) +# MACRO_OPTIONAL_FIND_PACKAGE( [QUIT] ) + +MACRO(MACRO_APPEND_SOURCE_FILES_PROPERTIES _file _properties _property) + GET_SOURCE_FILE_PROPERTY(_tmp_FILE_PROPS ${_file} ${_property}) + + IF (NOT _tmp_FILE_PROPS) # make sure it's empty not e.g. "NOTFOUND" or "FALSE" + SET(_tmp_FILE_PROPS) + ENDIF (NOT _tmp_FILE_PROPS) + + FOREACH(_value ${ARGN}) + IF (_tmp_FILE_PROPS) + SET(_tmp_FILE_PROPS ${_tmp_FILE_PROPS} ${_value}) + ELSE (_tmp_FILE_PROPS) + SET(_tmp_FILE_PROPS ${_value}) + ENDIF (_tmp_FILE_PROPS) + ENDFOREACH(_value ${ARGN}) + + SET_SOURCE_FILES_PROPERTIES(${_file} ${_properties} ${_property} "${_tmp_FILE_PROPS}") +ENDMACRO(MACRO_APPEND_SOURCE_FILES_PROPERTIES) + -- cgit v1.2.1