Introduction
If you want to boot your Librem 5 from software loaded via USB (e.g. if your install on the eMMC drive is broken, or you want to perform a backup of the eMMC drive) then you will need the uuu
tool and, for the specific examples noted here, you will also need Jumpdrive.
These instructions tell you how to build those two pieces of software.
In theory, if you have two phones, you might be able to do this from a working phone - and these instructions are not for that use case. The assumption is that you are doing this from an x86 computer (amd64
architecture).
The procedure here may be time-consuming. However you should only need to do it once.
Since uuu
is a prerequisite to use Jumpdrive, I will build uuu
first.
These instructions are for Ubuntu 20.04 (focal) but should point you in the right direction for other Linux distros.
Building uuu
should not be needed as of Ubuntu 21.04 (hirsute) because uuu
is included in the distro. You would still need to build Jumpdrive however.
Disclaimers
No-one's install of Ubuntu will exactly match mine. Your starting point may be different from mine.
I am putting all my git
stuff in a subdirectory of my home directory called git
. Feel free to vary that as you see fit. Path references should be relative, so it should work if you do something different.
uuu
Building Update: There is some uncertainty as to whether a C++ compiler is always present out-of-the-box with a Ubuntu focal install. If there isn't one then the build procedure below will fail quickly, complaining that it can't find a C++ compiler. To preempt that, use the command which c++
and if that command gives no output, use the command sudo apt install g++
before following the procedure below.
sudo apt install git
sudo apt install cmake
sudo apt install libusb-1.0-0-dev
sudo apt install libzip-dev
sudo apt install libbz2-dev
cd
mkdir -p git
cd git
git clone https://source.puri.sm/Librem5/librem5-devkit-tools.git
cd librem5-devkit-tools
./scripts/build_uuu.sh -i
This actually puts uuu
in /usr/local/bin
hence you can confirm basic success with which uuu
after you have performed the above build procedure. uuu
must be in your path in order to use the provided scripts for using uuu
.
Building Jumpdrive
Update: This procedure may technically be redundant now, as Purism is apparently making Jumpdrive available pre-built at location: https://github.com/dreemurrs-embedded/Jumpdrive/releases/download/0.8/purism-librem5.tar.xz so the following procedure need only be followed out of interest or if the pre-built version does not meet your requirements.
On a modest computer and with a slow internet connection, this build may take many hours (e.g. 5 hours for me). Plan accordingly.
sudo apt install gcc-aarch64-linux-gnu
sudo apt install flex
sudo apt install bison
sudo apt install libssl-dev
sudo apt install device-tree-compiler
sudo apt install gcc-arm-none-eabi
cd
mkdir -p git
cd git
git clone https://source.puri.sm/sebastian.krzyszkowiak/jumpdrive
cd jumpdrive
# the following two commands are listed in other doco but I don't know whether they do
# anything or are needed - but they were harmless for me at least
git submodule init
git submodule update
make purism-librem5