hi,
i'm using tasm and i'm still writing dos code, so i'd like to use tlink.exe instead of tlink32.exe which is always used whenever i try to link my .obj ... how can i tell RADasm to use tlink.exe?
Posted on 2003-06-25 09:41:03 by wasiliy
Go under project options and change the linker.
Posted on 2003-06-25 10:06:26 by roticv
ok but when i'm working with just one file then it doesnt work.
Posted on 2003-06-25 10:11:45 by wasiliy
Ketil will correct me if I'm wrong but I believe you can add a section to TASM.INI named , set it as the first project type in the ini file and it will be the default options that are loaded if you have an asm file loaded without a project. Do not add the MakeDefNoProject section to your types and it will not appear when you create a new project. This section will have to be manually maintained.
Posted on 2003-06-25 10:32:28 by donkey
ok i edited the tasm.ini
assembling the file works fine with the line:
2=$.obj,O,$B\tasm32.EXE ,$.asm

but linking doesnt work with this line:
3=$.exe,O,$B\tlink.EXE /t ,$.obj


( /t because i have a com file )

radasm just returns the following: Make error(s) occured.
not quite helpful

it worked when i tried to link in command.com manually, so there must be something wrong with my .ini
do you see any mistakes??
Posted on 2003-06-25 14:16:13 by wasiliy
Make errors occured is just to signal you that a file that was supposed to have been created by your command line was not created. For link errors you will have to set the output of your linker to verbose and it will specify the link errors. In effect all that RadASM can do is pipe the stdout of your linker to the output window, if there is no output fron the linker RadASM hs nothing to display. It does however check to make sure that the file was created. In your example :

3=$.exe,O,$B\tlink.EXE /t ,$.obj

3 = link
$.exe = make sure that an exe is created
,O = pipe the output of the linker to the RadASM output window
,$B\tlink.EXE /t = Your link command with switches
,$.OBJ = file to link - the comma at the beginning indicates a quoted file name

This is the correct command line as it will assure that there is output from the link command. If you are not getting any output from it try to find the verbose mode for tlink and it will indicate the problem.

You may want to try it as follows:

3=$.exe,O,$B\tlink.EXE /t $.obj

(no comma for the $.obj) this will not encapsulate the obj file in quotes. If you do this you cannot have spaces in the filename. Some older programs cannot parse filenames with quotes.
Posted on 2003-06-25 15:20:18 by donkey
it even doesnt work when i use the correct file name.
Posted on 2003-06-26 02:08:22 by wasiliy
unfortunataly it seems like tlink.exe undlike tlink32.exe has no verbose link.
Posted on 2003-06-26 02:10:20 by wasiliy
The only thing I can suggest is to try this :

3=$.exe,OT,$B\tlink.EXE /t $.obj

It will output the link command used to the output window. You can then use the exact same command from a command prompt. It may provide more information for you.
Posted on 2003-06-26 06:11:10 by donkey
ok now when i use ,$.obj tlink.exe tries to link "file.obj" but tlink.exe doesnt allow "-chars.
then i use $.obj ( without comma ) tlink.exe tries to link $.obj which, of course, does not exist.
the weird thing is: even when i write the name of the file correctly into the tasm.ini, tlink.exe
gets the correct parameters but i still have a Make error(s) occured. only when i link it in command.com
it does work.
Posted on 2003-06-26 07:19:46 by wasiliy
I just checked it and you are right, I will try to find a way to do this but I think that there is no way with the present parser.

EDIT: As far as I can tell there is currently no way to do this. You will have to create a project in order use the tlink package without a quoted filename. You can create a new project type for 16 bit applications and use that to create your project. The details on creating new project types are in the help file under "Adding to the default project types" in the advanced section.
Posted on 2003-06-26 08:52:31 by donkey
Well, you make a .com file and test if it created a .exe file.

To build 16 bit code I think the best solution is to make a .bat file.

KetilO
Posted on 2003-06-26 09:12:23 by KetilO
i know, thats the way i do it usually, but the IDE looks good and i'd be really thankful if the developers could fix it soon.
Posted on 2003-06-26 12:05:12 by wasiliy
The is only one developper (KetilO). It would require a rewrite of the command parser and I'm not sure Ketil wants to do that. I will look at writing an AddIn that will interupt the link command when there is no project loaded and redirect the output to a batch file. I'm not sure how much work it will be so give me a week and I should have something for you. If the addin can be done with a minimum of disturbance I will write it.
Posted on 2003-06-26 14:01:36 by donkey
I have looked a little more closely at the problem and I think that it might be better not to alter the way RadASM works at all. I wrote a link filter for GoLink a while back that adjusted the command line sent by RadASM and re-dispatched it to GoLink. The program is no longer useful for GoLink but it shouldn't take much to re-write it for your problem. I will work on it tonight and should have something for you in a day or two. Please post the TASM.INI entry you widh to use and the acutal output to tlink that you need and it will be easier to meet your requirements.
Posted on 2003-06-26 14:12:27 by donkey
i'd like to use somthing like this:


MenuMake=1,1,1,1,1,1,1,0
1=rsrc.res,O,$B\brcc32.exe -r -i"$I" -v,rsrc.res
2=$.obj,O,$B\tasm32.EXE ,$.asm
3=$.exe,OT,$B\tlink.EXE /t ,$.obj
4=0,0,,$.com
5=
6=*.obj,O,$B\tasm32.EXE /mx /m4 /z /q /zn /I"$I",*.asm


well actually i dont know what lines 1 and 6 do but they look usefull =)
it's just important that i'm able to use tlink.exe and can send parameters to it.

thank you very much for your work, i appreciate that!!!
Posted on 2003-06-26 15:42:00 by wasiliy
Hi wasily,

Try this out. copy tlink16.exe to the same folder where you have tlink.exe. Change the tlink.exe in the tasm.ini file to tlink16.exe. This will alter the command line to remove the quotes from the obj file and execute tlink.exe.

tasm.ini command line:

3=$.exe,O,$B\tlink.EXE /t ,$.obj

Changes to

3=$.exe,O,$B\tlink16.EXE /t ,$.obj
Posted on 2003-06-26 21:45:39 by donkey
hmm there is still an error:

C:\Tasm\BIN\tlink16.EXE /t "C:\tasm\BIN\CANNON.obj"

Make error(s) occured.
Posted on 2003-06-27 02:08:50 by wasiliy
If I understand it right you are making a .com file.

The line:

3=$.exe,O,$B\tlink16.EXE /t ,$.obj

Creates a .com file, but test if a .exe was made.

Change it to:

3=$.com,O,$B\tlink16.EXE /t ,$.obj

KetilO
Posted on 2003-06-27 02:26:13 by KetilO
I tested the command line exactly as you have shown and the output was (actual not what RadASM displayed) :

"C:\RadASM\Masm\Projects\TLink16\tlink.exe" /t C:\tasm\BIN\CANNON.obj

C:\RadASM\Masm\Projects\TLink16\ is replaced by the $BIN folder. Make sure that your bin folder is set right and it should work. The output of the command line to RadASM's output window will no longer display the command line that is sent to tlink.exe, that command is altered before it is sent. I have tested this with LINK.EXE and GoLink.exe and the command line parsing works as predicted so it must be something else.
Posted on 2003-06-27 02:26:58 by donkey