Author Topic: [SOLVED]linker that can be used along with nasm in windows  (Read 35948 times)

Offline yaami

  • Jr. Member
  • *
  • Posts: 2
[SOLVED]linker that can be used along with nasm in windows
« on: January 04, 2011, 06:41:24 PM »
Hi all,

I'm just starting with assembly language and nasm. What linker can be used to link programs assembled using nasm?

how can we produce a exe file and run it check the output of a program.

which books do you suggest for a beginner like me to learn assembly (in windows).

Thanks.
« Last Edit: January 05, 2011, 04:25:58 PM by yaami »

Offline Rob Neff

  • Forum Moderator
  • Full Member
  • *****
  • Posts: 429
  • Country: us
Re: linker that can be used along with nasm in windows
« Reply #1 on: January 05, 2011, 12:15:19 AM »
I've used Jeremy Gordon's GoDev tools with much success:

http://www.godevtool.com/

Offline the_mart

  • Jr. Member
  • *
  • Posts: 14
  • Country: gb
Re: linker that can be used along with nasm in windows
« Reply #2 on: January 05, 2011, 07:56:24 AM »
If you have the Microsoft C compiler, you can use link.exe. If you don’t, you can download the Windows 7 SDK, which provides the C compiler and linker.

Code: [Select]
link HelloWorld.obj /OUT:HelloWorld.exe /SUBSYSTEM:CONSOLE /ENTRY:start
If you download MinGW, it provides ld.exe which can also be used to do the linking.

Code: [Select]
ld -o HelloWorld.exe HelloWorld.obj -entry=start --subsystem=console
Most of the assembly books I know of are for Linux, not Windows. Do you have access to a Linux machine or VM?

Offline yaami

  • Jr. Member
  • *
  • Posts: 2
Re: linker that can be used along with nasm in windows
« Reply #3 on: January 05, 2011, 04:25:27 PM »
Yes I do have linux installed on my laptop and I've used nasm with ld (tried some examples)... I wanted to know what linkers were available for windows/dos....

Thanks.
« Last Edit: January 05, 2011, 04:27:17 PM by yaami »