@@ -2450,9 +2450,45 @@ function Build-ExperimentalRuntime([Hashtable] $Platform, [switch] $Static = $fa
2450
2450
Invoke-IsolatingEnvVars {
2451
2451
$env: Path = " $ ( Get-CMarkBinaryCache $Platform ) \src;$ ( Get-PinnedToolchainRuntime ) ;${env: Path} "
2452
2452
2453
+ $RuntimeBinaryCache = if ($Static ) {
2454
+ Get-ProjectBinaryCache $Platform ExperimentalStaticRuntime
2455
+ } else {
2456
+ throw " dynamic Experimental Runtime is not yet implemented"
2457
+ }
2458
+
2459
+ $OverlayBinaryCache = if ($Static ) {
2460
+ Get-ProjectBinaryCache $Platform ExperimentalStaticOverlay
2461
+ } else {
2462
+ throw " dynamic Experimental Runtime is not yet implemented"
2463
+ }
2464
+
2465
+ $StringProcessingBinaryCache = if ($Static ) {
2466
+ Get-ProjectBinarycache $Platform ExperimentalStaticStringProcessing
2467
+ } else {
2468
+ throw " dynamic Experimental Runtime is not yet implemented"
2469
+ }
2470
+
2471
+ $SynchronizationBinaryCache = if ($Static ) {
2472
+ Get-ProjectBinarycache $Platform ExperimentalStaticSynchronization
2473
+ } else {
2474
+ throw " dynamic Experimental Runtime is not yet implemented"
2475
+ }
2476
+
2477
+ $DistributedBinaryCache = if ($Static ) {
2478
+ Get-ProjectBinarycache $Platform ExperimentalStaticDistributed
2479
+ } else {
2480
+ throw " dynamic Experimental Runtime is not yet implemented"
2481
+ }
2482
+
2483
+ $ObservationBinaryCache = if ($Static ) {
2484
+ Get-ProjectBinarycache $Platform ExperimentalStaticObservation
2485
+ } else {
2486
+ throw " dynamic Experimental Runtime is not yet implemented"
2487
+ }
2488
+
2453
2489
Build-CMakeProject `
2454
2490
- Src $SourceCache \swift\Runtimes\Core `
2455
- - Bin ( Get-ProjectBinaryCache $Platform ExperimentalStaticRuntime) `
2491
+ - Bin $RuntimeBinaryCache `
2456
2492
- InstallTo " $ ( Get-SwiftSDK $Platform.OS - Identifier " $ ( $Platform.OS ) Experimental" ) \usr" `
2457
2493
- Platform $Platform `
2458
2494
- UseBuiltCompilers C, CXX, Swift `
@@ -2481,7 +2517,7 @@ function Build-ExperimentalRuntime([Hashtable] $Platform, [switch] $Static = $fa
2481
2517
2482
2518
Build-CMakeProject `
2483
2519
- Src $SourceCache \swift\Runtimes\Overlay `
2484
- - Bin ( Get-ProjectBinaryCache $Platform ExperimentalStaticOverlay) `
2520
+ - Bin $OverlayBinaryCache `
2485
2521
- InstallTo " $ ( Get-SwiftSDK $Platform.OS - Identifier " $ ( $Platform.OS ) Experimental" ) \usr" `
2486
2522
- Platform $Platform `
2487
2523
- UseBuiltCompilers C, CXX, Swift `
@@ -2495,12 +2531,12 @@ function Build-ExperimentalRuntime([Hashtable] $Platform, [switch] $Static = $fa
2495
2531
CMAKE_STATIC_LIBRARY_PREFIX_Swift = " lib" ;
2496
2532
CMAKE_SYSTEM_NAME = $Platform.OS.ToString ();
2497
2533
2498
- SwiftCore_DIR = " $ ( Get-ProjectBinaryCache $Platform ExperimentalStaticRuntime ) \cmake\SwiftCore" ;
2534
+ SwiftCore_DIR = " ${RuntimeBinaryCache} \cmake\SwiftCore" ;
2499
2535
}
2500
2536
2501
2537
Build-CMakeProject `
2502
2538
- Src $SourceCache \swift\Runtimes\Supplemental\StringProcessing `
2503
- - Bin ( Get-ProjectBinaryCache $Platform ExperimentalStaticStringProcessing) `
2539
+ - Bin $StringProcessingBinaryCache `
2504
2540
- InstallTo " $ ( Get-SwiftSDK $Platform.OS - Identifier " $ ( $Platform.OS ) Experimental" ) \usr" `
2505
2541
- Platform $Platform `
2506
2542
- UseBuiltCompilers C, Swift `
@@ -2514,12 +2550,12 @@ function Build-ExperimentalRuntime([Hashtable] $Platform, [switch] $Static = $fa
2514
2550
CMAKE_STATIC_LIBRARY_PREFIX_Swift = " lib" ;
2515
2551
CMAKE_SYSTEM_NAME = $Platform.OS.ToString ();
2516
2552
2517
- SwiftCore_DIR = " $ ( Get-ProjectBinaryCache $Platform ExperimentalStaticRuntime ) \cmake\SwiftCore" ;
2553
+ SwiftCore_DIR = " ${RuntimeBinaryCache} \cmake\SwiftCore" ;
2518
2554
}
2519
2555
2520
2556
Build-CMakeProject `
2521
2557
- Src $SourceCache \swift\Runtimes\Supplemental\Synchronization `
2522
- - Bin ( Get-ProjectBinaryCache $Platform ExperimentalStaticSynchronization) `
2558
+ - Bin $SynchronizationBinaryCache `
2523
2559
- InstallTo " $ ( Get-SwiftSDK $Platform.OS - Identifier " $ ( $Platform.OS ) Experimental" ) \usr" `
2524
2560
- Platform $Platform `
2525
2561
- UseBuiltCompilers C, Swift `
@@ -2533,13 +2569,13 @@ function Build-ExperimentalRuntime([Hashtable] $Platform, [switch] $Static = $fa
2533
2569
CMAKE_STATIC_LIBRARY_PREFIX_Swift = " lib" ;
2534
2570
CMAKE_SYSTEM_NAME = $Platform.OS.ToString ();
2535
2571
2536
- SwiftCore_DIR = " $ ( Get-ProjectBinaryCache $Platform ExperimentalStaticRuntime ) \cmake\SwiftCore" ;
2537
- SwiftOverlay_DIR = " $ ( Get-ProjectBinaryCache $Platform ExperimentalStaticOverlay ) \cmake\SwiftOverlay" ;
2572
+ SwiftCore_DIR = " ${RuntimeBinaryCache} \cmake\SwiftCore" ;
2573
+ SwiftOverlay_DIR = " ${OverlayBinaryCache} \cmake\SwiftOverlay" ;
2538
2574
}
2539
2575
2540
2576
Build-CMakeProject `
2541
2577
- Src $SourceCache \swift\Runtimes\Supplemental\Distributed `
2542
- - Bin ( Get-ProjectBinaryCache $Platform ExperimentalStaticDistributed) `
2578
+ - Bin $DistributedBinaryCache `
2543
2579
- InstallTo " $ ( Get-SwiftSDK $Platform.OS - Identifier " $ ( $Platform.OS ) Experimental" ) \usr" `
2544
2580
- Platform $Platform `
2545
2581
- UseBuiltCompilers C, CXX, Swift `
@@ -2548,19 +2584,19 @@ function Build-ExperimentalRuntime([Hashtable] $Platform, [switch] $Static = $fa
2548
2584
- Defines @ {
2549
2585
BUILD_SHARED_LIBS = if ($Static ) { " NO" } else { " YES" };
2550
2586
CMAKE_FIND_PACKAGE_PREFER_CONFIG = " YES" ;
2551
- CMAKE_CXX_FLAGS = @ (" -I$ ( Get-ProjectBinaryCache $Platform ExperimentalStaticRuntime ) \include" );
2587
+ CMAKE_CXX_FLAGS = @ (" -I${RuntimeBinaryCache} \include" );
2552
2588
CMAKE_Swift_COMPILER_TARGET = (Get-ModuleTriple $Platform );
2553
2589
CMAKE_Swift_COMPILER_WORKS = " YES" ;
2554
2590
CMAKE_STATIC_LIBRARY_PREFIX_Swift = " lib" ;
2555
2591
CMAKE_SYSTEM_NAME = $Platform.OS.ToString ();
2556
2592
2557
- SwiftCore_DIR = " $ ( Get-ProjectBinaryCache $Platform ExperimentalStaticRuntime ) \cmake\SwiftCore" ;
2558
- SwiftOverlay_DIR = " $ ( Get-ProjectBinaryCache $Platform ExperimentalStaticOverlay ) \cmake\SwiftOverlay" ;
2593
+ SwiftCore_DIR = " ${RuntimeBinaryCache} \cmake\SwiftCore" ;
2594
+ SwiftOverlay_DIR = " ${OverlayBinaryCache} \cmake\SwiftOverlay" ;
2559
2595
}
2560
2596
2561
2597
Build-CMakeProject `
2562
2598
- Src $SourceCache \swift\Runtimes\Supplemental\Observation `
2563
- - Bin ( Get-ProjectBinaryCache $Platform ExperimentalStaticObservation) `
2599
+ - Bin $ObservationBinaryCache `
2564
2600
- InstallTo " $ ( Get-SwiftSDK $Platform.OS - Identifier " $ ( $Platform.OS ) Experimental" ) \usr" `
2565
2601
- Platform $Platform `
2566
2602
- UseBuiltCompilers CXX, Swift `
@@ -2569,14 +2605,14 @@ function Build-ExperimentalRuntime([Hashtable] $Platform, [switch] $Static = $fa
2569
2605
- Defines @ {
2570
2606
BUILD_SHARED_LIBS = if ($Static ) { " NO" } else { " YES" };
2571
2607
CMAKE_FIND_PACKAGE_PREFER_CONFIG = " YES" ;
2572
- CMAKE_CXX_FLAGS = @ (" -I$ ( Get-ProjectBinaryCache $Platform ExperimentalStaticRuntime ) \include" );
2608
+ CMAKE_CXX_FLAGS = @ (" -I${RuntimeBinaryCache} \include" );
2573
2609
CMAKE_Swift_COMPILER_TARGET = (Get-ModuleTriple $Platform );
2574
2610
CMAKE_Swift_COMPILER_WORKS = " YES" ;
2575
2611
CMAKE_STATIC_LIBRARY_PREFIX_Swift = " lib" ;
2576
2612
CMAKE_SYSTEM_NAME = $Platform.OS.ToString ();
2577
2613
2578
- SwiftCore_DIR = " $ ( Get-ProjectBinaryCache $Platform ExperimentalStaticRuntime ) \cmake\SwiftCore" ;
2579
- SwiftOverlay_DIR = " $ ( Get-ProjectBinaryCache $Platform ExperimentalStaticOverlay ) \cmake\SwiftOverlay" ;
2614
+ SwiftCore_DIR = " ${RuntimeBinaryCache} \cmake\SwiftCore" ;
2615
+ SwiftOverlay_DIR = " ${OverlayBinaryCache} \cmake\SwiftOverlay" ;
2580
2616
}
2581
2617
}
2582
2618
}
0 commit comments