From db93e372db4777647c7d9c7d03569ab2224f74ed Mon Sep 17 00:00:00 2001 From: Ben Elliston Date: Thu, 22 Jun 2006 15:47:53 +0000 Subject: 2006-06-23 Eric Botcazou * libgloss.exp (find_gnatmake): Rewrite. --- lib/libgloss.exp | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) (limited to 'lib') diff --git a/lib/libgloss.exp b/lib/libgloss.exp index 5722636..e904b8c 100644 --- a/lib/libgloss.exp +++ b/lib/libgloss.exp @@ -705,21 +705,21 @@ proc find_g77 {} { proc find_gnatmake {} { global tool_root_dir - set root "$tool_root_dir/gcc" - set GM "" - if {![is_remote host]} { - set file [lookfor_file $root gnatmake] - if { $file != "" } { - set GM "$file -I$root/ada/rts --GCC=$root/xgcc --GNATBIND=$root/gnatbind --GNATLINK=$root/gnatlink -cargs -B$root -largs --GCC=$root/xgcc -margs"; - } - } - - if {$GM == ""} { - set GM [transform gnatmake] + set file [lookfor_file $tool_root_dir gnatmake] + if { $file == "" } { + set file [lookfor_file $tool_root_dir gcc/gnatmake] + } + if { $file != "" } { + set root [file dirname $file] + set CC "$file -I$root/ada/rts --GCC=$root/xgcc --GNATBIND=$root/gnatbind --GNATLINK=$root/gnatlink -cargs -B$root -largs --GCC=$root/xgcc -B$root -margs" + } else { + set CC [transform gnatmake] + } + } else { + set CC [transform gnatmake] } - - return $GM + return $CC } proc find_nm {} { -- cgit v1.1