00. Build infrastructure / VM

If you wish to run the build locally, make sure you have a pretty powerful x64 laptop/PC (8-16 powerful cores, 32GB RAM, 50GB SSD free space).

Otherwise, we offer some rather powerful VMs hosted inside the Faculty’s private cloud (OpenStack) for use with this workshop.

It’s going to be a headless (no graphics) server-like environment, so Linux command line knowledge is required. Don’t worry, you have all the tools you need in there (plus a tweaked Zsh, TMux for running persistent/multiplexed terminals and vim with AstroNvim config for enthusiasts).

But first, you will need to gain access to this VM. To do this, you must create a SSH private/public key pair and give the public counterpart to the superviser for account creation & authorization (do this on your personal PC / laptop in a Linux sh-compatible shell or Windows Powershell), generate a public/private SSH keypair:

# first, check if a keypair already exists
you@laptop:~# ls ~/.ssh/
# if the files `id_ed25519` and `id_ed25519.pub` already exist, SKIP everything else!
you@laptop:~# ssh-keygen -t ed25519  # Edwards curves: better & shorter keys!
# answer the defaults (aka just press enter multiple times)
you@laptop:~# ls -l ~/.ssh/
-rw------- 1 root root 2602 Oct 15 12:59 id_ed25519     # <-- THE PRIVATE KEY, keep secret!
-rw-r--r-- 1 root root  571 Oct 15 12:59 id_ed25519.pub # <-- your PUBLIC key to give away!
# print and copy the private key (including the 'ssh-ed25519' prefix!):
you@laptop:~# cat ~/.ssh/id_ed25519.pub
ssh-ed25519 AAAAB3NzaC...  # a longish line containing the public key number + email

Now copy your public key and give it to a supervisor (together with a preferred username to be created) to gain access to the build machine, but wait for confirmation…

When notified, try to connect to your assigned VM and port, e.g.:

ssh youruser@arm2025.root.sx -p 220X  # where X is your assigned VM index

Suggestion #1: After manually solving each task, automate the steps you've taken by writing a Makefile. Chances are that you're going to have to rebuild things (at least partially) dozens of times, and you'll also need to reuse your scripts usable for the next labs as well! E.g.:

export CROSS_COMPILE = /path/to/your/toolchain/gcc-prefix...-
 
ATF_DIR = imx-atf
ATF_MAKE_FLAGS = SPD=none PLAT=TODO...
atf:
	make -C "$(ATF_DIR)" $(ATF_MAKE_FLAGS)
 
UBOOT_DIR = uboot
UBOOT_MAKE_FLAGS =
uboot:
	make -C "$(UBOOT_DIR)" $(UBOOT_MAKE_FLAGS)
 
.PHONY: uboot atf
# ... and so on !

Suggestion #2: You can either manually download all required open-source projects via git or use git submodules and add them to a parent repository! But beware though: Linux's repo is quite huge (several GBs – but you'll see it yourself in the next lab)!

ass/labs-2025/01/tasks/00.txt · Last modified: 2025/08/04 18:00 by florin.stancu
CC Attribution-Share Alike 3.0 Unported
www.chimeric.de Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0