Skip to content

Commit 66f2d86

Browse files
committed
Rename SKCore to BuildSystemIntegration
1 parent 6d34d70 commit 66f2d86

File tree

49 files changed

+86
-108
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

49 files changed

+86
-108
lines changed

Documentation/Modules.md

Lines changed: 5 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ Swift types to represent the [Build Server Protocol (BSP) specification, version
88

99
FIXME: Add link for BSP and version
1010

11+
### BuildSystemIntegration
12+
13+
Defines the queries SourceKit-LSP can ask of a a build system, like getting compiler arguments for a file. Finding a target’s dependencies or preparing a target.
14+
1115
### CAtomics
1216

1317
Implementation of atomics for Swift using C. Once we can raise our deployment target to use the `Atomic` type from the Swift standard library, this module should be removed.
@@ -42,31 +46,6 @@ A connection to or from a SourceKit-LSP server. Since message parsing can fail,
4246

4347
Contains the interface with which SourceKit-LSP queries the semantic index, adding up-to-date checks on top of the indexstore-db API. Also implements the types that manage background indexing.
4448

45-
### SKCore
46-
47-
FIXME: Currently serves two independent purposes and should be split up into two modules
48-
49-
#### BuildSystem
50-
51-
Defines the queries SourceKit-LSP can ask of a a build system, like getting compiler arguments for a file. Finding a target’s dependencies or preparing a target.
52-
53-
This includes:
54-
- BuildConfiguration.swift
55-
- BuildServerBuildSystem.swift
56-
- BuildSetup.swift
57-
- BuildSystem.swift
58-
- BuildSystemDelegate.swift
59-
- BuildSystemManager.swift
60-
- CompilationDatabase.swift
61-
- CompilationDatabaseBuildSystem.swift
62-
- FallbackBuildSystem.swift
63-
- FileBuildSettings.swift
64-
- IndexTaskID.swift
65-
- MainFilesProvider.swift
66-
- PathPrefixMapping.swift
67-
- SplitShellCommand.swift
68-
- WorkspaceType.swift
69-
7049
### SKLogging
7150

7251
Types that are API-compatible with OSLog to allow logging to OSLog when building for Darwin platforms and logging to stderr or files on non-Darwin platforms. This should not be dependent on any LSP specific types and be portable to other packages.
@@ -86,7 +65,7 @@ Contains SourceKit-LSP-specific helper functions. These fall into three differen
8665

8766
Implements the `BuildSystem` protocol for Swift packages.
8867

89-
FIXME: Merge this into the BuildSystem module once SKCore is split.
68+
FIXME: Merge this into the BuildSystem module once BuildSystemIntegration is split.
9069

9170
### SKTestSupport
9271

Package.swift

Lines changed: 41 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,10 @@ let package = Package(
2424
.executableTarget(
2525
name: "sourcekit-lsp",
2626
dependencies: [
27+
"BuildSystemIntegration",
2728
"Diagnose",
2829
"LanguageServerProtocol",
2930
"LanguageServerProtocolJSONRPC",
30-
"SKCore",
3131
"SKOptions",
3232
"SKSupport",
3333
"SourceKitLSP",
@@ -49,6 +49,36 @@ let package = Package(
4949
exclude: ["CMakeLists.txt"]
5050
),
5151

52+
// MARK: BuildSystemIntegration
53+
54+
.target(
55+
name: "BuildSystemIntegration",
56+
dependencies: [
57+
"BuildServerProtocol",
58+
"LanguageServerProtocol",
59+
"LanguageServerProtocolJSONRPC",
60+
"SKLogging",
61+
"SKOptions",
62+
"SKSupport",
63+
"SourceKitD",
64+
"SwiftExtensions",
65+
"ToolchainRegistry",
66+
.product(name: "SwiftPMDataModel-auto", package: "swift-package-manager"),
67+
.product(name: "SwiftToolsSupport-auto", package: "swift-tools-support-core"),
68+
],
69+
exclude: ["CMakeLists.txt"]
70+
),
71+
72+
.testTarget(
73+
name: "BuildSystemIntegrationTests",
74+
dependencies: [
75+
"BuildSystemIntegration",
76+
"SKOptions",
77+
"SKTestSupport",
78+
"ToolchainRegistry",
79+
]
80+
),
81+
5282
// MARK: CAtomics
5383

5484
.target(
@@ -76,8 +106,8 @@ let package = Package(
76106
.target(
77107
name: "Diagnose",
78108
dependencies: [
109+
"BuildSystemIntegration",
79110
"InProcessClient",
80-
"SKCore",
81111
"SKLogging",
82112
"SKOptions",
83113
"SKSupport",
@@ -97,8 +127,8 @@ let package = Package(
97127
.testTarget(
98128
name: "DiagnoseTests",
99129
dependencies: [
130+
"BuildSystemIntegration",
100131
"Diagnose",
101-
"SKCore",
102132
"SKLogging",
103133
"SKTestSupport",
104134
"SourceKitD",
@@ -112,8 +142,8 @@ let package = Package(
112142
.target(
113143
name: "InProcessClient",
114144
dependencies: [
145+
"BuildSystemIntegration",
115146
"LanguageServerProtocol",
116-
"SKCore",
117147
"SKLogging",
118148
"SKOptions",
119149
"SourceKitLSP",
@@ -162,8 +192,8 @@ let package = Package(
162192
.target(
163193
name: "SemanticIndex",
164194
dependencies: [
195+
"BuildSystemIntegration",
165196
"LanguageServerProtocol",
166-
"SKCore",
167197
"SKLogging",
168198
"SwiftExtensions",
169199
"ToolchainRegistry",
@@ -181,36 +211,6 @@ let package = Package(
181211
]
182212
),
183213

184-
// MARK: SKCore
185-
186-
.target(
187-
name: "SKCore",
188-
dependencies: [
189-
"BuildServerProtocol",
190-
"LanguageServerProtocol",
191-
"LanguageServerProtocolJSONRPC",
192-
"SKLogging",
193-
"SKOptions",
194-
"SKSupport",
195-
"SourceKitD",
196-
"SwiftExtensions",
197-
"ToolchainRegistry",
198-
.product(name: "SwiftPMDataModel-auto", package: "swift-package-manager"),
199-
.product(name: "SwiftToolsSupport-auto", package: "swift-tools-support-core"),
200-
],
201-
exclude: ["CMakeLists.txt"]
202-
),
203-
204-
.testTarget(
205-
name: "SKCoreTests",
206-
dependencies: [
207-
"SKCore",
208-
"SKOptions",
209-
"SKTestSupport",
210-
"ToolchainRegistry",
211-
]
212-
),
213-
214214
// MARK: SKLogging
215215

216216
.target(
@@ -273,8 +273,8 @@ let package = Package(
273273
name: "SKSwiftPMWorkspace",
274274
dependencies: [
275275
"BuildServerProtocol",
276+
"BuildSystemIntegration",
276277
"LanguageServerProtocol",
277-
"SKCore",
278278
"SKLogging",
279279
"SKOptions",
280280
"SwiftExtensions",
@@ -288,8 +288,8 @@ let package = Package(
288288
.testTarget(
289289
name: "SKSwiftPMWorkspaceTests",
290290
dependencies: [
291+
"BuildSystemIntegration",
291292
"LanguageServerProtocol",
292-
"SKCore",
293293
"SKOptions",
294294
"SKSwiftPMWorkspace",
295295
"SKTestSupport",
@@ -305,11 +305,11 @@ let package = Package(
305305
.target(
306306
name: "SKTestSupport",
307307
dependencies: [
308+
"BuildSystemIntegration",
308309
"CSKTestSupport",
309310
"InProcessClient",
310311
"LanguageServerProtocol",
311312
"LanguageServerProtocolJSONRPC",
312-
"SKCore",
313313
"SKLogging",
314314
"SKOptions",
315315
"SKSupport",
@@ -338,8 +338,8 @@ let package = Package(
338338
.testTarget(
339339
name: "SourceKitDTests",
340340
dependencies: [
341+
"BuildSystemIntegration",
341342
"SourceKitD",
342-
"SKCore",
343343
"SKTestSupport",
344344
"SwiftExtensions",
345345
"ToolchainRegistry",
@@ -352,10 +352,10 @@ let package = Package(
352352
name: "SourceKitLSP",
353353
dependencies: [
354354
"BuildServerProtocol",
355+
"BuildSystemIntegration",
355356
"LanguageServerProtocol",
356357
"LanguageServerProtocolJSONRPC",
357358
"SemanticIndex",
358-
"SKCore",
359359
"SKLogging",
360360
"SKOptions",
361361
"SKSupport",
@@ -382,9 +382,9 @@ let package = Package(
382382
name: "SourceKitLSPTests",
383383
dependencies: [
384384
"BuildServerProtocol",
385+
"BuildSystemIntegration",
385386
"LanguageServerProtocol",
386387
"SemanticIndex",
387-
"SKCore",
388388
"SKLogging",
389389
"SKOptions",
390390
"SKSupport",

Sources/SKCore/CMakeLists.txt renamed to Sources/BuildSystemIntegration/CMakeLists.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11

2-
add_library(SKCore STATIC
2+
add_library(BuildSystemIntegration STATIC
33
BuildServerBuildSystem.swift
44
BuildSystem.swift
55
BuildSystemDelegate.swift
@@ -12,9 +12,9 @@ add_library(SKCore STATIC
1212
MainFilesProvider.swift
1313
PathPrefixMapping.swift
1414
SplitShellCommand.swift)
15-
set_target_properties(SKCore PROPERTIES
15+
set_target_properties(BuildSystemIntegration PROPERTIES
1616
INTERFACE_INCLUDE_DIRECTORIES ${CMAKE_Swift_MODULE_DIRECTORY})
17-
target_link_libraries(SKCore PUBLIC
17+
target_link_libraries(BuildSystemIntegration PUBLIC
1818
BuildServerProtocol
1919
LanguageServerProtocol
2020
LanguageServerProtocolJSONRPC

0 commit comments

Comments
 (0)