]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blobdiff - ld/testsuite/ld-auto-import/auto-import.exp
Update year range in copyright notice of binutils files
[thirdparty/binutils-gdb.git] / ld / testsuite / ld-auto-import / auto-import.exp
index 0192345e7e92738df76e3a33261ea2c38b08c22e..39a0e376849d73d9af13339409df58e0eee33028 100644 (file)
@@ -1,6 +1,5 @@
 # Expect script for ld-auto-import tests
-#   Copyright 2002, 2007
-#   Free Software Foundation, Inc.
+#   Copyright (C) 2002-2021 Free Software Foundation, Inc.
 #
 # This file is part of the GNU Binutils.
 #
@@ -68,7 +67,7 @@ if [istarget *-pc-mingw*] {
 }
 
 # No compiler, no test.
-if { [which $CC] == 0 } {
+if { ![check_compiler_available] } {
     untested "Auto import test (compiler not found)"
     return
 }
@@ -122,7 +121,7 @@ if [istarget *-pc-cygwin] {
     if ![ld_compile "$CC $CFLAGS $SHCFLAG" $srcdir/$subdir/dll.c $tmpdir/dll.o] {
        fail "compiling shared lib"
     }
-    if ![ld_special_link "$CC -shared --enable-auto-import --out-implib=$tmpdir/libstandard.dll.a" $tmpdir/dll.dll "$tmpdir/dll.o $MYLIBS"] {
+    if ![ld_special_link "$ld -shared --enable-auto-import -e __cygwin_dll_entry@12 --out-implib=$tmpdir/libstandard.dll.a" $tmpdir/dll.dll "$tmpdir/dll.o $MYLIBS"] {
        fail "linking shared lib"
     }