mirror of
https://gitlab.kitware.com/cmake/cmake.git
synced 2026-09-25 04:09:36 +03:00
Remove trailing whitespace from most CMake and C/C++ code
Our Git commit hooks disallow modification or addition of lines with trailing whitespace. Wipe out all remnants of trailing whitespace everywhere except third-party code. Run the following shell code: git ls-files -z -- \ bootstrap doxygen.config '*.readme' \ '*.c' '*.cmake' '*.cpp' '*.cxx' \ '*.el' '*.f' '*.f90' '*.h' '*.in' '*.in.l' '*.java' \ '*.mm' '*.pike' '*.py' '*.txt' '*.vim' | egrep -z -v '^(Utilities/cm|Source/(kwsys|CursesDialog/form)/)' | egrep -z -v '^(Modules/CPack\..*\.in)' | xargs -0 sed -i 's/ \+$//'
This commit is contained in:
@@ -21,12 +21,12 @@ INCLUDE(CMakeTestCompilerCommon)
|
||||
# any makefiles or projects.
|
||||
IF(NOT CMAKE_CXX_COMPILER_WORKS)
|
||||
PrintTestCompilerStatus("CXX" "")
|
||||
FILE(WRITE ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/testCXXCompiler.cxx
|
||||
FILE(WRITE ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/testCXXCompiler.cxx
|
||||
"#ifndef __cplusplus\n"
|
||||
"# error \"The CMAKE_CXX_COMPILER is set to a C compiler\"\n"
|
||||
"#endif\n"
|
||||
"int main(){return 0;}\n")
|
||||
TRY_COMPILE(CMAKE_CXX_COMPILER_WORKS ${CMAKE_BINARY_DIR}
|
||||
TRY_COMPILE(CMAKE_CXX_COMPILER_WORKS ${CMAKE_BINARY_DIR}
|
||||
${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/testCXXCompiler.cxx
|
||||
OUTPUT_VARIABLE __CMAKE_CXX_COMPILER_OUTPUT)
|
||||
SET(CXX_TEST_WAS_RUN 1)
|
||||
|
||||
Reference in New Issue
Block a user