Home | History | Annotate | Download | only in clang-format-vs
      1 option(BUILD_CLANG_FORMAT_VS_PLUGIN "Build clang-format VS plugin" OFF)
      2 if (BUILD_CLANG_FORMAT_VS_PLUGIN)
      3   add_custom_target(clang_format_exe_for_vsix
      4       ${CMAKE_COMMAND} -E copy_if_different
      5       "${LLVM_TOOLS_BINARY_DIR}/${CMAKE_CFG_INTDIR}/clang-format.exe"
      6       "${CMAKE_CURRENT_SOURCE_DIR}/ClangFormat/clang-format.exe"
      7       DEPENDS clang-format)
      8 
      9   add_custom_target(clang_format_vsix ALL
     10       devenv "${CMAKE_CURRENT_SOURCE_DIR}/ClangFormat.sln" /Build Release
     11       DEPENDS clang_format_exe_for_vsix
     12       COMMAND ${CMAKE_COMMAND} -E copy_if_different
     13       "${CMAKE_CURRENT_SOURCE_DIR}/ClangFormat/bin/Release/ClangFormat.vsix"
     14       "${LLVM_TOOLS_BINARY_DIR}/${CMAKE_CFG_INTDIR}/ClangFormat.vsix"
     15       DEPENDS clang_format_exe_for_vsix)
     16 endif()
     17