Embedded Linux Projects Using Yocto Project Cookbook

Book description

Over 70 hands-on recipes for professional embedded Linux developers to optimize and boost their Yocto know-how

In Detail

The embedded Linux world is standardizing around Yocto Project as the best integration framework to create reliable embedded Linux products. Yocto Project effectively shortens the time it takes to develop and maintain an embedded Linux product, and it increases its reliability and robustness by using proven and tested components.

This book begins with the installation of a professional embedded Yocto setup, then advises you on best practices, and finally explains how to quickly get hands on with the Freescale ARM ecosystem and community layer, using the affordable and open source Wandboard embedded board.

What You Will Learn

  • Optimize your Yocto setup to speed up development and debug build issues

  • Introduce development workflows for the U-Boot and the Linux kernel, including debugging and optimization methodologies

  • Customize your root filesystem with both already supported and new Yocto packages

  • Understand the open source licensing requirements and how to comply with them when cohabiting with proprietary programs

  • Bring professional embedded Yocto products to market in a timely manner

  • Optimize your production systems by reducing the size of both the Linux kernel and root filesystems

  • Table of contents

    1. Embedded Linux Projects Using Yocto Project Cookbook
      1. Table of Contents
      2. Embedded Linux Projects Using Yocto Project Cookbook
      3. Credits
      4. Foreword
      5. About the Author
      6. About the Reviewers
      7. www.PacktPub.com
        1. Support files, eBooks, discount offers, and more
          1. Why Subscribe?
          2. Free Access for Packt account holders
      8. Preface
        1. What this book covers
        2. What you need for this book
        3. Who this book is for
        4. Sections
          1. Getting ready
          2. How to do it…
          3. How it works…
          4. There's more…
          5. See also
        5. Conventions
        6. Reader feedback
        7. Customer support
          1. Downloading the example code
          2. Errata
          3. Piracy
          4. Questions
      9. 1. The Build System
        1. Introduction
        2. Setting up the host system
          1. Getting ready
          2. How to do it...
          3. How it works...
          4. There's more...
          5. See also
        3. Installing Poky
          1. Getting ready
          2. How to do it...
          3. How it works...
          4. There's more...
          5. See also
        4. Creating a build directory
          1. How to do it...
          2. How it works...
          3. There's more...
        5. Building your first image
          1. Getting ready
          2. How to do it...
          3. How it works...
          4. There's more...
        6. Explaining the Freescale Yocto ecosystem
          1. Getting ready
          2. How to do it...
          3. How it works...
          4. There's more...
          5. See also
        7. Installing support for Freescale hardware
          1. Getting ready
          2. How to do it...
          3. How it works...
          4. There's more...
          5. See also
        8. Building Wandboard images
          1. How to do it...
          2. How it works...
          3. See also
        9. Troubleshooting your Wandboard's first boot
          1. Getting ready
          2. How to do it...
          3. There's more...
        10. Configuring network booting for a development setup
          1. Getting ready
            1. Installing a TFTP server
            2. Installing an NFS server
          2. How to do it...
        11. Sharing downloads
          1. Getting ready
          2. How to do it...
        12. Sharing the shared state cache
          1. How to do it...
          2. There's more...
        13. Setting up a package feed
          1. Getting ready
            1. Versioning packages
          2. How to do it...
          3. See also
        14. Using build history
          1. How to do it...
          2. How it works...
            1. Looking at the build history
          3. There's more...
        15. Working with build statistics
          1. How to do it...
          2. How it works...
          3. There's more...
        16. Debugging the build system
          1. Getting ready
            1. Finding recipes
            2. Dumping BitBake's environment
            3. Using the development shell
          2. How to do it...
            1. Task log and run files
            2. Adding logging to recipes
            3. Looking at dependencies
            4. Debugging BitBake
            5. Error reporting tool
          3. There's more...
      10. 2. The BSP Layer
        1. Introduction
        2. Creating a custom BSP layer
          1. How to do it...
          2. How it works...
          3. There's more...
            1. Adding a new machine
            2. Adding a custom device tree to the Linux kernel
            3. Adding a custom U-Boot machine
            4. Adding a custom formfactor file
        3. Introducing system development workflows
          1. How to do it...
          2. How it works...
            1. External development
            2. Working directory development
            3. External source development
        4. Adding a custom kernel and bootloader
          1. Getting Ready
            1. Finding the Linux kernel source
            2. Finding the U-Boot source
            3. Developing using a Git repository fork
          2. How to do it...
          3. How it works...
        5. Building the U-Boot bootloader
          1. How to do it...
          2. How it works...
            1. External development
          3. How it works…
            1. External source development
            2. Working directory development
        6. Explaining Yocto's Linux kernel support
          1. How to do it...
          2. How it works...
          3. See also
        7. Describing Linux's build system
          1. How to do it...
          2. How it works...
          3. There's more...
        8. Configuring the Linux kernel
          1. Getting ready
          2. How to do it...
          3. There's more...
            1. Using configuration fragments
        9. Building the Linux kernel
          1. How to do it...
          2. How it works...
            1. External development
            2. External source development
            3. Working directory development
        10. Building external kernel modules
          1. Getting ready
          2. How to do it...
          3. There's more...
        11. Debugging the Linux kernel and modules
          1. How to do it...
          2. How it works...
          3. There's more...
            1. Using dynamic debug
            2. Rate-limiting debug messages
          4. See also
        12. Debugging the Linux kernel booting process
          1. How to do it...
          2. How it works...
            1. Dumping the kernel's printk buffer from the bootloader
          3. There's more...
        13. Using the kernel function tracing system
          1. Getting ready...
          2. How to do it...
          3. How it works...
          4. There's more...
            1. Filtering function traces
            2. Enabling trace options
            3. Using the function tracer on oops
            4. Getting a stack trace for a given function
            5. Configuring the function tracer at boot
          5. See also
        14. Managing the device tree
          1. Getting ready
          2. How to do it...
          3. How it works...
            1. The compatible property
            2. The Wandboard device tree file
            3. Defining buses and memory-addressable devices
          4. There's more...
            1. Modifying and compiling the device tree in Yocto
          5. See also
        15. Debugging device tree issues
          1. How to do it...
          2. How it works...
            1. Looking at the device tree from U-Boot
            2. Looking at the device tree from the Linux kernel
      11. 3. The Software Layer
        1. Introduction
        2. Exploring an image's contents
          1. Getting ready
          2. How to do it...
          3. How it works...
        3. Adding a new software layer
          1. Getting ready
          2. How to do it...
          3. How it works...
          4. There's more...
        4. Selecting a specific package version and providers
          1. How to do it...
            1. How do we select which provider to use?
            2. How do we select which version to use?
            3. How do we select which version not to use?
        5. Adding supported packages
          1. Getting ready
          2. How to do it...
          3. How it works...
          4. There's more...
            1. Configuring packages
        6. Adding new packages
          1. Getting ready
          2. How to do it...
          3. How it works...
            1. Package licensing
            2. Fetching package contents
            3. Specifying task overrides
            4. Configuring packages
            5. Splitting into several packages
            6. Setting machine-specific variables
        7. Adding data, scripts, or configuration files
          1. How to do it...
        8. Managing users and groups
          1. Getting ready
          2. How to do it...
          3. There's more...
        9. Using the sysvinit initialization manager
          1. Getting ready
          2. How to do it...
        10. Using the systemd initialization manager
          1. Getting ready
          2. How to do it...
          3. There's more...
            1. Installing systemd unit files
        11. Installing package-installation scripts
          1. Getting ready
          2. How to do it...
          3. How it works...
        12. Reducing the Linux kernel image size
          1. How to do it...
          2. How it works...
        13. Reducing the root filesystem image size
          1. How to do it...
          2. How it works...
        14. Releasing software
          1. Getting ready
          2. How to do it...
          3. There's more…
          4. See also
        15. Analyzing your system for compliance
          1. How to do it...
          2. There's more
        16. Working with open source and proprietary code
          1. How to do it...
          2. How it works...
            1. The U-Boot bootloader
            2. The Linux kernel
            3. Glibc
            4. BusyBox
            5. The Qt framework
            6. The X Windows system
          3. There's more...
          4. See also
      12. 4. Application Development
        1. Introduction
        2. Introducing toolchains
          1. Getting ready
          2. How to do it...
        3. Preparing and using an SDK
          1. Getting ready
          2. How to do it...
        4. Using the Application Development Toolkit
          1. Getting ready
          2. How to do it...
          3. How it works...
        5. Using the Eclipse IDE
          1. Getting ready
          2. How to do it...
          3. There's more...
          4. See also
        6. Developing GTK+ applications
          1. Getting ready
          2. How to do it...
          3. There's more...
        7. Using the Qt Creator IDE
          1. Getting ready
          2. How to do it...
        8. Developing Qt applications
          1. Getting ready
          2. How to do it...
          3. There's more...
        9. Describing workflows for application development
          1. How to do it...
          2. How it works...
            1. External development
            2. Working directory development
            3. External source development
        10. Working with GNU make
          1. How to do it...
          2. See also
        11. Working with the GNU build system
          1. Getting ready
          2. How to do it...
          3. See also
        12. Working with the CMake build system
          1. Getting ready
          2. How to do it...
          3. See also
        13. Working with the SCons builder
          1. Getting ready
          2. How to do it...
          3. See also
        14. Developing with libraries
          1. Getting ready
            1. Building a static library
            2. Building a shared dynamic library
          2. How to do it...
          3. How it works...
          4. There's more...
          5. See also
        15. Working with the Linux framebuffer
          1. Getting ready
          2. How to do it...
          3. How it works...
          4. There's more...
          5. See also
        16. Using the X Windows system
          1. Getting ready
          2. How to do it...
          3. There's more...
          4. See also
        17. Using Wayland
          1. Getting ready
          2. How to do it...
          3. There's more...
          4. See also
        18. Adding Python applications
          1. Getting ready
          2. How to do it...
          3. There's more...
        19. Integrating the Oracle Java Runtime Environment
          1. Getting ready
          2. How to do it...
          3. There's more...
        20. Integrating the Open Java Development Kit
          1. Getting ready
          2. How to do it...
          3. How it works...
          4. There's more...
          5. See also
        21. Integrating Java applications
          1. Getting ready
          2. How to do it...
          3. How it works...
          4. There's more...
      13. 5. Debugging, Tracing, and Profiling
        1. Introduction
        2. Analyzing core dumps
          1. Getting ready
          2. How to do it...
          3. How it works...
          4. See also
        3. Native GDB debugging
          1. Getting ready
          2. How to do it...
          3. There's more...
          4. See also
        4. Cross GDB debugging
          1. Getting ready
          2. How to do it...
          3. How it works...
        5. Using strace for application debugging
          1. Getting ready
          2. How to do it...
          3. How it works...
          4. See also
        6. Using the kernel's performance counters
          1. Getting ready
          2. How to do it...
          3. How it works...
          4. There's more...
          5. See also
        7. Using static kernel tracing
          1. Getting ready
          2. How to do it...
          3. How it works...
          4. There's more...
          5. See also
        8. Using dynamic kernel tracing
          1. Getting ready
          2. How to do it...
          3. There's more...
          4. See also
        9. Using dynamic kernel events
          1. Getting ready
          2. How to do it...
          3. How it works...
          4. There's more...
        10. Exploring Yocto's tracing and profiling tools
          1. Getting ready
          2. How to do it...
          3. There's more...
        11. Tracing and profiling with perf
          1. Getting ready
          2. How to do it...
          3. How it works...
            1. Reading tracing data
          4. There's more...
            1. Profile charts
            2. Using perf as strace substitute
          5. See also
        12. Using SystemTap
          1. Getting ready
          2. How to do it...
          3. How it works...
          4. See also
        13. Using OProfile
          1. Getting ready
          2. How to do it...
          3. How it works...
          4. There's more...
          5. See also
        14. Using LTTng
          1. Getting ready
          2. How to do it...
          3. How it works...
            1. Extending application profiling
          4. There's more...
          5. See also
        15. Using blktrace
          1. Getting ready
          2. How to do it...
          3. How it works...
          4. There's more...
      14. Index

    Product information

    • Title: Embedded Linux Projects Using Yocto Project Cookbook
    • Author(s): Alex González
    • Release date: March 2015
    • Publisher(s): Packt Publishing
    • ISBN: 9781784395186