home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #19 / NN_1992_19.iso / spool / comp / sys / mac / programm / 14855 < prev    next >
Encoding:
Text File  |  1992-09-01  |  1.9 KB  |  46 lines

  1. Newsgroups: comp.sys.mac.programmer
  2. Path: sparky!uunet!stanford.edu!ames!elroy.jpl.nasa.gov!news
  3. From: jhl@naif.jpl.nasa.gov (Jay Lieske)
  4. Subject: Re: Fortran callable rountines in THINK C
  5. Message-ID: <1992Sep1.211401.10314@elroy.jpl.nasa.gov>
  6. Sender: news@elroy.jpl.nasa.gov (Usenet)
  7. Nntp-Posting-Host: achilles.jpl.nasa.gov
  8. Organization: Jet Propulsion Laboratory
  9. References: <1992Sep1.113040.943@galaxy.gov.bc.ca>
  10. Distribution: na
  11. Date: Tue, 1 Sep 1992 21:14:01 GMT
  12. Lines: 32
  13.  
  14. In article <1992Sep1.113040.943@galaxy.gov.bc.ca> cconstantine@galaxy.gov.bc.ca
  15. writes:
  16. >I will be working on a program with a friend of mine that will interface some
  17. >Fortran code (Language Systems) and would like my C libraries to be callable
  18. >form Fortran.  Is there a specific way I need to do this?  I'm using THINK C
  19. >5.0.2 on an LCII (now called a Perforama 400) and System 7.0.1 w/ tune-up.
  20. >
  21. >Thanks muchly!!!!
  22. >-- 
  23. >Carl B. Constantine
  24. >CCONSTANTINE@galaxy.gov.bc.ca
  25. >    "Opinions are mine only!!"
  26. >
  27.  
  28. In principle, I think it can be done, but it's rather tough with Think
  29. products.  Specifically, I tried this a few years ago using Think Pascal.
  30. The basic problem is that Think compilers are case-sensitive and its
  31. linker is case-insensitive whereas the MPW Pascal compiler is case
  32. insensitive but the linker is case-sensitive.  For Pascal programs that
  33. means that the ENTRY points must be all caps.  One interesting and
  34. potentially useful side effect of all this is that Think and MPW libraries
  35. may be intermixed--for example MPW's NEWPTR is "different" from
  36. Think's NewPtr because of the capitalization.
  37.  
  38. At one time Rich Siegel mentioned that Think Pascal might look into
  39. the problem, but I don't believe they have done anything up to now.  It's
  40. much easier just to recompile things with MPW compilers (after using 
  41. Think's excellent debugging tools) and link with Language Systems Fortran.
  42.  
  43.  
  44. Jay H. Lieske                                            jhl@naif.jpl.nasa.gov
  45.  
  46.