home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / gnu / gcc / help / 1748 next >
Encoding:
Internet Message Format  |  1992-07-21  |  2.0 KB

  1. Path: sparky!uunet!cs.utexas.edu!sun-barr!ames!network.ucsd.edu!sdcc12!sdcc3!jclark
  2. From: jclark@sdcc3.ucsd.edu (John Clark)
  3. Newsgroups: gnu.gcc.help
  4. Subject: Re: installing gcc linker (ld)
  5. Message-ID: <35900@sdcc12.ucsd.edu>
  6. Date: 21 Jul 92 18:55:22 GMT
  7. References: <9207162210.AA26434@cod.nosc.mil> <1992Jul18.190052.11346@utkux1.utk.edu>
  8. Sender: news@sdcc12.ucsd.edu
  9. Distribution: gnu
  10. Organization: University of California, San Diego
  11. Lines: 41
  12. Nntp-Posting-Host: sdcc3.ucsd.edu
  13.  
  14. In article <1992Jul18.190052.11346@utkux1.utk.edu> rich@laser1.engr.utk.edu (Stevie-weave) writes:
  15. +
  16. +In a similar and related issue, I'm building gcc-2.2.2 as a x-compiler for
  17. +VxWorks for a 68030 processor with the compiler host a Sparc2. Some other
  18. +stuff we have needs a cross loader, but the ld that is in the
  19. +sun3/2.2.2/ set doesn't work. It dies with
  20. +
  21. +laser3$ ld -d -r -Bstatic -o test2.o test.o
  22. +ld: test.o: wrong machine type
  23. +collect: /usr/bin/ld returned 4 exit status
  24.  
  25. The complete sparc to mc68030 environment requires that you build a
  26. X-ld program supplied in the 'binutils' package, I think the current
  27. released version is 1.94 or so. The 'ld' function built will take
  28. the 68k gas output and create an executable.
  29.  
  30. If you've already compiled the GNU ld, and got the above error, then
  31. you may not have 'configured' the build correctly. You should have
  32. configured with a line something to the effect of:
  33.  
  34. configure -host=sun4 -target=sun3
  35.  
  36. (may be off modulo some dashes, but there is doc in the bintuils
  37. directory with examples).
  38.  
  39. However, your stated command line seems to indicate that you're
  40. using the sparc 'ld' rather than
  41. '/usr/local/lib/gcc-lib/sun3/2.2.2/ld' (or something to that
  42. effect).
  43.  
  44.  
  45. As a practice, I've set up the m68k ld to be in /usr/local/bin/ld68k
  46. which may be linked to the ugly path list above. Similarly, gcc68k
  47. and gas68k would be linked to the appropriate m68k executables. This
  48. prevents the inadvertent use of the host's native tools and the
  49. resulting 'wrong machine....' error messages.
  50.  
  51. -- 
  52.  
  53. John Clark
  54. jclark@ucsd.edu
  55.