* lib/target.exp (default_target_compile): Honor LDFLAGS_FOR_TARGET.
authorMichael Forney <forney@google.com>
Wed, 11 Nov 2015 10:14:04 +0000 (21:14 +1100)
committerBen Elliston <bje@gnu.org>
Wed, 11 Nov 2015 10:14:04 +0000 (21:14 +1100)
Signed-off-by: Ben Elliston <bje@gnu.org>
ChangeLog
lib/target.exp

index 952769c..affcaab 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2015-11-11  Michael Forney  <forney@google.com>
+
+       * lib/target.exp (default_target_compile): Honor LDFLAGS_FOR_TARGET.
+
 2015-11-11  Ben Elliston  <bje@gnu.org>
 
        * doc/dejagnu.texi: Regenerate.
index 30e4585..6749caa 100644 (file)
@@ -307,6 +307,7 @@ proc default_target_compile {source destfile type options} {
     global target_triplet
     global tool_root_dir
     global CFLAGS_FOR_TARGET
+    global LDFLAGS_FOR_TARGET
     global compiler_flags
 
     if { $destfile == "" && $type != "preprocess" && $type != "none" } {
@@ -324,6 +325,10 @@ proc default_target_compile {source destfile type options} {
        append add_flags " $CFLAGS_FOR_TARGET"
     }
 
+    if {[info exists LDFLAGS_FOR_TARGET]} {
+       append ldflags " $LDFLAGS_FOR_TARGET"
+    }
+
     if {[info exists target_info(host,name)]} {
        set host [host_info name]
     } else {