File tree Expand file tree Collapse file tree 2 files changed +9
-5
lines changed
Expand file tree Collapse file tree 2 files changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -77,3 +77,7 @@ test = false # no unit tests
7777name = " rustup-init"
7878path = " src/rustup-cli/main.rs"
7979test = false # no unit tests
80+
81+ [profile .release ]
82+ lto = true
83+ codegen-units = 1
Original file line number Diff line number Diff line change 1414
1515#![ recursion_limit = "1024" ]
1616
17- use std:: alloc:: System ;
18-
19- #[ global_allocator]
20- static A : System = System ;
21-
2217#[ macro_use]
2318extern crate error_chain;
2419extern crate rustup_dist;
@@ -60,12 +55,17 @@ mod term2;
6055mod errors;
6156mod help;
6257
58+ use std:: alloc:: System ;
6359use std:: env;
6460use std:: path:: PathBuf ;
6561use errors:: * ;
6662use rustup_dist:: dist:: TargetTriple ;
6763use rustup:: env_var:: RUST_RECURSION_COUNT_MAX ;
6864
65+ // Always use the system allocator, to reduce binary size.
66+ #[ global_allocator]
67+ static _ALLOCATOR: System = System ;
68+
6969fn main ( ) {
7070 if let Err ( ref e) = run_rustup ( ) {
7171 common:: report_error ( e) ;
You can’t perform that action at this time.
0 commit comments