@@ -131,7 +131,8 @@ struct Manifest {
131131 manifest_version : String ,
132132 date : String ,
133133 pkg : BTreeMap < String , Package > ,
134- renames : BTreeMap < String , Rename >
134+ renames : BTreeMap < String , Rename > ,
135+ profiles : BTreeMap < String , Vec < String > > ,
135136}
136137
137138#[ derive( Serialize ) ]
@@ -340,6 +341,7 @@ impl Builder {
340341 date : self . date . to_string ( ) ,
341342 pkg : BTreeMap :: new ( ) ,
342343 renames : BTreeMap :: new ( ) ,
344+ profiles : BTreeMap :: new ( ) ,
343345 } ;
344346
345347 self . package ( "rustc" , & mut manifest. pkg , HOSTS ) ;
@@ -355,6 +357,20 @@ impl Builder {
355357 self . package ( "llvm-tools-preview" , & mut manifest. pkg , TARGETS ) ;
356358 self . package ( "lldb-preview" , & mut manifest. pkg , TARGETS ) ;
357359
360+ self . profile ( "minimal" ,
361+ & mut manifest. profiles ,
362+ & [ "rustc" , "cargo" , "rust-std" , "rust-mingw" ] ) ;
363+ self . profile ( "default" ,
364+ & mut manifest. profiles ,
365+ & [ "rustc" , "cargo" , "rust-std" , "rust-mingw" ,
366+ "rust-docs" , "rustfmt-preview" , "clippy-preview" ] ) ;
367+ self . profile ( "complete" ,
368+ & mut manifest. profiles ,
369+ & [ "rustc" , "cargo" , "rust-std" , "rust-mingw" ,
370+ "rust-docs" , "rustfmt-preview" , "clippy-preview" ,
371+ "rls-preview" , "rust-src" , "llvm-tools-preview" ,
372+ "lldb-preview" , "rust-analysis" ] ) ;
373+
358374 manifest. renames . insert ( "rls" . to_owned ( ) , Rename { to : "rls-preview" . to_owned ( ) } ) ;
359375 manifest. renames . insert ( "rustfmt" . to_owned ( ) , Rename { to : "rustfmt-preview" . to_owned ( ) } ) ;
360376 manifest. renames . insert ( "clippy" . to_owned ( ) , Rename { to : "clippy-preview" . to_owned ( ) } ) ;
@@ -453,6 +469,13 @@ impl Builder {
453469 return manifest;
454470 }
455471
472+ fn profile ( & mut self ,
473+ profile_name : & str ,
474+ dst : & mut BTreeMap < String , Vec < String > > ,
475+ pkgs : & [ & str ] ) {
476+ dst. insert ( profile_name. to_owned ( ) , pkgs. iter ( ) . map ( |s| ( * s) . to_owned ( ) ) . collect ( ) ) ;
477+ }
478+
456479 fn package ( & mut self ,
457480 pkgname : & str ,
458481 dst : & mut BTreeMap < String , Package > ,
0 commit comments