File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -753,10 +753,14 @@ fn dylib_path_envvar() -> &'static str {
753753 }
754754}
755755fn dylib_path ( ) -> Vec < PathBuf > {
756- match env:: var_os ( dylib_path_envvar ( ) ) {
756+ let mut dylibs = match env:: var_os ( dylib_path_envvar ( ) ) {
757757 Some ( var) => env:: split_paths ( & var) . collect ( ) ,
758758 None => Vec :: new ( ) ,
759+ } ;
760+ if let Ok ( dir) = env:: current_dir ( ) {
761+ dylibs. push ( dir) ;
759762 }
763+ dylibs
760764}
761765
762766fn find_rustc_codegen_spirv ( ) -> Result < PathBuf , SpirvBuilderError > {
@@ -766,7 +770,8 @@ fn find_rustc_codegen_spirv() -> Result<PathBuf, SpirvBuilderError> {
766770 env:: consts:: DLL_PREFIX ,
767771 env:: consts:: DLL_SUFFIX
768772 ) ;
769- for mut path in dylib_path ( ) {
773+ let dylib_paths = dylib_path ( ) ;
774+ for mut path in dylib_paths {
770775 path. push ( & filename) ;
771776 if path. is_file ( ) {
772777 return Ok ( path) ;
You can’t perform that action at this time.
0 commit comments