File tree Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Original file line number Diff line number Diff line change @@ -464,13 +464,15 @@ option(SWIFT_BUILD_ONLY_SYNTAXPARSERLIB "Only build the Swift Syntax Parser libr
464
464
option (SWIFT_BUILD_SOURCEKIT "Build SourceKit" TRUE )
465
465
option (SWIFT_ENABLE_SOURCEKIT_TESTS "Enable running SourceKit tests" TRUE )
466
466
467
- if (NOT CMAKE_SYSTEM_NAME STREQUAL Darwin )
468
- if (NOT EXISTS "${SWIFT_PATH_TO_LIBDISPATCH_SOURCE} " )
469
- message (SEND_ERROR "SyntaxParserLib and SourceKit require libdispatch on non-Darwin hosts. Please specify SWIFT_PATH_TO_LIBDISPATCH_SOURCE" )
467
+ if (SWIFT_BUILD_SYNTAXPARSERLIB OR SWIFT_BUILD_SOURCEKIT )
468
+ if (CMAKE_SYSTEM_NAME STREQUAL Darwin )
469
+ set (SWIFT_NEED_EXPLICIT_LIBDISPATCH FALSE )
470
+ else ()
471
+ set (SWIFT_NEED_EXPLICIT_LIBDISPATCH TRUE )
472
+ if (NOT EXISTS "${SWIFT_PATH_TO_LIBDISPATCH_SOURCE} " )
473
+ message (SEND_ERROR "SyntaxParserLib and SourceKit require libdispatch on non-Darwin hosts. Please specify SWIFT_PATH_TO_LIBDISPATCH_SOURCE" )
474
+ endif ()
470
475
endif ()
471
- set (SWIFT_NEED_EXPLICIT_LIBDISPATCH TRUE )
472
- else ()
473
- set (SWIFT_NEED_EXPLICIT_LIBDISPATCH FALSE )
474
476
endif ()
475
477
476
478
#
You can’t perform that action at this time.
0 commit comments