- 1 ArchLinux ARM
- 1.1 Introduction to Archlinux ARM
- 1.2 Installing Archlinux ARM PixiePro
- 1.3 Installing Packages in Archlinux
- 1.4 Removing Packages in Archlinux
- 1.5 Updating/Upgrading Archlinux
- 1.6 Querying package databases
- 1.7 Packaging software for Archlinux (Advanced)
- 1.8 Distributed Compiling using DistCC (Advanced)
Introduction to Archlinux ARM
ArchlinuxARM is a Linux distribution derived from Archlinux specifically for ARM devices. ArchlinuxARM has gained popularity among the single-board computer hobbyists for its simplicity, minimalism, community and extensive documentation.
- Simplicity. You get exactly what you need, nothing more.
- Modernity. With Arch, you are always running the latest software packages . You don't have to wait for the distro to make those packages available for you; Arch Linux users will get them as soon as they're out.
- Minimalism. Arch gives you the ability to build your system from scratch, including only the software you actually need. This minimizes the amount of SD card memory it takes to hold the operating system for PixiePro, leaving more space for everything else you'll be doing.
- Community. Extensive Wiki and the biggest user repository
Installing Archlinux ARM PixiePro
We provide Archlinux ARM PixiePro built-in images specifically designed for PixiePro. In order to load the Archlinux Image to a micro SD card refer to this link
Installing Packages in Archlinux
Pixie has its own pacman repository with a variety of custom and optimized packages. To see a list of available Pixie custom packages, visit the following page:
Official Archlinux precompiled packages can be installed from Archlinux ARM repository
In order to install any of the packages from this repositories, issue the following command:
$sudo pacman -S <name_of_the_package>
If the package you're looking for is not in the previous repositories, you can search it on the unofficial Archlinux repository (AUR):
To install packages from the AUR:
$yaourt -S <name_of_the_package>
Removing Packages in Archlinux
- To remove a single package, leaving all of its dependencies installed:
$ sudo pacman -R <name_of_the_package>
- To remove a package and its dependencies which are not required by any other installed package::
$ sudo pacman -Rs <name_of_the_package>
ArchLinux is a rolling release distribution, that means that there are no periodic releases like in Debian or Ubuntu. In ArchLinux the packages are constantly being updated, so to have the latest software packages, just enter the following commands:
- To perform a full package database synchronization:
$ sudo pacman -Syy
- To perform a full system update:
$ sudo pacman -Syu
And that is all, you should run these commands, lets say once a week, and you will stay up to date.
Querying package databases
- To search for already installed packages:
$ pacman -Qs <name_of_the_package>
- To list all packages explicitly installed and not required as dependencies:
$ pacman -Qet
- To list a dependency tree of a package:
$ pactree <name_of_the_package>
- To list all packages no longer required as dependencies (orphans):
$ pacman -Qdt
Packaging software for Archlinux (Advanced)
This tutorial will guide you through the necessary steps to create your own packages using the Arch Linux build system (ABS).
Packages in Arch Linux are built using the makepkg utility and the information stored in a PKGBUILD file.When makepkg is run, it searches for a PKGBUILD in the current directory and follows the instructions there in order to retrieve and compile the required files to be packaged within a package file (pkgname.pkg.tar.xz). The resulting package contains binary files and installation instructions; readily installed with pacman.
- First, create a PKGBUILD file for the package you want to build. For more information about the PKGBUILD file structure and functions see here.
- Run makepkg utility:
- If the compile process was successfull, you should see a package file (pkgname.pkg.tar.xz) within the same directory.
- Now you can manually install the package using pacman:
$ sudo pacman -U pkgname.pkg.tar.xz
Submitting packages to the AUR
Please read the Archlinux User Repository (AUR) guidelines for a detailed description of the submission process.
Distributed Compiling using DistCC (Advanced)
If you plan on building a lot of packages and want to speed up the process, the following guide will turn an x86 Linux computer into an ARM cross-compiler.
Distcc is a program to distribute builds across several machines on a network. distcc is usually much faster than a local compile and its compatible with Archlinux makepkg utility.
The master (PixiePro) is the computer which initiates and distributes the compilation to the configured slaves.
The slaves are one or multiple machines running the distcc daemon which accepts incoming compilation requests send by the master.
We provide an out of the box Virtualbox Archlinux x86 Machine with everything configured in order to setup your computer as a distcc slave.
Configuring the Slave device
- Virtualbox is a free and cross-platform application. Download and install the latest VirtualBox version according to your platform from the following link:
- Open the VirtualBox application and create a new virtual machine:
- Download and extract the latest ArchDistCCPixie VirtualBox image from the Downloads Section .
- Create a new virtual machine, and select the option "Use an existing virtual hard disk file". Choose the memory size according to your needs (recommended size: 1024 MB):
- Once the virtual machine is created, go to to the virtual machine settings, and in the network tab select "Bridged Adapter":
- Login to Archlinux with the following username and password:
- Once login, check the machine's ip address:
Configuring the Master device
- Installing distcc on PixiePro:
$sudo pacman -S distcc
- Start the distcc daemon
$sudo systemctl start distccd
- If you want the distcc service to start at boot:
$sudo systemctl enable distccd
The minimal configuration for distcc on the master includes the setting of one or multiple slaves in the configuration file /etc/distcc/hosts.
- Check the ip address of the ArchDistcc VirtualBox machine created in the previous section and add the following line in the /etc/distcc/hosts file (For example, if the IP Address is 10.0.2.125) :
- In order to add distcc support to makepkg, edit the configuration file /etc/makepkg.conf in the following sections:
- BUILDENV has distcc unbanged i.e. without exclamation point.
- Uncomment the DISTCC_HOSTS line and add the IP addresses of the slaves then a slash and the number of threads they are to use.
- Adjust the MAKEFLAGS variable to correspond to the number of sum of the number of individual values specified for the max threads per server. In this case we are only configuring one slave with a maximum of 8 threads, so MAKEFLAGS variable should be equal to 8 threads.
BUILDENV=(distcc fakeroot color !ccache !check) MAKEFLAGS="-j8" DISTCC_HOSTS="10.0.2.125/8"
- Now everytime you compile a package using makepkg, you will be using distributed compiling with distcc. In order to check the received files in the slave device(s), open a terminal and type in the following command:
$tail -f /var/log/distcc/distccd.log