Linux Assembly HOWTO
Prev Chapter 6. Quick start Next

6.3. Building an executable

6.3.1. Producing object code

First step of building an executable is compiling (or assembling) object file from the source:

For nasm example:

$ nasm -f elf hello.asm

For gas example:

$ as -o hello.o hello.S

This makes hello.o object file.

6.3.2. Producing executable

Second step is producing executable file itself from the object file by invoking linker:

$ ld -s -o hello hello.o

This will finally build hello executable.

Hey, try to run it... Works? That's it. Pretty simple.


Prev Home Next
Hello, world! Up Resources


  • Bookmark
  • Add Resource
  • Modify Resource
  • Get Rated
  • Link to Us
  • Advertise
  • Contact
  • Search Resources

  • Recommended

    • Web Site Templates
    • Ultimate Trading Script
    • The Exterminator
    • Guestbook Script
    • Thumbnail Creator
    • Custom Programming
    • PHP Forums
    • Ajax Tutorial
  • Resource Map

    • Home
    • Expanded Directory
    • New Listings
    • Most Popular
    • Top Rated
    • Email Updates
    • Random Link
    • Advanced Search
    • Bookmark Us
    • Link to Us
    • Advertising Info
    • Webmaster Forum
    • Accessibility Statement
  • General Resources

    • ASP
    • C/C++
    • ColdFusion
    • Flash / ActionScript
    • General
    • HTML
    • Java
    • JavaScript
    • Perl
    • PHP
    • Python
    • Remotely Hosted
    • Unix Shell
    • Visual Basic
    • XML
  • Scripts & Programs

    • ASP
    • C/C++
    • ColdFusion
    • Flash / ActionScript
    • Java
    • JavaScript
    • Perl
    • PHP
    • Python
    • Remotely Hosted
    • Unix Shell
    • Visual Basic
    • XML
  • Online Tutorials

    • ASP
    • C/C++
    • ColdFusion
    • Flash / ActionScript
    • HTML
    • Howtos
    • Java
    • JavaScript
    • Perl
    • PHP
    • Python
    • Unix Shell
    • Visual Basic
    • XML
  • Books

    • ASP
    • C/C++
    • ColdFusion
    • Flash / ActionScript
    • HTML
    • Java
    • JavaScript
    • Perl
    • PHP
    • Python
    • Unix Shell
    • Visual Basic
    • XML
  • Supporters

    • Bigwebmaster Supporters
    • Ozzu Website Templates
    • Mortgages
    • Online Advertising
    • Debt Help
    • HP Laptops
    • Credit Cards
  • Partners

    • Unmelted Templates
    • Web Design Forum