OSDN Git Service

* lib/objc.exp (objc_target_compile): Add -L during compiles for
authorrobertl <robertl@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 1 Oct 1998 07:45:56 +0000 (07:45 +0000)
committerrobertl <robertl@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 1 Oct 1998 07:45:56 +0000 (07:45 +0000)
multilibbed hosts.   Idea grafted from g77.exp.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@22708 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/testsuite/ChangeLog
gcc/testsuite/lib/objc.exp

index c60f806..069b7b8 100644 (file)
@@ -1,3 +1,8 @@
+1998-10-01  Robert Lipe  <robertl@dgii.com>
+
+       * lib/objc.exp (objc_target_compile): Add -L during compiles for
+       multilibbed hosts.   Idea grafted from g77.exp.
+
 1998-09-30  Dave Love  <d.love@dl.ac.uk>
 
        * g77.f-torture/execute/u77-test.f (main): Excise `hostnm' to
index c4f325f..d67ef04 100644 (file)
@@ -139,6 +139,12 @@ proc objc_target_compile { source dest type options } {
     if [target_info exists objc,no_varargs] {
        lappend options "additional_flags=-DNO_VARARGS"
     }
+    set objcpath "[get_multilibs]"
+    set libobjc_dir [lookfor_file ${objcpath} libobjc/libobjc.a]
+    if { $libobjc_dir != "" } {
+       set objc_link_flags "-L[file dirname ${libobjc_dir}]"
+       lappend options "additional_flags=${objc_link_flags}"
+    }
     lappend options "compiler=$OBJC_UNDER_TEST"
     return [target_compile $source $dest $type $options]
 }