VOGONS


tlink error

Topic actions

First post, by philden

User metadata
Rank Newbie
Rank
Newbie

Hi. I would like to use DOSBox under Mac OS X to run some DOS accounting programs which I currently run on a PC under Windows 98(!).

The programs run OK, but I occasionally need to re-compile the progs to incorporate new data, using Turbo C. I have followed the instructions here: http://photogabble.co.uk/projects/dos-days/turbo-c-dos/ to install the Turbo C compilers.

However, if I use my compiling script I get the following error:

Error 1: Unable to execute command 'tlink.exe'

Does anyone know of a fix for this? My web searches so far have not found an answer.
Thanks, Phil.

Reply 1 of 5, by Qbix

User metadata
Rank DOSBox Author
Rank
DOSBox Author

set the path correctly (this guess is without looking at the link)

Water flows down the stream
How to ask questions the smart way!

Reply 2 of 5, by HunterZ

User metadata
Rank l33t++
Rank
l33t++

Yeah I just looked at the screenshots and saw this:
install_000.thumbnail.png

You should put something like this in the [AUTOEXEC] section at the end of your dosbox.conf:
PATH %PATH%;c:\tc

Reply 3 of 5, by philden

User metadata
Rank Newbie
Rank
Newbie

Thanks very much for the help, that has made the compiler run, but produces a new error:

Undefined symbol '_main' in module C0S

Each of my C progs contain a main() section, and all I have done is copy them by ftp from the Windows machine where they compile OK.

Phil.

Reply 4 of 5, by Qbix

User metadata
Rank DOSBox Author
Rank
DOSBox Author

be sure to write real C code.
The turbo compiler you are trying to use is ancient

Water flows down the stream
How to ask questions the smart way!

Reply 5 of 5, by HunterZ

User metadata
Rank l33t++
Rank
l33t++

Yeah, I wonder if it expects ANSI C or K&R C. It certainly doesn't look like a C++ compiler, just a C compiler.

Anyways, ask google and you'll find stuff like this:

Q. Why do I get the message: Linker Error: Undefined symbol '_main' in module C0 […]
Show full quote

Q. Why do I get the message:
Linker Error: Undefined symbol '_main' in module C0

A. Every C program must contain a function called main(). This is the first function executed in your program. The function name must be all in lower case. If your program does not have one, create one. If you are using multiple source files, the file that contains the function main() must be one of the files listed in the Project.

Note that an underscore character '_' is prepended to all external Borland C++ symbols.