Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* cross compiler host vs build
@ 2004-01-29  2:00 dan clark
  2004-01-29  3:45 ` Felix Lee
  0 siblings, 1 reply; 7+ messages in thread
From: dan clark @ 2004-01-29  2:00 UTC (permalink / raw)
  To: gdb-patches

During the configuration of gdb for cross compilation the configure 
command line can include:
--build, --host, --target.

The configure script in 6.0 checks if the host != target to decide if a
cross compiler should be used.  Based on the definitions in the
documentation the host is 'where gdb runs' and the target is 'where
program being debugged executes', neither of which have anything to do
what compiler is being used to build the code. Perhaps the decision on
when to use a cross compiler should be made based on when the 'build' is
not equal to the 'host' machine, thus requiring a cross compiler to
produce the binary. 

diff -r -c -N -p -x '*.orig' -x '*.rej' gdb-6.0-orig/configure gdb-6.0/configure
*** gdb-6.0-orig/configure	Tue Jun 17 19:25:31 2003
--- gdb-6.0/configure	Mon Dec 29 13:45:35 2003
*************** appdirs=""
*** 848,854 ****
  
  # Define is_cross_compiler to save on calls to 'test'.
  is_cross_compiler=
! if test x"${host}" = x"${target}" ; then
    is_cross_compiler=no
  else
    is_cross_compiler=yes
--- 848,854 ----
  
  # Define is_cross_compiler to save on calls to 'test'.
  is_cross_compiler=
! if test x"${host}" = x"${build}" ; then
    is_cross_compiler=no
  else
    is_cross_compiler=yes

-- 
Dan L. Clark       dlc@ncube.com    503/531-6432
nCUBE, 1825 NW 167th Place, Beaverton, OR  97006


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2004-01-29 22:25 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-01-29  2:00 cross compiler host vs build dan clark
2004-01-29  3:45 ` Felix Lee
2004-01-29 17:00   ` with-headers should be 'build' != 'host' dan clark
2004-01-29 18:12     ` Daniel Jacobowitz
2004-01-29 21:41       ` Ian Lance Taylor
2004-01-29 22:25         ` Felix Lee
2004-01-29 18:41     ` Felix Lee

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox