Extend macros acg_append_files_recursive acg_append_files to not include files starting with a dot
git-svn-id: http://www.openmesh.org/svnrepo/OpenMesh/trunk@329 fdac6126-5c0c-442c-9429-916003d36597
This commit is contained in:
@@ -193,21 +193,36 @@ macro (acg_ftgl)
|
|||||||
endmacro ()
|
endmacro ()
|
||||||
|
|
||||||
# append all files with extension "ext" in the "dirs" directories to "ret"
|
# append all files with extension "ext" in the "dirs" directories to "ret"
|
||||||
|
# excludes all files starting with a '.' (dot)
|
||||||
macro (acg_append_files ret ext)
|
macro (acg_append_files ret ext)
|
||||||
foreach (_dir ${ARGN})
|
foreach (_dir ${ARGN})
|
||||||
file (GLOB _files "${_dir}/${ext}")
|
file (GLOB _files "${_dir}/${ext}")
|
||||||
|
foreach (_file ${_files})
|
||||||
|
get_filename_component (_filename ${_file} NAME)
|
||||||
|
if (_filename MATCHES "^[.]")
|
||||||
|
list (REMOVE_ITEM _files ${_file})
|
||||||
|
endif ()
|
||||||
|
endforeach ()
|
||||||
list (APPEND ${ret} ${_files})
|
list (APPEND ${ret} ${_files})
|
||||||
endforeach ()
|
endforeach ()
|
||||||
endmacro ()
|
endmacro ()
|
||||||
|
|
||||||
# append all files with extension "ext" in the "dirs" directories and its subdirectories to "ret"
|
# append all files with extension "ext" in the "dirs" directories and its subdirectories to "ret"
|
||||||
|
# excludes all files starting with a '.' (dot)
|
||||||
macro (acg_append_files_recursive ret ext)
|
macro (acg_append_files_recursive ret ext)
|
||||||
foreach (_dir ${ARGN})
|
foreach (_dir ${ARGN})
|
||||||
file (GLOB_RECURSE _files "${_dir}/${ext}")
|
file (GLOB_RECURSE _files "${_dir}/${ext}")
|
||||||
|
foreach (_file ${_files})
|
||||||
|
get_filename_component (_filename ${_file} NAME)
|
||||||
|
if (_filename MATCHES "^[.]")
|
||||||
|
list (REMOVE_ITEM _files ${_file})
|
||||||
|
endif ()
|
||||||
|
endforeach ()
|
||||||
list (APPEND ${ret} ${_files})
|
list (APPEND ${ret} ${_files})
|
||||||
endforeach ()
|
endforeach ()
|
||||||
endmacro ()
|
endmacro ()
|
||||||
|
|
||||||
|
|
||||||
# drop all "*T.cc" files from list
|
# drop all "*T.cc" files from list
|
||||||
macro (acg_drop_templates list)
|
macro (acg_drop_templates list)
|
||||||
foreach (_file ${${list}})
|
foreach (_file ${${list}})
|
||||||
|
|||||||
Reference in New Issue
Block a user