@@ -518,6 +518,26 @@ def install_swiftpm(prefix, args):
518
518
dest = os .path .join (prefix , "lib" , "swift" , "pm" , "PluginAPI" )
519
519
install_dylib (args , "PackagePlugin" , dest , ["PackagePlugin" ])
520
520
521
+ # Install required resource bundles
522
+ resource_bundles = [
523
+ "SwiftBuild_SWBAndroidPlatform" ,
524
+ "SwiftBuild_SWBApplePlatform" ,
525
+ "SwiftBuild_SWBCore" ,
526
+ "SwiftBuild_SWBGenericUnixPlatform" ,
527
+ "SwiftBuild_SWBQNXPlatform" ,
528
+ "SwiftBuild_SWBUniversalPlatform" ,
529
+ "SwiftBuild_SWBWebAssemblyPlatform" ,
530
+ "SwiftBuild_SWBWindowsPlatform"
531
+ ]
532
+
533
+ if '-apple-' in args .build_target :
534
+ resource_bundle_extension = 'bundle'
535
+ else :
536
+ resource_bundle_extension = 'resources'
537
+
538
+ for bundle in resource_bundles :
539
+ install_binary (args , bundle + '.' + resource_bundle_extension , os .path .join (os .path .join (prefix , "share" ), "pm" ))
540
+
521
541
522
542
# Helper function that installs a dynamic library and a set of modules to a particular directory.
523
543
def install_dylib (args , library_name , install_dir , module_names ):
0 commit comments