This patch prevents a linker testsuite error if the checks are run with a
[deliverable/binutils-gdb.git] / ld / testsuite / lib / ld-lib.exp
index a657a975ebc10f8c2e5ee32422479212e4fa0aa4..9f7a414cc99f4bbb352bff7888b4990f32e5c22f 100644 (file)
@@ -1666,6 +1666,10 @@ proc check_lto_available { } {
     global CC
 
     if {![info exists lto_available_saved]} {
+        if { [which $CC] == 0 } {
+           set lto_available_saved 0
+           return 0
+       }
        # Check if gcc supports -flto -fuse-linker-plugin
        set flags ""
        if [board_info [target_info name] exists cflags] {
This page took 0.023292 seconds and 4 git commands to generate.