diff options
author | Dave Korn <dave.korn@artimi.com> | 2009-03-16 22:03:44 +0000 |
---|---|---|
committer | Dave Korn <dave.korn@artimi.com> | 2009-03-16 22:03:44 +0000 |
commit | 9b3ea03ba3f2b40b1d529f31695abaec432899ae (patch) | |
tree | a19fc998a390ec453b50269d5e8a359941126756 /ld/testsuite/ld-bootstrap/bootstrap.exp | |
parent | a624e1115aed93bdc9680076979926cb11d4b5ac (diff) | |
download | gdb-9b3ea03ba3f2b40b1d529f31695abaec432899ae.zip gdb-9b3ea03ba3f2b40b1d529f31695abaec432899ae.tar.gz gdb-9b3ea03ba3f2b40b1d529f31695abaec432899ae.tar.bz2 |
* ld-bootstrap/bootstrap.exp: Also pass '-liconv' to linker when
linking statically on Cygwin, necessitated by '-lintl'.
Diffstat (limited to 'ld/testsuite/ld-bootstrap/bootstrap.exp')
-rw-r--r-- | ld/testsuite/ld-bootstrap/bootstrap.exp | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/ld/testsuite/ld-bootstrap/bootstrap.exp b/ld/testsuite/ld-bootstrap/bootstrap.exp index fdeffe3..d84897d 100644 --- a/ld/testsuite/ld-bootstrap/bootstrap.exp +++ b/ld/testsuite/ld-bootstrap/bootstrap.exp @@ -83,13 +83,21 @@ foreach flags {"" "strip" "--static" "--traditional-format" } } + # On Cygwin, -lintl may require -liconv when linking statically. + set extralibs "" + if { [istarget "*-*-cygwin*"]} { + if {"$flags" == "--static"} { + set extralibs "-liconv" + } + } + # On Irix 5, linking with --static only works if all the files are # compiled using -non_shared. if {"$flags" == "--static"} { setup_xfail "mips*-*-irix5*" } - if ![ld_link $ld tmpdir/ld1 "$flags tmpdir/ld-partial.o $BFDLIB $LIBIBERTY"] { + if ![ld_link $ld tmpdir/ld1 "$flags tmpdir/ld-partial.o $BFDLIB $LIBIBERTY $extralibs"] { fail $testname continue } @@ -104,12 +112,12 @@ foreach flags {"" "strip" "--static" "--traditional-format" } } - if ![ld_link tmpdir/ld1 tmpdir/ld2 "$flags $OFILES $BFDLIB $LIBIBERTY"] { + if ![ld_link tmpdir/ld1 tmpdir/ld2 "$flags $OFILES $BFDLIB $LIBIBERTY $extralibs"] { fail $testname continue } - if ![ld_link tmpdir/ld2 tmpdir/ld3 "$flags $OFILES $BFDLIB $LIBIBERTY"] { + if ![ld_link tmpdir/ld2 tmpdir/ld3 "$flags $OFILES $BFDLIB $LIBIBERTY $extralibs"] { fail $testname continue } |