home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / sys / mac / programm / 20462 < prev    next >
Encoding:
Internet Message Format  |  1992-12-30  |  2.8 KB

  1. Path: sparky!uunet!zaphod.mps.ohio-state.edu!cs.utexas.edu!wupost!spool.mu.edu!agate!stanford.edu!rock!concert!duke!dsb
  2. From: dsb@duke.cs.duke.edu (D. Scott Bigham)
  3. Newsgroups: comp.sys.mac.programmer
  4. Subject: Re: Sozobon C - a free C for the Mac, too?
  5. Message-ID: <725766149@majors3.cs.duke.edu>
  6. Date: 31 Dec 92 01:42:30 GMT
  7. References: <29848@castle.ed.ac.uk>
  8. Distribution: comp
  9. Organization: n. Arrangement in an orderly or logical fashion.  See "miracle".
  10. Lines: 53
  11.  
  12. From the Holy Book of <29848@castle.ed.ac.uk>
  13.   as spake by ngse18@castle.ed.ac.uk (J R Evans) :
  14.  
  15. >[wishes for a non-proprietary C compiler for the Mac]
  16.  
  17. >                  [...] A group describing themselves as Sozobon Limited
  18. >put together a very nice K&R C for the Atari a couple of years ago, which
  19. >has seen a fair bit of use in that community, where most street machines
  20. >can't even load gcc, still less compile it.
  21.  
  22. Which is why it's my C compiler of choice.
  23.  
  24. The first question that occurs to me is which version of Sozobon C
  25. you're using.  The last official Sozobon Ltd. version released for the
  26. Atari is 2.0, which was reportedly still peppered with bugs.  The Atari
  27. version has been picked up and maintained under the name Heat-n-Serve C
  28. by Ian Lepore [who has, unfortunately, apparently vanished into the
  29. stratosphere :-( ].
  30.  
  31. >                             [...] The few initial problems I had were 
  32. >connected with Sozobon's assumption that sizeof(int)=4, whereas Think C 
  33. >uses sizeof(int)=2,
  34.  
  35. Case in point.  The latest versions of HSC set sizeof(int)=2.
  36.  
  37. >So given that we can have a basic small compiler running quickly, just how 
  38. >big a job might it be to make this produce Mac code?  Comments sought!
  39. >[e.g. Sozobon doesn't know about the specialised purposes assigned within 
  40. >the Mac to A5, but apart from telling the compiler to leave A5 alone, 
  41.  
  42. Code generation and output will be most of what you'll need to change in
  43. this regard.  For instance, you'll have to arrange to output a
  44. Mac-shaped executable header rather than a TOS-shaped one, and do the
  45. appropriate magic with resource forks and data forks, and doubtless
  46. other things I'm better off not knowing about ;).
  47.  
  48. >I guess most of this stuff will appear in the libraries? Is that so? -- 
  49.  
  50. This is where I see your major problems.  The provided library source
  51. is riddled with TOS system calls and therefore will be mostly useless on
  52. the Mac.  My advice would be to find a PD standard C library
  53. implementation for the Mac and tailor it to Sozobon.
  54.  
  55. >Russ Evans
  56. >British Geological Survey, Edinburgh
  57. >e_gs18@va.nmh.ac.uk ... ngse18@castle.ed.ac.uk
  58.  
  59.                         -sbigham
  60. -- 
  61. Scott Bigham                   | The opinions expressed above are
  62. dsb@romeo.cs.duke.edu          | (c) 1992 Hacker Ltd. and cannot be
  63. bigham@hercules.acpub.duke.edu | copied or distributed without a
  64.     (but not for long)         | Darn Good Reason(tm).
  65.