File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -419,22 +419,25 @@ impl Library {
419
419
( Some ( static_dir) , Some ( dynamic_dir) ) => match self . config . link {
420
420
LinkType :: Static => {
421
421
println ! ( "cargo:rustc-link-search={}" , static_dir. display( ) ) ;
422
+ println ! ( "cargo:rustc-link-lib=static={}" , OPENMP_RUNTIME_LIB ) ;
422
423
}
423
424
LinkType :: Dynamic => {
424
425
println ! ( "cargo:rustc-link-search={}" , dynamic_dir. display( ) ) ;
426
+ println ! ( "cargo:rustc-link-lib=dylib={}" , OPENMP_RUNTIME_LIB ) ;
425
427
}
426
428
} ,
427
429
( Some ( static_dir) , None ) => {
428
430
println ! ( "cargo:rustc-link-search={}" , static_dir. display( ) ) ;
431
+ println ! ( "cargo:rustc-link-lib=static={}" , OPENMP_RUNTIME_LIB ) ;
429
432
}
430
433
( None , Some ( dynamic_dir) ) => {
431
434
println ! ( "cargo:rustc-link-search={}" , dynamic_dir. display( ) ) ;
435
+ println ! ( "cargo:rustc-link-lib=dylib={}" , OPENMP_RUNTIME_LIB ) ;
432
436
}
433
437
_ => {
434
438
bail ! ( "OpenMP runtime not found" ) ;
435
439
}
436
440
}
437
- println ! ( "cargo:rustc-link-lib={}" , OPENMP_RUNTIME_LIB ) ;
438
441
}
439
442
Ok ( ( ) )
440
443
}
You can’t perform that action at this time.
0 commit comments