Chapter 2. Toolchains

Toolchains are the silent workhorses behind every major Open Source engineering project, including the Linux kernel itself. They are a collection of the necessary tools and utilities to build and debug anything from the simplest utility to the most complex Linux kernel feature imaginable. If you've done any Linux programming at all, then you have likely already encountered the GNU Compiler Collection (GCC), but there's a lot more to producing a finished application than simply compiling source code. To produce a finished application, you need the aid of a complete set of tools, commonly referred to as a toolchain.

A toolchain includes a compiler, a linker, and assembler as well as a debugger to aid in tracking down the inevitable bugs present in all but the most trivial of programs. In addition, a variety of miscellaneous utilities allow for manipulation of the resulting application binaries as may be necessary—for example, the processing of Linux kernel binaries into machine bootable images. The overwhelming majority of Linux applications are built using the GNU Toolchain, formed from tools released by the GNU project.

This chapter introduces you to the myriad tools that make up the GNU Toolchain, as well as a few other related tools that are also used by Linux developers to build and debug applications. These tools include many nonstandard features that are commonly used by Linux applications as well as the kernel. You will learn how to use the GNU Toolchain ...

Get Professional Linux® Programming now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.