Not run here: dosbench has no copy of TASM or Turbo Debugger, so their lines follow Borland's documentation. TLINK and TLIB come with Turbo C++, and their lines below were run on a dosbench box, on object files from MASM.
TASM reads MASM syntax by default (it also has its own IDEAL mode) and only assembles: each source becomes an object file, and TLINK makes the program. The extensions are optional on both command lines.
| Option | Effect |
|---|---|
| /l | write a listing (.LST) |
| /zi | Turbo Debugger information |
| /m2 | two passes (resolves forward references MASM-style) |
| /ml | names are case-sensitive |
| /t | quiet unless there are errors |
TASM HELLO ; HELLO.OBJTLINK /t HELLO ; HELLO.COMTASM HELLOXTLINK HELLOX ; HELLOX.EXETASM /zi MAINTASM /zi PRINTTLINK /v MAIN PRINT, PROG ; PROG.EXE with debug informationTD PROG
TLINK and TLIB
TLINK's fields are the objects (separated by spaces or +), then after commas the program, the map and the libraries. It writes a map unless told /x; /m adds the public names, /t makes a .COM, /v keeps Turbo Debugger information. TLIB adds with +, removes with -, replaces with -+, copies out with *, and lists the library after a comma: TLIB UTIL, UTIL.LST.
TLINK MAIN PRINT, PROGTLINK /t HELLO, HELLOTLIB UTIL +PRINTTLINK MAIN, PROG,, UTIL
Turbo Debugger
TD is Borland's full-screen debugger, with the source of a program built with /zi and /v. F7 traces into, F8 steps over, F9 runs, F2 sets a breakpoint, F4 runs to the cursor, Alt+F5 shows the program's own screen.
Pitfalls
TLINK 5 stops with "32-bit record encountered" on objects that carry MASM 6's CodeView information: link ML's objects built without /Zi. TLIB says a module is "already in LIB, not changed" when + adds a name that is there; replace it with -+.