Skip to content

Commit 3eb930b

Browse files
committed
[WindowsBuild] SwiftPM and SourceKit-LSP
1 parent 4ed581b commit 3eb930b

File tree

1 file changed

+47
-12
lines changed

1 file changed

+47
-12
lines changed

docs/WindowsBuild.md

Lines changed: 47 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -516,7 +516,7 @@ cmake -B S:\b\7\IndexStoreDB ^
516516
-D CMAKE_C_COMPILER=S:/b/1/bin/clang-cl.exe ^
517517
-D CMAKE_C_FLAGS="/GS- /Oy /Gw /Gy" ^
518518
-D CMAKE_CXX_COMPILER=S:/b/1/bin/clang-cl.exe ^
519-
-D CMAKE_CXX_FLAGS="/GS- /Oy /Gw /Gy" ^
519+
-D CMAKE_CXX_FLAGS="/GS- /Oy /Gw /Gy -Xclang -fno-split-cold-code" ^
520520
-D CMAKE_MT=mt ^
521521
-D CMAKE_EXE_LINKER_FLAGS="/INCREMENTAL:NO" ^
522522
-D CMAKE_SHARED_LINKER_FLAGS="/INCREMENTAL:NO" ^
@@ -537,6 +537,7 @@ cmake --build S:\b\7\IndexStoreDB
537537

538538
```cmd
539539
cmake -B S:\b\8 ^
540+
-D BUILD_SHARED_LIBS=YES ^
540541
-D CMAKE_BUILD_TYPE=RelWithDebInfo ^
541542
-D CMAKE_INSTALL_PREFIX=S:\b\toolchain\usr ^
542543
@@ -563,6 +564,7 @@ cmake --build S:\b\8
563564

564565
```cmd
565566
cmake -B S:\b\9 ^
567+
-D BUILD_SHARED_LIBS=YES ^
566568
-D CMAKE_BUILD_TYPE=RelWithDebInfo ^
567569
-D CMAKE_INSTALL_PREFIX=S:\b\toolchain\usr ^
568570
@@ -587,33 +589,66 @@ cmake -B S:\b\9 ^
587589
cmake --build S:\b\9
588590
```
589591

590-
### SwiftPM
592+
### SwiftPM (without tests)
591593

592594
```cmd
593595
cmake -B S:\b\10 ^
594596
-D BUILD_SHARED_LIBS=YES ^
595-
-D CMAKE_BUILD_TYPE=Release ^
597+
-D CMAKE_BUILD_TYPE=RelWithDebInfo ^
598+
-D CMAKE_INSTALL_PREFIX=S:\b\toolchain\usr ^
599+
596600
-D CMAKE_C_COMPILER=S:/b/1/bin/clang-cl.exe ^
597-
-D CMAKE_INSTALL_PREFIX=C:\Library\Developer\Toolchains\unknown-Asserts-development.xctoolchain\usr ^
601+
-D CMAKE_C_FLAGS="/GS- /Oy /Gw /Gy" ^
598602
-D CMAKE_MT=mt ^
603+
-D CMAKE_EXE_LINKER_FLAGS="/INCREMENTAL:NO" ^
604+
-D CMAKE_SHARED_LINKER_FLAGS="/INCREMENTAL:NO" ^
605+
599606
-D CMAKE_Swift_COMPILER=S:/b/1/bin/swiftc.exe ^
600-
-D dispatch_DIR=S:\b\2\cmake\modules ^
601-
-D Foundation_DIR=S:\b\3\cmake\modules ^
602-
-D TSC_DIR=S:\b\5\cmake\modules ^
607+
-D dispatch_DIR=S:\b\3\cmake\modules ^
608+
-D Foundation_DIR=S:\b\4\cmake\modules ^
603609
-D LLBuild_DIR=S:\b\6\cmake\modules ^
604-
-D Yams_DIR=S:\b\7\cmake\modules ^
605-
-D ArgumentParser_DIR=S:\b\8\cmake\modules ^
610+
-D SwiftSystem_DIR=S:\b\7\SwiftSystem\cmake\modules ^
611+
-D ArgumentParser_DIR=S:\b\7\ArgumentParser\cmake\modules ^
612+
-D SwiftCrypto_DIR=S:\b\7\SwiftCrypto\cmake\modules ^
613+
-D SwiftCollections_DIR=S:\b\7\SwiftCollections\cmake\modules ^
614+
-D TSC_DIR=S:\b\8\cmake\modules ^
606615
-D SwiftDriver_DIR=S:\b\9\cmake\modules ^
616+
607617
-G Ninja ^
608618
-S S:\swiftpm
609619
610-
ninja -C S:\b\10
620+
cmake --build S:\b\10
611621
```
612622

613-
Indicate to SwiftPM where to find `PackageDescription` before installation:
623+
### SourceKit-LSP (without tests)
614624

615625
```cmd
616-
set SWIFTPM_PD_LIBS=S:\b\10\pm
626+
cmake -B S:\b\11 ^
627+
-D BUILD_SHARED_LIBS=YES ^
628+
-D CMAKE_BUILD_TYPE=RelWithDebInfo ^
629+
-D CMAKE_INSTALL_PREFIX=S:\b\toolchain\usr ^
630+
631+
-D CMAKE_C_COMPILER=S:/b/1/bin/clang-cl.exe ^
632+
-D CMAKE_C_FLAGS="/GS- /Oy /Gw /Gy" ^
633+
-D CMAKE_MT=mt ^
634+
-D CMAKE_EXE_LINKER_FLAGS="/INCREMENTAL:NO" ^
635+
-D CMAKE_SHARED_LINKER_FLAGS="/INCREMENTAL:NO" ^
636+
637+
-D CMAKE_Swift_COMPILER=S:/b/1/bin/swiftc.exe ^
638+
-D dispatch_DIR=S:\b\3\cmake\modules ^
639+
-D Foundation_DIR=S:\b\4\cmake\modules ^
640+
-D LLBuild_DIR=S:\b\6\cmake\modules ^
641+
-D SwiftSystem_DIR=S:\b\7\SwiftSystem\cmake\modules ^
642+
-D ArgumentParser_DIR=S:\b\7\ArgumentParser\cmake\modules ^
643+
-D SwiftCollections_DIR=S:\b\7\SwiftCollections\cmake\modules ^
644+
-D IndexStoreDB_DIR=S:\b\7\IndexStoreDB\cmake\modules ^
645+
-D TSC_DIR=S:\b\8\cmake\modules ^
646+
-D SwiftPM_DIR=S:\b\10\cmake\modules ^
647+
648+
-G Ninja ^
649+
-S S:\sourcekit-lsp
650+
651+
cmake --build S:\b\11
617652
```
618653

619654
## Gather the toolchain and SDK

0 commit comments

Comments
 (0)