I have been trying to compile an asm file with tasm running on windows XP.
Tasm32 version - Turbo Assembler Version 5.0 Copyright (c) 1988, 1996 Borland International
Turbo Link Version 1.6.71.0 Copyright (c) 1993,1996 Borland International
With my current directory set to tasm\bin
I have been able to do the following-
TASM32 /m29A /ml filename.asm
This generates the normal .Obj file. So far so good. Then I try to link using -
TLINK32 -Tpe -aa -x filename.obj,,,"kernel32.lib"
I am using the appropriate path to the kernel32.lib
But it is throwing up the following errors -
Fatal: Unable to open file 'filename.obj,,,C:\Program Files\Microsoft SDKs\Windo
ws\v6.0A\Lib\Kernel32.lib'
I have very little knowledge of asm and did Google around for a solution but I can't seem to find one. It seems that the linker is taking everything to be one single file.
Any help will be appreciated as I am completely at sea how to solve this.
Thank you.
I have Borland C++ Builder 5 installed, which includes tasm32 and tlink32. The command-line options for TASM32 print as follows:
The command-line options for TLINK32 print as follows:
So your linker command line
has the following options: -Tpe means output file type PE exe, -aa means application type "uses Windowing API", -x means no map. Since the -n option was not specified, the default runtime libraries will be included.
Then there are six lists of filenames. The lists are separated by commas. The filenames are separated by spaces if I remember correctly.
Currently you have objfiles = filename.obj, resfiles=kernel32.lib, and the other four lists of filenames are empty. I think you actually mean kernel32.lib to be in the list of libfiles. Try this:
This project will be easier to build and maintain if you create a makefile, because all it takes is one extra comma to make the linker stage fail. You've already experienced the frustration of trying to debug a mysterious build recipie.
Sorry this is about as far as I can get with this question, there's not much here that I can actually test. Hopefully this is enough to get your build on the right track. Good luck!