News for hackers. Stuff that matters.

Garra

Re:"Hello, world" in Assembly. on Monday September 06, 2010 @12:50AM (#1665897)
In my case the binary turned out to be much larger than I would have expected. I was expecting a couple hundred bytes tops, but 8k?

  osx-box:dev esa$ nasm -f macho hello.asm && ld -e _start -o hello hello.o

  osx-box:dev esa$ ls -lh hello*
  -rwxr-xr-x  1 esa  staff   8.1K Sep  5 22:43 hello
  -rw-r--r--  1 esa  staff   721B Sep  5 22:39 hello.asm
  -rw-r--r--  1 esa  staff   389B Sep  5 22:43 hello.o
Can you backport an OS? Drivers? Sure. Subsystems, absolutely. But a whole OS? Isn't that like asking to backport Porsche to a Beetle? Anyway, if the end result is a Porsche, why not just start with it?