Install all the things!

Linux

Ubuntu 16/14

  1. Run cd ~/ to change to your home directory
  2. Run sudo apt install wget make to install wget and GNU Make
  3. Run wget [LINK] to download the install script
  4. Run ./install.mk to install the compiler
  5. Run sudo apt install nasm to install the assembler

The compiler (none-eabi-gcc) and assembler (nasm) should now be installed.

You can uninstall the compiler and assembler with

  1. sudo install.sh remove
  2. sudo apt remove nasm

Other Linux distributions

  1. Run cd ~/ to change to your home directory
  2. Run sudo apt install wget make to install wget and GNU Make
  3. Run wget https://raw.githubusercontent.com/jsren/os-workshop-ex1/files/install.mk to download the cross-compiler script
  4. Run chmod +x install.mk to allow the Makefile to execute
  5. Run install.mk to build and install the compiler
  6. Read through workshop website, check Facebook etc. until complete (~30 mins)
  7. Run sudo apt install nasm to install the assembler

(If you’re interested in what’s happening, check out this page.)

The compiler (none-eabi-gcc) and assembler (nasm) should now be installed.

You can uninstall the compiler and assembler with

  1. install.mk remove
  2. sudo apt remove nasm

Windows

Windows 10

Windows 10 supports native Linux binaries via the Windows Subsytem for Linux (WSL).

  1. Search for Windows Powershell in the start menu, right-click and run as administrator
  2. Run Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux
  3. Go to https://www.microsoft.com/store/productId/9NBLGGH4MSV6 or open the Microsoft Store and search for and install ‘Ubuntu’.

With this installed, you should be able to run bash from the command line.

  1. Run bash
  2. Change to a suitable directory (or cd ~/ to your home directory)
  3. Run sudo apt install wget make to install wget and GNU Make
  4. Run wget [LINK] to download the install script
  5. Run ./install.mk to install the compiler
  6. Run sudo apt install nasm to install the assembler

The compiler (none-eabi-gcc) and assembler (nasm) should now be installed.

You can uninstall the compiler and assembler with

  1. sudo install.sh remove
  2. sudo apt remove nasm

Other Windows Versions

In order to run the compiler, you will require a Linux shell. The easiest to set up is Cygwin.

To install Cygwin:

  1. Visit https://www.cygwin.com/install.html and download either the 64-bit or 32-bit setup
  2. Run the setup installer and proceed with setup
  3. Make sure “Install from Internet” is selected, click Next
  4. Select an installation directory, click Next
  5. Set a valid location for the package directory, e.g. your Downloads folder.
  6. Configure your network access (defaults are normally fine), click Next
  7. Select any item from the box and click Next
  8. The “Select Packages” page should now be visible
  9. Search for “nasm”
  10. Expand “Devel” in the tree
  11. Click on the “skip” label next to the entry for nasm until it changes to a version number (e.g. 2.10.07)
  12. Search for “wget”
  13. Expand “Web” in the tree
  14. Click on the “skip” label next to the entry for wget until it changes to a version number (e.g. 1.19.1)
  15. Search for “make”
  16. Expand “Devel” in the tree
  17. Click on the label next to the entry for make until it changes to a version number (e.g. 4.2.1)
  18. Click Next and Next again to complete installation

With this installed, you should be able to run bash from the command line.

  1. Run bash
  2. Change to a suitable directory (or cd ~/ to your home directory)
  3. Run wget [LINK] to download the install script
  4. Run ./install.mk to install the compiler

The compiler (none-eabi-gcc) and assembler (nasm) should now be installed.

OSx

  1. Run brew install qemu to install qemu