@@ -1591,9 +1591,15 @@ impl Step for Extended {
1591
1591
prepare ( "cargo" ) ;
1592
1592
prepare ( "rust-std" ) ;
1593
1593
prepare ( "rust-analysis" ) ;
1594
- prepare ( "clippy" ) ;
1595
- prepare ( "rust-analyzer" ) ;
1596
- for tool in & [ "rust-docs" , "miri" , "rustc-codegen-cranelift" ] {
1594
+
1595
+ for tool in & [
1596
+ "clippy" ,
1597
+ "rustfmt" ,
1598
+ "rust-analyzer" ,
1599
+ "rust-docs" ,
1600
+ "miri" ,
1601
+ "rustc-codegen-cranelift" ,
1602
+ ] {
1597
1603
if built_tools. contains ( tool) {
1598
1604
prepare ( tool) ;
1599
1605
}
@@ -1633,6 +1639,8 @@ impl Step for Extended {
1633
1639
"rust-analyzer-preview" . to_string ( )
1634
1640
} else if name == "clippy" {
1635
1641
"clippy-preview" . to_string ( )
1642
+ } else if name == "rustfmt" {
1643
+ "rustfmt-preview" . to_string ( )
1636
1644
} else if name == "miri" {
1637
1645
"miri-preview" . to_string ( )
1638
1646
} else if name == "rustc-codegen-cranelift" {
@@ -1652,7 +1660,7 @@ impl Step for Extended {
1652
1660
prepare ( "cargo" ) ;
1653
1661
prepare ( "rust-analysis" ) ;
1654
1662
prepare ( "rust-std" ) ;
1655
- for tool in & [ "clippy" , "rust-analyzer" , "rust-docs" , "miri" ] {
1663
+ for tool in & [ "clippy" , "rustfmt" , " rust-analyzer", "rust-docs" , "miri" ] {
1656
1664
if built_tools. contains ( tool) {
1657
1665
prepare ( tool) ;
1658
1666
}
@@ -1770,6 +1778,24 @@ impl Step for Extended {
1770
1778
. arg ( etc. join ( "msi/remove-duplicates.xsl" ) )
1771
1779
. run ( builder) ;
1772
1780
}
1781
+ if built_tools. contains ( "rustfmt" ) {
1782
+ command ( & heat)
1783
+ . current_dir ( & exe)
1784
+ . arg ( "dir" )
1785
+ . arg ( "rustfmt" )
1786
+ . args ( heat_flags)
1787
+ . arg ( "-cg" )
1788
+ . arg ( "RustFmtGroup" )
1789
+ . arg ( "-dr" )
1790
+ . arg ( "RustFmt" )
1791
+ . arg ( "-var" )
1792
+ . arg ( "var.RustFmtDir" )
1793
+ . arg ( "-out" )
1794
+ . arg ( exe. join ( "RustFmtGroup.wxs" ) )
1795
+ . arg ( "-t" )
1796
+ . arg ( etc. join ( "msi/remove-duplicates.xsl" ) )
1797
+ . run ( builder) ;
1798
+ }
1773
1799
if built_tools. contains ( "miri" ) {
1774
1800
command ( & heat)
1775
1801
. current_dir ( & exe)
@@ -1841,6 +1867,9 @@ impl Step for Extended {
1841
1867
if built_tools. contains ( "clippy" ) {
1842
1868
cmd. arg ( "-dClippyDir=clippy" ) ;
1843
1869
}
1870
+ if built_tools. contains ( "rustfmt" ) {
1871
+ cmd. arg ( "-dRustFmtDir=rustfmt" ) ;
1872
+ }
1844
1873
if built_tools. contains ( "rust-docs" ) {
1845
1874
cmd. arg ( "-dDocsDir=rust-docs" ) ;
1846
1875
}
@@ -1867,6 +1896,9 @@ impl Step for Extended {
1867
1896
if built_tools. contains ( "clippy" ) {
1868
1897
candle ( "ClippyGroup.wxs" . as_ref ( ) ) ;
1869
1898
}
1899
+ if built_tools. contains ( "rustfmt" ) {
1900
+ candle ( "RustFmtGroup.wxs" . as_ref ( ) ) ;
1901
+ }
1870
1902
if built_tools. contains ( "miri" ) {
1871
1903
candle ( "MiriGroup.wxs" . as_ref ( ) ) ;
1872
1904
}
@@ -1905,6 +1937,9 @@ impl Step for Extended {
1905
1937
if built_tools. contains ( "clippy" ) {
1906
1938
cmd. arg ( "ClippyGroup.wixobj" ) ;
1907
1939
}
1940
+ if built_tools. contains ( "rustfmt" ) {
1941
+ cmd. arg ( "RustFmtGroup.wixobj" ) ;
1942
+ }
1908
1943
if built_tools. contains ( "miri" ) {
1909
1944
cmd. arg ( "MiriGroup.wixobj" ) ;
1910
1945
}
0 commit comments