summaryrefslogtreecommitdiffstats
path: root/config
diff options
context:
space:
mode:
authorAllen Byrne <byrn@hdfgroup.org>2020-11-03 18:23:06 (GMT)
committerAllen Byrne <byrn@hdfgroup.org>2020-11-03 18:23:06 (GMT)
commitd6c92bde006ce9c31d7dbf06ca25fa39a9657ee6 (patch)
treef64862fcaef1fda2558387d36d8441bf63458d51 /config
parent4f7bb20a8f3707a6af277f8f8728e31030dc239f (diff)
downloadhdf5-d6c92bde006ce9c31d7dbf06ca25fa39a9657ee6.zip
hdf5-d6c92bde006ce9c31d7dbf06ca25fa39a9657ee6.tar.gz
hdf5-d6c92bde006ce9c31d7dbf06ca25fa39a9657ee6.tar.bz2
Doxygen add new files and update docs
Diffstat (limited to 'config')
-rw-r--r--config/sanitizer/formatting.cmake52
1 files changed, 0 insertions, 52 deletions
diff --git a/config/sanitizer/formatting.cmake b/config/sanitizer/formatting.cmake
index 677a69a..5aaa2a6 100644
--- a/config/sanitizer/formatting.cmake
+++ b/config/sanitizer/formatting.cmake
@@ -90,55 +90,3 @@ function(clang_format TARGET_NAME)
endif()
endfunction()
-#
-# cmake-format
-#
-find_program(CMAKE_FORMAT_EXE "cmake-format")
-mark_as_advanced(FORCE CMAKE_FORMAT_EXE)
-if(CMAKE_FORMAT_EXE)
- message(STATUS "cmake-format found: ${CMAKE_FORMAT_EXE}")
-else()
- message(STATUS "cmake-format not found!")
-endif()
-
-# When called, this function will call 'cmake-format' program on all listed
-# files (if both the program and the files exist and are found)
-# ~~~
-# Required:
-# TARGET_NAME - The name of the target to create.
-#
-# Optional:
-# ARGN - Any arguments passed in will be considered as 'files' to perform the
-# formatting on. Any items that are not files will be ignored. Both relative and
-# absolute paths are accepted.
-# ~~~
-function(cmake_format TARGET_NAME)
- if(CMAKE_FORMAT_EXE)
- set(FORMAT_FILES)
- # Determine files that exist
- foreach(iter IN LISTS ARGN)
- if(EXISTS ${iter})
- set(FORMAT_FILES ${FORMAT_FILES} ${iter})
- elseif(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/${iter})
- set(FORMAT_FILES ${FORMAT_FILES} ${CMAKE_CURRENT_SOURCE_DIR}/${iter})
- endif()
- endforeach()
-
- # Generate target
- if(FORMAT_FILES)
- if(TARGET ${TARGET_NAME})
- message(
- ERROR
- "Cannot create cmake-format target '${TARGET_NAME}', already exists.")
- else()
- add_custom_target(${TARGET_NAME} COMMAND ${CMAKE_FORMAT_EXE} -i
- ${FORMAT_FILES})
-
- if(NOT TARGET cmake-format)
- add_custom_target(cmake-format)
- endif()
- add_dependencies(cmake-format ${TARGET_NAME})
- endif()
- endif()
- endif()
-endfunction()