Skip to content

Commit

Permalink
Merge pull request #40188 from apple/QuietMisdreavus/cmark
Browse files Browse the repository at this point in the history
use swift-cmark/gfm instead of /main
  • Loading branch information
shahmishal authored May 2, 2022
2 parents 58ea5d3 + f3cc9eb commit d292a85
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 9 deletions.
4 changes: 2 additions & 2 deletions cmake/modules/SwiftSharedCMakeConfig.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ macro(swift_common_standalone_build_config_cmark product)
get_filename_component(CMARK_LIBRARY_DIR "${${product}_CMARK_LIBRARY_DIR}"
ABSOLUTE)

set(CMARK_MAIN_INCLUDE_DIR "${CMARK_MAIN_SRC_DIR}/src")
set(CMARK_MAIN_INCLUDE_DIR "${CMARK_MAIN_SRC_DIR}/src/include")
set(CMARK_BUILD_INCLUDE_DIR "${PATH_TO_CMARK_BUILD}/src")

file(TO_CMAKE_PATH "${CMARK_MAIN_INCLUDE_DIR}" CMARK_MAIN_INCLUDE_DIR)
Expand Down Expand Up @@ -290,7 +290,7 @@ macro(swift_common_unified_build_config product)
ABSOLUTE)

set(CMARK_BUILD_INCLUDE_DIR "${PATH_TO_CMARK_BUILD}/src")
set(CMARK_MAIN_INCLUDE_DIR "${CMARK_MAIN_SRC_DIR}/src")
set(CMARK_MAIN_INCLUDE_DIR "${CMARK_MAIN_SRC_DIR}/src/include")
endif()

include_directories(
Expand Down
4 changes: 2 additions & 2 deletions lib/Markup/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ add_swift_host_library(swiftMarkup STATIC
LineList.cpp
Markup.cpp)
target_link_libraries(swiftMarkup PRIVATE
libcmark_static)
libcmark-gfm_static)
target_compile_definitions(swiftMarkup
PRIVATE
CMARK_STATIC_DEFINE)
CMARK_GFM_STATIC_DEFINE)

2 changes: 1 addition & 1 deletion lib/Markup/Markup.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
#include "swift/AST/Comment.h"
#include "swift/Markup/LineList.h"
#include "swift/Markup/Markup.h"
#include "cmark.h"
#include "cmark-gfm.h"

using namespace swift;
using namespace markup;
Expand Down
2 changes: 1 addition & 1 deletion tools/SourceKit/lib/SwiftLang/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ target_link_libraries(SourceKitSwiftLang PRIVATE
swiftSyntax
swiftOption
swiftSymbolGraphGen
libcmark_static
libcmark-gfm_static
# Clang dependencies.
clangIndex
clangFormat
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@ def build(self, host_target):
self.cmake_options.define('CMAKE_BUILD_TYPE:STRING',
self.args.cmark_build_variant)

self.cmake_options.define('CMARK_THREADING', 'ON')

(platform, arch) = host_target.split('-')

common_c_flags = ' '.join(self.common_cross_c_flags(platform, arch))
Expand Down
6 changes: 3 additions & 3 deletions utils/update_checkout/update-checkout-config.json
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@
"repos": {
"llvm-project": "stable/20211026",
"swift": "main",
"cmark": "main",
"cmark": "gfm",
"llbuild": "main",
"swift-tools-support-core": "main",
"swiftpm": "main",
Expand Down Expand Up @@ -131,7 +131,7 @@
"repos": {
"llvm-project": "stable/20220421",
"swift": "rebranch",
"cmark": "main",
"cmark": "gfm",
"llbuild": "main",
"swift-tools-support-core": "main",
"swiftpm": "main",
Expand Down Expand Up @@ -374,7 +374,7 @@
"repos": {
"llvm-project": "next",
"swift": "next",
"cmark": "main",
"cmark": "gfm",
"llbuild": "main",
"swift-tools-support-core": "main",
"swiftpm": "main",
Expand Down

0 comments on commit d292a85

Please sign in to comment.