Skip to content

Latest commit

 

History

History
39 lines (31 loc) · 1.47 KB

README.md

File metadata and controls

39 lines (31 loc) · 1.47 KB

Learn x86 Assembly on a Mac

Setup

  1. Install Homebrew if you don't already have it
  2. brew cask install docker
  3. Run make hello.test

How It Works

The Makefile sets up a Docker container running the appropriate version of Ubuntu for you to follow along with Jorgensen's book. The yasm, ld, and gdb commands are all executed inside the container, but you can still edit your source files (and see the output!) from your Mac. Thanks to Docker's adoption of Apple's Hypervisor, we don't actually have to acknowledge that there's a virtual machine here! 🎉

Doing Your Own Thing

  1. Write your program in whatever.s
  2. Write your GDB Script in whatever.gdb
  3. Run make whatever.test

Pro Tips

  • In Calculator.app, press ⌘3 to open "Programmer Mode" (Hex conversions and bitwise arithmetic).

License

Creative Commons License

This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License.