home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #20 / NN_1992_20.iso / spool / comp / sys / mac / programm / 15063 < prev    next >
Encoding:
Text File  |  1992-09-08  |  1.8 KB  |  53 lines

  1. Path: sparky!uunet!sun-barr!cs.utexas.edu!usc!rpi!uwm.edu!psuvax1!rutgers!ub!acsu.buffalo.edu!triantos
  2. From: triantos@acsu.buffalo.edu (Nick B Triantos)
  3. Newsgroups: comp.sys.mac.programmer
  4. Subject: Help needed translating from MPW to THINK C ...
  5. Message-ID: <Bu6tnD.I96@acsu.buffalo.edu>
  6. Date: 7 Sep 92 03:59:34 GMT
  7. Sender: nntp@acsu.buffalo.edu
  8. Distribution: comp
  9. Organization: The University at Buffalo
  10. Lines: 39
  11. Originator: triantos@autarch.acsu.buffalo.edu
  12. Nntp-Posting-Host: autarch.acsu.buffalo.edu
  13.  
  14. Hi,
  15.  
  16. I'm trying to compile the source to Windows 3 (Name correct?), the program that
  17. lets me show everyone that my Mac can run Windows (Check it out before you
  18. flame me).  Anyway, I'm trying to compile it in THINK, and, after some minor
  19. changes, I'm getting errors caused by the line below.  It's used as follows:
  20.  
  21. extern void _DataInit();
  22.  
  23. /* This routine is part of the MPW runtime library. This external
  24.    reference to it is done so that we can unload its segment, %A5Init. */
  25.  
  26.  
  27. #pragma segment Main
  28. void main(void)
  29. {
  30.     UnloadSeg((Ptr) _DataInit);        /* note that _DataInit must not
  31.  
  32. be in Main! */
  33.     
  34.     /* 1.01 - call to ForceEnvirons removed */
  35.     
  36.     /*    If you have stack requirements that differ from the default,
  37.         then you could use SetApplLimit to increase StackSpace at 
  38.         this point, before calling MaxApplZone. */
  39.     MaxApplZone();                    /* expand the heap so 
  40. code segments load at the top */
  41.  
  42. My question is, how can I make this part work in THINK?  I have tried just
  43. commenting it out ("When in doubt, comment it out"), and, well, that was a
  44. stupid idea.  Any others?
  45.  
  46. Thanks,
  47. -Nick
  48. --
  49. Nick Triantos    internet: triantos@acsu.buffalo.edu
  50.                  AOL:      Triantos
  51. "Scientists tell us that the fastest animal on earth, with a top speed of
  52. 120 ft/sec, is a cow that has been dropped out of a helicopter." - Dave Barry
  53.