@@ -42,6 +42,14 @@ set TMPDIR=%BuildRoot%\tmp
42
42
43
43
set NINJA_STATUS = [%% f/%% t][%% p][%% es]
44
44
45
+ rem TODO(compnerd) remove this clean up code once we have had enough time for
46
+ rem the injection to soak.
47
+ :: Clean up old deployments as that breaks the tests
48
+ del /f /q " %UniversalCRTSdkDir% \Include\%UCRTVersion% \ucrt\module.modulemap"
49
+ del /f /q " %UniversalCRTSdkDir% \Include\%UCRTVersion% \um\module.modulemap"
50
+ del /f /q " %VCToolsInstallDir% \include\module.modulemap"
51
+ del /f /q " %VCToolsInstallDir% \include\vcruntime.apinotes"
52
+
45
53
call :CloneDependencies || (exit /b)
46
54
call :CloneRepositories || (exit /b)
47
55
@@ -178,12 +186,6 @@ cmake ^
178
186
cmake --build " %BuildRoot% \curl" || (exit /b)
179
187
cmake --build " %BuildRoot% \curl" --target install || (exit /b)
180
188
181
- :: Prepare system modules
182
- copy /y " %SourceRoot% \swift\stdlib\public\Platform\ucrt.modulemap" " %UniversalCRTSdkDir% \Include\%UCRTVersion% \ucrt\module.modulemap" || (exit /b)
183
- copy /y " %SourceRoot% \swift\stdlib\public\Platform\winsdk.modulemap" " %UniversalCRTSdkDir% \Include\%UCRTVersion% \um\module.modulemap" || (exit /b)
184
- copy /y " %SourceRoot% \swift\stdlib\public\Platform\vcruntime.modulemap" " %VCToolsInstallDir% \include\module.modulemap" || (exit /b)
185
- copy /y " %SourceRoot% \swift\stdlib\public\Platform\vcruntime.apinotes" " %VCToolsInstallDir% \include\vcruntime.apinotes" || (exit /b)
186
-
187
189
:: Build Toolchain
188
190
cmake ^
189
191
-B " %BuildRoot% \1" ^
@@ -273,6 +275,7 @@ cmake ^
273
275
-D CMAKE_CXX_FLAGS=" /GS- /Oy /Gw /Gy" ^
274
276
-D CMAKE_MT=mt ^
275
277
-D CMAKE_Swift_COMPILER=%BuildRoot% /1/bin/swiftc.exe ^
278
+ -D CMAKE_Swift_FLAGS=" -vfsoverlay %BuildRoot% /2/stdlib/windows-vfs-overlay.yaml" ^
276
279
-D CMAKE_EXE_LINKER_FLAGS=" /INCREMENTAL:NO" ^
277
280
-D CMAKE_SHARED_LINKER_FLAGS=" /INCREMENTAL:NO" ^
278
281
@@ -296,6 +299,7 @@ cmake ^
296
299
-D CMAKE_CXX_FLAGS=" /GS- /Oy /Gw /Gy" ^
297
300
-D CMAKE_MT=mt ^
298
301
-D CMAKE_Swift_COMPILER=%BuildRoot% /1/bin/swiftc.exe ^
302
+ -D CMAKE_Swift_FLAGS=" -vfsoverlay %BuildRoot% /2/stdlib/windows-vfs-overlay.yaml" ^
299
303
-D CMAKE_EXE_LINKER_FLAGS=" /INCREMENTAL:NO" ^
300
304
-D CMAKE_SHARED_LINKER_FLAGS=" /INCREMENTAL:NO" ^
301
305
@@ -331,6 +335,7 @@ cmake ^
331
335
-D CMAKE_CXX_FLAGS=" /GS- /Oy /Gw /Gy" ^
332
336
-D CMAKE_MT=mt ^
333
337
-D CMAKE_Swift_COMPILER=%BuildRoot% /1/bin/swiftc.exe ^
338
+ -D CMAKE_Swift_FLAGS=" -vfsoverlay %BuildRoot% /2/stdlib/windows-vfs-overlay.yaml" ^
334
339
-D CMAKE_EXE_LINKER_FLAGS=" /INCREMENTAL:NO" ^
335
340
-D CMAKE_SHARED_LINKER_FLAGS=" /INCREMENTAL:NO" ^
336
341
@@ -358,6 +363,7 @@ cmake ^
358
363
-D CMAKE_CXX_FLAGS=" /GS- /Oy /Gw /Gy" ^
359
364
-D CMAKE_MT=mt ^
360
365
-D CMAKE_Swift_COMPILER=%BuildRoot% /1/bin/swiftc.exe ^
366
+ -D CMAKE_Swift_FLAGS=" -vfsoverlay %BuildRoot% /2/stdlib/windows-vfs-overlay.yaml" ^
361
367
-D CMAKE_EXE_LINKER_FLAGS=" /INCREMENTAL:NO" ^
362
368
-D CMAKE_SHARED_LINKER_FLAGS=" /INCREMENTAL:NO" ^
363
369
@@ -379,6 +385,7 @@ cmake ^
379
385
-D CMAKE_CXX_FLAGS=" /GS- /Oy /Gw /Gy" ^
380
386
-D CMAKE_MT=mt ^
381
387
-D CMAKE_Swift_COMPILER=%BuildRoot% /1/bin/swiftc.exe ^
388
+ -D CMAKE_Swift_FLAGS=" -vfsoverlay %BuildRoot% /2/stdlib/windows-vfs-overlay.yaml" ^
382
389
-D CMAKE_EXE_LINKER_FLAGS=" /INCREMENTAL:NO" ^
383
390
-D CMAKE_SHARED_LINKER_FLAGS=" /INCREMENTAL:NO" ^
384
391
@@ -406,6 +413,7 @@ cmake ^
406
413
-D CMAKE_CXX_FLAGS=" /GS- /Oy /Gw /Gy -Xclang -fno-split-cold-code" ^
407
414
-D CMAKE_MT=mt ^
408
415
-D CMAKE_Swift_COMPILER=%BuildRoot% /1/bin/swiftc.exe ^
416
+ -D CMAKE_Swift_FLAGS=" -vfsoverlay %BuildRoot% /2/stdlib/windows-vfs-overlay.yaml" ^
409
417
-D CMAKE_EXE_LINKER_FLAGS=" /INCREMENTAL:NO" ^
410
418
-D CMAKE_SHARED_LINKER_FLAGS=" /INCREMENTAL:NO" ^
411
419
@@ -434,6 +442,7 @@ cmake ^
434
442
-D CMAKE_CXX_FLAGS=" /GS- /Oy /Gw /Gy" ^
435
443
-D CMAKE_MT=mt ^
436
444
-D CMAKE_Swift_COMPILER=%BuildRoot% /1/bin/swiftc.exe ^
445
+ -D CMAKE_Swift_FLAGS=" -vfsoverlay %BuildRoot% /2/stdlib/windows-vfs-overlay.yaml" ^
437
446
-D CMAKE_EXE_LINKER_FLAGS=" /INCREMENTAL:NO" ^
438
447
-D CMAKE_SHARED_LINKER_FLAGS=" /INCREMENTAL:NO" ^
439
448
@@ -460,7 +469,7 @@ cmake ^
460
469
-D CMAKE_CXX_FLAGS=" /GS- /Oy /Gw /Gy" ^
461
470
-D CMAKE_MT=mt ^
462
471
-D CMAKE_Swift_COMPILER=%BuildRoot% /1/bin/swiftc.exe ^
463
- -D CMAKE_Swift_FLAGS=" -Xcc -DYAML_DECLARE_EXPORT -Xcc -DWIN32" ^
472
+ -D CMAKE_Swift_FLAGS=" -Xcc -DYAML_DECLARE_EXPORT -Xcc -DWIN32 -vfsoverlay %BuildRoot% /2/stdlib/windows-vfs-overlay.yaml " ^
464
473
-D CMAKE_EXE_LINKER_FLAGS=" /INCREMENTAL:NO" ^
465
474
-D CMAKE_SHARED_LINKER_FLAGS=" /INCREMENTAL:NO" ^
466
475
@@ -485,6 +494,7 @@ cmake ^
485
494
-D CMAKE_CXX_FLAGS=" /GS- /Oy /Gw /Gy" ^
486
495
-D CMAKE_MT=mt ^
487
496
-D CMAKE_Swift_COMPILER=%BuildRoot% /1/bin/swiftc.exe ^
497
+ -D CMAKE_Swift_FLAGS=" -vfsoverlay %BuildRoot% /2/stdlib/windows-vfs-overlay.yaml" ^
488
498
-D CMAKE_EXE_LINKER_FLAGS=" /INCREMENTAL:NO" ^
489
499
-D CMAKE_SHARED_LINKER_FLAGS=" /INCREMENTAL:NO" ^
490
500
@@ -518,6 +528,7 @@ cmake ^
518
528
-D CMAKE_CXX_FLAGS=" /GS- /Oy /Gw /Gy" ^
519
529
-D CMAKE_MT=mt ^
520
530
-D CMAKE_Swift_COMPILER=%BuildRoot% /1/bin/swiftc.exe ^
531
+ -D CMAKE_Swift_FLAGS=" -vfsoverlay %BuildRoot% /2/stdlib/windows-vfs-overlay.yaml" ^
521
532
-D CMAKE_EXE_LINKER_FLAGS=" /INCREMENTAL:NO" ^
522
533
-D CMAKE_SHARED_LINKER_FLAGS=" /INCREMENTAL:NO" ^
523
534
@@ -541,6 +552,7 @@ cmake ^
541
552
-D CMAKE_CXX_FLAGS=" /GS- /Oy /Gw /Gy" ^
542
553
-D CMAKE_MT=mt ^
543
554
-D CMAKE_Swift_COMPILER=%BuildRoot% /1/bin/swiftc.exe ^
555
+ -D CMAKE_Swift_FLAGS=" -vfsoverlay %BuildRoot% /2/stdlib/windows-vfs-overlay.yaml" ^
544
556
-D CMAKE_EXE_LINKER_FLAGS=" /INCREMENTAL:NO" ^
545
557
-D CMAKE_SHARED_LINKER_FLAGS=" /INCREMENTAL:NO" ^
546
558
@@ -562,6 +574,7 @@ cmake ^
562
574
-D CMAKE_CXX_FLAGS=" /GS- /Oy /Gw /Gy" ^
563
575
-D CMAKE_MT=mt ^
564
576
-D CMAKE_Swift_COMPILER=%BuildRoot% /1/bin/swiftc.exe ^
577
+ -D CMAKE_Swift_FLAGS=" -vfsoverlay %BuildRoot% /2/stdlib/windows-vfs-overlay.yaml" ^
565
578
-D CMAKE_EXE_LINKER_FLAGS=" /INCREMENTAL:NO" ^
566
579
-D CMAKE_SHARED_LINKER_FLAGS=" /INCREMENTAL:NO" ^
567
580
@@ -597,6 +610,7 @@ cmake ^
597
610
-D CMAKE_CXX_FLAGS=" /GS- /Oy /Gw /Gy -Xclang -fno-split-cold-code" ^
598
611
-D CMAKE_MT=mt ^
599
612
-D CMAKE_Swift_COMPILER=%BuildRoot% /1/bin/swiftc.exe ^
613
+ -D CMAKE_Swift_FLAGS=" -vfsoverlay %BuildRoot% /2/stdlib/windows-vfs-overlay.yaml" ^
600
614
-D CMAKE_EXE_LINKER_FLAGS=" /INCREMENTAL:NO" ^
601
615
-D CMAKE_SHARED_LINKER_FLAGS=" /INCREMENTAL:NO" ^
602
616
@@ -640,6 +654,7 @@ cmake ^
640
654
-D CMAKE_CXX_FLAGS=" /GS- /Oy /Gw /Gy -Xclang -fno-split-cold-code" ^
641
655
-D CMAKE_MT=mt ^
642
656
-D CMAKE_Swift_COMPILER=%BuildRoot% /1/bin/swiftc.exe ^
657
+ -D CMAKE_Swift_FLAGS=" -vfsoverlay %BuildRoot% /2/stdlib/windows-vfs-overlay.yaml" ^
643
658
-D CMAKE_EXE_LINKER_FLAGS=" /INCREMENTAL:NO" ^
644
659
-D CMAKE_SHARED_LINKER_FLAGS=" /INCREMENTAL:NO" ^
645
660
0 commit comments