Disable code formatting on CI builds.

This commit is contained in:
Chris Marsh 2017-11-29 09:50:22 -08:00
parent 2af5adca3d
commit 8af28e46be
3 changed files with 6 additions and 6 deletions

View file

@ -25,11 +25,6 @@ if (CLANG_FORMAT_CMD)
DEPENDS
${ALL_SOURCE_FILES}
)
else(CLANG_FORMAT_CMD)
add_custom_target(
clangformat
COMMENT "no clang format"
)
endif(CLANG_FORMAT_CMD)
# thirdparty stuff

View file

@ -79,6 +79,9 @@ def build_lib(build_name, generator, options):
]
if generator:
initial_cmake.extend(['-G', generator])
if IS_BUILD_MACHINE:
# disable formatting on CI builds
initial_cmake.append('-DCLANG_FORMAT_SUFFIX=none')
for key in options:
val = 'ON' if options[key] else 'OFF'
initial_cmake.append('-D%s=%s' % (key, val))

View file

@ -106,7 +106,9 @@ if (${BUILD_SHARED_LIBS})
target_compile_definitions(discord-rpc PRIVATE -DDISCORD_BUILDING_SDK)
endif(${BUILD_SHARED_LIBS})
if (CLANG_FORMAT_CMD)
add_dependencies(discord-rpc clangformat)
endif(CLANG_FORMAT_CMD)
# install