PRODUCT : Borland C NUMBER : 657 VERSION : 2.0 OS : PC DOS DATE : September 11, 1991 PAGE : 1/1 TITLE : Linking a Windows Application from the Command Line The syntax for TLINK is: TLINK objfiles,exefile,mapfile,libfiles,deffile You must always use the /Tw option to create a Windows EXE or DLL. Use /Twe or /Twd to specifically create a Windows EXE or DLL, respectively. The last two options override specifications in the DEF file. There is a specific startup module to use with Windows EXE's; it is C0Wx.OBJ. For DLL's it is C0Dx.OBJ. The required libraries are: IMPORT.LIB, CWINx.LIB, MATHx.LIB and Cx.LIB. For DLL's the Windows library for the small and compact models is CWINC.LIB and for medium and large it is CWINL.LIB. The last three libraries, CWINx.LIB, MATHx.LIB and Cx.LIB, must always be in this exact order. NOTE: The libraries EMU.LIB and FP87.LIB will NEVER be used in a Windows program. BC++ will take care of the floating-point math automatically. You will then have to run the Resource Compiler to fully create a Windows EXE. For more information, consult pages 115-130 in the User's Guide on linking for Windows.