File tree 1 file changed +9
-1
lines changed
1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -125,11 +125,19 @@ impl Step for Llvm {
125
125
. define ( "WITH_POLLY" , "OFF" )
126
126
. define ( "LLVM_ENABLE_TERMINFO" , "OFF" )
127
127
. define ( "LLVM_ENABLE_LIBEDIT" , "OFF" )
128
- . define ( "LLVM_LINK_LLVM_DYLIB" , "ON" )
129
128
. define ( "LLVM_PARALLEL_COMPILE_JOBS" , build. jobs ( ) . to_string ( ) )
130
129
. define ( "LLVM_TARGET_ARCH" , target. split ( '-' ) . next ( ) . unwrap ( ) )
131
130
. define ( "LLVM_DEFAULT_TARGET_TRIPLE" , target) ;
132
131
132
+
133
+ // This setting makes the LLVM tools link to the dynamic LLVM library,
134
+ // which saves both memory during parallel links and overall disk space
135
+ // for the tools. We don't distribute any of those tools, so this is
136
+ // just a local concern. However, this doesn't seem to work on Windows.
137
+ if !target. contains ( "windows" ) {
138
+ cfg. define ( "LLVM_LINK_LLVM_DYLIB" , "ON" ) ;
139
+ }
140
+
133
141
if target. contains ( "msvc" ) {
134
142
cfg. define ( "LLVM_USE_CRT_DEBUG" , "MT" ) ;
135
143
cfg. define ( "LLVM_USE_CRT_RELEASE" , "MT" ) ;
You can’t perform that action at this time.
0 commit comments