Commit 8f018cae authored by Christian Heine's avatar Christian Heine
Browse files

[FIX] split long parameter list for brainlint

parent 8f35249d
......@@ -228,20 +228,30 @@ FOREACH( dirname ${EXCLUDE_DIRS} )
LIST( REMOVE_ITEM STYLE_CPP ${fname} )
ENDFOREACH( fname )
ENDFOREACH( dirname )
IF( CMAKE_COLOR_MAKEFILE )
ADD_CUSTOM_TARGET( stylecheck
COMMAND ${PROJECT_SOURCE_DIR}/../tools/brainlint.py --color ${STYLE_CPP} ${STYLE_H}
WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
COMMENT "Check if code complies to CodingStandard"
)
SET( STYLECHECK_OPTIONS "--color" )
ELSE()
SET( STYLECHECK_OPTIONS "" )
ENDIF()
IF( CMAKE_HOST_WIN32 )
SET( XARGS_OPTIONS "-n 128" )
ELSE()
ADD_CUSTOM_TARGET( stylecheck
COMMAND ${PROJECT_SOURCE_DIR}/../tools/brainlint.py ${STYLE_CPP} ${STYLE_H}
WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
COMMENT "Check if code complies to CodingStandard and use noncolored output for violation messages"
)
SET( XARGS_OPTIONS "" )
ENDIF()
FILE( WRITE ${PROJECT_BINARY_DIR}/brainlintlist "" )
FOREACH( fname ${STYLE_CPP} ${STYLE_H} )
FILE( APPEND ${PROJECT_BINARY_DIR}/brainlintlist "${fname}\n" )
ENDFOREACH()
ADD_CUSTOM_TARGET( stylecheck
COMMAND cat ${PROJECT_BINARY_DIR}/brainlintlist | xargs ${XARGS_OPTIONS} ${PROJECT_SOURCE_DIR}/../tools/brainlint.py ${STYLECHECK_OPTIONS}
WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
COMMENT "Check if code complies to CodingStandard"
)
#-------------------------------------------------------------------------------------------------------------
# Writes information about the revision of the current code to a file
ADD_CUSTOM_TARGET( identify
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment