home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / os / os2 / programm / 3866 < prev    next >
Encoding:
Internet Message Format  |  1992-07-29  |  3.6 KB

  1. Path: sparky!uunet!darwin.sura.net!wupost!usc!rutgers!njitgw.njit.edu!hertz.njit.edu!dic5340
  2. From: dic5340@hertz.njit.edu (David Charlap)
  3. Newsgroups: comp.os.os2.programmer
  4. Subject: Re: Using MS-C (MSDOS) library for OS/2 ... possible?
  5. Message-ID: <1992Jul29.160423.15953@njitgw.njit.edu>
  6. Date: 29 Jul 92 16:04:23 GMT
  7. References: <1992Jul28.135030.3386@monu6.cc.monash.edu.au>
  8. Sender: news@njit.edu
  9. Organization: New Jersey Institute of Technology, Newark, N.J.
  10. Lines: 66
  11. Nntp-Posting-Host: hertz.njit.edu
  12.  
  13. In article <1992Jul28.135030.3386@monu6.cc.monash.edu.au> sci240s@monu6.cc.monash.edu.au (Mr W.J. Ho) writes:
  14. >
  15. >Can I use Microsoft C (Version 6.00a) to write OS/2 programs (I understand
  16. >they will be 16-bit only) using the libraries (eg, neural nets library that
  17. >uses specialize co-processor board)?
  18.  
  19. Yes.  I do this quite a bit.  Go to your C 6.00 install disk and
  20. re-install it, telling it to build the OS/2 libraries.  Also have it
  21. include the OS/2 compiler.  Afterwards, apply the 6.0a patch (if you
  22. have a separate set of patch disks for the "a" revision).
  23.  
  24. You may want to delete the DOS isntalltion first, although this isn't
  25. necessary.
  26.  
  27. The OS/2 executables will be placed in a .../BINP directory
  28. The DOS executables will be placed in a .../BINR directory
  29. The bound (both OS/2 and DOS) executables will be placed in a .../BINB directory
  30.  
  31. All libraries will be placed in one place: .../LIB
  32. Real-mode (DOS) libraries will have names of the form ?LIBC?R.LIB
  33. Protected mode (OS/2) libraries will have names of the form ?LIBC?P.LIB
  34. One of the library sets (Real or protected) may be renamed without the
  35. P/R suffix.  This will be your default library for the linker.
  36.  
  37. After installing, place the .../BINP and .../BINB directories on your
  38. OS/2 PATH (in config.sys).  Place the .../BINR and .../BINB
  39. directories on your DOS PATH (in autoexec.bat)
  40.  
  41. The other variables (like LIB, INCLUDE, HELPFILES, etc) should be set
  42. in both config.sys and in autoexec.bat, since they are common to OS/2
  43. and DOS.
  44.  
  45. Once this is done, you simply give the "CL" command to compile.  Your
  46. default executable type will be either DOS or OS/2 depending on what
  47. kind of session you run it from.  To force the other type (required if
  48. you need libraries with the P/R suffix), you use the parameters "/Lp"
  49. or "/Lr".  This way, you can compile DOS code from the OS/2 compiler
  50. and vice-versa.
  51.  
  52. Use the LINK.EXE that came with OS/2 2.0.  It's of a slightly higher
  53. version than the Microsoft LINK.EXE.  I renames the Microsoft LINK.EXE
  54. to MSLINK.EXE, to allow me to use either one.
  55.  
  56. The NMAKE utility that comes with Microsoft C 6.0 is compatible
  57. (mostly) with the Unix make utility, and is useful for compiling GNU
  58. makefiles. 
  59.  
  60. The Microsoft compiler comes with all the headers and libraries you
  61. need to produce OS/2 1.2 code.  OS/2 2.0 comes with rc for compiling
  62. resources in, and it also includes the icon editor.  You do not have a
  63. font editor or a dialog box editor.  The IBM OS/2 2.0 toolkit has
  64. these and lots of other stuff.
  65.  
  66. The Microsoft on-line help (QuickHelp) does not include the OS/2 API
  67. reference.  You must get the Microsoft OS/2 1.2 toolkit for this.
  68. It's been discontinued, but you may be able to find a copy at some
  69. stores or computer flea markets.
  70.  
  71. If you can find the IBM OS/2 1.3 toolkit, I believe it'll have the
  72. headers and libraries to produce OS/2 1.3 code.  But there aren't too
  73. many new API's in it, so it may not be necessary.
  74. -- 
  75.    |)  David Charlap           "I don't even represent myself
  76.   /|_  dic5340@hertz.njit.edu   sometimes so NJIT is right out!.
  77.  ((|,)
  78.   ~|~  Hi! I am a .signature virus, copy me into your .signature file.
  79.