This is the simple compilation that combines the FASM and ALINK in the way to compile Win32 programs. If anyone wants to continue such project to make some better package (maybe even something similar to MASM32), please post here - maybe it's worth doing but I have other important things for FASM to finish and a bit not enough time and energy for everything...
Posted on 2003-04-27 14:58:30 by Tomasz Grysztar
Cool Privalov!

I'll continue on it (I think, if I have time enough)....

Posted on 2003-04-29 00:45:57 by Tommy
Thanks Privalov:alright:
Posted on 2003-04-29 02:12:44 by Vortex
Sounds good stuff !! :)
Posted on 2003-04-29 11:36:44 by Nguga
There is someone using GoLink with fasm?

I have doing some tests unsuccesfully. However it seems to be very interesting: a linker written in full asm.

There is someone that knows the author (Jeremy Gordon) and his opinions regarding the possibility of having an open-source asm written linker to use with fasm?
Posted on 2003-04-29 12:05:05 by pelaillo
It's possible to use Fasm with the linker of Digital Mars.(with the conversion tool coff2omf)
Posted on 2003-04-29 13:01:25 by Vortex
I'm afraid doing wrong about imports section. How is the imports section coding.

section '.idata' import data readable writeable

library kernel,'KERNEL32.DLL',\

import kernel,\

import user,\
...mmm not like so, is it?
Posted on 2003-05-02 16:21:22 by cakmak
Here is some tricks to decrease the lenght of files linked with alink:

a)First,using a very small DOS stub file,
b)Stripping the relocation section with Jordan Russel's free tool stripreloc:

I tried them on Privalov's demonstration example.Result:2584bytes -----> 2048 bytes
Posted on 2003-05-06 04:46:59 by Vortex
I used crayzee's PE wipe.reloc v1.40 on Privalov's demo and
reduced it's size from 2584 to 1684 bytes.

crayzee's PE wipe.reloc v1.40 is quite stable and written in
TASM with full source included.
Posted on 2003-05-06 13:48:01 by Poimander
OK, if anyone wants to continue it, I can provide for him some subdirectory on the fasm's server for that purpose, anyone interested?
Posted on 2003-05-06 13:52:19 by Tomasz Grysztar
Nice stuff Privalov.:alright:

Here are the environment variables needed to use it with RadASM in case anyone is interested:
(It assumes that you are using the GORC res compiler to get rid of the last MS stuff)

GoRC is a nice resource compiler by Jeremy Gordon, it can be downloaded from his site.

Compile RC=0,O,$B\GORC /r /f,1
Assemble = 3,O,$A\FASM,2,3
Link = 5,O,$B\alink -oPE,3,4,$L\win32.lib,-entry,start
Run = 0,0,,5
Res to Obj = N/A

$A path=C:\FASM
$I path =$A\Include
$B path usually = $A (path to alink and GoRC usually C:\FASM)
$L path variable set to $A\LIB

I tried the setup like that and it works fine.
Posted on 2003-05-06 21:13:48 by donkey

Don't forget that the file size must be a multiple of 512;so your 1684 bytes are not aligned.
Posted on 2003-05-07 02:32:52 by Vortex
It's possible also to create import libraries for alink.
The attachment contains the free import librarian from Digital Mars and
the .def files for some import libraries.
Posted on 2003-05-07 02:58:56 by Vortex

GoRC is a nice resource compiler by Jeremy Gordon, it can be downloaded from his site.

Hi donkey, have you tried to link coffs produced by fasm using GoLink?
Posted on 2003-05-07 07:35:12 by pelaillo
I've just downloaded it after reading you post and I'll try. It would be nice to have so I'll try, but I like ALink. For now though I'm trying to figure out how to do DLLs in fasm COFF format so that when I use it with RadASM I can have all of the same output types as MASM, making it a true replacement for me. But I'll try soon.
Posted on 2003-05-07 07:39:19 by donkey
Hi pelaillo,

I just tried it and it's nice. No import files at all, amazing little linker. It uses a list of dll's referenced then finds the imports itself. You can keep a long list if you like just make sure that they are in order of most often used as it starts at the top and quits when it finds what it's looking for. Here's the list I used, it is in a file called GFL.TXT in the same folder as GoLink :

With this object file in the same folder the following command links properly, change start to the label of your exe's entry point:

GoLink TestFasm.obj @GFL.txt /entry start
Posted on 2003-05-07 08:12:51 by donkey
Donkey,are you talking about this file?

I couldn't find that GFL.txt :confused:
Posted on 2003-05-07 09:35:21 by Vortex
GFL is a text file that I created to hold the list of DLLs that I use, with the above mentioned dlls listed. It is the comand file that the page talks about but this way I don't have to specify the obj file in it so it is static and reuseable. I just put it in the same folder that I put GoLink in.
Posted on 2003-05-07 09:48:09 by donkey
I use GoLink (with GoAsm, not FASM - sorry) and really like it. The unicode stuff is interesting, although I haven't used unicode yet myself.

The only issue I have found so far is that it cannot link libraries. There are some pretty cool libraries out there. So far, however, it is not a problem with me. It is my linker of choice.

I understand from an email from the Mr. Gordon a few months ago that he is planning on adding library support "someday".

Posted on 2003-05-07 10:13:19 by bushpilot
The main issue I have is that it seems to have problems with quoted parameters so it doesn't run properly from RadASM's make menu. I posted the problem and if that's fixed it would be a good linker to use with FASM as there is currently no full set of Win32 libs like with MASM32. A good stop-gap solution until some-one starts the FASM32 project :)
Posted on 2003-05-07 10:20:01 by donkey