Beyond Linux® From Scratch (System V Edition)

Version 11.1

The BLFS Development Team

Copyright © 1999-2022, The BLFS Development Team

All rights reserved.

This book is licensed under a Creative Commons License.

Computer instructions may be extracted from the book under the MIT License.

Linux® is a registered trademark of Linus Torvalds.

Published 2022-03-01

Revision History
Revision 11.1 2022-02-01 Twenty-fifth Release
Revision 11.0 2021-09-01 Twenty-fourth Release
Revision 10.1 2021-03-01 Twenty-third Release
Revision 10.0 2020-09-01 Twenty-second Release
Revision 9.1 2020-03-01 Twenty-first Release
Revision 9.0 2019-09-01 Twentieth release
Revision 8.4 2019-03-01 Nineteenth release
Revision 8.3 2018-09-01 Eighteenth release
Revision 8.2 2018-03-02 Seventeenth release
Revision 8.1 2017-09-01 Sixteenth release
Revision 8.0 2017-02-25 Fifteenth release
Revision 7.10 2016-09-07 Fourteenth release
Revision 7.9 2016-03-08 Thirteenth release
Revision 7.8 2015-10-01 Twelfth release
Revision 7.7 2015-03-06 Eleventh release
Revision 7.6 2014-09-23 Tenth release
Revision 7.5 2014-03-05 Ninth release
Revision 7.4 2013-09-14 Eighth release
Revision 6.3 2008-08-24 Seventh release
Revision 6.2 2007-02-14 Sixth release
Revision 6.1 2005-08-14 Fifth release
Revision 6.0 2005-04-02 Fourth release
Revision 5.1 2004-06-05 Third release
Revision 5.0 2003-11-06 Second release
Revision 1.0 2003-04-25 First release

Abstract

This book follows on from the Linux From Scratch book. It introduces and guides the reader through additions to the system including networking, graphical interfaces, sound support, and printer and scanner support.


Dedication

This book is dedicated to the LFS community

Table of Contents

Preface

Having helped out with Linux From Scratch for a short time, I noticed that we were getting many queries as to how to do things beyond the base LFS system. At the time, the only assistance specifically offered relating to LFS were the LFS hints (https://www.linuxfromscratch.org/hints). Most of the LFS hints are extremely good and well written but I (and others) could still see a need for more comprehensive help to go Beyond LFS — hence BLFS.

BLFS aims to be more than the LFS-hints converted to XML although much of our work is based around the hints and indeed some authors write both hints and the relevant BLFS sections. We hope that we can provide you with enough information to not only manage to build your system up to what you want, whether it be a web server or a multimedia desktop system, but also that you will learn a lot about system configuration as you go.

Thanks as ever go to everyone in the LFS/BLFS community; especially those who have contributed instructions, written text, answered questions and generally shouted when things were wrong!

Finally, we encourage you to become involved in the community; ask questions on the mailing list or news gateway and join in the fun on #lfs and #lfs-support at Libera. You can find more details about all of these in the Introduction section of the book.

Enjoy using BLFS.

Mark Hymers
markh <at> linuxfromscratch.org
BLFS Editor (July 2001–March 2003)

I still remember how I found the BLFS project and started using the instructions that were completed at the time. I could not believe how wonderful it was to get an application up and running very quickly, with explanations as to why things were done a certain way. Unfortunately, for me, it wasn't long before I was opening applications that had nothing more than "To be done" on the page. I did what most would do, I waited for someone else to do it. It wasn't too long before I am looking through Bugzilla for something easy to do. As with any learning experience, the definition of what was easy kept changing.

We still encourage you to become involved as BLFS is never really finished. Contributing or just using, we hope you enjoy your BLFS experience.

Larry Lawrence
larry <at> linuxfromscratch.org
BLFS Editor (March 2003–June 2004)

The BLFS project is a natural progression of LFS. Together, these projects provide a unique resource for the Open Source Community. They take the mystery out of the process of building a complete, functional software system from the source code contributed by many talented individuals throughout the world. They truly allow users to implement the slogan Your distro, your rules.

Our goal is to continue to provide the best resource available that shows you how to integrate many significant Open Source applications. Since these applications are constantly updated and new applications are developed, this book will never be complete. Additionally, there is always room for improvement in explaining the nuances of how to install the different packages. To make these improvements, we need your feedback. I encourage you to participate on the different mailing lists, news groups, and IRC channels to help meet these goals.

Bruce Dubbs
bdubbs <at> linuxfromscratch.org
BLFS Editor (June 2004–December 2006 and February 2011–now)

My introduction to the [B]LFS project was actually by accident. I was trying to build a GNOME environment using some how-tos and other information I found on the web. A couple of times I ran into some build issues and Googling pulled up some old BLFS mailing list messages. Out for curiosity, I visited the Linux From Scratch web site and shortly thereafter was hooked. I've not used any other Linux distribution for personal use since.

I can't promise anyone will feel the sense of satisfaction I felt after building my first few systems using [B]LFS instructions, but I sincerely hope that your BLFS experience is as rewarding for you as it has been for me.

The BLFS project has grown significantly the last couple of years. There are more package instructions and related dependencies than ever before. The project requires your input for continued success. If you discover that you enjoy building BLFS, please consider helping out in any way you can. BLFS requires hundreds of hours of maintenance to keep it even semi-current. If you feel confident enough in your editing skills, please consider joining the BLFS team. Simply contributing to the mailing list discussions with sound advice and/or providing patches to the book's XML will probably result in you receiving an invitation to join the team.

Randy McMurchy
randy <at> linuxfromscratch.org
BLFS Editor (December 2006–January 2011)

Foreword

This version of the book is intended to be used when building on top of a system built using the LFS book. Every effort has been made to ensure accuracy and reliability of the instructions. Many people find that using the instructions in this book after building the current stable or development version of LFS provides a stable and very modern Linux system.

Enjoy!

Randy McMurchy
August 24th, 2008

Last updated on

Who Would Want to Read this Book

This book is mainly aimed at those who have built a system based on the LFS book. It will also be useful for those who are using other distributions, but for one reason or another want to manually build software and are in need of some assistance. Note that the material contained in this book, in particular the dependency listings, is based upon the assumption that you are using a base LFS system with every package listed in the LFS book already installed and configured. BLFS can be used to create a range of diverse systems and so the target audience is probably nearly as wide as that of the LFS book. If you found LFS useful, you should also like this!

Since Release 7.4, the BLFS book version matches the LFS book version. This book may be incompatible with a previous or later release of the LFS book.

Last updated on

Organization

This book is divided into the following parts.

Part I - Introduction

This part contains information which is essential to the rest of the book.

Part II - Post LFS Configuration and Extra Software

Here we introduce basic configuration and security issues. We also discuss a range of editors, file systems, and shells which aren't covered in the main LFS book.

Part III - General Libraries and Utilities

In this section we cover libraries which are often needed by the rest of the book as well as system utilities. Information on Programming (including recompiling GCC to support its full range of languages) concludes this part.

Part IV - Basic Networking

Here we cover how to connect to a network when you aren't using the simple static IP setup given in the main LFS book. Networking libraries and command-line networking tools are also covered here.

Part V - Servers

Here we deal with setting up mail and other servers (such as FTP, Apache, etc.).

Part VI - X + Window Managers

This part explains how to set up a basic X Window System installation along with some generic X libraries and Window managers.

Part VII - KDE

For those who want to use the K Desktop Environment or some parts of it, this part covers it.

Part VIII - GNOME

GNOME is the main alternative to KDE in the Desktop Environment arena.

Part IX - Xfce

Xfce is a lightweight alternative to GNOME and KDE.

Part X - LXDE

LXDE is another lightweight alternative to GNOME and KDE.

Part XI - X Software

Office programs and graphical web browsers are important to most people. They, along with some generic X software can be found in this part of the book.

Part XII - Multimedia

Here we cover setting multimedia libraries and drivers along with some audio, video and CD-writing programs.

Part XIII - Printing, Scanning and Typesetting (PST)

The PST part of the book covers document handling with applications like Ghostscript, CUPS and DocBook to installing texlive.

Appendices

The Appendices cover information which doesn't belong in the main book; they are mainly there as a reference.

Last updated on

Part I. Introduction

Chapter 1. Welcome to BLFS

The Beyond Linux From Scratch book is designed to carry on from where the LFS book leaves off. But unlike the LFS book, it isn't designed to be followed straight through. Reading the Which sections of the book? part of this chapter should help guide you through the book.

Please read most of this part of the book carefully as it explains quite a few of the conventions used throughout the book.

Which Sections of the Book Do I Want?

Unlike the Linux From Scratch book, BLFS isn't designed to be followed in a linear manner. This is because LFS provides instructions on how to create a base system which is capable of turning into anything from a web server to a multimedia desktop system. BLFS attempts to guide you in the process of going from the base system to your intended destination. Choice is very much involved.

Everyone who reads the book will want to read certain sections. The Introduction part, which you are currently reading, contains generic information. Especially take note of the information in Chapter 2, Important Information, as this contains comments about how to unpack software, issues related to using different locales and various other aspects which apply throughout the book.

The part on Post LFS Configuration and Extra Software is where most people will want to turn next. This deals with not just configuration but also Security (Chapter 4, Security), File Systems (Chapter 5, File Systems and Disk Management), Editors (Chapter 6, Editors) and Shells (Chapter 7, Shells). Indeed, you may wish to reference certain parts of this chapter (especially the sections on Editors and File Systems) while building your LFS system.

Following these basic items, most people will want to at least browse through the General Libraries and Utilities part of the book. This part contains information on many items which are prerequisites for other sections of the book as well as some items (such as Chapter 13, Programming) which are useful in their own right. Note that you don't have to install all of these libraries and packages found in this part to start with as each BLFS installation procedure tells you which packages it depends upon so you can choose the program you want to install and see what it needs.

Likewise, most people will probably want to look at the Networking part. It deals with connecting to the Internet or your LAN (Chapter 14, Connecting to a Network) using a variety of methods such as DHCP and PPP, and with items such as Networking Libraries (Chapter 17, Networking Libraries) and various basic networking programs and utilities.

Once you have dealt with these basics, you may wish to configure more advanced network services. These are dealt with in the Servers part of the book. Those wanting to build servers should find a good starting point there. Note that this section also contains information on various database packages.

The next parts of the book principally deal with desktop systems. This portion of the book starts with a part talking about Graphical Components. This part also deals with some generic X-based libraries (Chapter 25, Graphical Environment Libraries). After this, KDE and GNOME are given their own parts which are followed by one on X Software.

The book then moves on to deal with Multimedia packages. Note that many people may want to use the ALSA-1.2.6 instructions from this chapter quite near the start of their BLFS journey; they are placed here simply because it is the most logical place for them.

The final part of the main BLFS book deals with Printing, Scanning and Typesetting. This is useful for most people with desktop systems and even those who are creating mainly server systems will find it useful.

We hope you enjoy using BLFS and find it useful.

Last updated on

Conventions Used in this Book

Typographical Conventions

To make things easy to follow, there are a number of conventions used throughout the book. Following are some examples:

./configure --prefix=/usr

This form of text is designed to be typed exactly as seen unless otherwise noted in the surrounding text. It is also used to identify references to specific commands.

install-info: unknown option
`--dir-file=/mnt/lfs/usr/info/dir'

This form of text (fixed width text) is showing screen output, probably a result from issuing a command. It is also used to show filenames such as /boot/grub/grub.conf

Emphasis

This form of text is used for several purposes in the book but mainly to emphasize important points or to give examples as to what to type.

https://www.linuxfromscratch.org/

This form of text is used for hypertext links external to the book such as HowTos, download locations, websites, etc.

SeaMonkey-2.53.10.2

This form of text is used for links internal to the book such as another section describing a different package.

cat > $LFS/etc/group << "EOF"
root:x:0:
bin:x:1:
......
EOF

This type of section is used mainly when creating configuration files. The first command (in bold) tells the system to create the file $LFS/etc/group from whatever is typed on the following lines until the sequence EOF is encountered. Therefore, this whole section is generally typed as seen.

<REPLACED TEXT>

This form of text is used to encapsulate text that should be modified and is not to be typed as seen, or copy and pasted. Note that the square brackets are not part of the text, but should be substituted for as well.

root

This form of text is used to show a specific system user or group reference in the instructions.

Conventions Used for Package Dependencies

When packages are created, the authors depend on prior work. In order to build a package in BLFS, these dependencies must be built prior to the desired package. For each package, any prerequisite packages are listed in one or more separate sections: Required, Recommended, and Optional.

Required Dependencies

These dependencies are the minimum prerequisite packages required to build the package. Omitted from the list are packages in LFS and required dependencies of other required packages.

Recommended Dependencies

These dependencies are those that the BLFS editors have determined are important to give the package reasonable capabilities. Package installation instructions assume they are installed. If a recommended package is not desired, the instructions may need to be modified to accommodate the missing package.

Optional Dependencies

These dependencies are those that the package may use. Integration of optional dependencies may be automatic by the package or may need additional instructions not presented by BLFS. Optional packages may be listed without corresponding BLFS instructions. In this case it is up to the user to determine appropriate installation instructions.

Conventions Used for Kernel Configuration Options

Some packages have specific needs regarding the kernel configuration. The general layout is the following:

Master section --->
  Subsection --->
    [*]     Required parameter                     [CONFIG_REQU_PAR]
    <*>     Required parameter (not as module)     [CONFIG_REQU_PAR_NMOD]
    <*/M>   Required parameter (could be a module) [CONFIG_REQU_PAR_MOD]
    <*/M/ > Optional parameter                     [CONFIG_OPT_PAR]
    [ ] Incompatible parameter                     [CONFIG_INCOMP_PAR]
    < > Incompatible parameter (even as module)    [CONFIG_INCOMP_PAR_MOD]

[CONFIG_...] on the right gives the name of the option, so you can easily check whether it is set in your config file. The meaning of the various entries is:

Master section top level menu item
Subsection submenu item
Required parameter the option could be either built-in or not selected: it must be selected
Required parameter (not as module) the option could be either built-in, module, or not selected: it must be selected as built-in
Required parameter (could be a module) the option could be either built-in, module, or not selected: it must be selected, either as built-in or module
Optional parameter rarely used: the option could be either built-in, module, or not selected: it may be selected at will
Incompatible parameter the option could be either built-in or not selected: it must not be selected
Incompatible parameter (even as module) the option could be either built-in, module, or not selected: it must not be selected

Note that, depending on other selections, the angle brackets (<>) may appear as braces ({}), if the option cannot be unselected, or even dashes (-*- or -M-), when the choice is imposed. The help text about the option specifies the other selections on which this option relies, and how those other selections are set.

SBU values in BLFS

As in LFS, each package in BLFS has a build time listed in Standard Build Units (SBUs). These times are relative to the time it took to build binutils in LFS and are intended to provide some insight into how long it will take to build a package. Most times listed are for a single processor or core to build the package. In some cases, large, long running builds tested on multi-core systems have SBU times listed with comments such as '(parallelism=4)'. These values indicate testing was done using multiple cores. Note that while this speeds up the build on systems with the appropriate hardware, the speedup is not linear and to some extent depends on the individual package and specific hardware used.

For packages which use ninja (e.g. anything using meson) or rust, by default all cores are used so similar comments will be seen on such packages even when the build time is minimal.

Where even a parallel build takes more than 15 SBU, on certain machines the time may be considerably greater even when the build does not use swap. In particular, different micro-architectures will build some files at different relative speeds and this can introduce delays when certain make targets wait for another file to be created. Where a large build uses a lot of C++ files, processors with Simultaneous Multi Threading will share the Floating Point Unit and can take 45% longer than when using four 'prime' cores (measured on an intel i7 using taskset and keeping the other cores idle).

Some packages do not support parallel builds and using -j1 for the make command is required. Packages that are known to have such limits are marked as such in the text.

Last updated on

Book Version

This is BLFS-BOOK version 11.1 dated March 1st, 2022. This is the 11.1 branch of the BLFS book, currently targeting the LFS 11.1 book. For development versions, if this version is older than a month, it's likely that your mirror hasn't been synchronized recently and a newer version is probably available for download or viewing. Check one of the mirror sites at https://www.linuxfromscratch.org/mirrors.html for an updated version.

Last updated on

Mirror Sites

The BLFS project has a number of mirrors set up world-wide to make it easier and more convenient for you to access the website. Please visit the https://www.linuxfromscratch.org/mirrors.html website for the list of current mirrors.

Last updated on

Getting the Source Packages

Within the BLFS instructions, each package has two references for finding the source files for the package—an HTTP link and an FTP link (some packages may only list one of these links). Every effort has been made to ensure that these links are accurate. However, the World Wide Web is in continuous flux. Packages are sometimes moved or updated and the exact URL specified is not always available.

To overcome this problem, the BLFS Team, with the assistance of Oregon State University Open Source Lab, has made an HTTP/FTP site available through world wide mirrors. See https://www.linuxfromscratch.org/blfs/download.html#sources for a list. These sites have all the sources of the exact versions of the packages used in BLFS. If you can't find the BLFS package you need at the listed addresses, get it from these sites.

We would like to ask a favor, however. Although this is a public resource for you to use, please do not abuse it. We have already had one unthinking individual download over 3 GB of data, including multiple copies of the same files that are placed at different locations (via symlinks) to make finding the right package easier. This person clearly did not know what files he needed and downloaded everything. The best place to download files is the site or sites set up by the source code developer. Please try there first.

Last updated on

Change Log

Current release: 11.1 – March 1st, 2022

Changelog Entries:

  • March 1st, 2022

    • [bdubbs] - Release of BLFS-11.1.

  • February 24th, 2022

    • [renodr] - Update to gnome-shell-extensions-41.2. Fixes #16114.

    • [renodr] - Update to gnome-shell-41.4. Fixes #16113.

    • [renodr] - Update to mutter-41.4. Fixes #16115.

    • [renodr] - Update to colord-gtk-0.3.0. Fixes #16120.

    • [ken] - Update to mutt-2.2.1. Fixes #16147.

    • [renodr] - Update to Thunderbird-91.6.1 (Security Update). Fixes #16116.

  • February 23rd, 2022

    • [bdubbs] - Update to libxml2-2.9.13 (Security Update). Fixes #16161.

    • [renodr] - Update to WebKitGTK+-2.34.6 (Security Update). Fixes #16130.

    • [renodr] - Update to geoclue-2.6.0. Fixes #16110.

    • [renodr] - Update to libsecret-0.20.5. Fixes #16150.

  • February 22nd, 2022

    • [bdubbs] - Rename libvdpau documentation as a versioned directory. Fixes #16157.

    • [bdubbs] - Rename libnotify documentation as a versioned directory. Fixes #16156.

    • [bdubbs] - Rename xorgproto documentation as a versioned directory. Fixes #16155.

  • February 20th, 2022

    • [bdubbs] - Update to accountsservice-22.07.5. Fixes #16144.

    • [bdubbs] - Update to pipewire-0.3.47. Fixes #16145.

  • February 18th, 2022

    • [renodr] - Update to cups-filters-1.28.12. Fixes #16138.

    • [renodr] - Update to qpdf-10.6.2. Fixes #16124.

    • [renodr] - Update to php-8.1.3 (Security Update). Fixes #16136.

    • [bdubbs] - Update to libwnck-40.1. Fixes #16131.

    • [bdubbs] - Update to accountsservice-22.07.4. Fixes #16133.

    • [bdubbs] - Update to pipewire-0.3.46. Fixes #16137.

    • [bdubbs] - Update to x265-20220219.

    • [bdubbs] - Update to x264-20220219. Addresses #7555.

  • February 18th, 2022

    • [bdubbs] - Update to nano-6.2. Fixes #16139.

    • [bdubbs] - Update to vim-8.2.4383. Sync with LFS.

    • [renodr] - Update to librsvg-2.52.6. Fixes #16129.

    • [renodr] - Update to colord-1.4.6. Fixes #16119.

    • [pierre] - Update to OpenJDK-17.0.2+8. Fixes #16127.

    • [renodr] - Update to xf86-input-wacom-1.0.0 (Xorg Driver). Fixes #16111.

    • [renodr] - Update to xwayland-22.1.0. Fixes #16117.

    • [renodr] - Update to libdrm-2.4.110. Fixes #16126.

    • [pierre] - Work around a 32 bit issue in firefox and thunderbird. Part of #16106.

  • February 17th, 2022

    • [bdubbs] - Update to btrfs-progs-v5.16.2. Fixes #16123.

    • [renodr] - Update to scons-4.3.0. Fixes #16109.

    • [renodr] - Update to tree-2.0.2. Fixes #16125.

    • [ken] - Update to ImageMagick-7.1.0-25 (Security Update). Fixes Fixes #16122.

    • [ken] - Update to mutt-2.2.0. Fixes Fixes #16098.

    • [renodr] - Patch valgrind to work properly with glibc-2.35. Fixes #16121.

    • [renodr] - Add an option to disable DNS-over-HTTPS support in bind-utils, and add nghttp2 as a recommended dependency.

    • [xry111] - Update to efivar-38. Fixes #16128.

    • [xry111] - Add mandoc-1.14.6. Needed by efivar-38.

    • [xry111] - Update to unifont-14.0.01. Fixes #16132.

  • February 16th, 2022

    • [bdubbs] - Update to libqalculate-4.0.0. Fixes #16107.

    • [bdubbs] - Update to libxslt-1.1.35. Fixes #16118.

  • February 14th, 2022

    • [renodr] - Update to gnome-autoar-0.4.3. Fixes #16083.

    • [renodr] - Update to evolution-data-server-3.42.4. Fixes #16084.

    • [renodr] - Update to evolution-3.42.4. Fixes #16084.

    • [renodr] - Update to gnome-maps-41.4. Fixes #16093.

    • [renodr] - Update to gnome-user-docs-41.2. Fixes #16094.

    • [renodr] - Update to gucharmap-14.0.2. Fixes #16099.

    • [renodr] - Update to gnome-control-center-41.4. Fixes #16101.

    • [renodr] - Update to gedit-41.0. Fixes #16104.

    • [renodr] - Update to vala-0.54.7. Fixes #16105.

    • [renodr] - Patch gdb to work properly with glibc-2.35. Patch crafted by Bruce. Fixes #16046.

    • [renodr] - Update to mariadb-10.6.7 (Security Update). Fixes #16103.

    • [renodr] - Update to exempi-2.6.1 (Security Update). Fixes #16102.

  • February 13th, 2022

    • [bdubbs] - Update to plasma5-5.24.0. Fixes #15926.

    • [bdubbs] - Added libqalculate-3.22.0. Required for plasma.

    • [bdubbs] - Update to kf5-apps-21.12.2, including kate and kwave. Fixes #15938.

    • [bdubbs] - Update to kf5-5.91. Fixes #15947.

    • [renodr] - Update to thunderbird-91.6.0 (Security Update). Fixes #16007.

    • [renodr] - Update to samba-4.15.5 (Security Update). Fixes #15987.

    • [renodr] - Update to webkitgtk-2.34.5 (Security Update). Fixes #16014.

    • [renodr] - Fix an issue in gnome-shell-extensions that prevents icons from being displayed properly on the taskbar when window-list is enabled.

    • [renodr] - Fix the man pages in OpenLDAP to use /sbin instead of /usr/libexec.

    • [renodr] - Adjust MANPATH in rustc to allow rustc's man pages to be accessed.

    • [bdubbs] - Update to hexchat-2.16.1. Fixes #16100.

    • [bdubbs] - Update to harfbuzz-3.4.0. Fixes #16097.

    • [bdubbs] - Update to zsh-5.8.1. Fixes #16096.

    • [renodr] - Update the gstreamer stack to 1.20. This includes gstreamer, base/good/bad/ugly plugins, libav, and vaapi, and fixes a security vulnerability. Fixes #16040.

    • [renodr] - Update to dovecot-2.3.18. Fixes #16049.

    • [renodr] - Update to glib-2.70.4. Fixes #16013.

  • February 12th, 2022

    • [bdubbs] - Update to at_3.2.4. Fixes #16095.

    • [bdubbs] - Update to gtk-4.6.1. Fixes #16092.

    • [bdubbs] - Update to ModemManager-1.18.6. Fixes #16091.

    • [bdubbs] - Update to libwacom-2.1.0. Fixes #16090.

    • [bdubbs] - Update to libqmi-1.30.4. Fixes #16089.

    • [ken] - Update to fetchmail-6.4.27. Fixes #16019.

  • February 11th, 2022

    • [renodr] - Update to Mesa-21.3.6. Fixes #16075.

    • [renodr] - Introduced a patch to resolve several OpenGL Multi-Threading issues in the Nouveau driver for Mesa. Fixes #16033.

    • [bdubbs] - Update to xfce4-notifyd-0.6.3. Fixes #16088.

    • [bdubbs] - Update to freeglut-3.2.2. Fixes #16087.

    • [bdubbs] - Update to wireshark-3.6.2. Fixes #16079.

    • [bdubbs] - Update to postgresql-14.2. Fixes #16080.

    • [bdubbs] - Update to unbound-1.15.0. Fixes #16081.

    • [bdubbs] - Update to guile-3.0.8. Fixes #16082.

    • [bdubbs] - Update to libsigc++-2.10.8. Fixes #16085.

    • [ken] - Update to asymptote-2.78. Fixes #15899.

  • February 10th, 2022

    • [ken] - Update to biber-2.17 with biblatex-3.17. Fixes #16010.

    • [ken] - Update to dvisvgm-2.13.1. Fixes #15995.

    • [bdubbs] - Update to libgee-0.20.5. Fixes #16078.

    • [bdubbs] - Update to HTTP-Daemon-6.13 (Perl Module). Fixes #16077.

    • [bdubbs] - Update to qpdf-10.6.1. Fixes #16076.

  • February 9th, 2022

    • [bdubbs] - Update to pango-1.50.4. Fixes #16074.

    • [bdubbs] - Update to nano-6.1. Fixes #16073.

    • [bdubbs] - Update to gjs-1.70.1. Fixes #16072.

    • [bdubbs] - Update to node.js-16.14.0. Fixes #16070.

    • [bdubbs] - Update to libarchive-3.6.0. Fixes #16069.

  • February 8th, 2022

    • [bdubbs] - Update to intel-microcode-20220207 (Security Update). Fixes #16068.

    • [bdubbs] - Update to LVM2.2.03.15. Fixes #16067.

    • [bdubbs] - Update to gpgme-1.17.0. Fixes #16066.

    • [bdubbs] - Update to imlib2-1.8.0. Fixes #16064.

    • [bdubbs] - Update to xkeyboard-config-2.35.1. Fixes #16063.

    • [ken] - Update to firefox-91.6.0esr (Security Update). Fixes #16060.

    • [ken] - Reverted dvisvgm-2.13.1, the release tarball in the link is not what I tested and my altered commands will not work.

  • February 7th, 2022

    • [ken] - Updated to dvisvgm-2.13.1. Fixes #15995.

    • [xry111] - Update to gnupg-2.2.34. Fixes #16062.

    • [bdubbs] - Update to harfbuzz-3.3.2. Fixes #16059.

    • [bdubbs] - Update to ed-1.18. Fixes #16061.

    • [bdubbs] - Update to postfix-3.7.0. Fixes #16057.

    • [bdubbs] - Update to libreoffice-7.3.0.3. Fixes #16045.

    • [bdubbs] - Update to inkscape-1.1.2. Fixes #16058.

  • February 6th, 2022

    • [bdubbs] - Update to nss-3.75. Fixes #16047.

    • [bdubbs] - Update to libical-3.0.14. Fixes #16056.

    • [bdubbs] - Update to pycryptodome-3.14.1. Fixes #16055.

    • [bdubbs] - Update to libxkbcommon-1.4.0. Fixes #16054.

    • [bdubbs] - Update to btrfs-progs-v5.16.1. Fixes #16053.

  • February 5th, 2022

    • [bdubbs] - Update to tk8.6.12. Fixes #16052.

    • [bdubbs] - Update to mercurial-6.0.2. Fixes #16044.

    • [bdubbs] - Update to llvm-13.0.1. Fixes #16043.

    • [ken] - Update to DateTime-Calendar-Julian-0.107. Fixes #16030.

    • [ken] - Update dependant perl modules to Alien-Build-2.46, B-Hooks-EndOfScope-0.25, Class-Data-Inheritable-0.09, DateTime-1.55, DateTime-Locale-1.33, DateTime-TimeZone-2.51, HTTP-Message-6.36, libwww-perl-6.61, MRO-Compat-0.15, Net-HTTP-6.22, Net-SSLeay-1.92, Path-Tiny-0.122, Scalar-List-Utils-1.60, Term-Table-0.016, Test2-Suite-0.000144, Test-File-1.991, Text-CSV_XS-1.47, Tie-Cycle-1.227, Try-Tiny-0.31. Addresses #13850.

  • February 4th, 2022

    • [bdubbs] - Update to pipewire-0.3.45. Fixes #16050.

    • [bdubbs] - Update to lcms2-2.13.1. Fixes #16051.

    • [bdubbs] - Update to tcsh-6.24.00. Fixes #16042.

    • [bdubbs] - Update falkon dependencies. Fixes #16041.

    • [bdubbs] - Update to screen-4.9.0. Fixes #16039.

  • February 2nd, 2022

    • [bdubbs] - Update to poppler-22.02.0. Fixes #16038.

    • [bdubbs] - Update to libgcrypt-1.10.0. Fixes #16037.

  • February 1st, 2022

    • [bdubbs] - Update to harfbuzz-3.3.1. Fixes #16035.

    • [bdubbs] - Update to libusb-1.0.25. Fixes #16034.

    • [bdubbs] - Update to falkon-3.2.0. Fixes #16036.

  • January 31st, 2022

    • [bdubbs] - Update to vim-8.2.4236. Fixes #16032.

    • [bdubbs] - Update to git-2.35.1. Fixes #16028.

    • [bdubbs] - Update to accountsservice-22.04.62. Fixes #16027.

    • [bdubbs] - Update to cups-2.4.1. Fixes #16022.

    • [bdubbs] - Update to pipewire-0.3.44. Fixes #16021.

    • [bdubbs] - Update to pycryptodome-3.14.0 (Python module). Fixes #16031.

    • [bdubbs] - Update to lcms2-2.13. Fixes #16029.

    • [bdubbs] - Update to sudo-1.9.9. Fixes #16026.

    • [bdubbs] - Update to wayland-protocols-1.25. Fixes #16025.

    • [bdubbs] - Update to libgpg-error-1.44. Fixes #16020.

    • [bdubbs] - Update to libcap-2.63. Fixes #16008.

    • [bdubbs] - Update to Python3-3.10.2. Fixes #15972.

    • [bdubbs] - Update to libwacom-2.0.0. Fixes #15857.

  • January 27th, 2022

    • [ken] - In Qt5 apply consolidated kde (kf5.15) patches for all the qt5 modules required by packages mentioned in BLFS. This includes the existing qtsvg fix and gcc-11 changes, as well as other fixes including a new qtsvg vulnerability fix (Security Update). Fixes #16002.

    • [bdubbs] - Update to bind-9.18.0. Fixes #16016.

    • [bdubbs] - Update to lua-5.4.4. Fixes #16015.

    • [pierre] - Update to firefox-91.5.1. Fixes #16017.

    • [renodr] - Move Grantlee to X Libraries and significantly overhaul it's contents.

    • [pierre] - Update to mesa-21.3.5. Fixes #16018.

  • January 26th, 2022

    • [ken] - Move kerberos from a recommended dep of Qt5 to an optional dep of QtWebEngine.

    • [bdubbs] - Update to cmake-3.22.2. Fixes #16009.

    • [xry111] - Add patch to fix CVE-2021-4034 for polkit. Fixes #16012.

  • January 25th, 2022

    • [bdubbs] - Update to git-2.35.0. Fixes #16005.

    • [bdubbs] - Update to xf86-input-libinput-1.2.1. Fixes #16006.

    • [bdubbs] - Update to unrar-6.1.4. Fixes #16004.

  • January 24th, 2022

    • [ken] - Update to rustc-1.58.1 (Security Update). Fixes #16003.

  • January 23rd, 2022

    • [bdubbs] - Update to pycryptodome-3.13.0 (Python module). Fixes #16001.

    • [bdubbs] - Update to nfs-utils-2.6.1. Fixes #16000.

    • [bdubbs] - Update to php-8.1.2. Fixes #15999.

    • [bdubbs] - Update to bind-9.16.25. Fixes #15986.

  • January 22nd, 2022

    • [pierre] - Fix gedit for building with newer versions of meson. Report by Joe Locash.

    • [bdubbs] - Update to gnumeric-1.12.51. Fixes #15994.

    • [bdubbs] - Update to goffice-0.10.51. Fixes #15993.

    • [bdubbs] - Update to libwebp-1.2.2. Fixes #15991.

    • [bdubbs] - Update to dash-0.5.11.5. Fixes #15990.

    • [pierre] - Fix network-manager-applet for building with newer versions of meson. Report by Joe Locash.

    • [pierre] - Update to umockdev-0.17.6. Fixes #15998.

    • [pierre] - Update to gtk4-4.6.0. Fixes #15997.

    • [pierre] - Update to fop-2.7. Fixes #15996.

  • January 21st, 2022

    • [timtas] - Update to openldap-2.6.1. Fixes #15992.

    • [bdubbs] - Update to icewm-2.9.5. Fixes #15989.

    • [bdubbs] - Update to libnma-1.8.34. Fixes #15988.

    • [bdubbs] - Update to stunnel-5.62. Fixes #15980.

    • [bdubbs] - Update to p11-kit-0.24.1. Fixes #15979.

  • January 20th, 2022

    • [timtas] - Update to wpa_supplicant-2.10. Fixes #15978.

  • January 19th, 2022

    • [bdubbs] - Update to gdb-11.2. Fixes #15977.

    • [bdubbs] - Update to cups-filters-1.28.11. Fixes #15976.

    • [bdubbs] - Update to postfix-3.6.4. Fixes #15973.

    • [ken] - Update to mutt-2.1.5. Fixes #15914.

  • January 18th, 2022

    • [pierre] - Prevents tests from being built for gnome-shell since they need that tests be enabled for mutter.

    • [pierre] - Fixes for building with newer versions of meson: evince, gnome-disk-utility, gnome-maps, gnome-screenshot, gnome-terminal, gnome-tweaks, gnome-weather, gucharmap, gnome-bluetooth, gnome-control-center, gnome-settings-daemon, and epiphany.

    • [pierre] - Update to gnutls-3.7.3 (Security Fix). Fixes #15983.

    • [pierre] - Update to umockdev-0.17.5. Fixes #15984.

    • [pierre] - Update to folks-0.15.4. Fixes #15982.

    • [pierre] - Update to libical-3.0.13. Fixes #15981.

    • [pierre] - Apply fixes to dconf-editor and gcr to be able to build with newer versions of meson.

  • January 17th, 2022

    • [pierre] - Apply a fix to gvfs to be able to build with newer versions of meson.

    • [ken] - Update to qtwebengine-5.15.8 (Security Fix). Fixes #15922.

    • [pierre] - Apply upstream fix to accountservice to be able to build with newer versions of meson.

  • January 15th, 2022

    • [bdubbs] - Update to ristretto-0.12.2. Fixes #15974.

    • [bdubbs] - Update to plasma-wayland-protocols-1.6.0. Fixes #15971.

    • [pierre] - Apply upstream patch to gobject-introspection to allow building with meson version 0.61 or above.

    • [pierre] - Update to shadow-4.11.1. Fixes #15916.

    • [pierre] - Apply upstream patch to btrfs-progs-5.16 to be able to build with kernel headers version < 5.12.

  • January 13th, 2022

    • [renodr] - Update to thunderbird-91.5.0 (Security Update). Fixes #15964.

    • [renodr] - Update to epiphany-41.3 (Security Update). Fixes #15602.

    • [renodr] - Update to gucharmap-14.0.1. Fixes #15719.

    • [renodr] - Update to gnome-weather-41.0. Fixes #15590.

    • [renodr] - Update to gnome-terminal-3.42.2. Fixes #15605.

    • [renodr] - Update to gnome-system-monitor-41.0. Fixes #15970.

    • [renodr] - Update to gnome-screenshot-41.0. Fixes #15749.

    • [renodr] - Update to gnome-maps-41.2. Fixes #15574.

    • [renodr] - Update to gnome-disk-utility-41.0. Fixes #15604.

    • [renodr] - Update to gnome-calculator-41.1. Fixes #15821.

    • [renodr] - Update to NetworkManager-1.34.0. Fixes #15969.

    • [renodr] - Update to evolution-3.42.3. Fixes #15563.

    • [renodr] - Update to seahorse-41.0. Fixes #15626.

    • [renodr] - Update to evince-41.3. Fixes #15668.

    • [renodr] - Update to eog-41.1. Fixes #15598.

    • [renodr] - Update to brasero-3.12.3. Fixes #15579.

    • [renodr] - Update to baobab-41.0. Fixes #15589.

    • [bdubbs] - Update to btrfs-progs-5.16. Fixes #15967.

    • [bdubbs] - Update to mesa-21.3.4. Fixes #15966.

    • [bdubbs] - Update to cryptsetup-2.4.3. Fixes #15968.

    • [renodr] - Update to gnome-desktop-41.3. Fixes #15961.

    • [renodr] - Update to yelp-41.2. Fixes #15596.

    • [renodr] - Update to gnome-user-docs-41.1. Fixes #15572.

    • [renodr] - Update to gdm-41.3. Fixes #15595.

    • [renodr] - Update to gnome-session-41.3. Fixes #15965.

    • [renodr] - Update to gnome-shell-extensions-41.1. Fixes #15593.

    • [renodr] - Update to gnome-shell-41.3. Fixes #15587.

    • [renodr] - Update to mutter-41.3. Fixes #15588.

    • [renodr] - Update to gnome-control-center-41.2. Fixes #15562.

    • [renodr] - Update to gnome-settings-daemon-41.0. Fixes #15594.

    • [renodr] - Update to nautilus-41.2. Fixes #15603.

  • January 12th, 2022

    • [bdubbs] - Update to neon-0.32.2. Fixes #15962.

    • [pierre] - Change PAM configuration files of shadow applications so that only the types really used appear, and use system-password for the password type when needed. Fixes #15950.

  • January 11th, 2022

    • [bdubbs] - Update to mercurial-6.0.1. Fixes #15933.

  • January 11th, 2022

    • [ken] - Update to firefox-91.5.0 (Security Update). Fixes #15952.

    • [ken] - Update to node.js-v16.13.2 (Security Update). Fixes #15956.

    • [renodr] - Update to gnome-backgrounds-41.0. Fixes #15522.

    • [renodr] - Update to tracker-miners-3.2.1. Fixes #15573.

    • [renodr] - Update to tracker-3.2.1. Fixes #15573.

    • [renodr] - Update to gfbgraph-0.2.5 (Security Update). Fixes #15717.

    • [renodr] - Update to evolution-data-server-3.42.3. Fixes #15561.

    • [renodr] - Fix CVE-2016-20011 in libgrss. Fixes #15946.

    • [bdubbs] - Update to SDL2-2.0.20. Fixes #15959.

    • [bdubbs] - Update to hdparm-9.63. Fixes #15958.

    • [bdubbs] - Update to umockdev-0.17.3. Fixes #15957.

    • [bdubbs] - Update to libgusb-0.3.10. Fixes #15955.

    • [bdubbs] - Update to double-conversion-3.2.0. Fixes #15954.

  • January 10th, 2022

    • [renodr] - Update to grilo-0.3.14 (Security Update). Fixes #15654.

    • [renodr] - Update to gnome-online-accounts-3.40.1. Fixes #15684.

    • [renodr] - Update to cheese-41.1. Fixes #15584.

    • [renodr] - Update to gnome-desktop-41.2. Fixes #15599.

    • [renodr] - Update to gnome-autoar-0.4.2. Fixes #15718.

    • [renodr] - Update to yelp-xsl-41.1. Fixes #15597.

    • [renodr] - Update to vte-0.66.2. Fixes #15721.

    • [renodr] - Update to vala-0.54.6. Fixes #15945.

    • [xry111] - Update to make-ca-1.10 (security fix). Fixes #15951.

  • January 9th, 2022

    • [bdubbs] - Update to Business-ISBN-3.007 (Perl module). Fixes #15949.

  • January 8th, 2022

    • [bdubbs] - Update to PerlIO-utf8_strict-0.009 (Perl module). Fixes #15948.

    • [bdubbs] - Update to rpcsvc-proto-1.4.3. Fixes #15944.

    • [bdubbs] - Update to logrotate-3.19.0. Fixes #15941.

    • [bdubbs] - Update to libsigsegv-2.14. Fixes #15940.

    • [bdubbs] - Update to IO-Socket-SSL-2.074 (Perl module). Fixes #15942.

    • [bdubbs] - Update to Test-Differences-0.69 (Perl module). Fixes #15943.

    • [bdubbs] - Update to libreoffice-7.2.5.2. Fixes #15814.

  • January 7th, 2022

    • [bdubbs] - Update to Pygments-2.11.2. Fixes #15936.

    • [bdubbs] - Update to nss-3.74. Fixes #15935.

    • [bdubbs] - Update to sqlite-autoconf-3370200 (3.37.2). Fixes #15937.

  • January 6th, 2022

    • [bdubbs] - Update to poppler-22.01.0. Fixes #15930.

    • [pierre] - Patch mariadb to prevent a stack smashing error when building against openssl-3. Fixes #15928.

    • [renodr] - Update to gjs-1.70.0. Fixes #15571.

    • [renodr] - Update to gesttings-desktop-schemas-41.0. Fixes #15592.

    • [bdubbs] - Update to pipewire-0.3.43. Fixes #15934.

    • [bdubbs] - Update to bluez-5.63. Fixes #15932.

    • [bdubbs] - Update to asciidoctor-2.0.17. Fixes #15931.

    • [bdubbs] - Update to userspace-rcu-0.13.1 (liburcu). Fixes #15929.

    • [bdubbs] - Update to mdadm-4.2. Fixes #15906.

  • January 5th, 2022

    • [bdubbs] - Update to curl-7.81.0. Fixes #15927.

    • [bdubbs] - Update to libuv-v1.43.0. Fixes #15925.

    • [bdubbs] - Update to libunistring-1.0. Fixes #15924.

    • [pierre] - Patch exim for building against openssl-3.

  • January 4th, 2022

    • [bdubbs] - Update to feh-3.8. Fixes #15921.

    • [bdubbs] - Update to tree-2.0.1. Fixes #15920.

    • [bdubbs] - Update to tcsh-6.23.02. Fixes #15919.

    • [bdubbs] - Update to iso-codes-4.9.0. Fixes #15917.

    • [bdubbs] - Update to seamonkey-2.53.10.2. Fixes #15902.

  • January 3rd, 2022

    • [renodr] - Update to gexiv2-0.14.0. Fixes #15570.

    • [renodr] - Update to adwaita-icon-theme-41.0. Fixes #15521.

    • [bdubbs] - Update to xorg-server-21.1.3. Fixes #15915.

    • [bdubbs] - Update to Pygments-2.11.1 (Python module). Fixes #15912.

    • [bdubbs] - Update to doxygen-1.9.3. Fixes #15911.

    • [bdubbs] - Update to wireshark-3.6.1. Fixes #15904.

  • January 1st, 2022

    • [renodr] - Update to pygobject-3.42.0. Fixes #15576.

    • [renodr] - Update to sysprof-3.42.1. Fixes #15606.

    • [bdubbs] - Update to xapian-core-1.4.19. Fixes #15910.

    • [bdubbs] - Update to icewm-2.9.4. Fixes #15909.

    • [bdubbs] - Update to pygments-2.11.0 (Python module). Fixes #15907.

    • [bdubbs] - Update to sqlite-autoconf-3370100. Fixes #15908.

    • [bdubbs] - Update to iso-codes-4.8.0. Fixes #15905.

    • [bdubbs] - Update to libgsf-1.14.48. Fixes #15901.

    • [bdubbs] - Update to shadow-4.10. Fixes #15878.

  • December 31st, 2021

    • [renodr] - Update to at-spi2-core-2.42.0. Fixes #15569.

  • December 30th, 2021

    • [renodr] - Update to mesa-21.3.3. Fixes #15903.

    • [ken] - Update to mutt-2.1.4. Fixes #15847.

    • [ken] - Update to IO-Socket-SSL-2.073. Fixes #15892, this fixes some OpenSSL-3 issues.

    • [renodr] - Fix a couple of OpenSSL-3 related issues with serf. This includes a fix for a compilation problem in Subversion.

  • December 29th, 2021

    • [renodr] - Fix several OpenSSL-3 related issues in MIT Kerberos V5.

    • [renodr] - Update to Net-SSLeay-1.91_01 to fix problems with OpenSSL-3.

  • December 28th, 2021

    • [renodr] - Fix a bug in libarchive caused by behavior changes in OpenSSL-3.

    • [renodr] - Fix wpa_supplicant connection issues when using OpenSSL-3.

  • December 27th, 2021

    • [renodr] - Update to fetchmail-6.4.26. Fixes #15900.

  • December 26th, 2021

    • [bdubbs] - Update to tree-2.0.0. Fixes #15889.

    • [bdubbs] - Update to pango-1.50.3. Fixes #15888.

    • [bdubbs] - Update to qpdf-10.5.0. Fixes #15887.

    • [bdubbs] - Update to libportal-0.5. Fixes #15886.

    • [bdubbs] - Update to gtk+3 3.24.31. Fixes #15885.

    • [bdubbs] - Update URLs in Beyond BLFS section. Fixes #15893.

  • December 26th, 2021

    • [renodr] - Update to ruby-3.1.0. Fixes #15898.

    • [renodr] - Update to python-dbusmock-0.25.0 (Python Module). Fixes #15897.

    • [renodr] - Update to opencv-4.5.5. Fixes #15895.

    • [renodr] - Update to sawfish-1.13.0. Fixes #15894.

    • [renodr] - Update to stunnel-5.61. Fixes #15890.

    • [renodr] - Update to double-conversion-3.1.7. Fixes #15891.

    • [renodr] - Update to File-Slurper-0.013 (Perl Module). Fixes #15896.

    • [renodr] - Fix six security vulnerabilities in wpa_supplicant. Fixes #15851.

    • [renodr] - Update to Samba-4.15.3. Fixes #15831.

  • December 23rd, 2021

    • [renodr] - Update to ModemManager-1.18.4. Fixes #15794.

    • [renodr] - Update to dovecot-2.3.17.1. Fixes #15829.

  • December 22nd, 2021

    • [renodr] - Update to WebKitGTK+-2.34.3 (Security Update). Fixes #15783.

    • [renodr] - Update to seamonkey-2.53.10.1 (Security Update). Fixes #15753.

    • [renodr] - Fix building Firefox with wayland-1.20 installed. Similar issue to Thunderbird and SDL.

    • [renodr] - Update to thunderbird-91.4.1 (Security Update). Fixes #15729.

    • [renodr] - Update to nss-3.73.1. Fixes #15862.

  • December 21st, 2021

    • [bdubbs] - Update to httpd-2.4.52. Fixes #15882.

    • [bdubbs] - Update to asciidoc-10.1.1. Fixes #15884.

    • [bdubbs] - Update to icewm-2.9.3. Fixes #15778.

  • December 20th, 2021

    • [bdubbs] - Update to mlt-7.4.0. Fixes #15880.

    • [bdubbs] - Update to gimp-2.10.30. Fixes #15879.

  • December 19th, 2021

    • [bdubbs] - Update to mesa-21.3.2. Fixes #15873.

    • [bdubbs] - Update to php-8.1.1. Fixes #15871.

    • [bdubbs] - Update to gegl-0.4.34. Fixes #15877.

    • [bdubbs] - Update to librsvg-2.52.5. Fixes #15869.

    • [bdubbs] - Update to nspr-4.33. Fixes #15868.

    • [bdubbs] - Update to asciidoc-10.1.0 (python module). Fixes #15870.

    • [bdubbs] - Update to pipewire-0.3.42. Fixes #15874.

  • December 18th, 2021

    • [renodr] - Update to gtk-4.4.1. Fixes #15723.

    • [renodr] - Update to gtk-vnc-1.3.0. Fixes #15757.

    • [renodr] - Update to fetchmail-6.4.25. Fixes #15773.

    • [renodr] - Fix CVE-2021-38165 in Lynx. Fixes #15849.

  • December 17th, 2021

    • [bdubbs] - Update to bind9-9.16.24. Fixes #15861.

    • [bdubbs] - Update to qemu-6.2.0. Fixes #15859.

    • [bdubbs] - Update to Net-DNS-1.33 (Perl module). Fixes #15867.

    • [bdubbs] - Update to vala-0.54.5. Fixes #15866.

    • [bdubbs] - Update to nano-6.0. Fixes #15863.

    • [bdubbs] - Update to pipewire-0.3.41. Fixes #15852.

    • [bdubbs] - Update to gutenprint-5.3.4. Fixes #15850.

    • [renodr] - Update to jdk-17.0.1. Critical security update. Fixes #15845.

    • [bdubbs] - Add kio-extras-21.12.0.

  • December 16th, 2021

    • [bdubbs] - Add kdsoap-2.0.0.

    • [bdubbs] - Update to XWayland-21.1.4. Fixes #15858.

    • [bdubbs] - Update to xorg-server-21.1.2. Fixes #15860.

    • [bdubbs] - Update to harfbuzz-3.2.0. Fixes #15855.

    • [bdubbs] - Update to libinput-1.19.3 (Xorg driver). Fixes #15853.

    • [bdubbs] - Update to lxml-4.7.1 (python module). Fixes #15856.

    • [bdubbs] - Update to mpg123-1.29.3. Fixes #15848.

    • [bdubbs] - Update to umockdev-0.17.1. Fixes #15846.

    • [bdubbs] - Update to xine-ui-0.99.13. Fixes #15844.

    • [bdubbs] - Update to pango-1.50.2. Fixes #15843 and #15864.

    • [bdubbs] - Update to unrar-6.1.3. Fixes #15842.

    • [bdubbs] - Update to unbound-1.14.0. Fixes #15840.

    • [bdubbs] - Update to wayland-1.20.0. Fixes #15838.

    • [bdubbs] - Update to tcsh-6.23.01. Fixes #15837.

  • December 15th, 2021

    • [bdubbs] - Update to cmake-3.22.1. Fixes #15836.

    • [bdubbs] - Update to exo-4.16.3. Fixes #15828.

    • [bdubbs] - Update to alsa-lib-1.2.6.1, alsa-plugins-1.2.5, alsa-utils-1.2.6. Fixes #15823.

  • December 14th, 2021

    • [bdubbs] - Update to Python-3.10.1. Fixes #15827.

    • [bdubbs] - Update to libcap-2.62. Fixes #15854.

    • [renodr] - Fix building JasPer-2.0.33 with CMake-3.22. Sed by Bruce.

    • [bdubbs] - Update to plasma5-5.23.4. Fixes #15489.

    • [renodr] - Fix building the nouveau driver with the new Xorg-Server.

  • December 13th, 2021

    • [bdubbs] - Update to kf5-apps-21.12.0, including kate and kwave. Fixes #15526.

  • December 12th, 2021

    • [bdubbs] - Update to kf5-5.89, including extra-cmake-modules, breeze-icons, and oxygen-icons5. Fixes #15526.

    • [bdubbs] - Update to plasma-wayland-protocols-1.5.0.

    • [bdubbs] - Update to pyatspi-2.38.2 (Python Module). Fixes #15835.

    • [bdubbs] - Update to libical-3.0.12. Fixes #15834.

    • [bdubbs] - Update to libgusb-0.3.9. Fixes #15833.

    • [bdubbs] - Update to boost-1.78.0. Fixes #15832.

    • [thomas] - Add some notes about upgrading database server binaries on an existing installation.

    • [thomas] - Update to postgresql-14.1. Fixes #15830.

    • [thomas] - Update to mariadb-10.6.5. Fixes #15839.

  • December 11th, 2021

    • [renodr] - Fix installing Wireshark by removing references to files that don't exist anymore.

  • December 10th, 2021

    • [bdubbs] - Update to xfsprogs-5.14.2. Fixes #15826.

    • [bdubbs] - Update to libX11-1.7.3.1 (Xorg Library). Fixes #15825.

    • [bdubbs] - Update to imlib2-1.7.5. Fixes #15824.

    • [bdubbs] - Update to glib-networking-2.70.1. Fixes #15822.

  • December 7th, 2021

    • [bdubbs] - Update to glib-2.70.2. Fixes #15819.

    • [bdubbs] - Update to pangomm-1.46.2. Fixes #15820.

    • [bdubbs] - Update to pango-1.50.0. Fixes #15818.

    • [bdubbs] - Update to mypaint-brushes-1.3.1. Fixes #15817.

    • [bdubbs] - Update to sysstat-12.5.5. Fixes #15815.

    • [ken] - Update to firefox-91.4.0esr (security fixes). Fixes #15816.

    • [bdubbs] - Update to pycryptodome-3.12.0 (Python module). Fixes #15813.

    • [bdubbs] - Update to graphviz-2.50.0. Fixes #15812.

    • [bdubbs] - Update to double-conversion-3.1.6. Fixes #15811.

    • [bdubbs] - Update to enchant-2.3.2. Fixes #15810.

    • [bdubbs] - Update to ldns-1.8.1. Fixes #15809.

  • December 6th, 2021

    • [bdubbs] - Update to node-16.13.1. Fixes #15804.

    • [bdubbs] - Update to cups-2.4.0. Fixes #15801.

  • December 3rd, 2021

    • [pierre] - Update to blocaled-0.4. Fixes #15808.

    • [bdubbs] - Update to freetype-2.11.1. Fixes #15807.

    • [bdubbs] - Update to xfsprogs-5.14.1. Fixes #15806.

    • [bdubbs] - Update to poppler-21.12.0. Fixes #15805.

    • [bdubbs] - Update to gsl-2.7.1. Fixes #15803.

    • [bdubbs] - Update to SDL2-2.0.18. Fixes #15800.

    • [bdubbs] - Update to mesa-21.3.1. Fixes #15761.

  • December 2nd, 2021

    • [thomas] - Remove attempt to recreate existing documentation in neon. Thanks to Pierre for the sed.

  • December 1st, 2021

    • [ken] - Update to nss-3.73 (security update). Fixes #15802.

  • November 30th, 2021

    • [bdubbs] - Update to vala-0.54.4. Fixes #15799.

    • [bdubbs] - Update to libcap-2.61. Fixes #15775.

    • [bdubbs] - Update to libexif-0.6.24. Fixes #15787.

  • November 29th, 2021

    • [bdubbs] - Update to xauth-1.1.1 (Xorg App). Fixes #15798.

  • November 28th, 2021

    • [bdubbs] - Update to sqlite-autoconf-3370000 (3.37.0). Fixes #15796.

    • [bdubbs] - Update to rxvt-unicode-9.30. Fixes #15797.

    • [bdubbs] - Update to harfbuzz-3.1.2. Fixes #15795.

    • [bdubbs] - Update to ldns-1.8.0. Fixes #15793.

    • [bdubbs] - Update to ristretto-0.12.1. Fixes #15792.

    • [bdubbs] - Update to mousepad-0.5.8. Fixes #15791.

    • [bdubbs] - Update to libdrm-2.4.109. Fixes #15789.

    • [bdubbs] - Update to php-8.1.0. Fixes #15788.

    • [bdubbs] - Update to libreoffice-7.2.3.2. Fixes #15790.

  • November 27th, 2021

    • [pierre] - Fix Xwayland and GDM so that GNOME can be run without xorg-server.

  • November 26th, 2021

    • [ken] - Patch qtwebengine to bring it to 5.15.7 (security fixes). Fixes #15765.

    • [timtas] - Update to openldap-2.6.0. Fixes #15701.

  • November 25th, 2021

    • [bdubbs] - Update to git-2.34.1. Fixes #15786.

    • [bdubbs] - Update to ruby-3.0.3. Fixes #15785.

    • [bdubbs] - Update to libsoup-2.74.2. Fixes #15784.

    • [bdubbs] - Update to mercurial-6.0. Fixes #15780.

    • [renodr] - Update to btrfs-progs-5.15.1. Fixes #15659.

    • [renodr] - Update to libical-3.0.11. Fixes #15661.

    • [renodr] - Update to opencv-4.5.4. Fixes #15662.

    • [renodr] - Update to bluez-5.62. Fixes #15672.

    • [bdubbs] - Update to wayland-protocols-1.24. Fixes #15782.

    • [bdubbs] - Update to docutils-0.18.1. Fixes #15781.

    • [bdubbs] - Update to rxvt-unicode-9.29. Fixes #15777.

    • [bdubbs] - Added libptytty-2.0 required by rxvt-unicode-9.29.

    • [bdubbs] - Update to wireshark-3.6.0. Fixes #15776.

    • [bdubbs] - Update to libjpeg-turbo-2.1.2. Fixes #15771.

    • [bdubbs] - Update to php-8.0.13. Fixes #15770.

    • [bdubbs] - Update to xfsprogs-5.14.0. Fixes #15768.

    • [bdubbs] - Added userspace-rcu-0.13.0 (iburcu) required by xfsprogs-5.14.0.

    • [bdubbs] - Update to cmake-3.22.0. Fixes #15766.

  • November 23rd, 2021

    • [renodr] - Update to mupdf-1.19.0. Fixes #15655.

    • [renodr] - Update to gnupg-2.2.33. Fixes #15656.

    • [renodr] - Update to unrar-6.1.2. Fixes #15657.

    • [renodr] - Update to pycryptodome-3.11.0 (Python Module). Fixes #15658.

    • [renodr] - Update to icewm-2.8.0. Fixes #15653.

    • [renodr] - Update to xkeyboard-config-2.34. Fixes #15652.

    • [renodr] - Update to libva-2.13.0. Fixes #15651.

    • [renodr] - Update to libgusb-0.3.8. Fixes #15643.

    • [renodr] - Update to librsvg-2.52.4. Fixes #15644.

    • [renodr] - Update to vala-0.54.3. Fixes #15648.

  • November 22nd, 2021

    • [timtas] - Update to fltk-1.3.8. Fixes #15774.

  • November 21st, 2021

    • [pierre] - Update to xorg-server-21.1.1. Fixes #15709.

    • [pierre] - Add xwayland-21.1.3. Part of #15709.

  • November 20th, 2021

    • [renodr] - Fix a regression in Samba that causes winbindd to crash with some versions of Windows.

    • [ken] - Update to rustc-1.56.1 and adjust it to be ready for openssl-3.0.0.. Fixes #15767.

  • November 18th, 2021

    • [ken] - Patch inkscape to build with poppler-21.11.0.

    • [ken] - Update to poppler-21.11.0. Fixes #15725.

    • [bdubbs] - Update to tigervnc-1.12.0. Fixes #15744.

    • [bdubbs] - Update to wireshark-3.4.10. Fixes #15760.

    • [bdubbs] - Update to qpdf-10.4.0. Fixes #15755.

    • [bdubbs] - Update to Mako-1.1.6 (Python module). Fixes #15758.

    • [bdubbs] - Update to bind/bind utilities 9.16.23. Fixes #15759.

  • November 16th, 2021

    • [ken] - Update to postfix-3.6.3 and ensure -DNO_NIS is used. Fixes #15735.

    • [xry111] - Add back ntfs-3g because the utilities in it is still useful. Mention the new in-kernel NTFS implementation in the page.

    • [bdubbs] - Update to git-2.34.0. Fixes #15754.

    • [bdubbs] - Update to libuninameslist-20211114. Fixes #15752.

    • [bdubbs] - Update to sg3_utils-1.47. Fixes #15747.

    • [bdubbs] - Update to pipewire-0.3.40. Fixes #15745.

    • [bdubbs] - Update to curl-7.80.0. Fixes #15743.

    • [bdubbs] - Update to mlt-7.2.0. Fixes #15724.

  • November 15th, 2021

    • [bdubbs] - Update to iw-5.16. Fixes #15737.

    • [bdubbs] - Update to xterm-370. Fixes #15750.

    • [bdubbs] - Update to tcsh-6.23.00. Fixes #15746.

    • [bdubbs] - Update to libtasn1-4.18.0. Fixes #15740.

    • [bdubbs] - Update to libmbim-1.26.2. Fixes #15736.

    • [bdubbs] - Update to libseccomp-2.5.3. Fixes #15734.

    • [bdubbs] - Update to libgpg-error-1.43. Fixes #15727.

    • [bdubbs] - Update to asciidoc-10.0.2 (python module). Fixes #15751.

    • [bdubbs] - Update to Jinja2-3.0.3 (python module). Fixes #15741.

    • [bdubbs] - Update to lxml-4.6.4 (python module). Fixes #15726.

    • [bdubbs] - Update to fribidi-1.0.11. Fixes #15715.

  • November 14th, 2021

    • [ken] - Fixes for shared-mime-info-2.1. Fixes #15748.

    • [bdubbs] - Archive ntfs-3g. Support for NTFS is now built into the kernel.

    • [pierre] - Update to libdrm-2.4.108. Fixes #15739.

    • [pierre] - Update to libevdev-1.12.0. Fixes #15738.

    • [pierre] - Update to mesa-21.2.5. Fixes #15713.

    • [pierre] - Update to glib-2.70.1. Fixes #15710.

    • [pierre] - Update to cmake-3.21.4. Fixes #15707.

  • November 11th, 2021

    • [pierre] - Add libxcvt-0.1.1, needed by xorg-server-21.1.1. Part of #15709.

    • [pierre] - Update to samba-4.15.2 (security fix). Fixes #15742.

    • [ken] - Update to harfbuzz-3.1.1. Fixes #15728.

    • [ken] - Update to fetchmail-6.4.23. Fixes #15720.

    • [ken] - Update to URI-5.10 (perl module). Fixes #15699.

  • November 9th, 2021

    • [pierre] - Update to libsoup-2.74.1. Fixes #15696.

    • [pierre] - Update to dhcpcd-9.4.1. Fixes #15694.

    • [pierre] - Update to libinput-1.19.2 (Xorg driver). Fixes #15692.

    • [pierre] - Update to nghttp2-1.46.0. Fixes #15689.

  • November 7th, 2021

    • [bdubbs] - Update to pcre2-10.39. Fixes #15716.

    • [pierre] - Update to icu4c-70.1. Fixes #15639.

  • November 6th, 2021

    • [ken] - Update to nss-3.72. Fixes #15711.

  • November 5th, 2021

    • [pierre] - Update to libcap-pam-2.60. Fixes #15695.

    • [pierre] - Update to autofs-5.1.8. Fixes #15687.

    • [pierre] - Update to gc-8.0.6. Fixes #15685.

    • [pierre] - Update to mpg123-1.29.2. Fixes #15683.

    • [pierre] - Update to xscreensaver-6.02. Fixes #15670.

  • November 2nd, 2021

    • [ken] - Update to firefox-91.3.0 (security fixes). Fixes #15722.

  • November 1st, 2021

    • [ken] - Archive firefox-legacy-78.15.0 which is now end of life.

  • October 30th, 2021

    • [pierre] - Update to asciidoc-10.0.1. Fixes #15714.

    • [pierre] - Update to python-dbusmock-0.24.1. Fixes #15708.

    • [pierre] - Update to mercurial-5.9.3. Fixes #15704.

    • [pierre] - Update to docutils-0.18. Fixes #15703.

  • October 29th, 2021

    • [timtas] - Update to dovecot-2.3.17. Fixes #15712.

    • [renodr] - Update to poppler-21.10.0. Fixes #15635.

    • [renodr] - Update to links-2.25. Fixes #15637.

    • [renodr] - Update to polkit-0.120. Fixes #15640.

    • [pierre] - Update to LVM2-2.03.14. Fixes #15690.

    • [pierre] - Update to apache-ant-1.10.12. Fixes #15688.

    • [pierre] - Update to v4l-utils-1.22.1. Fixes #15678.

  • October 28th, 2021

    • [ken] - Update to node.js-v16.13.0. Fixes #15702.

    • [ken] - Update to c-ares-1.18.1. Fixes #15700.

    • [pierre] - Update to asciidoc-10.0.0 (move to python modules). Fixes #15682.

    • [pierre] - Update to graphviz-2.49.3. Fixes #15680.

    • [pierre] - Update to valgrind-3.18.1. Fixes #15677.

    • [pierre] - Update to py3c-1.4 (python module). Fixes #15676.

    • [pierre] - Update to pidgin-2.14.8. Fixes #15674.

    • [pierre] - Update to glibmm-2.66.2. Fixes #15667.

    • [pierre] - Update to jansson-2.14. Fixes #15664.

    • [pierre] - Update to lsof-4.94.0. Fixes #15663.

  • October 27th, 2021

    • [renodr] - Update to BIND (and bind-utils) 9.16.22 (Security Update). Fixes #15706.

    • [renodr] - Update to samba-4.15.1 (Security Update). Fixes #15705.

    • [renodr] - Update to ffmpeg-4.4.1 (Security Update). Fixes #15697.

    • [renodr] - Update to exiv2-0.27.5 (Security Update). Fixes #15527.

    • [renodr] - Update to php-8.0.12 (Security Update). Fixes #15693.

  • October 26th, 2021

    • [renodr] - Update to webkitgtk-2.34.1. Fixes #15691.

    • [renodr] - Update to wpebackend-fdo-1.12.0. Fixes #15686.

    • [renodr] - Update to libwpe-1.12.0. Fixes #15347.

  • October 25th, 2021

    • [renodr] - Update to libreoffice-7.2.2.2. Fixes #15673.

    • [pierre] - Fix seamonkey for building with rustc-1.56.0. See #15634.

    • [pierre] - Update to rustc-1.56.0. Fixes #15634.

    • [pierre] - Update to LLVM-13.0.0. Fixes #15633.

    • [thomas] - Update to postgresql-14.0. Fixes #15631.

  • October 22nd, 2021

    • [ken] - Update to nss-3.71. Fixes #15630.

    • [timtas] - Document and add patch for PAM support to exim-4.95. Fixes #15624.

    • [pierre] - Change the download location for upower, so that it is not needed to run autogen.sh. Fixes #15675.

    • [pierre] - Update to udisks2-2.9.4. Fixes #15628.

    • [pierre] - Update to mesa-21.2.4. Fixes #15627.

    • [pierre] - Update to libvpx-1.11.0. Fixes #15625.

    • [pierre] - Update to exim-4.95. Fixes #15624.

  • October 21st, 2021

    • [renodr] - Update to ghostscript-9.55.0. Fixes #15622.

    • [renodr] - Update to thunderbird-91.2.1 (Security Update). Fixes #15621.

    • [renodr] - Update to seamonkey-2.53.9.1 (Security Update). Fixes #15620.

    • [renodr] - Update to inkscape-1.1.1. Fixes #15619.

  • October 20th, 2021

    • [renodr] - Update to libinput-1.19.1. Fixes #15618.

    • [renodr] - Update to openssh-8.8p1 (and ssh-askpass-8.8p1). Fixes #15617.

    • [renodr] - Update to cifs-utils-6.14. Fixes #15612.

    • [renodr] - Update to NetworkManager-1.32.12. Fixes #15601.

  • October 18th, 2021

    • [renodr] - Update to samba-4.15.0. Fixes #15578.

    • [renodr] - Fix CVE-2021-37750 in MIT krb5 per the suggestion in the Samba release notes for 4.15.0.

    • [renodr] - Update to mercurial-5.9.2. Fixes #15646.

  • October 16th, 2021

    • [ken] - Tidy some obsolete pcre references: php can use pcre2 not the original pcre, balsa and lightdm no longer reference pcre.

  • October 15th, 2021

    • [renodr] - Adapt cracklib to build with Python 3.10.

    • [renodr] - Adapt gpgme to build with Python 3.10.

  • October 14th, 2021

    • [bdubbs] - Upgrade to imlib2-1.7.4. Fixes #15373.

    • [bdubbs] - Upgrade to vim-8.2.3508. Fixes #15671.

    • [bdubbs] - Upgrade to Jinja2-3.0.2. Fixes #15645.

    • [bdubbs] - Upgrade to python3-3.10.0. Fixes #15641.

  • October 13th, 2021

    • [thomas] - Upgrade ristretto-0.12.0. Fixes #15666.

    • [thomas] - Upgrade git-2.33.1. Fixes #15669.

  • October 12th, 2021

    • [renodr] - Archive Rarian.

    • [ken] - Update to node.js-v14.18.1 (security fix). Fixes #15623.

    • [thomas] - Upgrade hexchat-2.16.0. Fixes #15636.

    • [timtas] - Update to openldap-2.5.8. Fixes #15665.

  • October 9th, 2021

    • [ken] - Patch qtwebengine to build with harfbuzz-3.0. Fixes #15660.

  • October 7th, 2021

    • [thomas] - Update to httpd-2.4.51. Fixes #15650.

    • [thomas] - Update to nano-5.9. Fixes #15642.

  • October 5th, 2021

    • [ken] - Update to JS-78.15.0 (js/src unchanged since 78.13.0), firefox-legacy-78.15.0 (Security Update) and firefox-91.2.0esr (Security Update). Fixes #15638.

  • October 1st, 2021

    • [bdubbs] - Archive haveged. Fixes #15629.

    • [bdubbs] - Update to libcap-2.59. Fixes #15567.

  • September 26th, 2021

    • [bdubbs] - Update to itstool-2.0.7. Fixes #15616.

    • [bdubbs] - Update to feh-3.7.2. Fixes #15615.

    • [bdubbs] - Update to DateTime-Calendar-Julian-0.106 (Perl module). Fixes #15614.

    • [thomas] - Update to php-8.0.11. Fixes #15611.

  • September 25th, 2021

    • [bdubbs] - Update to pipewire-0.3.37. Fixes #15613.

    • [bdubbs] - Update to graphviz-2.49.1. Fixes #15610.

    • [bdubbs] - Update to pycryptodome-3.10.4. Fixes #15607.

    • [bdubbs] - Update to libreoffice-7.2.1.2. Fixes #15553.

  • September 24th, 2021

    • [pierre] - Update to vte-0.66.0. Fixes #15608.

    • [pierre] - Update to curl-7.79.1. Fixes #15600.

    • [pierre] - Update to pidgin-2.14.7. Fixes #15564.

    • [pierre] - Update to thunderbird-91.1.1. Fixes #15554.

    • [thomas] - Update to mousepad-0.5.7. Fixes #15609.

  • September 23rd, 2021

    • [bdubbs] - Update to sudo-1.9.8p2. Fixes #15591.

    • [bdubbs] - Update to xterm-369. Fixes #15586.

    • [bdubbs] - Update to mesa-21.2.2. Fixes #15585.

    • [bdubbs] - Update to nghttp2-1.45.1. Fixes #15583.

    • [bdubbs] - Update to neon-0.32.1. Fixes #15582.

    • [bdubbs] - Update to btrfs-progs-v5.14.1. Fixes #15580.

  • September 22nd, 2021

    • [renodr] - Update to WebKitGTK+-2.34.0 (Security Update). Fixes #15560.

    • [ken] - Update to mutt-2.1.3. Fixes #15520.

    • [ken] - Update to fetchmail-6.4.22 (Security Fix). Fixes #15533.

    • [renodr] - Update to libhandy-1.4.0. Fixes #15498.

    • [renodr] - Update to gtksourceview-4.8.2. Fixes #15494.

    • [renodr] - Update to gtksourceview-5.2.0. Fixes #15495.

    • [renodr] - Update the gstreamer stack to 1.18.5. Fixes #15514.

  • September 21st, 2021

    • [renodr] - Update to poppler-21.09.0. Fixes #14592.

    • [renodr] - Update to poppler-data-0.4.11. Fixes #15508.

    • [ken] - Update to nss-4.70. Fixes #15510.

    • [thomas] - Update to cmake-3.21.3. Fixes #15581.

    • [bdubbs] - Update to xf86-input-libinput-1.2.0. Fixes #15577.

    • [bdubbs] - Update to asciidoc-9.1.1. Fixes #15575.

    • [bdubbs] - Update to thunar-4.16.10. Fixes #15566.

    • [bdubbs] - Update to vala-0.54.1. Fixes #15565.

    • [bdubbs] - Update to harfbuzz-3.0.0. Fixes #15559.

    • [bdubbs] - Update to libuninameslist-20210917. Fixes #15558.

    • [bdubbs] - Update to gobject-introspection-1.70.0. Fixes #15557.

  • September 18th, 2021

    • [pierre] - Update to gdb-11.1. Fixes #15529.

  • September 17th, 2021

    • [pierre] - Update to gucharmap-14.0.0. Fixes #15547.

    • [pierre] - Update to httpd-2.4.49 (Security Update). Fixes #15543.

    • [bdubbs] - Update to glib-networking-2.70.0. Fixes #15552.

    • [bdubbs] - Update to glib-2.70.0. Fixes #15556.

    • [bdubbs] - Update to bind9-9.16.21. Fixes #15541.

    • [bdubbs] - Update to pipewire-0.3.36. Fixes #15555.

    • [bdubbs] - Update to ModemManager-1.18.2. Fixes #15551.

    • [bdubbs] - Update to sudo-1.9.8p1. Fixes #15549.

    • [bdubbs] - Update to acpid-2.0.33. Fixes #15540.

    • [bdubbs] - Update to wayland-protocols-1.23. Fixes #15539.

    • [bdubbs] - Update to umockdev-0.16.3. Fixes #15538.

    • [bdubbs] - Update to qca-2.3.4. Fixes #15537.

    • [bdubbs] - Update to fftw-3.3.10. Fixes #15536.

  • September 16th, 2021

    • [bdubbs] - Update to librsvg-2.52.0. Fixes #15535.

    • [bdubbs] - Update to links-2.24. Fixes #15534.

    • [bdubbs] - Update to curl-7.79.0. Fixes #15542.

    • [bdubbs] - Update to libinput-1.19.0 (Xorg driver). Fixes #15545.

    • [bdubbs] - Update to libXi-1.8 (Xorg Library). Fixes #15544.

    • [bdubbs] - Update to xorgproto-2021.5. Fixes #15546.

    • [bdubbs] - Update to libatomic_ops-7.6.12. Fixes #15532.

    • [bdubbs] - Update to sudo-1.9.8. Fixes #15531.

    • [bdubbs] - Update to libass-0.15.2. Fixes #15530.

    • [bdubbs] - Update to libexif-0.6.23. Fixes #15528.

    • [bdubbs] - Update to ModemManager-1.18.0. Fixes #15515.

    • [bdubbs] - Archive python modules decorator and python-slip. Fixes #15525.

    • [bdubbs] - Update to Python3-3.9.7. Fixes #15485.

    • [bdubbs] - Update to libcap-2.57. Fixes #15465.

    • [dj] - Add --sbindir to Linux-PAM instruction to aid in packaging.

    • [dj] - Update to make-ca-1.9. Fixes #15548.

    • [dj] - Update download locations for blocaled and LSB-Tools.

  • September 15th, 2021

    • [renodr] - Update to gimp-2.10.28. Fixes #15502.

    • [renodr] - Update to libdazzle-3.42.0. Fixes #15496.

  • September 14th, 2021

    • [renodr] - Update to wayland-protocols-1.22. Fixes #15491.

  • September 12th, 2021

    • [pierre] - Update to thunar-4.16.9. Fixes #15524.

    • [pierre] - Update to pango-1.48.10. Fixes #15523.

    • [pierre] - Update to gexiv2-0.13.0. Fixes #15444.

  • September 11th, 2021

    • [bdubbs] - Update to btrfs-progs-v5.14. Fixes #15518.

    • [bdubbs] - Update to libxkbcommon-1.3.1. Fixes #15519.

    • [bdubbs] - Update to pipewire-0.3.35. Fixes #15516.

    • [renodr] - Update to fuse-3.10.5. Fixes #15506.

  • September 10th, 2021

    • [ken] - Patch ghostscript for CVE-2021-3781 0-day (security update re libgs). Thanks to Doug for helping me understand the public PoC. Fixes #15517.

    • [renodr] - Update to libseccomp-2.5.2. Fixes #15490.

    • [pierre] - Update to thunderbird-91.1.0 (Security Update). Fixes #15513.

  • September 9th, 2021

    • [bdubbs] - Update to wget-1.21.2. Fixes #15512.

    • [bdubbs] - Update to harfbuzz-2.9.1. Fixes #15511.

    • [bdubbs] - Update to soundtouch-2.3.1. Fixes #15509.

    • [bdubbs] - Update to libqmi-1.30.2. Fixes #15507.

  • September 8th, 2021

    • [renodr] - Update to Mercurial-5.9.1. Fixes #15481.

  • September 7th, 2021

    • [bdubbs] - Update to sane-backends-1.0.32. Fixes #15504.

    • [bdubbs] - Update to libsamplerate-0.2.2. Fixes #15503.

    • [bdubbs] - Update to libxfce4ui-4.16.1. Fixes #15501.

    • [bdubbs] - Update to DateTime-Calendar-Julian-0.105 (Perl module). Fixes #15500.

    • [bdubbs] - Update to gegl-0.4.32. Fixes #15499.

    • [ken] - Update to JS-78.14.0 (js/src is identical to 78.13.0), firefox-legacy-78.14.0 (Security Update) and firefox-91.1.0esr (Security Update). Fixes #15505.

  • September 6th, 2021

    • [renodr] - Update to node.js-14.17.6 (Security Update). Fixes #15488.

    • [renodr] - Update to libwacom-1.12. Fixes #15487.

    • [renodr] - Update to nss-3.69.1. Fixes #15486.

    • [renodr] - Update to libssh2-1.10.0. Fixes #15481.

    • [renodr] - Update to python-dbusmock-0.24.0. Fixes #15477.

    • [renodr] - Update to graphviz-2.49.0. Fixes #15476.

  • September 5th, 2021

    • [pierre] - Update to Linux-PAM-1.5.2. Fixes #15497.

  • September 3rd, 2021

    • [renodr] - Update to libnsl-2.0.0. Fixes #15410.

    • [dj] - Update to make-ca-1.8.1. Fixes #15475.

  • September 1st, 2021

    • [bdubbs] - Release of BLFS-11.0.

Last updated on

Mailing Lists

The linuxfromscratch.org server is hosting a number of mailing lists that are used for the development of the BLFS book. These lists include, among others, the main development and support lists.

For more information regarding which lists are available, how to subscribe to them, archive locations, etc., visit https://www.linuxfromscratch.org/mail.html.

Last updated on

BLFS Wiki

The BLFS Project has created a Wiki for users to comment on pages and instructions at https://wiki.linuxfromscratch.org/blfs/wiki. Comments are welcome from all users.

The following are the rules for posting:

  • Users must register and log in to edit a page.

  • Suggestions to change the book should be made by creating a new ticket, not by making comments in the Wiki.

  • Questions with your specific installation problems should be made by subscribing and mailing to the BLFS Support Mailing List at mailto:blfs-support AT linuxfromscratch D0T org.

  • Discussions of build instructions should be made by subscribing and mailing to the BLFS Development List at mailto:blfs-dev AT linuxfromscratch D0T org.

  • Inappropriate material will be removed.

Last updated on

Asking for Help and the FAQ

If you encounter a problem while using this book, and your problem is not listed in the FAQ (https://www.linuxfromscratch.org/faq), you will find that most of the people on Internet Relay Chat (IRC) and on the mailing lists are willing to help you. An overview of the LFS mailing lists can be found in Mailing lists. To assist us in diagnosing and solving your problem, include as much relevant information as possible in your request for help.

Things to Check Prior to Asking

Before asking for help, you should review the following items:

  • Is the hardware support compiled into the kernel or available as a module to the kernel? If it is a module, is it configured properly in modprobe.conf and has it been loaded? You should use lsmod as the root user to see if it's loaded. Check the sys.log file or run modprobe <driver> to review any error message. If it loads properly, you may need to add the modprobe command to your boot scripts.

  • Are your permissions properly set, especially for devices? LFS uses groups to make these settings easier, but it also adds the step of adding users to groups to allow access. A simple usermod -G audio <user> may be all that's necessary for that user to have access to the sound system. Any question that starts out with It works as root, but not as ... requires a thorough review of permissions prior to asking.

  • BLFS liberally uses /opt/<package>. The main objection to this centers around the need to expand your environment variables for each package placed there (e.g., PATH=$PATH:/opt/kde/bin). In most cases, the package instructions will walk you through the changes, but some will not. The section called Going Beyond BLFS is available to help you check.

Things to Mention

Apart from a brief explanation of the problem you're having, the essential things to include in your request are:

  • the version of the book you are using (being 11.1),

  • the package or section giving you problems,

  • the exact error message or symptom you are receiving,

  • whether you have deviated from the book or LFS at all,

  • if you are installing a BLFS package on a non-LFS system.

(Note that saying that you've deviated from the book doesn't mean that we won't help you. It'll just help us to see other possible causes of your problem.)

Expect guidance instead of specific instructions. If you are instructed to read something, please do so. It generally implies that the answer was way too obvious and that the question would not have been asked if a little research was done prior to asking. The volunteers in the mailing list prefer not to be used as an alternative to doing reasonable research on your end. In addition, the quality of your experience with BLFS is also greatly enhanced by this research, and the quality of volunteers is enhanced because they don't feel that their time has been abused, so they are far more likely to participate.

An excellent article on asking for help on the Internet in general has been written by Eric S. Raymond. It is available online at http://www.catb.org/~esr/faqs/smart-questions.html. Read and follow the hints in that document and you are much more likely to get a response to start with and also to get the help you actually need.

Last updated on

Credits

Many people have contributed both directly and indirectly to BLFS. This page lists all of those we can think of. We may well have left people out and if you feel this is the case, drop us a line. Many thanks to all of the LFS community for their assistance with this project.

Current Editors

  • Bruce Dubbs

  • Pierre Labastie

  • DJ Lucas

  • Ken Moffat

  • Douglas Reno

Contributors and Past Editors

The list of contributors is far too large to provide detailed information about the contributions for each contributor. Over the years, the following individuals have provided significant inputs to the book:

  • Timothy Bauscher

  • Daniel Bauman

  • Jeff Bauman

  • Andy Benton

  • Wayne Blaszczyk

  • Paul Campbell

  • Nathan Coulson

  • Jeroen Coumans

  • Guy Dalziel

  • Robert Daniels

  • Richard Downing

  • Manuel Canales Esparcia

  • Jim Gifford

  • Manfred Glombowski

  • Ag Hatzimanikas

  • Mark Hymers

  • James Iwanek

  • David Jensen

  • Jeremy Jones

  • Seth Klein

  • Alex Kloss

  • Eric Konopka

  • Larry Lawrence

  • Chris Lynn

  • Andrew McMurry

  • Randy McMurchy

  • Denis Mugnier

  • Billy O'Connor

  • Fernando de Oliveira

  • Alexander Patrakov

  • Olivier Peres

  • Andreas Pedersen

  • Henning Rohde

  • Matt Rogers

  • James Robertson

  • Henning Rohde

  • Chris Staub

  • Jesse Tie-Ten-Quee

  • Ragnar Thomsen

  • Thomas Trepl

  • Tushar Teredesai

  • Jeremy Utley

  • Zack Winkles

  • Christian Wurst

  • Igor Živković

General Acknowledgments

  • Fernando Arbeiza

  • Miguel Bazdresch

  • Gerard Beekmans

  • Oliver Brakmann

  • Jeremy Byron

  • Ian Chilton

  • David Ciecierski

  • Jim Harris

  • Lee Harris

  • Marc Heerdink

  • Steffen Knollmann

  • Eric Konopka

  • Scot McPherson

  • Ted Riley

Last updated on

Contact Information

Please direct your emails to one of the BLFS mailing lists. See Mailing lists for more information on the available mailing lists.

Last updated on

Chapter 2. Important Information

This chapter is used to explain some of the policies used throughout the book, to introduce important concepts and to explain some issues you may see with some of the included packages.

Notes on Building Software

Those people who have built an LFS system may be aware of the general principles of downloading and unpacking software. Some of that information is repeated here for those new to building their own software.

Each set of installation instructions contains a URL from which you can download the package. The patches; however, are stored on the LFS servers and are available via HTTP. These are referenced as needed in the installation instructions.

While you can keep the source files anywhere you like, we assume that you have unpacked the package and changed into the directory created by the unpacking process (the 'build' directory). We also assume you have uncompressed any required patches and they are in the directory immediately above the 'build' directory.

We can not emphasize strongly enough that you should start from a clean source tree each time. This means that if you have had an error during configuration or compilation, it's usually best to delete the source tree and re-unpack it before trying again. This obviously doesn't apply if you're an advanced user used to hacking Makefiles and C code, but if in doubt, start from a clean tree.

Building Software as an Unprivileged (non-root) User

The golden rule of Unix System Administration is to use your superpowers only when necessary. Hence, BLFS recommends that you build software as an unprivileged user and only become the root user when installing the software. This philosophy is followed in all the packages in this book. Unless otherwise specified, all instructions should be executed as an unprivileged user. The book will advise you on instructions that need root privileges.

Unpacking the Software

If a file is in .tar format and compressed, it is unpacked by running one of the following commands:

tar -xvf filename.tar.gz
tar -xvf filename.tgz
tar -xvf filename.tar.Z
tar -xvf filename.tar.bz2

Note

You may omit using the v parameter in the commands shown above and below if you wish to suppress the verbose listing of all the files in the archive as they are extracted. This can help speed up the extraction as well as make any errors produced during the extraction more obvious to you.

You can also use a slightly different method:

bzcat filename.tar.bz2 | tar -xv

Finally, you sometimes need to be able to unpack patches which are generally not in .tar format. The best way to do this is to copy the patch file to the parent of the 'build' directory and then run one of the following commands depending on whether the file is a .gz or .bz2 file:

gunzip -v patchname.gz
bunzip2 -v patchname.bz2

Verifying File Integrity

Generally, to verify that the downloaded file is complete, many package maintainers also distribute md5sums of the files. To verify the md5sum of the downloaded files, download both the file and the corresponding md5sum file to the same directory (preferably from different on-line locations), and (assuming file.md5sum is the md5sum file downloaded) run the following command:

md5sum -c file.md5sum

If there are any errors, they will be reported. Note that the BLFS book includes md5sums for all the source files also. To use the BLFS supplied md5sums, you can create a file.md5sum (place the md5sum data and the exact name of the downloaded file on the same line of a file, separated by white space) and run the command shown above. Alternately, simply run the command shown below and compare the output to the md5sum data shown in the BLFS book.

md5sum <name_of_downloaded_file>

MD5 is not cryptographically secure, so the md5sums are only provided for detecting unmalicious changes to the file content. For example, an error or truncation introduced during network transfer, or a stealth update to the package from the upstream (updating the content of a released tarball instead of making a new release properly).

There is no 100% secure way to make sure the genuity of the source files. Assuming the upstream is managing their website correctly (the private key is not leaked and the domain is not hijacked), and the trust anchors have been set up correctly using make-ca-1.10 on the BLFS system, we can reasonably trust download URLs to the upstream official website with https protocol. Note that BLFS book itself is published on a website with https, so you should already have some confidence in https protocol or you wouldn't trust the book content.

If the package is downloaded from an unofficial location (for example a local mirror), checksums generated by cryptographically secure digest algorithms (for example SHA256) can be used to verify the genuity of the package. Download the checksum file from the upstream official website (or somewhere you can trust) and compare the checksum of the package from unofficial location with it. For example, SHA256 checksum can be checked with the command:

Note

If the checksum and the package are downloaded from the same untrusted location, you won't gain security enhancement by verifying the package with the checksum. The attacker can fake the checksum as well as compromising the package itself.

sha256sum -c file.sha256sum

If GnuPG-2.2.34 is installed, you can also verify the genuity of the package with a GPG signature. Import the upstream GPG public key with:

gpg --recv-key keyID

keyID should be replaced with the key ID from somewhere you can trust (for example, copy it from the upstream official website using https). Now you can verify the signature with:

gpg --recv-key file.sig file

The advantage of GnuPG signature is, once you imported a public key which can be trusted, you can download both the package and its signature from the same unofficial location and verify them with the public key. So you won't need to connect to the official upstream website to retrieve a checksum for each new release. You only need to update the public key if it's expired or revoked.

Creating Log Files During Installation

For larger packages, it is convenient to create log files instead of staring at the screen hoping to catch a particular error or warning. Log files are also useful for debugging and keeping records. The following command allows you to create an installation log. Replace <command> with the command you intend to execute.

( <command> 2>&1 | tee compile.log && exit $PIPESTATUS )

2>&1 redirects error messages to the same location as standard output. The tee command allows viewing of the output while logging the results to a file. The parentheses around the command run the entire command in a subshell and finally the exit $PIPESTATUS command ensures the result of the <command> is returned as the result and not the result of the tee command.

Using Multiple Processors

For many modern systems with multiple processors (or cores) the compilation time for a package can be reduced by performing a "parallel make" by either setting an environment variable or telling the make program how many processors are available. For instance, a Core2Duo can support two simultaneous processes with:

export MAKEFLAGS='-j2'

or just building with:

make -j2

If you have applied the optional sed when building ninja in LFS, you can use:

export NINJAJOBS=2

when a package uses ninja, or just:

ninja -j2

but for ninja, the default number of jobs is <N>+2, where <N> is the number of processors available, so that using the above commands is rather for limiting the number of jobs (see below for why this could be necessary).

Generally the number of processes should not exceed the number of cores supported by the CPU. To list the processors on your system, issue: grep processor /proc/cpuinfo.

In some cases, using multiple processes may result in a 'race' condition where the success of the build depends on the order of the commands run by the make program. For instance, if an executable needs File A and File B, attempting to link the program before one of the dependent components is available will result in a failure. This condition usually arises because the upstream developer has not properly designated all the prerequisites needed to accomplish a step in the Makefile.

If this occurs, the best way to proceed is to drop back to a single processor build. Adding '-j1' to a make command will override the similar setting in the MAKEFLAGS environment variable.

Note

When running the package tests or the install portion of the package build process, we do not recommend using an option greater than '-j1' unless specified otherwise. The installation procedures or checks have not been validated using parallel procedures and may fail with issues that are difficult to debug.

Important

Another problem may occur with modern CPU's, which have a lot of cores. Each job started consumes memory, and if the sum of the needed memory for each job exceeds the available memory, you may encounter either an OOM (Out of Memory) kernel interrupt or intense swapping that will slow the build beyond reasonable limits.

Some compilations with g++ may consume up to 2.5 GB of memory, so to be safe, you should restrict the number of jobs to (Total Memory in GB)/2.5, at least for big packages such as LLVM, WebKitGtk, QtWebEngine, or libreoffice.

Automated Building Procedures

There are times when automating the building of a package can come in handy. Everyone has their own reasons for wanting to automate building, and everyone goes about it in their own way. Creating Makefiles, Bash scripts, Perl scripts or simply a list of commands used to cut and paste are just some of the methods you can use to automate building BLFS packages. Detailing how and providing examples of the many ways you can automate the building of packages is beyond the scope of this section. This section will expose you to using file redirection and the yes command to help provide ideas on how to automate your builds.

File Redirection to Automate Input

You will find times throughout your BLFS journey when you will come across a package that has a command prompting you for information. This information might be configuration details, a directory path, or a response to a license agreement. This can present a challenge to automate the building of that package. Occasionally, you will be prompted for different information in a series of questions. One method to automate this type of scenario requires putting the desired responses in a file and using redirection so that the program uses the data in the file as the answers to the questions.

Building the CUPS package is a good example of how redirecting a file as input to prompts can help you automate the build. If you run the test suite, you are asked to respond to a series of questions regarding the type of test to run and if you have any auxiliary programs the test can use. You can create a file with your responses, one response per line, and use a command similar to the one shown below to automate running the test suite:

make check < ../cups-1.1.23-testsuite_parms

This effectively makes the test suite use the responses in the file as the input to the questions. Occasionally you may end up doing a bit of trial and error determining the exact format of your input file for some things, but once figured out and documented you can use this to automate building the package.

Using yes to Automate Input

Sometimes you will only need to provide one response, or provide the same response to many prompts. For these instances, the yes command works really well. The yes command can be used to provide a response (the same one) to one or more instances of questions. It can be used to simulate pressing just the Enter key, entering the Y key or entering a string of text. Perhaps the easiest way to show its use is in an example.

First, create a short Bash script by entering the following commands:

cat > blfs-yes-test1 << "EOF"
#!/bin/bash

echo -n -e "\n\nPlease type something (or nothing) and press Enter ---> "

read A_STRING

if test "$A_STRING" = ""; then A_STRING="Just the Enter key was pressed"
else A_STRING="You entered '$A_STRING'"
fi

echo -e "\n\n$A_STRING\n\n"
EOF
chmod 755 blfs-yes-test1

Now run the script by issuing ./blfs-yes-test1 from the command line. It will wait for a response, which can be anything (or nothing) followed by the Enter key. After entering something, the result will be echoed to the screen. Now use the yes command to automate the entering of a response:

yes | ./blfs-yes-test1

Notice that piping yes by itself to the script results in y being passed to the script. Now try it with a string of text:

yes 'This is some text' | ./blfs-yes-test1

The exact string was used as the response to the script. Finally, try it using an empty (null) string:

yes '' | ./blfs-yes-test1

Notice this results in passing just the press of the Enter key to the script. This is useful for times when the default answer to the prompt is sufficient. This syntax is used in the Net-tools instructions to accept all the defaults to the many prompts during the configuration step. You may now remove the test script, if desired.

File Redirection to Automate Output

In order to automate the building of some packages, especially those that require you to read a license agreement one page at a time, requires using a method that avoids having to press a key to display each page. Redirecting the output to a file can be used in these instances to assist with the automation. The previous section on this page touched on creating log files of the build output. The redirection method shown there used the tee command to redirect output to a file while also displaying the output to the screen. Here, the output will only be sent to a file.

Again, the easiest way to demonstrate the technique is to show an example. First, issue the command:

ls -l /usr/bin | more

Of course, you'll be required to view the output one page at a time because the more filter was used. Now try the same command, but this time redirect the output to a file. The special file /dev/null can be used instead of the filename shown, but you will have no log file to examine:

ls -l /usr/bin | more > redirect_test.log 2>&1

Notice that this time the command immediately returned to the shell prompt without having to page through the output. You may now remove the log file.

The last example will use the yes command in combination with output redirection to bypass having to page through the output and then provide a y to a prompt. This technique could be used in instances when otherwise you would have to page through the output of a file (such as a license agreement) and then answer the question of do you accept the above?. For this example, another short Bash script is required:

cat > blfs-yes-test2 << "EOF"
#!/bin/bash

ls -l /usr/bin | more

echo -n -e "\n\nDid you enjoy reading this? (y,n) "

read A_STRING

if test "$A_STRING" = "y"; then A_STRING="You entered the 'y' key"
else A_STRING="You did NOT enter the 'y' key"
fi

echo -e "\n\n$A_STRING\n\n"
EOF
chmod 755 blfs-yes-test2

This script can be used to simulate a program that requires you to read a license agreement, then respond appropriately to accept the agreement before the program will install anything. First, run the script without any automation techniques by issuing ./blfs-yes-test2.

Now issue the following command which uses two automation techniques, making it suitable for use in an automated build script:

yes | ./blfs-yes-test2 > blfs-yes-test2.log 2>&1

If desired, issue tail blfs-yes-test2.log to see the end of the paged output, and confirmation that y was passed through to the script. Once satisfied that it works as it should, you may remove the script and log file.

Finally, keep in mind that there are many ways to automate and/or script the build commands. There is not a single correct way to do it. Your imagination is the only limit.

Dependencies

For each package described, BLFS lists the known dependencies. These are listed under several headings, whose meaning is as follows:

  • Required means that the target package cannot be correctly built without the dependency having first been installed.

  • Recommended means that BLFS strongly suggests this package is installed first for a clean and trouble-free build, that won't have issues either during the build process, or at run-time. The instructions in the book assume these packages are installed. Some changes or workarounds may be required if these packages are not installed.

  • Optional means that this package might be installed for added functionality. Often BLFS will describe the dependency to explain the added functionality that will result.

Using the Most Current Package Sources

On occasion you may run into a situation in the book when a package will not build or work properly. Though the Editors attempt to ensure that every package in the book builds and works properly, sometimes a package has been overlooked or was not tested with this particular version of BLFS.

If you discover that a package will not build or work properly, you should see if there is a more current version of the package. Typically this means you go to the maintainer's web site and download the most current tarball and attempt to build the package. If you cannot determine the maintainer's web site by looking at the download URLs, use Google and query the package's name. For example, in the Google search bar type: 'package_name download' (omit the quotes) or something similar. Sometimes typing: 'package_name home page' will result in you finding the maintainer's web site.

Stripping One More Time

Warning

If you did not strip programs and libraries in LFS, the following will probably make your system unusable. To avoid that, run the instructions at ../../../../lfs/view/11.1/chapter08/strippingagain.html instead. After the critical files are stripped using those instructions, the instructions below can be run any time new packages are installed.

In LFS, stripping of debugging symbols was discussed a couple of times. When building BLFS packages, there are generally no special instructions that discuss stripping again. It is probably not a good idea to strip an executable or a library while it is in use, so exiting any windowing environment is a good idea. Then you can do:

find /usr/{bin,lib,sbin} \
    -type f \( -name \*.so* -a ! -name \*dbg \) \
    -exec strip --strip-unneeded {} \;

If you install programs in other directories such as /opt or /usr/local, you may want to strip the files there too.

For more information on stripping, see http://www.technovelty.org/linux/stripping-shared-libraries.html.

Working with different build systems

There are now three different build systems in common use for converting C or C++ source code into compiled programs or libraries and their details (particularly, finding out about available options and their default values) differ. It may be easiest to understand the issues caused by some choices (typically slow execution or unexpected use of, or omission of, optimizatons) by starting with the CFLAGS and CXXFLAGS environment variables. There are also some programs which use rust.

Most LFS and BLFS builders are probably aware of the basics of CFLAGS and CXXFLAGS for altering how a program is compiled. Typically, some form of optimization is used by upstream developers (-O2 or -O3), sometimes with the creation of debug symbols (-g), as defaults.

If there are contradictory flags (e.g. multiple different -O values), the last value will be used. Sometimes this means that flags specified in environment variables will be picked up before values hardcoded in the Makefile, and therefore ignored. For example, where a user specifies '-O2' and that is followed by '-O3' the build will use '-O3'.

There are various other things which can be passed in CFLAGS or CXXFLAGS, such as forcing compilation for a specific microarchitecture (e.g. -march=amdfam10, -march=native) or specifying a specific standard for C or C++ (-std=c++17 for example). But one thing which has now come to light is that programmers might include debug assertions in their code, expecting them to be disabled in releases by using -DNDEBUG. Specifically, if Mesa-21.3.6 is built with these assertions enabled, some activities such as loading levels of games can take extremely long times, even on high-class video cards.

Autotools with Make

This combination is often described as 'CMMI' (configure, make, make install) and is used here to also cover the few packages which have a configure script that is not generated by autotools.

Sometimes running ./configure --help will produce useful options about switches which might be used. At other times, after looking at the output from configure you may need to look at the details of the script to find out what it was actually searching for.

Many configure scripts will pick up any CFLAGS or CXXFLAGS from the environment, but CMMI packages vary about how these will be mixed with any flags which would otherwise be used (variously: ignored, used to replace the programmer's suggestion, used before the programmer's suggestion, or used after the programmer's suggestion).

In most CMMI packages, running 'make' will list each command and run it, interspersed with any warnings. But some packages try to be 'silent' and only show which file they are compiling or linking instead of showing the command line. If you need to inspect the command, either because of an error, or just to see what options and flags are being used, adding 'V=1' to the make invocation may help.

CMake

CMake works in a very different way, and it has two backends which can be used on BLFS: 'make' and 'ninja'. The default backend is make, but ninja can be faster on large packages with multiple processors. To use ninja, specify '-G Ninja' in the cmake command. However, there are some packages which create fatal errors in their ninja files but build successfully using the default of Unix Makefiles.

The hardest part of using CMake is knowing what options you might wish to specify. The only way to get a list of what the package knows about is to run cmake -LAH and look at the output for that default configuration.

Perhaps the most-important thing about CMake is that it has a variety of CMAKE_BUILD_TYPE values, and these affect the flags. The default is that this is not set and no flags are generated. Any CFLAGS or CXXFLAGS in the environment will be used. If the programmer has coded any debug assertions, those will be enabled unless -DNDEBUG is used. The following CMAKE_BUILD_TYPE values will generate the flags shown, and these will come after any flags in the environment and therefore take precedence.

  • Debug : '-g'

  • Release : '-O3 -DNDEBUG'

  • RelWithDebInfo : '-O2 -g -DNDEBUG'

  • MinSizeRel : '-Os -DNDEBUG'

CMake tries to produce quiet builds. To see the details of the commands which are being run, use 'make VERBOSE=1' or 'ninja -v'.

Meson

Meson has some similarities to CMake, but many differences. To get details of the defines that you may wish to change you can look at meson_options.txt which is usually in the top-level directory.

If you have already configured the package by running meson and now wish to change one or more settings, you can either remove the build directory, recreate it, and use the altered options, or within the build directory run meson configure, e.g. to set an option:

meson configure -D<some_option>=true

If you do that, the file meson-private/cmd_line.txt will show the last commands which were used.

Meson provides the following buildtype values, and the flags they enable come after any flags supplied in the environment and therefore take precedence.

  • plain : no added flags. This is for distributors to supply their own CLFAGS, CXXFLAGS and LDFLAGS. There is no obvious reason to use this in BLFS.

  • debug : '-g' - this is the default if nothing is specified in either meson.build or the command line. However it results large and slow binaries, so we should override it in BLFS.

  • debugoptimized : '-O2 -g' : this is the default specified in meson.build of some packages.

  • release : '-O3 -DNDEBUG' (but occasionally a package will force -O2 here)

Although the 'release' buildtype is described as enabling -DNDEBUG, and all CMake Release builds pass that, it has so far only been observed (in verbose builds) for Mesa-21.3.6. That suggests that it might only be used when there are debug assertions present.

The -DNDEBUG flag can also be provided by passing -Db_ndebug=true.

To see the details of the commands which are being run in a package using meson, use 'ninja -v'.

Rustc and Cargo

Most released rustc programs are provided as crates (source tarballs) which will query a server to check current versions of dependencies and then download them as necessary. These packages are built using cargo --release. In theory, you can manipulate the RUSTFLAGS to change the optimize-level (default is 3, like -O3, e.g. -Copt-level=3) or to force it to build for the machine it is being compiled on, using -Ctarget-cpu=native but in practice this seems to make no significant difference.

If you find an interesting rustc program which is only provided as unpackaged source, you should at least specify RUSTFLAGS=-Copt-level=2 otherwise it will do an unoptimized compile with debug info and run much slower.

The rust developers seem to assume that everyone will compile on a machine dedicated to producing builds, so by default all CPUs are used. This can often be worked around, either by exporting CARGO_BUILD_JOBS=<N> or passing --jobs <N> to cargo. For compiling rustc itself, specifying --jobs <N> on invocations of x.py (together with the CARGO_BUILD_JOBS environment variable, which looks like a "belt and braces" approach but seems to be necessary) mostly works. The exception is running the tests when building rustc, some of them will nevertheless use all online CPUs, at least as of rustc-1.42.0.

Optimizing the build

Many people will prefer to optimize compiles as they see fit, by providing CFLAGS or CXXFLAGS. For an introduction to the options available with gcc and g++ see https://gcc.gnu.org/onlinedocs/gcc/Optimize-Options.html and https://gcc.gnu.org/onlinedocs/gcc/Instrumentation-Options.html and info gcc.

Some packages default to '-O2 -g', others to '-O3 -g', and if CFLAGS or CXXFLAGS are supplied they might be added to the package's defaults, replace the package's defaults, or even be ignored. There are details on some desktop packages which were mostly current in April 2019 at https://www.linuxfromscratch.org/~ken/tuning/ - in particular, README.txt, tuning-1-packages-and-notes.txt, and tuning-notes-2B.txt. The particular thing to remember is that if you want to try some of the more interesting flags you may need to force verbose builds to confirm what is being used.

Clearly, if you are optimizing your own program you can spend time to profile it and perhaps recode some of it if it is too slow. But for building a whole system that approach is impractical. In general, -O3 usually produces faster programs than -O2. Specifying -march=native is also beneficial, but means that you cannot move the binaries to an incompatible machine - this can also apply to newer machines, not just to older machines. For example programs compiled for 'amdfam10' run on old Phenoms, Kaveris, and Ryzens : but programs compiled for a Kaveri will not run on a Ryzen because certain op-codes are not present. Similarly, if you build for a Haswell not everything will run on a SandyBridge.

There are also various other options which some people claim are beneficial. At worst, you get to recompile and test, and then discover that in your usage the options do not provide a benefit.

If building Perl or Python modules, or Qt packages which use qmake, in general the CFLAGS and CXXFLAGS used are those which were used by those 'parent' packages.

Options for hardening the build

Even on desktop systems, there are still a lot of exploitable vulnerabilities. For many of these, the attack comes via javascript in a browser. Often, a series of vulnerabilities are used to gain access to data (or sometimes to pwn, i.e. own, the machine and install rootkits). Most commercial distros will apply various hardening measures.

For hardening options which are reasonably cheap, there is some discussion in the 'tuning' link above (occasionally, one or more of these options might be inappropriate for a package). These options are -D_FORTIFY_SOURCE=2, -fstack-protector=strong, and (for C++) -D_GLIBCXX_ASSERTIONS. On modern machines these should only have a little impact on how fast things run, and often they will not be noticeable.

In the past, there was Hardened LFS where gcc (a much older version) was forced to use hardening (with options to turn some of it off on a per-package basis. What is being covered here is different - first you have to make sure that the package is indeed using your added flags and not over-riding them.

The main distros use much more, such as RELRO (Relocation Read Only) and perhaps -fstack-clash-protection. You may also encounter the so-called 'userspace retpoline' (-mindirect-branch=thunk etc.) which is the equivalent of the spectre mitigations applied to the linux kernel in late 2018). The kernel mitigations caused a lot of complaints about lost performance, if you have a production server you might wish to consider testing that, along with the other available options, to see if performance is still sufficient.

Whilst gcc has many hardening options, clang/LLVM's strengths lie elsewhere. Some options which gcc provides are said to be less effective in clang/LLVM.

Last updated on

The /usr Versus /usr/local Debate

Should I install XXX in /usr or /usr/local?

This is a question without an obvious answer for an LFS based system.

In traditional Unix systems, /usr usually contains files that come with the system distribution, and the /usr/local tree is free for the local administrator to manage. The only really hard and fast rule is that Unix distributions should not touch /usr/local, except perhaps to create the basic directories within it.

With Linux distributions like Red Hat, Debian, etc., a possible rule is that /usr is managed by the distribution's package system and /usr/local is not. This way the package manager's database knows about every file within /usr.

LFS users build their own system and so deciding where the system ends and local files begin is not straightforward. So the choice should be made in order to make things easier to administer. There are several reasons for dividing files between /usr and /usr/local.

  • On a network of several machines all running LFS, or mixed LFS and other Linux distributions, /usr/local could be used to hold packages that are common between all the computers in the network. It can be NFS mounted or mirrored from a single server. Here local indicates local to the site.

  • On a network of several computers all running an identical LFS system, /usr/local could hold packages that are different between the machines. In this case local refers to the individual computers.

  • Even on a single computer, /usr/local can be useful if you have several distributions installed simultaneously, and want a place to put packages that will be the same on all of them.

  • Or you might regularly rebuild your LFS, but want a place to put files that you don't want to rebuild each time. This way you can wipe the LFS file system and start from a clean partition every time without losing everything.

Some people ask why not use your own directory tree, e.g., /usr/site, rather than /usr/local?

There is nothing stopping you, many sites do make their own trees, however it makes installing new software more difficult. Automatic installers often look for dependencies in /usr and /usr/local, and if the file it is looking for is in /usr/site instead, the installer will probably fail unless you specifically tell it where to look.

What is the BLFS position on this?

All of the BLFS instructions install programs in /usr with optional instructions to install into /opt for some specific packages.

Last updated on

Optional Patches

As you follow the various sections in the book, you will observe that the book occasionally includes patches that are required for a successful and secure installation of the packages. The general policy of the book is to include patches that fall in one of the following criteria:

  • Fixes a compilation problem.

  • Fixes a security problem.

  • Fixes a broken functionality.

In short, the book only includes patches that are either required or recommended. There is a Patches subproject which hosts various patches (including the patches referenced in the books) to enable you to configure your LFS the way you like it.

Last updated on

BLFS Boot Scripts

The BLFS Bootscripts package contains the init scripts that are used throughout the book. It is assumed that you will be using the BLFS Bootscripts package in conjunction with a compatible LFS-Bootscripts package. Refer to ../../../../lfs/view/11.1/chapter09/bootscripts.html for more information on the LFS-Bootscripts package.

The BLFS Bootscripts package will be used throughout the BLFS book for startup scripts. Unlike LFS, each init script has a separate install target in the BLFS Bootscripts package. It is recommended you keep the package source directory around until completion of your BLFS system. When a script is requested from BLFS Bootscripts, simply change to the directory and as the root user, execute the given make install-<init-script> command. This command installs the init script to its proper location (along with any auxiliary configuration scripts) and also creates the appropriate symlinks to start and stop the service at the appropriate run-level.

Note

You should review each bootscript before installation to ascertain that it satisfies your need. Also verify that the start and stop symlinks it creates match your preferences.

Note

From time to time the bootscripts are updated to accommodate new packages or to make minor corrections. All versions of the bootscripts are located at https://anduin.linuxfromscratch.org/BLFS/blfs-bootscripts/.

Last updated on

About Libtool Archive (.la) files

Files with a .la extension

In LFS we installed a package, libtool, that is used by many packages to build on a variety of Unix platforms. This includes platforms such as AIX, Solaris, IRIX, HP-UX, and Cygwin as well as Linux. The origins of this tool are quite dated. It was intended to manage libraries on systems with less advanced capabilities than a modern Linux system.

On a Linux system, libtool specific files are generally unneeded. Normally libraries are specified in the build process during the link phase. Since a linux system uses the Executable and Linkable Format (ELF) for executables and libraries, information needed to complete the task is embedded in the files. At run time the program loader can query the appropriate files and properly load and execute the program.

The problem is that libtool usually creates one or more text files for package libraries called libtool archives. These small files have a ".la" extension and contain information that is similar to that embedded in the libraries. When building a package that uses libtool, the process automatically looks for these files. If a package is updated and no longer uses the .la file, then the build process can break.

The solution is to remove the .la files. However there is a catch. Some packages, such as ImageMagick-7.1.0-25, use a libtool function, lt_dlopen, to load libraries as needed during execution and resolve their dependencies at run time. In this case, the .la files should remain.

The script below, removes all unneeded .la files and saves them in a directory, /var/local/la-files by default, not in the normal library path. It also searches all pkg-config files (.pc) for embedded references to .la files and fixes them to be conventional library references needed when an application or library is built. It can be run as needed to clean up the directories that may be causing problems.

cat > /usr/sbin/remove-la-files.sh << "EOF"
#!/bin/bash

# /usr/sbin/remove-la-files.sh
# Written for Beyond Linux From Scratch
# by Bruce Dubbs <bdubbs@linuxfromscratch.org>

# Make sure we are running with root privs
if test "${EUID}" -ne 0; then
    echo "Error: $(basename ${0}) must be run as the root user! Exiting..."
    exit 1
fi

# Make sure PKG_CONFIG_PATH is set if discarded by sudo
source /etc/profile

OLD_LA_DIR=/var/local/la-files

mkdir -p $OLD_LA_DIR

# Only search directories in /opt, but not symlinks to directories
OPTDIRS=$(find /opt -mindepth 1 -maxdepth 1 -type d)

# Move any found .la files to a directory out of the way
find /usr/lib $OPTDIRS -name "*.la" ! -path "/usr/lib/ImageMagick*" \
  -exec mv -fv {} $OLD_LA_DIR \;
###############

# Fix any .pc files that may have .la references

STD_PC_PATH='/usr/lib/pkgconfig
             /usr/share/pkgconfig
             /usr/local/lib/pkgconfig
             /usr/local/share/pkgconfig'

# For each directory that can have .pc files
for d in $(echo $PKG_CONFIG_PATH | tr : ' ') $STD_PC_PATH; do

  # For each pc file
  for pc in $d/*.pc ; do
    if [ $pc == "$d/*.pc" ]; then continue; fi

    # Check each word in a line with a .la reference
    for word in $(grep '\.la' $pc); do
      if $(echo $word | grep -q '.la$' ); then
        mkdir -p $d/la-backup
        cp -fv  $pc $d/la-backup

        basename=$(basename $word )
        libref=$(echo $basename|sed -e 's/^lib/-l/' -e 's/\.la$//')

        # Fix the .pc file
        sed -i "s:$word:$libref:" $pc
      fi
    done
  done
done

EOF

chmod +x /usr/sbin/remove-la-files.sh

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/la-files

Last updated on

Libraries: Static or shared?

Libraries: Static or shared?

The original libraries were simply an archive of routines from which the required routines were extracted and linked into the executable program. These are described as static libraries (libfoo.a). On some old operating systems they are the only type available.

On almost all Linux platforms there are also shared libraries (libfoo.so) - one copy of the library is loaded into virtual memory, and shared by all the programs which call any of its functions. This is space efficient.

In the past, essential programs such as a shell were often linked statically so that some form of minimal recovery system would exist even if shared libraries, such as libc.so, became damaged (e.g. moved to lost+found after fsck following an unclean shutdown). Nowadays, most people use an alternative system install or a Live CD if they have to recover. Journaling filesystems also reduce the likelihood of this sort of problem.

Developers, at least while they are developing, often prefer to use static versions of the libraries which their code links to.

Within the book, there are various places where configure switches such as --disable-static are employed, and other places where the possibility of using system versions of libraries instead of the versions included within another package is discussed. The main reason for this is to simplify updates of libraries.

If a package is linked to a dynamic library, updating to a newer library version is automatic once the newer library is installed and the program is (re)started (provided the library major version is unchanged, e.g. going from libfoo.so.2.0 to libfoo.so.2.1. Going to libfoo.so.3 will require recompilation - ldd can be used to find which programs use the old version). If a program is linked to a static library, the program always has to be recompiled. If you know which programs are linked to a particular static library, this is merely an annoyance. But usually you will not know which programs to recompile.

Most libraries are shared, but if you do something unusual, such as moving a shared library to /lib accidentally breaking the .so symlink in /usr/lib while keeping the static library in /lib, the static library will be silently linked into the programs which need it.

One way to identify when a static library is used, is to deal with it at the end of the installation of every package. Write a script to find all the static libraries in /usr/lib or wherever you are installing to, and either move them to another directory so that they are no longer found by the linker, or rename them so that libfoo.a becomes e.g. libfoo.a.hidden. The static library can then be temporarily restored if it is ever needed, and the package needing it can be identified. You may choose to exclude some of the static libraries from glibc if you do this (libc_nonshared.a, libg.a, libieee.a, libm.a, libpthread_nonshared.a, librpcsvc.a, libsupc++.a) to simplify compilation.

If you use this approach, you may discover that more packages than you were expecting use a static library. That was the case with nettle-2.4 in its default static-only configuration: It was required by GnuTLS-3.0.19, but also linked into package(s) which used GnuTLS, such as glib-networking-2.32.3.

Many packages put some of their common functions into a static library which is only used by the programs within the package and, crucially, the library is not installed as a standalone library. These internal libraries are not a problem - if the package has to be rebuilt to fix a bug or vulnerability, nothing else is linked to them.

When BLFS mentions system libraries, it means shared versions of libraries. Some packages such as Firefox-91.6.0 and ghostscript-9.55.0 include many other libraries. When they link to them, they link statically so this also makes the programs bigger. The version they ship is often older than the version used in the system, so it may contain bugs - sometimes developers go to the trouble of fixing bugs in their included libraries, other times they do not.

Sometimes, deciding to use system libraries is an easy decision. Other times it may require you to alter the system version (e.g. for libpng-1.6.37 if used for Firefox-91.6.0). Occasionally, a package ships an old library and can no longer link to the current version, but can link to an older version. In this case, BLFS will usually just use the shipped version. Sometimes the included library is no longer developed separately, or its upstream is now the same as the package's upstream and you have no other packages which will use it. In those cases, you might decide to use the included static library even if you usually prefer to use system libraries.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libraries

Last updated on

Locale Related Issues

This page contains information about locale related problems and issues. In the following paragraphs you'll find a generic overview of things that can come up when configuring your system for various locales. Many (but not all) existing locale related problems can be classified and fall under one of the headings below. The severity ratings below use the following criteria:

  • Critical: The program doesn't perform its main function. The fix would be very intrusive, it's better to search for a replacement.

  • High: Part of the functionality that the program provides is not usable. If that functionality is required, it's better to search for a replacement.

  • Low: The program works in all typical use cases, but lacks some functionality normally provided by its equivalents.

If there is a known workaround for a specific package, it will appear on that package's page. For the most recent information about locale related issues for individual packages, check the User Notes in the BLFS Wiki.

The Needed Encoding is Not a Valid Option in the Program

Severity: Critical

Some programs require the user to specify the character encoding for their input or output data and present only a limited choice of encodings. This is the case for the -X option in Enscript-1.6.6, the -input-charset option in unpatched Cdrtools-3.02a09, and the character sets offered for display in the menu of Links-2.25. If the required encoding is not in the list, the program usually becomes completely unusable. For non-interactive programs, it may be possible to work around this by converting the document to a supported input character set before submitting to the program.

A solution to this type of problem is to implement the necessary support for the missing encoding as a patch to the original program or to find a replacement.

The Program Assumes the Locale-Based Encoding of External Documents

Severity: High for non-text documents, low for text documents

Some programs, nano-6.2 or JOE-4.6 for example, assume that documents are always in the encoding implied by the current locale. While this assumption may be valid for the user-created documents, it is not safe for external ones. When this assumption fails, non-ASCII characters are displayed incorrectly, and the document may become unreadable.

If the external document is entirely text based, it can be converted to the current locale encoding using the iconv program.

For documents that are not text-based, this is not possible. In fact, the assumption made in the program may be completely invalid for documents where the Microsoft Windows operating system has set de facto standards. An example of this problem is ID3v1 tags in MP3 files (see the BLFS Wiki ID3v1Coding page for more details). For these cases, the only solution is to find a replacement program that doesn't have the issue (e.g., one that will allow you to specify the assumed document encoding).

Among BLFS packages, this problem applies to nano-6.2, JOE-4.6, and all media players except Audacious-4.1.

Another problem in this category is when someone cannot read the documents you've sent them because their operating system is set up to handle character encodings differently. This can happen often when the other person is using Microsoft Windows, which only provides one character encoding for a given country. For example, this causes problems with UTF-8 encoded TeX documents created in Linux. On Windows, most applications will assume that these documents have been created using the default Windows 8-bit encoding.

In extreme cases, Windows encoding compatibility issues may be solved only by running Windows programs under Wine.

The Program Uses or Creates Filenames in the Wrong Encoding

Severity: Critical

The POSIX standard mandates that the filename encoding is the encoding implied by the current LC_CTYPE locale category. This information is well-hidden on the page which specifies the behavior of Tar and Cpio programs. Some programs get it wrong by default (or simply don't have enough information to get it right). The result is that they create filenames which are not subsequently shown correctly by ls, or they refuse to accept filenames that ls shows properly. For the GLib-2.70.4 library, the problem can be corrected by setting the G_FILENAME_ENCODING environment variable to the special "@locale" value. Glib2 based programs that don't respect that environment variable are buggy.

The Zip-3.0 and UnZip-6.0 have this problem because they hard-code the expected filename encoding. UnZip contains a hard-coded conversion table between the CP850 (DOS) and ISO-8859-1 (UNIX) encodings and uses this table when extracting archives created under DOS or Microsoft Windows. However, this assumption only works for those in the US and not for anyone using a UTF-8 locale. Non-ASCII characters will be mangled in the extracted filenames.

The general rule for avoiding this class of problems is to avoid installing broken programs. If this is impossible, the convmv command-line tool can be used to fix filenames created by these broken programs, or intentionally mangle the existing filenames to meet the broken expectations of such programs.

In other cases, a similar problem is caused by importing filenames from a system using a different locale with a tool that is not locale-aware (e.g., OpenSSH-8.8p1). In order to avoid mangling non-ASCII characters when transferring files to a system with a different locale, any of the following methods can be used:

  • Transfer anyway, fix the damage with convmv.

  • On the sending side, create a tar archive with the --format=posix switch passed to tar (this will be the default in a future version of tar).

  • Mail the files as attachments. Mail clients specify the encoding of attached filenames.

  • Write the files to a removable disk formatted with a FAT or FAT32 filesystem.

  • Transfer the files using Samba.

  • Transfer the files via FTP using RFC2640-aware server (this currently means only wu-ftpd, which has bad security history) and client (e.g., lftp).

The last four methods work because the filenames are automatically converted from the sender's locale to UNICODE and stored or sent in this form. They are then transparently converted from UNICODE to the recipient's locale encoding.

The Program Breaks Multibyte Characters or Doesn't Count Character Cells Correctly

Severity: High or critical

Many programs were written in an older era where multibyte locales were not common. Such programs assume that C "char" data type, which is one byte, can be used to store single characters. Further, they assume that any sequence of characters is a valid string and that every character occupies a single character cell. Such assumptions completely break in UTF-8 locales. The visible manifestation is that the program truncates strings prematurely (i.e., at 80 bytes instead of 80 characters). Terminal-based programs don't place the cursor correctly on the screen, don't react to the "Backspace" key by erasing one character, and leave junk characters around when updating the screen, usually turning the screen into a complete mess.

Fixing this kind of problems is a tedious task from a programmer's point of view, like all other cases of retrofitting new concepts into the old flawed design. In this case, one has to redesign all data structures in order to accommodate to the fact that a complete character may span a variable number of "char"s (or switch to wchar_t and convert as needed). Also, for every call to the "strlen" and similar functions, find out whether a number of bytes, a number of characters, or the width of the string was really meant. Sometimes it is faster to write a program with the same functionality from scratch.

Among BLFS packages, this problem applies to xine-ui-0.99.13 and all the shells.

The Package Installs Manual Pages in Incorrect or Non-Displayable Encoding

Severity: Low

LFS expects that manual pages are in the language-specific (usually 8-bit) encoding, as specified on the LFS Man DB page. However, some packages install translated manual pages in UTF-8 encoding (e.g., Shadow, already dealt with), or manual pages in languages not in the table. Not all BLFS packages have been audited for conformance with the requirements put in LFS (the large majority have been checked, and fixes placed in the book for packages known to install non-conforming manual pages). If you find a manual page installed by any of BLFS packages that is obviously in the wrong encoding, please remove or convert it as needed, and report this to BLFS team as a bug.

You can easily check your system for any non-conforming manual pages by copying the following short shell script to some accessible location,

#!/bin/sh
# Begin checkman.sh
# Usage: find /usr/share/man -type f | xargs checkman.sh
for a in "$@"
do
    # echo "Checking $a..."
    # Pure-ASCII manual page (possibly except comments) is OK
    grep -v '.\\"' "$a" | iconv -f US-ASCII -t US-ASCII >/dev/null 2>&1 \
        && continue
    # Non-UTF-8 manual page is OK
    iconv -f UTF-8 -t UTF-8 "$a" >/dev/null 2>&1 || continue
    # Found a UTF-8 manual page, bad.
    echo "UTF-8 manual page: $a" >&2
done
# End checkman.sh

and then issuing the following command (modify the command below if the checkman.sh script is not in your PATH environment variable):

find /usr/share/man -type f | xargs checkman.sh

Note that if you have manual pages installed in any location other than /usr/share/man (e.g., /usr/local/share/man), you must modify the above command to include this additional location.

Last updated on

Going Beyond BLFS

The packages that are installed in this book are only the tip of the iceberg. We hope that the experience you gained with the LFS book and the BLFS book will give you the background needed to compile, install and configure packages that are not included in this book.

When you want to install a package to a location other than /, or /usr, you are installing outside the default environment settings on most machines. The following examples should assist you in determining how to correct this situation. The examples cover the complete range of settings that may need updating, but they are not all needed in every situation.

  • Expand the PATH to include $PREFIX/bin.

  • Expand the PATH for root to include $PREFIX/sbin.

  • Add $PREFIX/lib to /etc/ld.so.conf or expand LD_LIBRARY_PATH to include it. Before using the latter option, check out http://xahlee.org/UnixResource_dir/_/ldpath.html. If you modify /etc/ld.so.conf, remember to update /etc/ld.so.cache by executing ldconfig as the root user.

  • Add $PREFIX/man to /etc/man_db.conf or expand MANPATH.

  • Add $PREFIX/info to INFOPATH.

  • Add $PREFIX/lib/pkgconfig to PKG_CONFIG_PATH. Some packages are now installing .pc files in $PREFIX/share/pkgconfig, so you may have to include this directory also.

  • Add $PREFIX/include to CPPFLAGS when compiling packages that depend on the package you installed.

  • Add $PREFIX/lib to LDFLAGS when compiling packages that depend on a library installed by the package.

If you are in search of a package that is not in the book, the following are different ways you can search for the desired package.

Some general hints on handling new packages:

  • Many of the newer packages follow the ./configure && make && make install process. Help on the options accepted by configure can be obtained via the command ./configure --help.

  • Most of the packages contain documentation on compiling and installing the package. Some of the documents are excellent, some not so excellent. Check out the homepage of the package for any additional and updated hints for compiling and configuring the package.

  • If you are having a problem compiling the package, try searching the LFS archives at https://www.linuxfromscratch.org/search.html for the error or if that fails, try searching Google. Often, a distribution will have already solved the problem (many of them use development versions of packages, so they see the changes sooner than those of us who normally use stable released versions). But be cautious - all builders tend to carry patches which are no longer necessary, and to have fixes which are only required because of their particular choices in how they build a package. You may have to search deeply to find a fix for the package version you are trying to use, or even to find the package (names are sometimes not what you might expect, e.g. ghostscript often has a prefix or a suffix in its name), but the following notes might help, particularly for those who, like the editors, are trying to build the latest versions and encountering problems:

    • Arch http://www.archlinux.org/packages/ - enter the package name in the 'Keywords' box, select the package name, select the 'Source Files' field, and then select the PKGBUILD entry to see how they build this package.

    • Debian http://ftp.uk.debian.org/debian/pool (use your country's version if there is one) - the source will be in .tar.gz tarballs (either the original upstream .orig source, or else a dfsg containing those parts which comply with debian's free software guidelines) accompanied by versioned .diff.gz or .tar.gz additions. These additions often show how the package is built, and may contain patches. In the .diff.gz versions, any patches create files in debian/patches.

    • Fedora package source gets reorganized from time to time. At the moment the package source for rpms is at https://src.fedoraproject.org/projects/rpms/%2A and from there you can try putting a package name in the search box. If the package is found you can look at the files (specfile to control the build, various patches) or the commits. If that fails, you can download an srpm (source rpm) and using rpm2cpio (see the Tip at the bottom of the page). For rpms go to https://dl.fedoraproject.org/pub/fedora/linux/ and then choose which repo you wish to look at - development/rawhide is the latest development, or choose releases for what was shipped in a release, updates for updates to a release, or updates/testing for the latest updates which might work or might have problems.

    • Gentoo - the mirrors for ebuilds and patches seem to be well-hidden, and they change frequently. Also, if you have found a mirror, you need to know which directory the application has been assigned to. The ebuilds themselves can be found at http://packages.gentoo.org/ - use the search field. If there are any patches, a mirror will have them in the files/ directory. Depending on your browser, or the mirror, you might need to download the ebuild to be able to read it. Treat the ebuild as a sort of pseudo-code / shell combination - look in particular for sed commands and patches, or hazard a guess at the meanings of the functions such as dodoc.

    • openSUSE provide a rolling release, some package versions are in http://download.opensuse.org/source/tumbleweed/repo/oss/src/ but others are in ../update/openSUSE-current/src - the source only seems to be available in source rpms.

    • Slackware - the official package browser is currently broken. The site at http://slackbuilds.org/ has current and previous versions in their unofficial repository with links to homepages, downloads, and some individual files, particularly the .SlackBuild files.

    • Ubuntu ftp://ftp.ubuntu.com/ubuntu/pool/ - see the debian notes above.

    If everything else fails, try the blfs-support mailing-list.

Tip

If you have found a package that is only available in .deb or .rpm format, there are two small scripts, rpm2targz and deb2targz that are available at https://anduin.linuxfromscratch.org/BLFS/extras/deb2targz.tar.bz2 and https://anduin.linuxfromscratch.org/BLFS/extras/rpm2targz.tar.bz2 to convert the archives into a simple tar.gz format.

You may also find an rpm2cpio script useful. The Perl version in the linux kernel archives at http://lkml.indiana.edu/hypermail/linux/kernel/0210.2/att-0093/01-rpm2cpio works for most source rpms. The rpm2targz script will use an rpm2cpio script or binary if one is on your path. Note that rpm2cpio will unpack a source rpm in the current directory, giving a tarball, a spec file, and perhaps patches or other files.

Last updated on

Part II. Post LFS Configuration and Extra Software

Chapter 3. After LFS Configuration Issues

The intention of LFS is to provide a basic system which you can build upon. There are several things about tidying up the system which many people wonder about once they have done the base install. We hope to cover these issues in this chapter.

Most people coming from non-Unix like backgrounds to Linux find the concept of text-only configuration files slightly strange. In Linux, just about all configuration is done via the manipulation of text files. The majority of these files can be found in the /etc hierarchy. There are often graphical configuration programs available for different subsystems but most are simply pretty front ends to the process of editing a text file. The advantage of text-only configuration is that you can edit parameters using your favorite text editor, whether that be vim, emacs, or any other editor.

The first task is making a recovery boot device in Creating a Custom Boot Device because it's the most critical need. Hardware issues relevant to firmware and other devices is addressed next. The system is then configured to ease addition of new users, because this can affect the choices you make in the two subsequent topics—The Bash Shell Startup Files and The vimrc Files.

The remaining topics, Customizing your Logon with /etc/issue and Random number generation are then addressed, in that order. They don't have much interaction with the other topics in this chapter.

Creating a Custom Boot Device

Decent Rescue Boot Device Needs

This section is really about creating a rescue device. As the name rescue implies, the host system has a problem, often lost partition information or corrupted file systems, that prevents it from booting and/or operating normally. For this reason, you must not depend on resources from the host being "rescued". To presume that any given partition or hard drive will be available is a risky presumption.

In a modern system, there are many devices that can be used as a rescue device: floppy, cdrom, usb drive, or even a network card. Which one you use depends on your hardware and your BIOS. In the past, a rescue device was thought to be a floppy disk. Today, many systems do not even have a floppy drive.

Building a complete rescue device is a challenging task. In many ways, it is equivalent to building an entire LFS system. In addition, it would be a repetition of information already available. For these reasons, the procedures for a rescue device image are not presented here.

Creating a Rescue Floppy

The software of today's systems has grown large. Linux 2.6 no longer supports booting directly from a floppy. In spite of this, there are solutions available using older versions of Linux. One of the best is Tom's Root/Boot Disk available at http://www.toms.net/rb/. This will provide a minimal Linux system on a single floppy disk and provides the ability to customize the contents of your disk if necessary.

Creating a Bootable CD-ROM

There are several sources that can be used for a rescue CD-ROM. Just about any commercial distribution's installation CD-ROMs or DVDs will work. These include RedHat, Ubuntu, and SuSE. One very popular option is Knoppix.

Also, the LFS Community has developed its own LiveCD available at https://www.linuxfromscratch.org/livecd/. This LiveCD, is no longer capable of building an entire LFS/BLFS system, but is still a good rescue CD-ROM. If you download the ISO image, use xorriso to copy the image to a CD-ROM.

The instructions for using GRUB2 to make a custom rescue CD-ROM are also available in LFS Chapter 10.

Creating a Bootable USB Drive

A USB Pen drive, sometimes called a Thumb drive, is recognized by Linux as a SCSI device. Using one of these devices as a rescue device has the advantage that it is usually large enough to hold more than a minimal boot image. You can save critical data to the drive as well as use it to diagnose and recover a damaged system. Booting such a drive requires BIOS support, but building the system consists of formatting the drive, adding GRUB as well as the Linux kernel and supporting files.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/CreatingaCustomBootDevice

Last updated on

About Console Fonts

An LFS system can be used without a graphical desktop, and unless or until you install a graphical environment you will have to work in the console. Most, if not all, PCs boot with an 8x16 font - whatever the actual screen size. There are a few things you can do to alter the display on the console. Most of them involve changing the font, but the first alters the commandline used by grub.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/aboutconsolefonts

Setting a smaller screen size in grub

Modern screens often have a lot more pixels then the screens used in the past. If your screen is 1600 pixels wide, an 8x16 font will give you 200 columns of text - unless your monitor is enormous, the text will be tiny. One of the ways to work around this is to tell grub to use a smaller size, such as 1024x768 or 800x600 or even 640x480. Even if your screen does not have a 4:3 aspect ratio, this should work.

To try this, you can reboot and edit grub's command-line to insert a 'video=' parameter between the 'root=/dev/sdXn' and 'ro', for example root=/dev/sda2 video=1024x768 ro based on the example in LFS section 10.4.4 : ../../../../lfs/view/11.1/chapter10/grub.html.

If you decide that you wish to do this, you can then (as the root user) edit /boot/grub/grub.cfg.

Using the standard psf fonts

In LFS the kbd package is used. The fonts it provides are PC Screen Fonts, usually called PSF, and they were installed into /usr/share/consolefonts. Where these include a unicode mapping table, the file suffix is often changed to .psfu although packages such as terminus-font (see below) do not add the 'u'. These fonts are usually compressed with gzip to save space, but that is not essential.

The initial PC text screens had 8 colours, or 16 colours if the bright versions of the original 8 colours were used. A PSF font can include up to 256 characters (technically, glyphs) while allowing 16 colours, or up to 512 characters (in which case, the bright colours will not be available). Clearly, these console fonts cannot be used to display CJK text - that would need thousands of available glyphs.

Some fonts in kbd can cover more than 512 codepoints ('characters'), with varying degrees of fidelity: unicode contains several whitespace codepoints which can all be mapped to a space, varieties of dashes can be mapped to a minus sign, smart quotes can map to the regular ASCII quotes rather than to whatever is used for "codepoint not present or invalid", and those cyrillic or greek letters which look like latin letters can be mapped onto them, so 'A' can also do duty for cyrillic A and greek Alpha, and 'P' can also do duty for cyrillic ER and greek RHO. Unfortunately, where a font has been created from a BDF file (the method in terminus and debian's console-setup ) such mapping of additional codepoints onto an existing glyph is not always done, although the terminus ter-vXXn fonts do this well.

There are over 120 combinations of font and size in kbd: often a font is provided at several character sizes, and sometimes varieties cover different subsets of unicode. Most are 8 pixels wide, in heights from 8 to 16 pixels, but there are a few which are 9 pixels wide, some others which are 12x22, and even one (latarcyrheb-sun32.psfu) which has been scaled up to 16x32. Using a bigger font is another way of making text on a large screen easier to read.

Testing different fonts

You can test fonts as a normal user. If you have a font which has not been installed, you can load it with :

setfont /path/to/yourfont.ext

For the fonts already installed you only need the name, so using gr737a-9x16.psfu.gz as an example:

setfont gr737a-9x16

To see the glyphs in the font, use:

showconsolefont

If the font looks as if it might be useful, you can then go on to test it more thoroughly.

When you find a font which you wish to use, as the root user) edit /etc/sysconfig/console as described in LFS section 9.6.5 ../../../../lfs/view/11.1/chapter09/usage.html. .

For fonts not supplied with the kbd package you will need to optionally compress it / them with gzip and then install it / them as the root user.

Editing fonts using psf-tools

Although some console fonts are created from BDF files, which is a text format with hex values for the pixels in each row of the character, there are more-modern tools available for editing psf fonts. The psftools package allows you to dump a font to a text representation with a dash for a pixel which is off (black) and a hash for a pixel which is on (white). You can then edit the text file to add more characters, or reshape them, or map extra codepoints onto them, and then create a new psf font with your changes.

Using fonts from Terminus-font

The Terminus Font package provides fixed-width bitmap fonts designed for long (8 hours and more per day) work with computers. Under 'Character variants' on that page is a list of patches (in the alt/ directory). If you are using a graphical browser to look at that page, you can see what the patches do, e.g. 'll2' makes 'l' more visibly different from 'i' and '1'.

By default terminus-fonts will try to create several types of font, and it will fail if bdftopcf from Xorg Applications has not been installed. The configure script is only really useful if you go on to install all the fonts (console and X11 bitmap) to the correct directories, as in a distro. To build only the PSF fonts and their dependencies, run:

make psf

This will create more than 240 ter-*.psf fonts. The 'b' suffix indicates bright, 'n' indicates normal. You can then test them to see if any fit your requirements. Unless you are creating a distro, there seems little point in installing them all.

As an example, to install the last of these fonts, you can gzip it and then as the root user:

install -v -m644 ter-v32n.psf.gz /usr/share/consolefonts

Last updated on

About Firmware

On some recent PCs it can be necessary, or desirable, to load firmware to make them work at their best. There is a directory, /lib/firmware, where the kernel or kernel drivers look for firmware images.

Currently, most firmware can be found at a git repository: http://git.kernel.org/cgit/linux/kernel/git/firmware/linux-firmware.git/tree/. For convenience, the LFS Project has created a mirror, updated daily, where these firmware files can be accessed via wget or a web browser at https://anduin.linuxfromscratch.org/BLFS/linux-firmware/.

To get the firmware, either point a browser to one of the above repositories and then download the item(s) which you need, or install git-2.35.1 and clone that repository.

For some other firmware, particularly for Intel microcode and certain wifi devices, the needed firmware is not available in the above repository. Some of this will be addressed below, but a search of the Internet for needed firmware is sometimes necessary.

Firmware files are conventionally referred to as blobs because you cannot determine what they will do. Note that firmware is distributed under various different licenses which do not permit disassembly or reverse-engineering.

Firmware for PCs falls into four categories:

  • Updates to the CPU to work around errata, usually referred to as microcode.

  • Firmware for video controllers. On x86 machines this is required for ATI devices (Radeon and AMDGPU chips) and may be useful for Intel (Skylake and later) and Nvidia (Kepler and later) GPUs.

    ATI Radeon and AMGPU devices all require firmware to be able to use KMS (kernel modesetting - the preferred option) as well as for Xorg. For old radeon chips (before the R600), the firmware is still in the kernel source.

    Intel integrated GPUs from Skylake onwards can use firmware for GuC (the Graphics microcontroller), and also for the HuC (HEVC/H265 microcontroller which offloads to the GPU) and the DMC (Display Microcontroller) to provide additional low-power states. The GuC and HuC have had a chequered history in the kernel and updated firmware may be disabled by default, depending on your kernel version. Further details may be found at 01.org and Arch linux.

    Nvidia GPUs from Kepler onwards require signed firmware, otherwise the nouveau driver is unable to provide hardware acceleration. Nvidia has now released firmware up to Turing (most, maybe all, GTX16xx and RTX20xx GPUs) to linux-firmware, and kernels from linux-5.6 should support it, although Mesa support may require a development version until Mesa-20.2 is released. Note that faster clocks than the default are not enabled by the released firmware.

  • Firmware updates for wired network ports. Mostly they work even without the updates, but probably they will work better with the updated firmware. For some modern laptops, firmware for both wired ethernet (e.g. rtl_nic) and also for bluetooth devices (e.g. qca) is required before the wired network can be used.

  • Firmware for other devices, such as wifi. These devices are not required for the PC to boot, but need the firmware before these devices can be used.

Note

Although not needed to load a firmware blob, the following tools may be useful for determining, obtaining, or preparing the needed firmware in order to load it into the system: cpio-2.13, git-2.35.1, pciutils-3.7.0, and Wget-1.21.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/aboutfirmware

Microcode updates for CPUs

In general, microcode can be loaded by the BIOS or UEFI, and it might be updated by upgrading to a newer version of those. On linux, you can also load the microcode from the kernel if you are using an AMD family 10h or later processor (first introduced late 2007), or an Intel processor from 1998 and later (Pentium4, Core, etc), if updated microcode has been released. These updates only last until the machine is powered off, so they need to be applied on every boot.

Intel provide updates of their microcode for Skylake and later processors as new vulnerabilities come to light, and have in the past provided updates for processors from SandyBridge onwards, although those are no-longer supported for new fixes. New versions of AMD firmware are rare and usually only apply to a few models, although motherboard manufacturers get extra updates which maybe update microcode along with the changes to support newer CPUs and faster memory.

There are two ways of loading the microcode, described as 'early' and 'late'. Early loading happens before userspace has been started, late loading happens after userspace has started. Not surprisingly, early loading is preferred, (see e.g. an explanatory comment in a kernel commit noted at x86/microcode: Early load microcode on LWN.) Indeed, it is needed to work around one particular erratum in early Intel Haswell processors which had TSX enabled. (See Intel Disables TSX Instructions: Erratum Found in Haswell, Haswell-E/EP, Broadwell-Y .) Without this update glibc can do the wrong thing in uncommon situations.

It is still possible to manually force late loading of microcode, either for testing or to prevent having to reboot. You will need to reconfigure your kernel for either method. The instructions here will create a kernel .config to suite early loading, before forcing late loading to see if there is any microcode. If there is, the instructions then show you how to create an initrd for early loading.

To confirm what processor(s) you have (if more than one, they will be identical) look in /proc/cpuinfo.

If you are creating an initrd to update firmware for different machines, as a distro would do, go down to 'Early loading of microcode' and cat all the Intel blobs to GenuineIntel.bin or cat all the AMD blobs to AuthenticAMD.bin. This creates a larger initrd - for all Intel machines in the 20200609 update the size is 3.0 MB compared to typically 24 KB for one machine.

Intel Microcode for the CPU

The first step is to get the most recent version of the Intel microcode. This must be done by navigating to https://github.com/intel/Intel-Linux-Processor-Microcode-Data-Files/releases/ and downloading the latest file there. As of this writing the most secure version of the microcode is microcode-20220207. Extract this file in the normal way, the microcode is in the intel-ucode directory, containing various blobs with names in the form XX-YY-ZZ. There are also various other files, and a releasenote.

In the past, intel did not provide any details of which blobs had changed versions, but now the release note details this.

The recent firmware for older processors is provided to deal with vulnerabilities which have now been made public, and for some of these such as Microarchitectural Data Sampling (MDS) you might wish to increase the protection by disabling hyperthreading, or alternatively to disable the kernel's default mitigation because of its impact on compile times. Please read the online documentation at https://www.kernel.org/doc/html/latest/admin-guide/hw-vuln/index.html.

Now you need to determine your processor's identity to see if there is any microcode for it. Determine the decimal values of the cpu family, model and stepping by running the following command (it will also report the current microcode version):

head -n7 /proc/cpuinfo

Convert the cpu family, model and stepping to pairs of hexadecimal digits. For a Skylake i3 6100 (described as Intel(R) Core(TM) i3-6100 CPU) the relevant values are cpu family 6, model 94, stepping 3 so in this case the required identification is 06-5e-03. A look at the blobs will show that there is one for this CPU (although for older issues it might have already been applied by the BIOS). If there is a blob for your system then test if it will be applied by copying it (replace <XX-YY-ZZ> by the identifier for your CPU) to where the kernel can find it:

mkdir -pv /lib/firmware/intel-ucode
cp -v intel-ucode/<XX-YY-ZZ> /lib/firmware/intel-ucode

Now that the Intel microcode has been prepared, use the following options when you configure the kernel to load Intel microcode:

General Setup --->
  [*] Initial RAM filesystem and RAM disk (initramfs/initrd) support [CONFIG_BLK_DEV_INITRD]
Processor type and features  --->
  [*] CPU microcode loading support  [CONFIG_MICROCODE]
  [*]      Intel microcode loading support [CONFIG_MICROCODE_INTEL]

After you have successfully booted the new system, force late loading by using the command:

echo 1 > /sys/devices/system/cpu/microcode/reload

Then use the following command to see if anything was loaded: (N.B. the dates when microcode was created may be months ahead of when it was released.)

dmesg | grep -e 'microcode' -e 'Linux version' -e 'Command line'

This old example showing the very old BIOS firmware version was created by temporarily booting without microcode, to show the current Firmware Bug messages, then the late load shows it being updated to revision 0xea which was current at that time.

[    0.000000] Linux version 5.12.8 (lfs@leshp) (gcc (GCC) 11.1.0,
               GNU ld (GNU Binutils) 2.36.1)
               #2 SMP PREEMPT Fri Jun 4 01:25:02 BST 2021
[    0.000000] Command line: BOOT_IMAGE=/vmlinuz-5.12.8-sda11 root=/dev/sda11 ro
               resume=/dev/sda10
[    0.028741] [Firmware Bug]: TSC_DEADLINE disabled due to Errata;
               please update microcode to version: 0xb2 (or later)
[    0.115716] SRBDS: Vulnerable: No microcode
[    0.115826] MDS: Vulnerable: Clear CPU buffers attempted, no microcode
[    0.389005] microcode: sig=0x506e3, pf=0x2, revision=0x74
[    0.389030] microcode: Microcode Update Driver: v2.2.
[   70.089502] microcode: updated to revision 0xea, date = 2021-01-25
[   70.089528] x86/CPU: CPU features have changed after loading microcode,
               but might not take effect.
[   70.089530] microcode: Reload completed, microcode revision: 0xea

If the microcode was not updated, there is no new microcode for this system's processor. If it did get updated, you can now proceed to the section called “Early loading of microcode”.

AMD Microcode for the CPU

Begin by downloading a container of firmware for your CPU family from https://anduin.linuxfromscratch.org/BLFS/linux-firmware/amd-ucode/. The family is always specified in hex. Families 10h to 14h (16 to 20) are in microcode_amd.bin. Families 15h, 16h and 17h have their own containers. Create the required directory and put the firmware you downloaded into it as the root user:

mkdir -pv /lib/firmware/amd-ucode
cp -v microcode_amd* /lib/firmware/amd-ucode

When you configure the kernel, use the following options to load AMD microcode:

General Setup --->
  [*] Initial RAM filesystem and RAM disk (initramfs/initrd) support [CONFIG_BLK_DEV_INITRD]
Processor type and features  --->
  [*] CPU microcode loading support  [CONFIG_MICROCODE]
  [*]      AMD microcode loading support [CONFIG_MICROCODE_AMD]

After you have successfully booted the new system, force late loading by using the command:

echo 1 > /sys/devices/system/cpu/microcode/reload

Then use the following command to see if anything was loaded:

dmesg | grep -e 'microcode' -e 'Linux version' -e 'Command line'

This historic example from an old Athlon(tm) II X2 shows it has been updated. At that time, all CPUs were still reported in the microcode details on AMD machines (the current position for AMD machines where newer microcode is available is unknown) :

[    0.000000] Linux version 4.15.3 (ken@testserver) (gcc version 7.3.0 (GCC))
               #1 SMP Sun Feb 18 02:08:12 GMT 2018
[    0.000000] Command line: BOOT_IMAGE=/vmlinuz-4.15.3-sda5 root=/dev/sda5 ro
[    0.307619] microcode: CPU0: patch_level=0x010000b6
[    0.307671] microcode: CPU1: patch_level=0x010000b6
[    0.307743] microcode: Microcode Update Driver: v2.2.
[  187.928891] microcode: CPU0: new patch_level=0x010000c8
[  187.928899] microcode: CPU1: new patch_level=0x010000c8

If the microcode was not updated, there is no new microcode for this system's processor. If it did get updated, you can now proceed to the section called “Early loading of microcode”.

Early loading of microcode

If you have established that updated microcode is available for your system, it is time to prepare it for early loading. This requires an additional package, cpio-2.13 and the creation of an initrd which will need to be added to grub.cfg.

It does not matter where you prepare the initrd, and once it is working you can apply the same initrd to later LFS systems or newer kernels on this same machine, at least until any newer microcode is released. Use the following commands:

mkdir -p initrd/kernel/x86/microcode
cd initrd

For an AMD machine, use the following command (replace <MYCONTAINER> with the name of the container for your CPU's family):

cp -v /lib/firmware/amd-ucode/<MYCONTAINER> kernel/x86/microcode/AuthenticAMD.bin

Or for an Intel machine copy the appropriate blob using this command:

cp -v /lib/firmware/intel-ucode/<XX-YY-ZZ> kernel/x86/microcode/GenuineIntel.bin

Now prepare the initrd:

find . | cpio -o -H newc > /boot/microcode.img

You now need to add a new entry to /boot/grub/grub.cfg and here you should add a new line after the linux line within the stanza. If /boot is a separate mountpoint:

initrd /microcode.img

or this if it is not:

initrd /boot/microcode.img

If you are already booting with an initrd (see the section called “About initramfs”), you should run mkinitramfs again after putting the appropriate blob or container into /lib/firmware as explained above. Alternatively, you can have both initrd on the same line, such as initrd /microcode.img /other-initrd.img (adapt that as above if /boot is not a separate mountpoint).

You can now reboot with the added initrd, and then use the same command to check that the early load worked:

dmesg | grep -e 'microcode' -e 'Linux version' -e 'Command line'

If you updated to address vulnerabilities, you can look at /sys/devices/system/cpu/vulnerabilities/ to see what is now reported.

The places and times where early loading happens are very different in AMD and Intel machines. First, an old example of an Intel (Skylake) with early loading:

[    0.000000] microcode: microcode updated early to revision 0xea, date = 2021-01-25
[    0.000000] Linux version 5.12.8 (lfs@leshp) (gcc (GCC) 11.1.0,
               GNU ld (GNU Binutils) 2.36.1) #2 SMP PREEMPT Fri Jun 4 01:25:02 BST 2021
[    0.000000] Command line: BOOT_IMAGE=/vmlinuz-5.12.8-sda11 root=/dev/sda11 ro
               resume=/dev/sda10
[    0.381420] microcode: sig=0x506e3, pf=0x2, revision=0xea
[    0.381479] microcode: Microcode Update Driver: v2.2.

A historic AMD example:

[    0.000000] Linux version 4.15.3 (ken@testserver) (gcc version 7.3.0 (GCC))
               #2 SMP Sun Feb 18 02:32:03 GMT 2018
[    0.000000] Command line: BOOT_IMAGE=/vmlinuz-4.15.3-sda5 root=/dev/sda5 ro
[    0.307619] microcode: microcode updated early to new patch_level=0x010000c8
[    0.307678] microcode: CPU0: patch_level=0x010000c8
[    0.307723] microcode: CPU1: patch_level=0x010000c8
[    0.307795] microcode: Microcode Update Driver: v2.2.

Firmware for Video Cards

Firmware for ATI video chips (R600 and later)

These instructions do NOT apply to old radeons before the R600 family. For those, the firmware is in the kernel's /lib/firmware/ directory. Nor do they apply if you intend to avoid a graphical setup such as Xorg and are content to use the default 80x25 display rather than a framebuffer.

Early radeon devices only needed a single 2K blob of firmware. Recent devices need several different blobs, and some of them are much bigger. The total size of the radeon firmware directory is over 500K — on a large modern system you can probably spare the space, but it is still redundant to install all the unused files each time you build a system.

A better approach is to install pciutils-3.7.0 and then use lspci to identify which VGA controller is installed.

With that information, check the RadeonFeature page of the Xorg wiki for Decoder ring for engineering vs marketing names to identify the family (you may need to know this for the Xorg driver in BLFS — Southern Islands and Sea Islands use the radeonsi driver) and the specific model.

Now that you know which controller you are using, consult the Radeon page of the Gentoo wiki which has a table listing the required firmware blobs for the various chipsets. Note that Southern Islands and Sea Islands chips use different firmware for kernel 3.17 and later compared to earlier kernels. Identify and download the required blobs then install them:

mkdir -pv /lib/firmware/radeon
cp -v <YOUR_BLOBS> /lib/firmware/radeon

There are actually two ways of installing this firmware. BLFS, in the 'Kernel Configuration for additional firmware' section part of the Xorg ATI Driver-19.1.0 section gives an example of compiling the firmware into the kernel - that is slightly faster to load, but uses more kernel memory. Here we will use the alternative method of making the radeon driver a module. In your kernel config set the following:

Device Drivers --->
  Graphics support --->
      Direct Rendering Manager --->
        [*] Direct Rendering Manager (XFree86 ... support)  [CONFIG_DRM]
      [M] ATI Radeon                                        [CONFIG_DRM_RADEON]

Loading several large blobs from /lib/firmware takes a noticeable time, during which the screen will be blank. If you do not enable the penguin framebuffer logo, or change the console size by using a bigger font, that probably does not matter. If desired, you can slightly reduce the time if you follow the alternate method of specifying 'y' for CONFIG_DRM_RADEON covered in BLFS at the link above — you must specify each needed radeon blob if you do that.

Firmware for Nvidia video chips

Some Nvidia graphics chips need firmware updates to take advantage of all the card's capability. These are generally the GeForce 8, 9, 9300, and 200-900 series chips. For more exact information, see https://nouveau.freedesktop.org/wiki/VideoAcceleration/#firmware.

First, the kernel Nvidia driver must be activated:

Device Drivers --->
  Graphics support --->
      Direct Rendering Manager --->
        <*> Direct Rendering Manager (XFree86 ... support)  [CONFIG_DRM]
      <*/M> Nouveau (NVIDIA) cards                          [CONFIG_DRM_NOUVEAU]

The steps to install the Nvidia firmware are:

wget https://raw.github.com/imirkin/re-vp2/master/extract_firmware.py
wget http://us.download.nvidia.com/XFree86/Linux-x86/325.15/NVIDIA-Linux-x86-325.15.run
sh NVIDIA-Linux-x86-325.15.run --extract-only
python extract_firmware.py
mkdir -p /lib/firmware/nouveau
cp -d nv* vuc-* /lib/firmware/nouveau/

Firmware for Network Interfaces

The kernel likes to load firmware for some network drivers, particularly those from Realtek (the /lib/linux-firmware/rtl_nic/) directory, but they generally appear to work without it. Therefore, you can boot the kernel, check dmesg for messages about this missing firmware, and if necessary download the firmware and put it in the specified directory in /lib/firmware so that it will be found on subsequent boots. Note that with current kernels this works whether or not the driver is compiled in or built as a module, there is no need to build this firmware into the kernel. Here is an example where the R8169 driver has been compiled in but the firmware was not made available. Once the firmware had been provided, there was no mention of it on later boots.

dmesg | grep firmware | grep r8169
[    7.018028] r8169 0000:01:00.0: Direct firmware load for rtl_nic/rtl8168g-2.fw failed with error -2
[    7.018036] r8169 0000:01:00.0 eth0: unable to load firmware patch rtl_nic/rtl8168g-2.fw (-2)

Firmware for Other Devices

Identifying the correct firmware will typically require you to install pciutils-3.7.0, and then use lspci to identify the device. You should then search online to check which module it uses, which firmware, and where to obtain the firmware — not all of it is in linux-firmware.

If possible, you should begin by using a wired connection when you first boot your LFS system. To use a wireless connection you will need to use a network tools such as Wireless Tools-29 and wpa_supplicant-2.10.

Different countries have different regulations on the radio spectrum usage of wireless devices. You can install a firmware to make the wireless devices obey local spectrum regulations, so you won't be inquired by local authority or find your wireless NIC jamming the frequencies of other devices (for example, remote controllers). The regulatory database firmware can be downloaded from https://kernel.org/pub/software/network/wireless-regdb/. To install it, simply extract regulatory.db and regulatory.db.p7s from the tarball into /lib/firmware. The access point would send a country code to your wireless NIC, and wpa_supplicant-2.10 would tell the kernel to load the regulation of this country from regulatory.db, and enforce it.

Firmware may also be needed for other devices such as some SCSI controllers, bluetooth adaptors, or TV recorders. The same principles apply.

Last updated on

About Devices

Although most devices needed by packages in BLFS and beyond are set up properly by udev using the default rules installed by LFS in /etc/udev/rules.d, there are cases where the rules must be modified or augmented.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/aboutdevices

Multiple Sound Cards

If there are multiple sound cards in a system, the "default" sound card becomes random. The method to establish sound card order depends on whether the drivers are modules or not. If the sound card drivers are compiled into the kernel, control is via kernel command line parameters in /boot/grub/grub.cfg. For example, if a system has both an FM801 card and a SoundBlaster PCI card, the following can be appended to the command line:

snd-fm801.index=0 snd-ens1371.index=1

If the sound card drivers are built as modules, the order can be established in the /etc/modprobe.conf file with:

options snd-fm801 index=0
options snd-ens1371 index=1

USB Device Issues

USB devices usually have two kinds of device nodes associated with them.

The first kind is created by device-specific drivers (e.g., usb_storage/sd_mod or usblp) in the kernel. For example, a USB mass storage device would be /dev/sdb, and a USB printer would be /dev/usb/lp0. These device nodes exist only when the device-specific driver is loaded.

The second kind of device nodes (/dev/bus/usb/BBB/DDD, where BBB is the bus number and DDD is the device number) are created even if the device doesn't have a kernel driver. By using these "raw" USB device nodes, an application can exchange arbitrary USB packets with the device, i.e., bypass the possibly-existing kernel driver.

Access to raw USB device nodes is needed when a userspace program is acting as a device driver. However, for the program to open the device successfully, the permissions have to be set correctly. By default, due to security concerns, all raw USB devices are owned by user root and group usb, and have 0664 permissions (the read access is needed, e.g., for lsusb to work and for programs to access USB hubs). Packages (such as SANE and libgphoto2) containing userspace USB device drivers also ship udev rules that change the permissions of the controlled raw USB devices. That is, rules installed by SANE change permissions for known scanners, but not printers. If a package maintainer forgot to write a rule for your device, report a bug to both BLFS (if the package is there) and upstream, and you will need to write your own rule.

There is one situation when such fine-grained access control with pre-generated udev rules doesn't work. Namely, PC emulators such as KVM, QEMU and VirtualBox use raw USB device nodes to present arbitrary USB devices to the guest operating system (note: patches are needed in order to get this to work without the obsolete /proc/bus/usb mount point described below). Obviously, maintainers of these packages cannot know which USB devices are going to be connected to the guest operating system. You can either write separate udev rules for all needed USB devices yourself, or use the default catch-all "usb" group, members of which can send arbitrary commands to all USB devices.

Before Linux-2.6.15, raw USB device access was performed not with /dev/bus/usb/BBB/DDD device nodes, but with /proc/bus/usb/BBB/DDD pseudofiles. Some applications (e.g., VMware Workstation) still use only this deprecated technique and can't use the new device nodes. For them to work, use the "usb" group, but remember that members will have unrestricted access to all USB devices. To create the fstab entry for the obsolete usbfs filesystem:

usbfs  /proc/bus/usb  usbfs  devgid=14,devmode=0660  0  0

Note

Adding users to the "usb" group is inherently insecure, as they can bypass access restrictions imposed through the driver-specific USB device nodes. For instance, they can read sensitive data from USB hard drives without being in the "disk" group. Avoid adding users to this group, if you can.

Udev Device Attributes

Fine-tuning of device attributes such as group name and permissions is possible by creating extra udev rules, matching on something like this. The vendor and product can be found by searching the /sys/devices directory entries or using udevadm info after the device has been attached. See the documentation in the current udev directory of /usr/share/doc for details.

SUBSYSTEM=="usb_device", SYSFS{idVendor}=="05d8", SYSFS{idProduct}=="4002", \
  GROUP:="scanner", MODE:="0660"

Note

The above line is used for descriptive purposes only. The scanner udev rules are put into place when installing SANE-1.0.32.

Devices for Servers

In some cases, it makes sense to disable udev completely and create static devices. Servers are one example of this situation. Does a server need the capability of handling dynamic devices? Only the system administrator can answer that question, but in many cases the answer will be no.

If dynamic devices are not desired, then static devices must be created on the system. In the default configuration, the /etc/rc.d/rcS.d/S10udev boot script mounts a tmpfs partition over the /dev directory. This problem can be overcome by mounting the root partition temporarily:

Warning

If the instructions below are not followed carefully, your system could become unbootable.

mount --bind / /mnt
cp -a /dev/* /mnt/dev
rm /etc/rc.d/rcS.d/{S10udev,S50udev_retry}
umount /mnt

At this point, the system will use static devices upon the next reboot. Create any desired additional devices using mknod.

If you want to restore the dynamic devices, recreate the /etc/rc.d/rcS.d/{S10udev,S50udev_retry} symbolic links and reboot again. Static devices do not need to be removed (console and null are always needed) because they are covered by the tmpfs partition. Disk usage for devices is negligible (about 20–30 bytes per entry.)

Devices for DVD Drives

If the initial boot process does not set up the /dev/dvd device properly, it can be installed using the following modification to the default udev rules. As the root user, run:

sed '1d;/SYMLINK.*cdrom/ a\
KERNEL=="sr0", ENV{ID_CDROM_DVD}=="1", SYMLINK+="dvd", OPTIONS+="link_priority=-100"' \
/lib/udev/rules.d/60-cdrom_id.rules > /etc/udev/rules.d/60-cdrom_id.rules

Last updated on

Configuring for Adding Users

Together, the /usr/sbin/useradd command and /etc/skel directory (both are easy to set up and use) provide a way to assure new users are added to your LFS system with the same beginning settings for things such as the PATH, keyboard processing and other environmental variables. Using these two facilities makes it easier to assure this initial state for each new user added to the system.

The /etc/skel directory holds copies of various initialization and other files that may be copied to the new user's home directory when the /usr/sbin/useradd program adds the new user.

Useradd

The useradd program uses a collection of default values kept in /etc/default/useradd. This file is created in a base LFS installation by the Shadow package. If it has been removed or renamed, the useradd program uses some internal defaults. You can see the default values by running /usr/sbin/useradd -D.

To change these values, simply modify the /etc/default/useradd file as the root user. An alternative to directly modifying the file is to run useradd as the root user while supplying the desired modifications on the command line. Information on how to do this can be found in the useradd man page.

/etc/skel

To get started, create an /etc/skel directory and make sure it is writable only by the system administrator, usually root. Creating the directory as root is the best way to go.

The mode of any files from this part of the book that you put in /etc/skel should be writable only by the owner. Also, since there is no telling what kind of sensitive information a user may eventually place in their copy of these files, you should make them unreadable by "group" and "other".

You can also put other files in /etc/skel and different permissions may be needed for them.

Decide which initialization files should be provided in every (or most) new user's home directory. The decisions you make will affect what you do in the next two sections, The Bash Shell Startup Files and The vimrc Files. Some or all of those files will be useful for root, any already-existing users, and new users.

The files from those sections that you might want to place in /etc/skel include .inputrc, .bash_profile, .bashrc, .bash_logout, .dircolors, and .vimrc. If you are unsure which of these should be placed there, just continue to the following sections, read each section and any references provided, and then make your decision.

You will run a slightly modified set of commands for files which are placed in /etc/skel. Each section will remind you of this. In brief, the book's commands have been written for files not added to /etc/skel and instead just sends the results to the user's home directory. If the file is going to be in /etc/skel, change the book's command(s) to send output there instead and then just copy the file from /etc/skel to the appropriate directories, like /etc, ~ or the home directory of any other user already in the system.

When Adding a User

When adding a new user with useradd, use the -m parameter, which tells useradd to create the user's home directory and copy files from /etc/skel (can be overridden) to the new user's home directory. For example (perform as the root user):

useradd -m <newuser>

Last updated on

About System Users and Groups

Throughout BLFS, many packages install programs that run as daemons or in some way should have a user or group name assigned. Generally these names are used to map a user ID (uid) or group ID (gid) for system use. Generally the specific uid or gid numbers used by these applications are not significant. The exception of course, is that root has a uid and gid of 0 (zero) that is indeed special. The uid values are stored in /etc/passwd and the gid values are found in /etc/group.

Customarily, Unix systems classify users and groups into two categories: system users and regular users. The system users and groups are given low numbers and regular users and groups have numeric values greater than all the system values. The cutoff for these numbers is found in two parameters in the /etc/login.defs configuration file. The default UID_MIN value is 1000 and the default GID_MIN value is 1000. If a specific uid or gid value is not specified when creating a user with useradd or a group with groupadd the values assigned will always be above these cutoff values.

Additionally, the Linux Standard Base recommends that system uid and gid values should be below 100.

Below is a table of suggested uid/gid values used in BLFS beyond those defined in a base LFS installation. These can be changed as desired, but provide a suggested set of consistent values.

Table 3.1. UID/GID Suggested Values

Name uid gid
bin 1
lp 9
adm 16
atd 17 17
messagebus 18 18
lpadmin   19
named 20 20
gdm 21 21
fcron 22 22
systemd-journal 23 23
apache 25 25
smmsp 26 26
polkitd 27 27
rpc 28 28
exim 31 31
postfix 32 32
postdrop 33
sendmail 34
mail 34
vmailman 35 35
news 36 36
kdm 37 37
fetchmail 38
mysql 40 40
postgres 41 41
dovecot 42 42
dovenull 43 43
ftp 45 45
proftpd 46 46
vsftpd 47 47
rsyncd 48 48
sshd 50 50
stunnel 51 51
dhcpcd 52 52
svn 56 56
svntest 57
git 58 58
games 60 60
kvm 61
wireshark 62
lightdm 63 63
sddm 64 64
lightdm 65 65
scanner 70
colord 71 71
systemd-journal-gateway 73 73
systemd-journal-remote 74 74
systemd-journal-upload 75 75
systemd-network 76 76
systemd-resolve 77 77
systemd-timesync 78 78
systemd-coredump 79 79
uuidd 80 80
systemd-oom 81 81
ldap 83 83
avahi 84 84
avahi-autoipd 85 85
netdev 86
ntp 87 87
unbound 88 88
plugdev 90
wheel 97
anonymous 98
nobody 99
nogroup 99

One value that is missing is 65534. This value is customarily assigned to the user nobody and group nogroup and is unnecessary.

Last updated on

The Bash Shell Startup Files

The shell program /bin/bash (hereafter referred to as just "the shell") uses a collection of startup files to help create an environment. Each file has a specific use and may affect login and interactive environments differently. The files in the /etc directory generally provide global settings. If an equivalent file exists in your home directory it may override the global settings.

An interactive login shell is started after a successful login, using /bin/login, by reading the /etc/passwd file. This shell invocation normally reads /etc/profile and its private equivalent ~/.bash_profile (or ~/.profile if called as /bin/sh) upon startup.

An interactive non-login shell is normally started at the command-line using a shell program (e.g., [prompt]$/bin/bash) or by the /bin/su command. An interactive non-login shell is also started with a terminal program such as xterm or konsole from within a graphical environment. This type of shell invocation normally copies the parent environment and then reads the user's ~/.bashrc file for additional startup configuration instructions.

A non-interactive shell is usually present when a shell script is running. It is non-interactive because it is processing a script and not waiting for user input between commands. For these shell invocations, only the environment inherited from the parent shell is used.

The file ~/.bash_logout is not used for an invocation of the shell. It is read and executed when a user exits from an interactive login shell.

Many distributions use /etc/bashrc for system wide initialization of non-login shells. This file is usually called from the user's ~/.bashrc file and is not built directly into bash itself. This convention is followed in this section.

For more information see info bash -- Nodes: Bash Startup Files and Interactive Shells.

Note

Most of the instructions below are used to create files located in the /etc directory structure which requires you to execute the commands as the root user. If you elect to create the files in user's home directories instead, you should run the commands as an unprivileged user.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/bash-shell-startup-files

/etc/profile

Here is a base /etc/profile. This file starts by setting up some helper functions and some basic parameters. It specifies some bash history parameters and, for security purposes, disables keeping a permanent history file for the root user. It also sets a default user prompt. It then calls small, single purpose scripts in the /etc/profile.d directory to provide most of the initialization.

For more information on the escape sequences you can use for your prompt (i.e., the PS1 environment variable) see info bash -- Node: Printing a Prompt.

cat > /etc/profile << "EOF"
# Begin /etc/profile
# Written for Beyond Linux From Scratch
# by James Robertson <jameswrobertson@earthlink.net>
# modifications by Dagmar d'Surreal <rivyqntzne@pbzpnfg.arg>

# System wide environment variables and startup programs.

# System wide aliases and functions should go in /etc/bashrc.  Personal
# environment variables and startup programs should go into
# ~/.bash_profile.  Personal aliases and functions should go into
# ~/.bashrc.

# Functions to help us manage paths.  Second argument is the name of the
# path variable to be modified (default: PATH)
pathremove () {
        local IFS=':'
        local NEWPATH
        local DIR
        local PATHVARIABLE=${2:-PATH}
        for DIR in ${!PATHVARIABLE} ; do
                if [ "$DIR" != "$1" ] ; then
                  NEWPATH=${NEWPATH:+$NEWPATH:}$DIR
                fi
        done
        export $PATHVARIABLE="$NEWPATH"
}

pathprepend () {
        pathremove $1 $2
        local PATHVARIABLE=${2:-PATH}
        export $PATHVARIABLE="$1${!PATHVARIABLE:+:${!PATHVARIABLE}}"
}

pathappend () {
        pathremove $1 $2
        local PATHVARIABLE=${2:-PATH}
        export $PATHVARIABLE="${!PATHVARIABLE:+${!PATHVARIABLE}:}$1"
}

export -f pathremove pathprepend pathappend

# Set the initial path
export PATH=/usr/bin

# Attempt to provide backward compatibility with LFS earlier than 11
if [ ! -L /bin ]; then
        pathappend /bin
fi

if [ $EUID -eq 0 ] ; then
        pathappend /usr/sbin
        if [ ! -L /sbin ]; then
                pathappend /sbin
        fi
        unset HISTFILE
fi

# Setup some environment variables.
export HISTSIZE=1000
export HISTIGNORE="&:[bf]g:exit"

# Set some defaults for graphical systems
export XDG_DATA_DIRS=${XDG_DATA_DIRS:-/usr/share/}
export XDG_CONFIG_DIRS=${XDG_CONFIG_DIRS:-/etc/xdg/}
export XDG_RUNTIME_DIR=${XDG_RUNTIME_DIR:-/tmp/xdg-$USER}

# Setup a red prompt for root and a green one for users.
NORMAL="\[\e[0m\]"
RED="\[\e[1;31m\]"
GREEN="\[\e[1;32m\]"
if [[ $EUID == 0 ]] ; then
  PS1="$RED\u [ $NORMAL\w$RED ]# $NORMAL"
else
  PS1="$GREEN\u [ $NORMAL\w$GREEN ]\$ $NORMAL"
fi

for script in /etc/profile.d/*.sh ; do
        if [ -r $script ] ; then
                . $script
        fi
done

unset script RED GREEN NORMAL

# End /etc/profile
EOF

The /etc/profile.d Directory

Now create the /etc/profile.d directory, where the individual initialization scripts are placed:

install --directory --mode=0755 --owner=root --group=root /etc/profile.d

/etc/profile.d/bash_completion.sh

Note

Using the bash completion script below is controversial. Not all users like it. It adds many (usually over 1000) lines to the bash environment and makes it difficult to use the 'set' command to examine simple environment variables. Omitting this script does not interfere with the ability of bash to use the tab key for file name completion.

This script imports bash completion scripts, installed by many other BLFS packages, to allow TAB command line completion.

cat > /etc/profile.d/bash_completion.sh << "EOF"
# Begin /etc/profile.d/bash_completion.sh
# Import bash completion scripts

# If the bash-completion package is installed, use its configuration instead
if [ -f /usr/share/bash-completion/bash_completion ]; then

  # Check for interactive bash and that we haven't already been sourced.
  if [ -n "${BASH_VERSION-}" -a -n "${PS1-}" -a -z "${BASH_COMPLETION_VERSINFO-}" ]; then

    # Check for recent enough version of bash.
    if [ ${BASH_VERSINFO[0]} -gt 4 ] || \
       [ ${BASH_VERSINFO[0]} -eq 4 -a ${BASH_VERSINFO[1]} -ge 1 ]; then
       [ -r "${XDG_CONFIG_HOME:-$HOME/.config}/bash_completion" ] && \
            . "${XDG_CONFIG_HOME:-$HOME/.config}/bash_completion"
       if shopt -q progcomp && [ -r /usr/share/bash-completion/bash_completion ]; then
          # Source completion code.
          . /usr/share/bash-completion/bash_completion
       fi
    fi
  fi

else

  # bash-completions are not installed, use only bash completion directory
  if shopt -q progcomp; then
    for script in /etc/bash_completion.d/* ; do
      if [ -r $script ] ; then
        . $script
      fi
    done
  fi
fi

# End /etc/profile.d/bash_completion.sh
EOF

Make sure that the directory exists:

install --directory --mode=0755 --owner=root --group=root /etc/bash_completion.d

For a more complete installation, see https://wiki.linuxfromscratch.org/blfs/wiki/bash-shell-startup-files#bash-completions.

/etc/profile.d/dircolors.sh

This script uses the ~/.dircolors and /etc/dircolors files to control the colors of file names in a directory listing. They control colorized output of things like ls --color. The explanation of how to initialize these files is at the end of this section.

cat > /etc/profile.d/dircolors.sh << "EOF"
# Setup for /bin/ls and /bin/grep to support color, the alias is in /etc/bashrc.
if [ -f "/etc/dircolors" ] ; then
        eval $(dircolors -b /etc/dircolors)
fi

if [ -f "$HOME/.dircolors" ] ; then
        eval $(dircolors -b $HOME/.dircolors)
fi

alias ls='ls --color=auto'
alias grep='grep --color=auto'
EOF

/etc/profile.d/extrapaths.sh

This script adds some useful paths to the PATH and can be used to customize other PATH related environment variables (e.g. LD_LIBRARY_PATH, etc) that may be needed for all users.

cat > /etc/profile.d/extrapaths.sh << "EOF"
if [ -d /usr/local/lib/pkgconfig ] ; then
        pathappend /usr/local/lib/pkgconfig PKG_CONFIG_PATH
fi
if [ -d /usr/local/bin ]; then
        pathprepend /usr/local/bin
fi
if [ -d /usr/local/sbin -a $EUID -eq 0 ]; then
        pathprepend /usr/local/sbin
fi

if [ -d /usr/local/share ]; then
        pathprepend /usr/local/share XDG_DATA_DIRS
fi

# Set some defaults before other applications add to these paths.
pathappend /usr/share/man  MANPATH
pathappend /usr/share/info INFOPATH
EOF

/etc/profile.d/readline.sh

This script sets up the default inputrc configuration file. If the user does not have individual settings, it uses the global file.

cat > /etc/profile.d/readline.sh << "EOF"
# Setup the INPUTRC environment variable.
if [ -z "$INPUTRC" -a ! -f "$HOME/.inputrc" ] ; then
        INPUTRC=/etc/inputrc
fi
export INPUTRC
EOF

/etc/profile.d/umask.sh

Setting the umask value is important for security. Here the default group write permissions are turned off for system users and when the user name and group name are not the same.

cat > /etc/profile.d/umask.sh << "EOF"
# By default, the umask should be set.
if [ "$(id -gn)" = "$(id -un)" -a $EUID -gt 99 ] ; then
  umask 002
else
  umask 022
fi
EOF

/etc/profile.d/i18n.sh

This script sets an environment variable necessary for native language support. A full discussion on determining this variable can be found on the LFS Bash Shell Startup Files page.

cat > /etc/profile.d/i18n.sh << "EOF"
# Set up i18n variables
export LANG=<ll>_<CC>.<charmap><@modifiers>
EOF

Other Initialization Values

Other initialization can easily be added to the profile by adding additional scripts to the /etc/profile.d directory.

/etc/bashrc

Here is a base /etc/bashrc. Comments in the file should explain everything you need.

cat > /etc/bashrc << "EOF"
# Begin /etc/bashrc
# Written for Beyond Linux From Scratch
# by James Robertson <jameswrobertson@earthlink.net>
# updated by Bruce Dubbs <bdubbs@linuxfromscratch.org>

# System wide aliases and functions.

# System wide environment variables and startup programs should go into
# /etc/profile.  Personal environment variables and startup programs
# should go into ~/.bash_profile.  Personal aliases and functions should
# go into ~/.bashrc

# Provides colored /bin/ls and /bin/grep commands.  Used in conjunction
# with code in /etc/profile.

alias ls='ls --color=auto'
alias grep='grep --color=auto'

# Provides prompt for non-login shells, specifically shells started
# in the X environment. [Review the LFS archive thread titled
# PS1 Environment Variable for a great case study behind this script
# addendum.]

NORMAL="\[\e[0m\]"
RED="\[\e[1;31m\]"
GREEN="\[\e[1;32m\]"
if [[ $EUID == 0 ]] ; then
  PS1="$RED\u [ $NORMAL\w$RED ]# $NORMAL"
else
  PS1="$GREEN\u [ $NORMAL\w$GREEN ]\$ $NORMAL"
fi

unset RED GREEN NORMAL

# End /etc/bashrc
EOF

~/.bash_profile

Here is a base ~/.bash_profile. If you want each new user to have this file automatically, just change the output of the command to /etc/skel/.bash_profile and check the permissions after the command is run. You can then copy /etc/skel/.bash_profile to the home directories of already existing users, including root, and set the owner and group appropriately.

cat > ~/.bash_profile << "EOF"
# Begin ~/.bash_profile
# Written for Beyond Linux From Scratch
# by James Robertson <jameswrobertson@earthlink.net>
# updated by Bruce Dubbs <bdubbs@linuxfromscratch.org>

# Personal environment variables and startup programs.

# Personal aliases and functions should go in ~/.bashrc.  System wide
# environment variables and startup programs are in /etc/profile.
# System wide aliases and functions are in /etc/bashrc.

if [ -f "$HOME/.bashrc" ] ; then
  source $HOME/.bashrc
fi

if [ -d "$HOME/bin" ] ; then
  pathprepend $HOME/bin
fi

# Having . in the PATH is dangerous
#if [ $EUID -gt 99 ]; then
#  pathappend .
#fi

# End ~/.bash_profile
EOF

~/.profile

Here is a base ~/.profile. The comments and instructions for using /etc/skel for .bash_profile above also apply here. Only the target file names are different.

cat > ~/.profile << "EOF"
# Begin ~/.profile
# Personal environment variables and startup programs.

if [ -d "$HOME/bin" ] ; then
  pathprepend $HOME/bin
fi

# Set up user specific i18n variables
#export LANG=<ll>_<CC>.<charmap><@modifiers>

# End ~/.profile
EOF

~/.bashrc

Here is a base ~/.bashrc.

cat > ~/.bashrc << "EOF"
# Begin ~/.bashrc
# Written for Beyond Linux From Scratch
# by James Robertson <jameswrobertson@earthlink.net>

# Personal aliases and functions.

# Personal environment variables and startup programs should go in
# ~/.bash_profile.  System wide environment variables and startup
# programs are in /etc/profile.  System wide aliases and functions are
# in /etc/bashrc.

if [ -f "/etc/bashrc" ] ; then
  source /etc/bashrc
fi

# Set up user specific i18n variables
#export LANG=<ll>_<CC>.<charmap><@modifiers>

# End ~/.bashrc
EOF

~/.bash_logout

This is an empty ~/.bash_logout that can be used as a template. You will notice that the base ~/.bash_logout does not include a clear command. This is because the clear is handled in the /etc/issue file.

cat > ~/.bash_logout << "EOF"
# Begin ~/.bash_logout
# Written for Beyond Linux From Scratch
# by James Robertson <jameswrobertson@earthlink.net>

# Personal items to perform on logout.

# End ~/.bash_logout
EOF

/etc/dircolors

If you want to use the dircolors capability, then run the following command. The /etc/skel setup steps shown above also can be used here to provide a ~/.dircolors file when a new user is set up. As before, just change the output file name on the following command and assure the permissions, owner, and group are correct on the files created and/or copied.

dircolors -p > /etc/dircolors

If you wish to customize the colors used for different file types, you can edit the /etc/dircolors file. The instructions for setting the colors are embedded in the file.

Finally, Ian Macdonald has written an excellent collection of tips and tricks to enhance your shell environment. You can read it online at http://www.caliban.org/bash/index.shtml.

Last updated on

The /etc/vimrc and ~/.vimrc Files

The LFS book installs Vim as its text editor. At this point it should be noted that there are a lot of different editing applications out there including Emacs, nano, Joe and many more. Anyone who has been around the Internet (especially usenet) for a short time will certainly have observed at least one flame war, usually involving Vim and Emacs users!

The LFS book creates a basic vimrc file. In this section you'll find an attempt to enhance this file. At startup, vim reads the global configuration file (/etc/vimrc) as well as a user-specific file (~/.vimrc). Either or both can be tailored to suit the needs of your particular system.

Here is a slightly expanded .vimrc that you can put in ~/.vimrc to provide user specific effects. Of course, if you put it into /etc/skel/.vimrc instead, it will be made available to users you add to the system later. You can also copy the file from /etc/skel/.vimrc to the home directory of users already on the system, such as root. Be sure to set permissions, owner, and group if you do copy anything directly from /etc/skel.

" Begin .vimrc

set columns=80
set wrapmargin=8
set ruler

" End .vimrc

Note that the comment tags are " instead of the more usual # or //. This is correct, the syntax for vimrc is slightly unusual.

Below you'll find a quick explanation of what each of the options in this example file means here:

  • set columns=80: This simply sets the number of columns used on the screen.

  • set wrapmargin=8: This is the number of characters from the right window border where wrapping starts.

  • set ruler: This makes vim show the current row and column at the bottom right of the screen.

More information on the many vim options can be found by reading the help inside vim itself. Do this by typing :help in vim to get the general help, or by typing :help usr_toc.txt to view the User Manual Table of Contents.

Last updated on

Customizing your Logon with /etc/issue

When you first boot up your new LFS system, the logon screen will be nice and plain (as it should be in a bare-bones system). Many people however, will want their system to display some information in the logon message. This can be accomplished using the file /etc/issue.

The /etc/issue file is a plain text file which will also accept certain escape sequences (see below) in order to insert information about the system. There is also the file issue.net which can be used when logging on remotely. ssh however, will only use it if you set the option in the configuration file and will not interpret the escape sequences shown below.

One of the most common things which people want to do is clear the screen at each logon. The easiest way of doing that is to put a "clear" escape sequence into /etc/issue. A simple way of doing this is to issue the command clear > /etc/issue. This will insert the relevant escape code into the start of the /etc/issue file. Note that if you do this, when you edit the file, you should leave the characters (normally '^[[H^[[2J') on the first line alone.

Note

Terminal escape sequences are special codes recognized by the terminal. The ^[ represents an ASCII ESC character. The sequence ESC [ H puts the cursor in the upper left hand corner of the screen and ESC 2 J erases the screen. For more information on terminal escape sequences see http://rtfm.etla.org/xterm/ctlseq.html

The following sequences are recognized by agetty (the program which usually parses /etc/issue). This information is from man agetty where you can find extra information about the logon process.

The issue file can contain certain character sequences to display various information. All issue sequences consist of a backslash (\) immediately followed by one of the letters explained below (so \d in /etc/issue would insert the current date).

b   Insert the baudrate of the current line.
d   Insert the current date.
s   Insert the system name, the name of the operating system.
l   Insert the name of the current tty line.
m   Insert the architecture identifier of the machine, e.g., i686.
n   Insert the nodename of the machine, also known as the hostname.
o   Insert the domainname of the machine.
r   Insert the release number of the kernel, e.g., 2.6.11.12.
t   Insert the current time.
u   Insert the number of current users logged in.
U   Insert the string "1 user" or "<n> users" where <n> is the
    number of current users logged in.
v   Insert the version of the OS, e.g., the build-date etc.

Last updated on

Random Number Generation

The Linux kernel supplies a random number generator which is accessed through /dev/random and /dev/urandom. Programs that utilize the random and urandom devices, such as OpenSSH, will benefit from these instructions.

When a Linux system starts up without much operator interaction, the entropy pool (data used to compute a random number) may be in a fairly predictable state. This creates the real possibility that the number generated at startup may always be the same. In order to counteract this effect, you should carry the entropy pool information across your shut-downs and start-ups.

Install the /etc/rc.d/init.d/random init script included with the blfs-bootscripts-20210826 package.

make install-random

Last updated on

Chapter 4. Security

Security takes many forms in a computing environment. After some initial discussion, this chapter gives examples of three different types of security: access, prevention and detection.

Access for users is usually handled by login or an application designed to handle the login function. In this chapter, we show how to enhance login by setting policies with PAM modules. Access via networks can also be secured by policies set by iptables, commonly referred to as a firewall. The Network Security Services (NSS) and Netscape Portable Runtime (NSPR) libraries can be installed and shared among the many applications requiring them. For applications that don't offer the best security, you can use the Stunnel package to wrap an application daemon inside an SSL tunnel.

Prevention of breaches, like a trojan, are assisted by applications like GnuPG, specifically the ability to confirm signed packages, which recognizes modifications of the tarball after the packager creates it.

Finally, we touch on detection with a package that stores "signatures" of critical files (defined by the administrator) and then regenerates those "signatures" and compares for files that have been changed.

Vulnerabilities

About vulnerabilities

All software has bugs. Sometimes, a bug can be exploited, for example to allow users to gain enhanced privileges (perhaps gaining a root shell, or simply accessing or deleting other user's files), or to allow a remote site to crash an application (denial of service), or for theft of data. These bugs are labelled as vulnerabilities.

The main place where vulnerabilities get logged is cve.mitre.org. Unfortunately, many vulnerability numbers (CVE-yyyy-nnnn) are initially only labelled as "reserved" when distributions start issuing fixes. Also, some vulnerabilities apply to particular combinations of configure options, or only apply to old versions of packages which have long since been updated in BLFS.

BLFS differs from distributions—there is no BLFS security team, and the editors only become aware of vulnerabilities after they are public knowledge. Sometimes, a package with a vulnerability will not be updated in the book for a long time. Issues can be logged in the Trac system, which might speed up resolution.

The normal way for BLFS to fix a vulnerability is, ideally, to update the book to a new fixed release of the package. Sometimes that happens even before the vulnerability is public knowledge, so there is no guarantee that it will be shown as a vulnerability fix in the Changelog. Alternatively, a sed command, or a patch taken from a distribution, may be appropriate.

The bottom line is that you are responsible for your own security, and for assessing the potential impact of any problems.

The editors now issue Security Advisories for packages in BLFS (and LFS), which can be found at BLFS Security Advisories, and grade the severity according to what upstream reports, or to what is shown at nvd.nist.gov if that has details.

To keep track of what is being discovered, you may wish to follow the security announcements of one or more distributions. For example, Debian has Debian security. Fedora's links on security are at the Fedora wiki. Details of Gentoo linux security announcements are discussed at Gentoo security. Finally, the Slackware archives of security announcements are at Slackware security.

The most general English source is perhaps the Full Disclosure Mailing List, but please read the comment on that page. If you use other languages you may prefer other sites such as heise.de (German) or cert.hr (Croatian). These are not linux-specific. There is also a daily update at lwn.net for subscribers (free access to the data after 2 weeks, but their vulnerabilities database at lwn.net/Vulnerabilities is unrestricted).

For some packages, subscribing to their 'announce' lists will provide prompt news of newer versions.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/vulnerabilities

Last updated on

make-ca-1.10

Introduction to make-ca

Public Key Infrastructure (PKI) is a method to validate the authenticity of an otherwise unknown entity across untrusted networks. PKI works by establishing a chain of trust, rather than trusting each individual host or entity explicitly. In order for a certificate presented by a remote entity to be trusted, that certificate must present a complete chain of certificates that can be validated using the root certificate of a Certificate Authority (CA) that is trusted by the local machine.

Establishing trust with a CA involves validating things like company address, ownership, contact information, etc., and ensuring that the CA has followed best practices, such as undergoing periodic security audits by independent investigators and maintaining an always available certificate revocation list. This is well outside the scope of BLFS (as it is for most Linux distributions). The certificate store provided here is taken from the Mozilla Foundation, who have established very strict inclusion policies described here.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

make-ca Dependencies

Required

p11-kit-0.24.1 (required at runtime to generate certificate stores from trust anchors)

Optional (runtime)

nss-3.75 (to generate a shared NSSDB)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/make-ca

Installation of make-ca

The make-ca script will download and process the certificates included in the certdata.txt file for use as trust anchors for the p11-kit-0.24.1 trust module. Additionally, it will generate system certificate stores used by BLFS applications (if the recommended and optional applications are present on the system). Any local certificates stored in /etc/ssl/local will be imported to both the trust anchors and the generated certificate stores (overriding Mozilla's trust). Additionally, any modified trust values will be copied from the trust anchors to /etc/ssl/local prior to any updates, preserving custom trust values that differ from Mozilla when using the trust utility from p11-kit to operate on the trust store.

To install the various certificate stores, first install the make-ca script into the correct location. As the root user:

make install &&
install -vdm755 /etc/ssl/local

As the root user, after installing p11-kit-0.24.1, download the certificate source and prepare for system use with the following command:

Note

If running the script a second time with the same version of certdata.txt, for instance, to update the stores when make-ca is upgraded, or to add additional stores as the requisite software is installed, replace the -g switch with the -r switch in the command line. If packaging, run make-ca --help to see all available command line options.

/usr/sbin/make-ca -g

You should periodically update the store with the above command, either manually, or via a cron job. If you've installed Fcron-3.2.1 and completed the section on periodic jobs, execute the following commands, as the root user, to create a weekly cron job:

cat > /etc/cron.weekly/update-pki.sh << "EOF" &&
#!/bin/bash
/usr/sbin/make-ca -g
EOF
chmod 754 /etc/cron.weekly/update-pki.sh

Configuring make-ca

For most users, no additional configuration is necessary, however, the default certdata.txt file provided by make-ca is obtained from the mozilla-release branch, and is modified to provide a Mercurial revision. This will be the correct version for most systems. There are several other variants of the file available for use that might be preferred for one reason or another, including the files shipped with Mozilla products in this book. RedHat and OpenSUSE, for instance, use the version included in nss-3.75. Additional upstream downloads are available at the links included in /etc/make-ca.conf.dist. Simply copy the file to /etc/make-ca.conf and edit as appropriate.

About Trust Arguments

There are three trust types that are recognized by the make-ca script, SSL/TLS, S/Mime, and code signing. For OpenSSL, these are serverAuth, emailProtection, and codeSigning respectively. If one of the three trust arguments is omitted, the certificate is neither trusted, nor rejected for that role. Clients that use OpenSSL or NSS encountering this certificate will present a warning to the user. Clients using GnuTLS without p11-kit support are not aware of trusted certificates. To include this CA into the ca-bundle.crt, email-ca-bundle.crt, or objsign-ca-bundle.crt files (the GnuTLS legacy bundles), it must have the appropriate trust arguments.

Adding Additional CA Certificates

The /etc/ssl/local directory is available to add additional CA certificates to the system trust store. This directory is also used to store certificates that were added to or modified in the system trust store by p11-kit-0.24.1 so that trust values are maintained across upgrades. Files in this directory must be in the OpenSSL trusted certificate format. Certificates imported using the trust utility from p11-kit-0.24.1 will utilize the x509 Extended Key Usage values to assign default trust values for the system anchors.

If you need to override trust values, or otherwise need to create an OpenSSL trusted certificate manually from a regular PEM encoded file, you need to add trust arguments to the openssl command, and create a new certificate. For example, using the CAcert roots, if you want to trust both for all three roles, the following commands will create appropriate OpenSSL trusted certificates (run as the root user after Wget-1.21.2 is installed):

wget http://www.cacert.org/certs/root.crt &&
wget http://www.cacert.org/certs/class3.crt &&
openssl x509 -in root.crt -text -fingerprint -setalias "CAcert Class 1 root" \
        -addtrust serverAuth -addtrust emailProtection -addtrust codeSigning \
        > /etc/ssl/local/CAcert_Class_1_root.pem &&
openssl x509 -in class3.crt -text -fingerprint -setalias "CAcert Class 3 root" \
        -addtrust serverAuth -addtrust emailProtection -addtrust codeSigning \
        > /etc/ssl/local/CAcert_Class_3_root.pem &&
/usr/sbin/make-ca -r

Overriding Mozilla Trust

Occasionally, there may be instances where you don't agree with Mozilla's inclusion of a particular certificate authority. If you'd like to override the default trust of a particular CA, simply create a copy of the existing certificate in /etc/ssl/local with different trust arguments. For example, if you'd like to distrust the "Makebelieve_CA_Root" file, run the following commands:

openssl x509 -in /etc/ssl/certs/Makebelieve_CA_Root.pem \
             -text \
             -fingerprint \
             -setalias "Disabled Makebelieve CA Root" \
             -addreject serverAuth \
             -addreject emailProtection \
             -addreject codeSigning \
       > /etc/ssl/local/Disabled_Makebelieve_CA_Root.pem &&
/usr/sbin/make-ca -r

Contents

Installed Programs: make-ca
Installed Directories: /etc/ssl/{certs,local} and /etc/pki/{nssdb,anchors,tls/{certs,java}}

Short Descriptions

make-ca

is a shell script that adapts a current version of certdata.txt, and prepares it for use as the system trust store

Last updated on

CrackLib-2.9.7

Introduction to CrackLib

The CrackLib package contains a library used to enforce strong passwords by comparing user selected passwords to words in chosen word lists.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

There are additional word lists available for download, e.g., from http://www.cotse.com/tools/wordlists.htm. CrackLib can utilize as many, or as few word lists you choose to install.

Important

Users tend to base their passwords on regular words of the spoken language, and crackers know that. CrackLib is intended to filter out such bad passwords at the source using a dictionary created from word lists. To accomplish this, the word list(s) for use with CrackLib must be an exhaustive list of words and word-based keystroke combinations likely to be chosen by users of the system as (guessable) passwords.

The default word list recommended above for downloading mostly satisfies this role in English-speaking countries. In other situations, it may be necessary to download (or even create) additional word lists.

Note that word lists suitable for spell-checking are not usable as CrackLib word lists in countries with non-Latin based alphabets, because of word-based keystroke combinations that make bad passwords.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/cracklib

Installation of CrackLib

Install CrackLib by running the following commands:

sed -i '/skipping/d' util/packer.c &&

sed -i '15209 s/.*/am_cv_python_version=3.10/' configure &&

PYTHON=python3 CPPFLAGS=-I/usr/include/python3.10 \
./configure --prefix=/usr    \
            --disable-static \
            --with-default-dict=/usr/lib/cracklib/pw_dict &&
make

Now, as the root user:

make install

Issue the following commands as the root user to install the recommended word list and create the CrackLib dictionary. Other word lists (text based, one word per line) can also be used by simply installing them into /usr/share/dict and adding them to the create-cracklib-dict command.

install -v -m644 -D    ../cracklib-words-2.9.7.bz2 \
                         /usr/share/dict/cracklib-words.bz2    &&

bunzip2 -v               /usr/share/dict/cracklib-words.bz2    &&
ln -v -sf cracklib-words /usr/share/dict/words                 &&
echo $(hostname) >>      /usr/share/dict/cracklib-extra-words  &&
install -v -m755 -d      /usr/lib/cracklib                     &&

create-cracklib-dict     /usr/share/dict/cracklib-words \
                         /usr/share/dict/cracklib-extra-words

If desired, check the proper operation of the library as an unprivileged user by issuing the following command:

make test

Important

If you are installing CrackLib after your LFS system has been completed and you have the Shadow package installed, you must reinstall Shadow-4.11.1 if you wish to provide strong password support on your system. If you are now going to install the Linux-PAM-1.5.2 package, you may disregard this note as Shadow will be reinstalled after the Linux-PAM installation.

Command Explanations

sed -i '/skipping/d' util/packer.c: Remove a meaningless warning.

PYTHON=python3: This forces the installation of python bindings for Python 3, even if Python 2 is installed.

CPPFLAGS=-I/usr/include/python3.10: This works around an issue caused by incorrect usage of Python 3 headers.

--with-default-dict=/lib/cracklib/pw_dict: This parameter forces the installation of the CrackLib dictionary to the /lib hierarchy.

--disable-static: This switch prevents installation of static versions of the libraries.

install -v -m644 -D ...: This command creates the /usr/share/dict directory (if it doesn't already exist) and installs the compressed word list there.

ln -v -s cracklib-words /usr/share/dict/words: The word list is linked to /usr/share/dict/words as historically, words is the primary word list in the /usr/share/dict directory. Omit this command if you already have a /usr/share/dict/words file installed on your system.

echo $(hostname) >>...: The value of hostname is echoed to a file called cracklib-extra-words. This extra file is intended to be a site specific list which includes easy to guess passwords such as company or department names, user names, product names, computer names, domain names, etc.

create-cracklib-dict ...: This command creates the CrackLib dictionary from the word lists. Modify the command to add any additional word lists you have installed.

Contents

Installed Programs: cracklib-check, cracklib-format, cracklib-packer, cracklib-unpacker and create-cracklib-dict
Installed Libraries: libcrack.so and the _cracklib.so (Python module)
Installed Directories: /lib/cracklib, /usr/share/dict and /usr/share/cracklib

Short Descriptions

cracklib-check

is used to determine if a password is strong

cracklib-format

is used to format text files (lowercases all words, removes control characters and sorts the lists)

cracklib-packer

creates a database with words read from standard input

cracklib-unpacker

displays on standard output the database specified

create-cracklib-dict

is used to create the CrackLib dictionary from the given word list(s)

libcrack.so

provides a fast dictionary lookup method for strong password enforcement

Last updated on

cryptsetup-2.4.3

Introduction to cryptsetup

cryptsetup is used to set up transparent encryption of block devices using the kernel crypto API.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

cryptsetup Dependencies

Required

JSON-C-0.15, LVM2-2.03.15, and popt-1.18

Optional

libpwquality-1.4.4, argon2, libssh, and passwdqc

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/cryptsetup

Kernel Configuration

Encrypted block devices require kernel support. To use it, the appropriate kernel configuration parameters need to be set:

Device Drivers  --->
  [*] Multiple devices driver support (RAID and LVM) ---> [CONFIG_MD]
       <*/M> Device mapper support                        [CONFIG_BLK_DEV_DM]
       <*/M> Crypt target support                         [CONFIG_DM_CRYPT]

Cryptographic API  --->
  <*/M> XTS support                                       [CONFIG_CRYPTO_XTS]
  <*/M> SHA224 and SHA256 digest algorithm                [CONFIG_CRYPTO_SHA256]
  <*/M> AES cipher algorithms                             [CONFIG_CRYPTO_AES]
  <*/M> User-space interface for symmetric key cipher algorithms
                                                          [CONFIG_CRYPTO_USER_API_SKCIPHER]
  For tests:
  <*/M> Twofish cipher algorithm                          [CONFIG_CRYPTO_TWOFISH]

Installation of cryptsetup

Install cryptsetup by running the following commands:

./configure --prefix=/usr --disable-ssh-token &&
make

To test the result, issue as the root user: make check. Some tests will fail if appropriate kernel configuration options are not set. Some additional options that may be needed for tests are: CONFIG_SCSI_LOWLEVEL, CONFIG_SCSI_DEBUG, CONFIG_BLK_DEV_DM_BUILTIN, CONFIG_CRYPTO_USER, CONFIG_CRYPTO_CRYPTD, CONFIG_CRYPTO_LRW, CONFIG_CRYPTO_XTS, CONFIG_CRYPTO_ESSIV, CONFIG_CRYPTO_CRCT10DIF, CONFIG_CRYPTO_AES_TI, CONFIG_CRYPTO_AES_NI_INTEL, CONFIG_CRYPTO_BLOWFISH, CONFIG_CRYPTO_CAST5, CONFIG_CRYPTO_SERPENT, CONFIG_CRYPTO_SERPENT_SSE2_X86_64, CONFIG_CRYPTO_SERPENT_AVX_X86_64, CONFIG_CRYPTO_SERPENT_AVX2_X86_64, and CONFIG_CRYPTO_TWOFISH_X86_64.

Now, as the root user:

make install

Command Explanations

--disable-ssh-token: This option is required if the optional libssh dependency is not installed.

Configuring cryptsetup

Because of the number of possible configurations, setup of encrypted volumes is beyond the scope of the BLFS book. Please see the configuration guide in the cryptsetup FAQ.

Contents

Installed Programs: cryptsetup, cryptsetup-reencrypt, integritysetup, and veritysetup
Installed Libraries: libcryptsetup.so
Installed Directories: None

Short Descriptions

cryptsetup

is used to setup dm-crypt managed device-mapper mappings

cryptsetup-reencrypt

is a tool for offline LUKS device re-encryption

integritysetup

is a tool to manage dm-integrity (block level integrity) volumes

veritysetup

is used to configure dm-verity managed device-mapper mappings. Device-mapper verity target provides read-only transparent integrity checking of block devices using kernel crypto API

Last updated on

Cyrus SASL-2.1.27

Introduction to Cyrus SASL

The Cyrus SASL package contains a Simple Authentication and Security Layer, a method for adding authentication support to connection-based protocols. To use SASL, a protocol includes a command for identifying and authenticating a user to a server and for optionally negotiating protection of subsequent protocol interactions. If its use is negotiated, a security layer is inserted between the protocol and the connection.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Cyrus SASL Dependencies

Recommended
Optional

Linux-PAM-1.5.2, MIT Kerberos V5-1.19.2, MariaDB-10.6.7 or MySQL, OpenJDK-17.0.2, OpenLDAP-2.6.1, PostgreSQL-14.2, SQLite-3.37.2, krb4, Dmalloc, Pod::POM::View::Restructured, and Sphinx

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/cyrus-sasl

Installation of Cyrus SASL

Note

This package does not support parallel build.

First, fix a build failure if Sphinx or docutils-0.18.1 is installed on the system:

patch -Np1 -i ../cyrus-sasl-2.1.27-doc_fixes-1.patch

Install Cyrus SASL by running the following commands:

./configure --prefix=/usr        \
            --sysconfdir=/etc    \
            --enable-auth-sasldb \
            --with-dbpath=/var/lib/sasl/sasldb2 \
            --with-sphinx-build=no              \
            --with-saslauthd=/var/run/saslauthd &&
make -j1

This package does not come with a test suite. If you are planning on using the GSSAPI authentication mechanism, test it after installing the package using the sample server and client programs which were built in the preceding step. Instructions for performing the tests can be found at https://www.linuxfromscratch.org/hints/downloads/files/cyrus-sasl.txt.

Now, as the root user:

make install &&
install -v -dm755                          /usr/share/doc/cyrus-sasl-2.1.27/html &&
install -v -m644  saslauthd/LDAP_SASLAUTHD /usr/share/doc/cyrus-sasl-2.1.27      &&
install -v -m644  doc/legacy/*.html        /usr/share/doc/cyrus-sasl-2.1.27/html &&
install -v -dm700 /var/lib/sasl

Command Explanations

--with-dbpath=/var/lib/sasl/sasldb2: This switch forces the sasldb database to be created in /var/lib/sasl instead of /etc.

--with-saslauthd=/var/run/saslauthd: This switch forces saslauthd to use the FHS compliant directory /var/run/saslauthd for variable run-time data.

--enable-auth-sasldb: This switch enables SASLDB authentication backend.

--with-dblib=gdbm: This switch forces GDBM to be used instead of Berkeley DB.

--with-ldap: This switch enables the OpenLDAP support.

--enable-ldapdb: This switch enables the LDAPDB authentication backend. There is a circular dependency with this parameter. See https://wiki.linuxfromscratch.org/blfs/wiki/cyrus-sasl for a solution to this problem.

--enable-java: This switch enables compiling of the Java support libraries.

--enable-login: This option enables unsupported LOGIN authentication.

--enable-ntlm: This option enables unsupported NTLM authentication.

install -v -m644 ...: These commands install documentation which is not installed by the make install command.

install -v -m700 -d /var/lib/sasl: This directory must exist when starting saslauthd or using the sasldb plugin. If you're not going to be running the daemon or using the plugins, you may omit the creation of this directory.

Configuring Cyrus SASL

Config Files

/etc/saslauthd.conf (for saslauthd LDAP configuration) and /etc/sasl2/Appname.conf (where "Appname" is the application defined name of the application)

Configuration Information

See https://www.cyrusimap.org/sasl/sasl/sysadmin.html for information on what to include in the application configuration files.

See file:///usr/share/doc/cyrus-sasl-2.1.27/LDAP_SASLAUTHD for configuring saslauthd with OpenLDAP.

See https://www.cyrusimap.org/sasl/sasl/gssapi.html#gssapi for configuring saslauthd with Kerberos.

Init Script

If you need to run the saslauthd daemon at system startup, install the /etc/rc.d/init.d/saslauthd init script included in the blfs-bootscripts-20210826 package using the following command:

make install-saslauthd

Note

You'll need to modify /etc/sysconfig/saslauthd and modify the AUTHMECH parameter with your desired authentication mechanism.

Contents

Installed Programs: pluginviewer, saslauthd, sasldblistusers2, saslpasswd2 and testsaslauthd
Installed Library: libsasl2.so
Installed Directories: /usr/include/sasl, /usr/lib/sasl2, /usr/share/doc/cyrus-sasl-2.1.27 and /var/lib/sasl

Short Descriptions

pluginviewer

is used to list loadable SASL plugins and their properties

saslauthd

is the SASL authentication server

sasldblistusers2

is used to list the users in the SASL password database sasldb2

saslpasswd2

is used to set and delete a user's SASL password and mechanism specific secrets in the SASL password database sasldb2

testsaslauthd

is a test utility for the SASL authentication server

libsasl2.so

is a general purpose authentication library for server and client applications

Last updated on

GnuPG-2.2.34

Introduction to GnuPG

The GnuPG package is GNU's tool for secure communication and data storage. It can be used to encrypt data and to create digital signatures. It includes an advanced key management facility and is compliant with the proposed OpenPGP Internet standard as described in RFC2440 and the S/MIME standard as described by several RFCs. GnuPG 2 is the stable version of GnuPG integrating support for OpenPGP and S/MIME.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GnuPG 2 Dependencies

Required

libassuan-2.5.5, libgcrypt-1.10.0, libksba-1.6.0, and npth-1.6

Recommended
Optional

cURL-7.81.0, Fuse-3.10.5, ImageMagick-7.1.0-25 (for the convert utility, used for generating the documentation), libusb-1.0.25, an MTA, OpenLDAP-2.6.1, SQLite-3.37.2, texlive-20210325 (or install-tl-unx), fig2dev (for generating documentation), and GNU adns

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnupg2

Installation of GnuPG

By default GnuPG doesn't install the deprecated gpg-zip script, but it is still needed by some programs. Make GnuPG install it with:

sed -e '/noinst_SCRIPTS = gpg-zip/c sbin_SCRIPTS += gpg-zip' \
    -i tools/Makefile.in

Install GnuPG by running the following commands:

./configure --prefix=/usr            \
            --localstatedir=/var     \
            --sysconfdir=/etc        \
            --docdir=/usr/share/doc/gnupg-2.2.34 &&
make &&

makeinfo --html --no-split -o doc/gnupg_nochunks.html doc/gnupg.texi &&
makeinfo --plaintext       -o doc/gnupg.txt           doc/gnupg.texi &&
make -C doc html

If you have texlive-20210325 installed and you wish to create documentation in alternate formats, issue the following commands (fig2dev is needed for the ps format):

make -C doc pdf ps

To test the results, issue: make check.

Note that if you have already installed GnuPG, the instructions below will overwrite /usr/share/man/man1/gpg-zip.1. Now, as the root user:

make install &&

install -v -m755 -d /usr/share/doc/gnupg-2.2.34/html            &&
install -v -m644    doc/gnupg_nochunks.html \
                    /usr/share/doc/gnupg-2.2.34/html/gnupg.html &&
install -v -m644    doc/*.texi doc/gnupg.txt \
                    /usr/share/doc/gnupg-2.2.34 &&
install -v -m644    doc/gnupg.html/* \
                    /usr/share/doc/gnupg-2.2.34/html

If you created alternate formats of the documentation, install them using the following command as the root user:

install -v -m644 doc/gnupg.{pdf,dvi,ps} \
                 /usr/share/doc/gnupg-2.2.34

Command Explanations

sed ... tools/Makefile.in: This command is needed to build the gpg-zip program.

--docdir=/usr/share/doc/gnupg-2.2.34: This switch changes the default docdir to /usr/share/doc/gnupg-2.2.34.

--enable-all-tests: This switch allows more tests to be run with make check.

--enable-g13: This switch enables building the g13 program.

Contents

Installed Programs: addgnupghome, applygnupgdefaults, dirmngr, dirmngr-client, g13 (optional), gpg-agent, gpg-connect-agent, gpg, gpgconf, gpgparsemail, gpgscm, gpgsm, gpgsplit, gpgtar, gpgv, gpg-wks-server, gpg-zip, kbxutil, and watchgnupg
Installed Libraries: None
Installed Directories: /usr/share/doc/gnupg-2.2.34 and /usr/share/gnupg

Short Descriptions

addgnupghome

is used to create and populate a user's ~/.gnupg directories

applygnupgdefaults

is a wrapper script used to run gpgconf with the --apply-defaults parameter on all user's GnuPG home directories

dirmngr

is a tool that takes care of accessing the OpenPGP keyservers

dirmngr-client

is a tool to contact a running dirmngr and test whether a certificate has been revoked

g13

is a tool to create, mount or unmount an encrypted file system container (optional)

gpg-agent

is a daemon used to manage secret (private) keys independently from any protocol. It is used as a backend for gpg and gpgsm as well as for a couple of other utilities

gpg-connect-agent

is a utility used to communicate with a running gpg-agent

gpg

is the OpenPGP part of the GNU Privacy Guard (GnuPG). It is a tool used to provide digital encryption and signing services using the OpenPGP standard

gpgconf

is a utility used to automatically and reasonably safely query and modify configuration files in the ~/.gnupg home directory. It is designed not to be invoked manually by the user, but automatically by graphical user interfaces

gpgparsemail

is a utility currently only useful for debugging. Run it with --help for usage information

gpgscm

executes the given scheme program or spawns an interactive shell

gpgsm

is a tool similar to gpg used to provide digital encryption and signing services on X.509 certificates and the CMS protocol. It is mainly used as a backend for S/MIME mail processing

gpgsplit

splits an OpenPGP message into packets

gpgtar

is a tool to encrypt or sign files into an archive

gpgv

is a verify only version of gpg

gpg-wks-server

provides a server for the Web Key Service protocol

gpg-zip

encrypts or signs files into an archive

kbxutil

is used to list, export and import Keybox data

watchgnupg

is used to listen to a Unix Domain socket created by any of the GnuPG tools

Last updated on

GnuTLS-3.7.3

Introduction to GnuTLS

The GnuTLS package contains libraries and userspace tools which provide a secure layer over a reliable transport layer. Currently the GnuTLS library implements the proposed standards by the IETF's TLS working group. Quoting from the TLS protocol specification:

The TLS protocol provides communications privacy over the Internet. The protocol allows client/server applications to communicate in a way that is designed to prevent eavesdropping, tampering, or message forgery.

GnuTLS provides support for TLS 1.3, TLS 1.2, TLS 1.1, TLS 1.0, and SSL 3.0 protocols, TLS extensions, including server name and max record size. Additionally, the library supports authentication using the SRP protocol, X.509 certificates and OpenPGP keys, along with support for the TLS Pre-Shared-Keys (PSK) extension, the Inner Application (TLS/IA) extension and X.509 and OpenPGP certificate handling.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GnuTLS Dependencies

Required

Nettle-3.7.3

Recommended
Optional

Doxygen-1.9.3, GTK-Doc-1.33.2, Guile-3.0.8, libidn-1.38 or libidn2-2.3.2, libseccomp-2.5.3, Net-tools-2.10 (used during the test suite), texlive-20210325 or install-tl-unx, Unbound-1.15.0 (to build the DANE library), Valgrind-3.18.1 (used during the test suite), autogen, cmocka and datefudge (used during the test suite if the DANE library is built), and Trousers (Trusted Platform Module support)

Note

Note that if you do not install libtasn1-4.18.0, an older version shipped in the GnuTLS tarball will be used instead.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnutls

Installation of GnuTLS

Install GnuTLS by running the following commands:

./configure --prefix=/usr \
            --docdir=/usr/share/doc/gnutls-3.7.3 \
            --disable-guile \
            --disable-rpath \
            --with-default-trust-store-pkcs11="pkcs11:" &&
make

To test the results, issue: make check.

Now, as the root user:

make install

If you passed --enable-gtk-doc to the configure script, the API will automatically be installed. Otherwise, if desired, you can still install the API documentation to the /usr/share/gtk-doc/html/gnutls directory using the following command as the root user:

make -C doc/reference install-data-local

Command Explanations

--with-default-trust-store-pkcs11="pkcs11:": This switch tells gnutls to use the PKCS #11 trust store as the default trust. Omit this switch if p11-kit-0.24.1 is not installed.

--disable-guile: This switch disables GUILE support, since GnuTLS does not support Guile-2.2.x yet.

--disable-rpath: This switch prevents building GnuTLS utilities and tests with hardcoded runtime library search path. Hardcoded rpath is unneeded for BLFS, and it causes test failures if an old version of GnuTLS is installed.

--with-default-trust-store-file=/etc/pki/tls/certs/ca-bundle.crt: This switch tells configure where to find the legacy CA certificate bundle and to use it instead of PKCS #11 module by default. Use this if p11-kit-0.24.1 is not installed.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

--enable-openssl-compatibility: Use this switch if you wish to build the OpenSSL compatibility library.

--without-p11-kit: use this switch if you have not installed p11-kit.

--with-included-unistring: uses the bundled version of libunistring, instead of the system one. Use this switch if you have not installed libunistring-1.0.

Contents

Installed Programs: certtool, danetool, gnutls-cli, gnutls-cli-debug, gnutls-serv, ocsptool, p11tool, psktool, and srptool
Installed Libraries: libgnutls.so, libgnutls-dane.so, libgnutlsxx.so, and libgnutls-openssl.so (optional)
Installed Directories: /usr/include/gnutls, /usr/share/gtk-doc/html/gnutls, and /usr/share/doc/gnutls-3.7.3

Short Descriptions

certtool

is used to generate X.509 certificates, certificate requests, and private keys

danetool

is a tool used to generate and check DNS resource records for the DANE protocol

gnutls-cli

is a simple client program to set up a TLS connection to some other computer

gnutls-cli-debug

is a simple client program to set up a TLS connection to some other computer and produces very verbose progress results

gnutls-serv

is a simple server program that listens to incoming TLS connections

ocsptool

is a program that can parse and print information about OCSP requests/responses, generate requests and verify responses

p11tool

is a program that allows handling data from PKCS #11 smart cards and security modules

psktool

is a simple program that generates random keys for use with TLS-PSK

srptool

is a simple program that emulates the programs in the Stanford SRP (Secure Remote Password) libraries using GnuTLS

libgnutls.so

contains the core API functions and X.509 certificate API functions

Last updated on

GPGME-1.17.0

Introduction to GPGME

The GPGME package is a C library that allows cryptography support to be added to a program. It is designed to make access to public key crypto engines like GnuPG or GpgSM easier for applications. GPGME provides a high-level crypto API for encryption, decryption, signing, signature verification and key management.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GPGME Dependencies

Required

libassuan-2.5.5

Optional

Doxygen-1.9.3 and Graphviz-2.50.0 (for API documentation), GnuPG-2.2.34 (required if Qt or SWIG are installed; used during the testsuite), Clisp-2.49, Qt-5.15.2, and/or SWIG-4.0.2 (for language bindings)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gpgme

Installation of GPGME

First, fix an issue building the package with Glibc-2.34 or later:

sed 's/defined(__sun.*$/1/' -i src/posix-io.c

Next, fix an issue building with Python 3.10 installed:

sed -e 's/3\.9/3.10/'                    \
    -e 's/:3/:4/'                        \
    -e '23653 s/distutils"/setuptools"/' \
    -i configure

Install GPGME by running the following commands:

./configure --prefix=/usr --disable-gpg-test &&
make

To test the results, you should have GnuPG-2.2.34 installed and remove the --disable-gpg-test above. Issue: make -k check.

Now, as the root user:

make install

Command Explanations

--disable-gpg-test: if this parameter is not passed to configure, the test programs are built during make stage, which requires GnuPG-2.2.34. This parameter is not needed if GnuPG-2.2.34 is installed.

Contents

Installed Program: gpgme-config, gpgme-json, and gpgme-tool
Installed Libraries: libgpgme, libgpgmepp.so, and libqgpgme.so
Installed Directory: /usr/include/{gpgme++,qgpgme,QGpgME}, /usr/lib/cmake/{Gpgmepp,QGpgme}. /usr/lib/python{2.7,3.9}/site-packages/gpg, and /usr/share/common-lisp/source/gpgme

Short Descriptions

gpgme-config

is used to obtain GPGME compilation and linking information

gpgme-json

outputs GPGME commands in JSON format

gpgme-tool

is an assuan server exposing GPGME operations, such as printing fingerprints and keyids with keyservers

libgpgme.so

contains the GPGME API functions

libgpgmepp.so

contains the C++ GPGME API functions

libqgpgme.so

contains API functions for handling GPG operations in Qt applications

Last updated on

iptables-1.8.7

Introduction to iptables

iptables is a userspace command line program used to configure the Linux 2.4 and later kernel packet filtering ruleset.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

iptables Dependencies

Optional

libpcap-1.10.1 (required for nfsypproxy support), bpf-utils (required for Berkeley Packet Filter support), libnfnetlink (required for connlabel support), libnetfilter_conntrack (required for connlabel support), and nftables

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/iptables

Kernel Configuration

A firewall in Linux is accomplished through the netfilter interface. To use iptables to configure netfilter, the following kernel configuration parameters are required:

[*] Networking support  --->                                          [CONFIG_NET]
      Networking Options  --->
        [*] Network packet filtering framework (Netfilter) --->       [CONFIG_NETFILTER]
          [*] Advanced netfilter configuration                        [CONFIG_NETFILTER_ADVANCED]
          Core Netfilter Configuration --->
            <*/M> Netfilter connection tracking support               [CONFIG_NF_CONNTRACK]
            <*/M> Netfilter Xtables support (required for ip_tables)  [CONFIG_NETFILTER_XTABLES]
            <*/M> LOG target support                                  [CONFIG_NETFILTER_XT_TARGET_LOG]
          IP: Netfilter Configuration --->
            <*/M> IP tables support (required for filtering/masq/NAT) [CONFIG_IP_NF_IPTABLES]

Include any connection tracking protocols that will be used, as well as any protocols that you wish to use for match support under the "Core Netfilter Configuration" section. The above options are enough for running Creating a Personal Firewall With iptables below.

Installation of iptables

Note

The installation below does not include building some specialized extension libraries which require the raw headers in the Linux source code. If you wish to build the additional extensions (if you aren't sure, then you probably don't), you can look at the INSTALL file to see an example of how to change the KERNEL_DIR= parameter to point at the Linux source code. Note that if you upgrade the kernel version, you may also need to recompile iptables and that the BLFS team has not tested using the raw kernel headers.

Install iptables by running the following commands:

./configure --prefix=/usr      \
            --disable-nftables \
            --enable-libipq    &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-nftables: This switch disables building nftables compatibility.

--enable-libipq: This switch enables building of libipq.so which can be used by some packages outside of BLFS.

--enable-nfsynproxy: This switch enables installation of nfsynproxy SYNPROXY configuration tool.

Configuring iptables

Note

In the following example configurations, LAN1 is used for the internal LAN interface, and WAN1 is used for the external interface connected to the Internet. You will need to replace these values with appropriate interface names for your system.

Personal Firewall

A Personal Firewall is designed to let you access all the services offered on the Internet while keeping your computer secure and your data private.

Below is a slightly modified version of Rusty Russell's recommendation from the Linux 2.4 Packet Filtering HOWTO. It is still applicable to the Linux 5.x kernels.

cat > /etc/rc.d/rc.iptables << "EOF"
#!/bin/sh

# Begin rc.iptables

# Insert connection-tracking modules
# (not needed if built into the kernel)
modprobe nf_conntrack
modprobe xt_LOG

# Enable broadcast echo Protection
echo 1 > /proc/sys/net/ipv4/icmp_echo_ignore_broadcasts

# Disable Source Routed Packets
echo 0 > /proc/sys/net/ipv4/conf/all/accept_source_route
echo 0 > /proc/sys/net/ipv4/conf/default/accept_source_route

# Enable TCP SYN Cookie Protection
echo 1 > /proc/sys/net/ipv4/tcp_syncookies

# Disable ICMP Redirect Acceptance
echo 0 > /proc/sys/net/ipv4/conf/default/accept_redirects

# Do not send Redirect Messages
echo 0 > /proc/sys/net/ipv4/conf/all/send_redirects
echo 0 > /proc/sys/net/ipv4/conf/default/send_redirects

# Drop Spoofed Packets coming in on an interface, where responses
# would result in the reply going out a different interface.
echo 1 > /proc/sys/net/ipv4/conf/all/rp_filter
echo 1 > /proc/sys/net/ipv4/conf/default/rp_filter

# Log packets with impossible addresses.
echo 1 > /proc/sys/net/ipv4/conf/all/log_martians
echo 1 > /proc/sys/net/ipv4/conf/default/log_martians

# be verbose on dynamic ip-addresses  (not needed in case of static IP)
echo 2 > /proc/sys/net/ipv4/ip_dynaddr

# disable Explicit Congestion Notification
# too many routers are still ignorant
echo 0 > /proc/sys/net/ipv4/tcp_ecn

# Set a known state
iptables -P INPUT   DROP
iptables -P FORWARD DROP
iptables -P OUTPUT  DROP

# These lines are here in case rules are already in place and the
# script is ever rerun on the fly. We want to remove all rules and
# pre-existing user defined chains before we implement new rules.
iptables -F
iptables -X
iptables -Z

iptables -t nat -F

# Allow local-only connections
iptables -A INPUT  -i lo -j ACCEPT

# Free output on any interface to any ip for any service
# (equal to -P ACCEPT)
iptables -A OUTPUT -j ACCEPT

# Permit answers on already established connections
# and permit new connections related to established ones
# (e.g. port mode ftp)
iptables -A INPUT -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT

# Log everything else.
iptables -A INPUT -j LOG --log-prefix "FIREWALL:INPUT "

# End $rc_base/rc.iptables
EOF
chmod 700 /etc/rc.d/rc.iptables

This script is quite simple, it drops all traffic coming into your computer that wasn't initiated from your computer, but as long as you are simply surfing the Internet you are unlikely to exceed its limits.

If you frequently encounter certain delays at accessing FTP servers, take a look at BusyBox with iptables example number 4.

Even if you have daemons or services running on your system, these will be inaccessible everywhere but from your computer itself. If you want to allow access to services on your machine, such as ssh or ping, take a look at Creating a BusyBox With iptables.

Masquerading Router

A Network Firewall has two interfaces, one connected to an intranet, in this example LAN1, and one connected to the Internet, here WAN1. To provide the maximum security for the firewall itself, make sure that there are no unnecessary servers running on it such as X11. As a general principle, the firewall itself should not access any untrusted service (think of a remote server giving answers that makes a daemon on your system crash, or even worse, that implements a worm via a buffer-overflow).

cat > /etc/rc.d/rc.iptables << "EOF"
#!/bin/sh

# Begin rc.iptables

echo
echo "You're using the example configuration for a setup of a firewall"
echo "from Beyond Linux From Scratch."
echo "This example is far from being complete, it is only meant"
echo "to be a reference."
echo "Firewall security is a complex issue, that exceeds the scope"
echo "of the configuration rules below."
echo "You can find additional information"
echo "about firewalls in Chapter 4 of the BLFS book."
echo "https://www.linuxfromscratch.org/blfs"
echo

# Insert iptables modules (not needed if built into the kernel).

modprobe nf_conntrack
modprobe nf_conntrack_ftp
modprobe xt_conntrack
modprobe xt_LOG
modprobe xt_state

# Enable broadcast echo Protection
echo 1 > /proc/sys/net/ipv4/icmp_echo_ignore_broadcasts

# Disable Source Routed Packets
echo 0 > /proc/sys/net/ipv4/conf/all/accept_source_route

# Enable TCP SYN Cookie Protection
echo 1 > /proc/sys/net/ipv4/tcp_syncookies

# Disable ICMP Redirect Acceptance
echo 0 > /proc/sys/net/ipv4/conf/all/accept_redirects

# Don't send Redirect Messages
echo 0 > /proc/sys/net/ipv4/conf/default/send_redirects

# Drop Spoofed Packets coming in on an interface where responses
# would result in the reply going out a different interface.
echo 1 > /proc/sys/net/ipv4/conf/default/rp_filter

# Log packets with impossible addresses.
echo 1 > /proc/sys/net/ipv4/conf/all/log_martians

# Be verbose on dynamic ip-addresses  (not needed in case of static IP)
echo 2 > /proc/sys/net/ipv4/ip_dynaddr

# Disable Explicit Congestion Notification
# Too many routers are still ignorant
echo 0 > /proc/sys/net/ipv4/tcp_ecn

# Set a known state
iptables -P INPUT   DROP
iptables -P FORWARD DROP
iptables -P OUTPUT  DROP

# These lines are here in case rules are already in place and the
# script is ever rerun on the fly. We want to remove all rules and
# pre-existing user defined chains before we implement new rules.
iptables -F
iptables -X
iptables -Z

iptables -t nat -F

# Allow local connections
iptables -A INPUT  -i lo -j ACCEPT
iptables -A OUTPUT -o lo -j ACCEPT

# Allow forwarding if the initiated on the intranet
iptables -A FORWARD -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT
iptables -A FORWARD ! -i WAN1 -m conntrack --ctstate NEW       -j ACCEPT

# Do masquerading
# (not needed if intranet is not using private ip-addresses)
iptables -t nat -A POSTROUTING -o WAN1 -j MASQUERADE

# Log everything for debugging
# (last of all rules, but before policy rules)
iptables -A INPUT   -j LOG --log-prefix "FIREWALL:INPUT "
iptables -A FORWARD -j LOG --log-prefix "FIREWALL:FORWARD "
iptables -A OUTPUT  -j LOG --log-prefix "FIREWALL:OUTPUT "

# Enable IP Forwarding
echo 1 > /proc/sys/net/ipv4/ip_forward
EOF
chmod 700 /etc/rc.d/rc.iptables

With this script your intranet should be reasonably secure against external attacks. No one should be able to setup a new connection to any internal service and, if it's masqueraded, makes your intranet invisible to the Internet. Furthermore, your firewall should be relatively safe because there are no services running that a cracker could attack.

BusyBox

This scenario isn't too different from the Creating a Masquerading Router With iptables, but additionally offers some services to your intranet. Examples of this can be when you want to administer your firewall from another host on your intranet or use it as a proxy or a name server.

Note

Outlining specifically how to protect a server that offers services on the Internet goes far beyond the scope of this document. See the references in the section called “Extra Information” for more information.

Be cautious. Every service you have enabled makes your setup more complex and your firewall less secure. You are exposed to the risks of misconfigured services or running a service with an exploitable bug. A firewall should generally not run any extra services. See the introduction to the Creating a Masquerading Router With iptables for some more details.

If you want to add services such as internal Samba or name servers that do not need to access the Internet themselves, the additional statements are quite simple and should still be acceptable from a security standpoint. Just add the following lines into the script before the logging rules.

iptables -A INPUT  -i ! WAN1  -j ACCEPT
iptables -A OUTPUT -o ! WAN1  -j ACCEPT

If daemons, such as squid, have to access the Internet themselves, you could open OUTPUT generally and restrict INPUT.

iptables -A INPUT -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT
iptables -A OUTPUT -j ACCEPT

However, it is generally not advisable to leave OUTPUT unrestricted. You lose any control over trojans who would like to "call home", and a bit of redundancy in case you've (mis-)configured a service so that it broadcasts its existence to the world.

To accomplish this, you should restrict INPUT and OUTPUT on all ports except those that it's absolutely necessary to have open. Which ports you have to open depends on your needs: mostly you will find them by looking for failed accesses in your log files.

Have a Look at the Following Examples:

  • Squid is caching the web:

    iptables -A OUTPUT -p tcp --dport 80 -j ACCEPT
    iptables -A INPUT  -p tcp --sport 80 -m conntrack --ctstate ESTABLISHED \
      -j ACCEPT
  • Your caching name server (e.g., named) does its lookups via UDP:

    iptables -A OUTPUT -p udp --dport 53 -j ACCEPT
  • You want to be able to ping your computer to ensure it's still alive:

    iptables -A INPUT  -p icmp -m icmp --icmp-type echo-request -j ACCEPT
    iptables -A OUTPUT -p icmp -m icmp --icmp-type echo-reply   -j ACCEPT
  • If you are frequently accessing FTP servers or enjoy chatting, you might notice delays because some implementations of these daemons query an identd daemon on your system to obtain usernames. Although there's really little harm in this, having an identd running is not recommended because many security experts feel the service gives out too much additional information.

    To avoid these delays you could reject the requests with a 'tcp-reset' response:

    iptables -A INPUT  -p tcp --dport 113 -j REJECT --reject-with tcp-reset
  • To log and drop invalid packets (packets that came in after netfilter's timeout or some types of network scans) insert these rules at the top of the chain:

    iptables -I INPUT 0 -p tcp -m conntrack --ctstate INVALID \
      -j LOG --log-prefix "FIREWALL:INVALID "
    iptables -I INPUT 1 -p tcp -m conntrack --ctstate INVALID -j DROP
  • Anything coming from the outside should not have a private address, this is a common attack called IP-spoofing:

    iptables -A INPUT -i WAN1 -s 10.0.0.0/8     -j DROP
    iptables -A INPUT -i WAN1 -s 172.16.0.0/12  -j DROP
    iptables -A INPUT -i WAN1 -s 192.168.0.0/16 -j DROP

    There are other addresses that you may also want to drop: 0.0.0.0/8, 127.0.0.0/8, 224.0.0.0/3 (multicast and experimental), 169.254.0.0/16 (Link Local Networks), and 192.0.2.0/24 (IANA defined test network).

  • If your firewall is a DHCP client, you need to allow those packets:

    iptables -A INPUT  -i WAN1 -p udp -s 0.0.0.0 --sport 67 \
       -d 255.255.255.255 --dport 68 -j ACCEPT
  • To simplify debugging and be fair to anyone who'd like to access a service you have disabled, purposely or by mistake, you could REJECT those packets that are dropped.

    Obviously this must be done directly after logging as the very last lines before the packets are dropped by policy:

    iptables -A INPUT -j REJECT

These are only examples to show you some of the capabilities of the firewall code in Linux. Have a look at the man page of iptables. There you will find much more information. The port numbers needed for this can be found in /etc/services, in case you didn't find them by trial and error in your log file.

Boot Script

To set up the iptables firewall at boot, install the /etc/rc.d/init.d/iptables init script included in the blfs-bootscripts-20210826 package.

make install-iptables

Contents

Installed Programs: ip6tables, ip6tables-apply, ip6tables-legacy, ip6tables-legacy-restore, ip6tables-legacy-save, ip6tables-restore, ip6tables-save, iptables, iptables-apply, iptables-legacy, iptables-legacy-restore, iptables-legacy-apply, iptables-restore, iptables-save, iptables-xml, nfsynproxy (optional), and xtables-multi
Installed Libraries: libip4tc.so, libip6tc.so, libipq.so, libiptc.so, and libxtables.so
Installed Directories: /lib/xtables and /usr/include/libiptc

Short Descriptions

iptables

is used to set up, maintain, and inspect the tables of IP packet filter rules in the Linux kernel

iptables-apply

is a safer way to update iptables remotely

iptables-legacy

is used to interact with iptables using the legacy command set

iptables-legacy-restore

is used to restore a set of legacy iptables rules

iptables-legacy-save

is used to save a set of legacy iptables rules

iptables-restore

is used to restore IP Tables from data specified on STDIN. Use I/O redirection provided by your shell to read from a file

iptables-save

is used to dump the contents of an IP Table in easily parseable format to STDOUT. Use I/O-redirection provided by your shell to write to a file

iptables-xml

is used to convert the output of iptables-save to an XML format. Using the iptables.xslt stylesheet converts the XML back to the format of iptables-restore

ip6tables*

are a set of commands for IPV6 that parallel the iptables commands above

nfsynproxy

(optional) configuration tool. SYNPROXY target makes handling of large SYN floods possible without the large performance penalties imposed by the connection tracking in such cases

xtables-multi

is a binary that behaves according to the name it is called by

Last updated on

Setting Up a Network Firewall

Introduction to Firewall Creation

The purpose of a firewall is to protect a computer or a network against malicious access. In a perfect world every daemon or service, on every machine, is perfectly configured and immune to security flaws, and all users are trusted implicitly to use the equipment as intended. However, this is rarely, if ever, the case. Daemons may be misconfigured, or updates may not have been applied for known exploits against essential services. Additionally, you may wish to choose which services are accessible by certain machines or users, or you may wish to limit which machines or applications are allowed external access. Alternatively, you simply may not trust some of your applications or users. For these reasons, a carefully designed firewall should be an essential part of system security.

While a firewall can greatly limit the scope of the above issues, do not assume that having a firewall makes careful configuration redundant, or that any negligent misconfiguration is harmless. A firewall does not prevent the exploitation of any service you offer outside of it. Despite having a firewall, you need to keep applications and daemons properly configured and up to date.

Meaning of the Word "Firewall"

The word firewall can have several different meanings.

Personal Firewall

This is a hardware device or software program, intended to secure a home or desktop computer connected to the Internet. This type of firewall is highly relevant for users who do not know how their computers might be accessed via the Internet or how to disable that access, especially if they are always online and connected via broadband links.

An example configuration for a personal firewall is provided at Creating a Personal Firewall With iptables.

Masquerading Router

This is a system placed between the Internet and an intranet. To minimize the risk of compromising the firewall itself, it should generally have only one role—that of protecting the intranet. Although not completely risk-free, the tasks of doing the routing and IP masquerading (rewriting IP headers of the packets it routes from clients with private IP addresses onto the Internet so that they seem to come from the firewall itself) are commonly considered relatively secure.

An example configuration for a masquerading firewall is provided at Creating a Masquerading Router With iptables.

BusyBox

This is often an old computer you may have retired and nearly forgotten, performing masquerading or routing functions, but offering non-firewall services such as a web-cache or mail. This may be used for home networks, but is not to be considered as secure as a firewall only machine because the combination of server and router/firewall on one machine raises the complexity of the setup.

An example configuration for a BusyBox is provided at Creating a BusyBox With iptables.

Firewall with a Demilitarized Zone

This type of firewall performs masquerading or routing, but grants public access to some branch of your network that is physically separated from your regular intranet and is essentially a separate network with direct Internet access. The servers on this network are those which must be easily accessible from both the Internet and intranet. The firewall protects both networks. This type of firewall has a minimum of three network interfaces.

Packetfilter

This type of firewall does routing or masquerading but does not maintain a state table of ongoing communication streams. It is fast but quite limited in its ability to block undesired packets without blocking desired packets.

Conclusion

Caution

The example configurations provided for iptables-1.8.7 are not intended to be a complete guide to securing systems. Firewalling is a complex issue that requires careful configuration. The configurations provided by BLFS are intended only to give examples of how a firewall works. They are not intended to fit any particular configuration and may not provide complete protection from an attack.

BLFS provides an utility to manage the kernel Netfilter interface, iptables-1.8.7. It has been around since early 2.4 kernels, and has been the standard since. This is likely the set of tools that will be most familiar to existing admins. Other tools have been developed more recently, see the list of further readings below for more details. Here you will find a list of URLs that contain comprehensive information about building firewalls and further securing your system.

Last updated on

libcap-2.63 with PAM

Introduction to libcap with PAM

The libcap package was installed in LFS, but if Linux-PAM support is desired, the PAM module must be built (after installation of Linux-PAM).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libcap Dependencies

Required

Linux-PAM-1.5.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libcap

Installation of libcap

Note

If you are upgrading libcap from a previous version, use the instructions in LFS libcap page to upgrade libcap. If Linux-PAM-1.5.2 has been built, the PAM module will automatically be built too.

Install libcap by running the following commands:

make -C pam_cap

This package does not come with a test suite.

Now, as the root user:

install -v -m755 pam_cap/pam_cap.so /usr/lib/security &&
install -v -m644 pam_cap/capability.conf /etc/security

Configuring Libcap

In order to allow Linux-PAM to grant privileges based on POSIX capabilities, you need to add the libcap module to the beginning of the /etc/pam.d/system-auth file. Make the required edits with the following commands:

mv -v /etc/pam.d/system-auth{,.bak} &&
cat > /etc/pam.d/system-auth << "EOF" &&
# Begin /etc/pam.d/system-auth

auth      optional    pam_cap.so
EOF
tail -n +3 /etc/pam.d/system-auth.bak >> /etc/pam.d/system-auth

Additionally, you'll need to modify the /etc/security/capability.conf file to grant necessary privileges to users, and utilize the setcap utility to set capabilities on specific utilities as needed. See man 8 setcap and man 3 cap_from_text for additional information.

Contents

Installed Programs: None
Installed Library: pam_cap.so
Installed Directories: None

Last updated on

Linux-PAM-1.5.2

Introduction to Linux PAM

The Linux PAM package contains Pluggable Authentication Modules used to enable the local system administrator to choose how applications authenticate users.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Optional Documentation

Linux PAM Dependencies

Optional

Berkeley DB-5.3.28, libnsl-2.0.0, libtirpc-1.3.2, libaudit, and Prelude

Optional (To Rebuild the Documentation)

docbook-xml-4.5, docbook-xsl-1.79.2, fop-2.7, libxslt-1.1.35 and either Lynx-2.8.9rel.1 or W3m

Note

Shadow-4.11.1 needs to be reinstalled after installing and configuring Linux PAM.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/linux-pam

Installation of Linux PAM

First prevent the installation of an unneeded systemd file:

sed -e /service_DATA/d \
    -i modules/pam_namespace/Makefile.am &&
autoreconf

If you downloaded the documentation, unpack the tarball by issuing the following command.

tar -xf ../Linux-PAM-1.5.2-docs.tar.xz --strip-components=1

If you instead want to regenerate the documentation, fix the configure script so that it detects lynx if installed:

sed -e 's/dummy elinks/dummy lynx/'                                    \
    -e 's/-no-numbering -no-references/-force-html -nonumbers -stdin/' \
    -i configure

Install Linux PAM by running the following commands:

./configure --prefix=/usr                        \
            --sbindir=/usr/sbin                  \
            --sysconfdir=/etc                    \
            --libdir=/usr/lib                    \
            --enable-securedir=/usr/lib/security \
            --docdir=/usr/share/doc/Linux-PAM-1.5.2 &&
make

To test the results, a suitable /etc/pam.d/other configuration file must exist.

Reinstallation or upgrade of Linux PAM

If you have a system with Linux PAM installed and working, be careful when modifying the files in /etc/pam.d, since your system may become totally unusable. If you want to run the tests, you do not need to create another /etc/pam.d/other file. The installed one can be used for that purpose.

You should also be aware that make install overwrites the configuration files in /etc/security as well as /etc/environment. In case you have modified those files, be sure to back them up.

For a first installation, create the configuration file by issuing the following commands as the root user:

install -v -m755 -d /etc/pam.d &&

cat > /etc/pam.d/other << "EOF"
auth     required       pam_deny.so
account  required       pam_deny.so
password required       pam_deny.so
session  required       pam_deny.so
EOF

Now run the tests by issuing make check. Ensure there are no errors produced by the tests before continuing the installation. Note that the checks are quite long. It may be useful to redirect the output to a log file in order to inspect it thoroughly.

Only in case of a first installation, remove the configuration file created earlier by issuing the following command as the root user:

rm -fv /etc/pam.d/other

Now, as the root user:

make install &&
chmod -v 4755 /usr/sbin/unix_chkpwd

Command Explanations

--enable-securedir=/usr/lib/security: This switch sets the installation location for the PAM modules.

--disable-regenerate-docu : If the needed dependencies (docbook-xml-4.5, docbook-xsl-1.79.2, libxslt-1.1.35, and Lynx-2.8.9rel.1 or W3m) are installed, the manual pages, and the html and text documentations are (re)generated and installed. Furthermore, if fop-2.7 is installed, the PDF documentation is generated and installed. Use this switch if you do not want to rebuild the documentation.

chmod -v 4755 /usr/sbin/unix_chkpwd: The unix_chkpwd helper program must be setuid so that non-root processes can access the shadow file.

Configuring Linux-PAM

Config Files

/etc/security/* and /etc/pam.d/*

Configuration Information

Configuration information is placed in /etc/pam.d/. Below is an example file:

# Begin /etc/pam.d/other

auth            required        pam_unix.so     nullok
account         required        pam_unix.so
session         required        pam_unix.so
password        required        pam_unix.so     nullok

# End /etc/pam.d/other

Now set up some generic files. As the root user:

install -vdm755 /etc/pam.d &&
cat > /etc/pam.d/system-account << "EOF" &&
# Begin /etc/pam.d/system-account

account   required    pam_unix.so

# End /etc/pam.d/system-account
EOF

cat > /etc/pam.d/system-auth << "EOF" &&
# Begin /etc/pam.d/system-auth

auth      required    pam_unix.so

# End /etc/pam.d/system-auth
EOF

cat > /etc/pam.d/system-session << "EOF"
# Begin /etc/pam.d/system-session

session   required    pam_unix.so

# End /etc/pam.d/system-session
EOF
cat > /etc/pam.d/system-password << "EOF"
# Begin /etc/pam.d/system-password

# use sha512 hash for encryption, use shadow, and try to use any previously
# defined authentication token (chosen password) set by any prior module
password  required    pam_unix.so       sha512 shadow try_first_pass

# End /etc/pam.d/system-password
EOF

If you wish to enable strong password support, install libpwquality-1.4.4, and follow the instructions in that page to configure the pam_pwquality PAM module with strong password support.

Now add a restrictive /etc/pam.d/other configuration file. With this file, programs that are PAM aware will not run unless a configuration file specifically for that application is created.

cat > /etc/pam.d/other << "EOF"
# Begin /etc/pam.d/other

auth        required        pam_warn.so
auth        required        pam_deny.so
account     required        pam_warn.so
account     required        pam_deny.so
password    required        pam_warn.so
password    required        pam_deny.so
session     required        pam_warn.so
session     required        pam_deny.so

# End /etc/pam.d/other
EOF

The PAM man page (man pam) provides a good starting point for descriptions of fields and allowable entries. The Linux-PAM System Administrators' Guide is recommended for additional information.

Important

You should now reinstall the Shadow-4.11.1 package .

Contents

Installed Program: faillock, mkhomedir_helper, pam_namespace_helper, pam_timestamp_check, pwhistory_helper, unix_chkpwd and unix_update
Installed Libraries: libpam.so, libpamc.so and libpam_misc.so
Installed Directories: /etc/security, /usr/lib/security, /usr/include/security and /usr/share/doc/Linux-PAM-1.5.2

Short Descriptions

faillock

displays and modifies the authentication failure record files

mkhomedir_helper

is a helper binary that creates home directories

pam_namespace_helper

is a helper program used to configure a private namespace for a user session

pwhistory_helper

is a helper program that transfers password hashes from passwd or shadow to opasswd

pam_timestamp_check

is used to check if the default timestamp is valid

unix_chkpwd

is a helper binary that verifies the password of the current user

unix_update

is a helper binary that updates the password of a given user

libpam.so

provides the interfaces between applications and the PAM modules

Last updated on

liboauth-1.0.3

Introduction to liboauth

liboauth is a collection of POSIX-C functions implementing the OAuth Core RFC 5849 standard. Liboauth provides functions to escape and encode parameters according to OAuth specification and offers high-level functionality to sign requests or verify OAuth signatures as well as perform HTTP requests.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

liboauth Dependencies

Required

cURL-7.81.0

Optional

nss-3.75 and Doxygen-1.9.3 (to build documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/liboauth

Installation of liboauth

Apply a patch for the current version of openssl:

patch -Np1 -i ../liboauth-1.0.3-openssl-1.1.0-3.patch

Install liboauth by running the following commands:

./configure --prefix=/usr --disable-static &&
make

If you wish to build the documentation (needs Doxygen-1.9.3), issue:

make dox

To test the results, issue: make check.

Now, as the root user:

make install

If you have previously built the documentation, install it by running the following commands as the root user:

install -v -dm755 /usr/share/doc/liboauth-1.0.3 &&
cp -rv doc/html/* /usr/share/doc/liboauth-1.0.3

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-nss: Use this switch if you want to use Mozilla NSS instead of OpenSSL.

Contents

Installed Programs: None
Installed Libraries: liboauth.so
Installed Directories: /usr/share/doc/liboauth-1.0.3

Short Descriptions

liboauth.so

provides functions to escape and encode stings according to OAuth specifications and offers high-level functionality built on top to sign requests or verify signatures using either NSS or OpenSSL for calculating the hash/signatures

Last updated on

libpwquality-1.4.4

Introduction to libpwquality

The libpwquality package provides common functions for password quality checking and also scoring them based on their apparent randomness. The library also provides a function for generating random passwords with good pronounceability.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libpwquality Dependencies

Required

CrackLib-2.9.7

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libpwquality

Installation of libpwquality

Install libpwquality by running the following commands:

./configure --prefix=/usr                      \
            --disable-static                   \
            --with-securedir=/usr/lib/security \
            --with-python-binary=python3       &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--with-python-binary=python3: This parameter gives the location of the Python binary. The default is python, and requires Python-2.7.18.

Configuring libpwquality

libpwquality is intended to be a functional replacement for the now-obsolete pam_cracklib.so PAM module. To configure the system to use the pam_pwquality module, execute the following commands as the root user:

mv /etc/pam.d/system-password{,.orig} &&
cat > /etc/pam.d/system-password << "EOF"
# Begin /etc/pam.d/system-password

# check new passwords for strength (man pam_pwquality)
password  required    pam_pwquality.so   authtok_type=UNIX retry=1 difok=1 \
                                         minlen=8 dcredit=0 ucredit=0 \
                                         lcredit=0 ocredit=0 minclass=1 \
                                         maxrepeat=0 maxsequence=0 \
                                         maxclassrepeat=0 geoscheck=0 \
                                         dictcheck=1 usercheck=1 \
                                         enforcing=1 badwords="" \
                                         dictpath=/usr/lib/cracklib/pw_dict
# use sha512 hash for encryption, use shadow, and use the
# authentication token (chosen password) set by pam_pwquality
# above (or any previous modules)
password  required    pam_unix.so        sha512 shadow use_authtok

# End /etc/pam.d/system-password
EOF

Contents

Installed Programs: pwscore and pwmake
Installed Libraries: pam_pwquality.so and libpwquality.so
Installed Directories: None

Short Descriptions

pwmake

is a simple configurable tool for generating random and relatively easily pronounceable passwords

pwscore

is a simple tool for checking quality of a password

libpwquality.so

contains API functions for checking the password quality

pam_pwquality.so

is a Linux PAM module used to perform password quality checking

Last updated on

MIT Kerberos V5-1.19.2

Introduction to MIT Kerberos V5

MIT Kerberos V5 is a free implementation of Kerberos 5. Kerberos is a network authentication protocol. It centralizes the authentication database and uses kerberized applications to work with servers or services that support Kerberos allowing single logins and encrypted communication over internal networks or the Internet.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://kerberos.org/dist/krb5/1.19/krb5-1.19.2.tar.gz

  • Download MD5 sum: eb51b7724111e1a458a8c9a261d45a31

  • Download size: 8.3 MB

  • Estimated disk space required: 95 MB (add 24 MB for tests)

  • Estimated build time: 0.4 SBU (Using parallelism=4; add 1.6 SBU for tests)

Additional Downloads

MIT Kerberos V5 Dependencies

Optional

BIND Utilities-9.18.0, GnuPG-2.2.34 (to authenticate the package), keyutils-1.6.1, OpenLDAP-2.6.1, Valgrind-3.18.1 (used during the testsuite), yasm-1.3.0, libedit, cmocka, pyrad, and resolv_wrapper

Note

Some sort of time synchronization facility on your system (like ntp-4.2.8p15) is required since Kerberos won't authenticate if there is a time difference between a kerberized client and the KDC server.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/mitkrb

Installation of MIT Kerberos V5

First, fix a denial-of-service security vulnerability:

sed -i '210a if (sprinc == NULL) {\
       status = "NULL_SERVER";\
       errcode = KRB5KDC_ERR_S_PRINCIPAL_UNKNOWN;\
       goto cleanup;\
       }' src/kdc/do_tgs_req.c

Next, fix several issues identified by OpenSSL-3:

patch -Np1 -i ../mitkrb-1.19.2-openssl3_fixes-1.patch

Build MIT Kerberos V5 by running the following commands:

cd src &&

sed -i -e 's@\^u}@^u cols 300}@' tests/dejagnu/config/default.exp     &&
sed -i -e '/eq 0/{N;s/12 //}'    plugins/kdb/db2/libdb2/test/run.test &&
sed -i '/t_iprop.py/d'           tests/Makefile.in                    &&

autoreconf -fiv &&

./configure --prefix=/usr            \
            --sysconfdir=/etc        \
            --localstatedir=/var/lib \
            --runstatedir=/run       \
            --with-system-et         \
            --with-system-ss         \
            --with-system-verto=no   \
            --enable-dns-for-realm &&
make

To test the build, issue as the root user: make -k -j1 check. If you have a former version of MIT Kerberos V5 installed, it may happen that the test suite may pick up the installed versions of the libraries, rather than the newly built ones. If so, it is better to run the tests after the installation. Some tests may fail with the latest version of dejagnu and glibc.

Now, as the root user:

make install &&

install -v -dm755 /usr/share/doc/krb5-1.19.2 &&
cp -vfr ../doc/*  /usr/share/doc/krb5-1.19.2

Command Explanations

The first sed increases the width of the virtual terminal used for some tests to prevent some spurious text in the output which is taken as a failure. The second sed removes a test that is known to fail. The third sed removes a test that is known to hang.

--localstatedir=/var/lib: This option is used so that the Kerberos variable runtime data is located in /var/lib instead of /usr/var.

--runstatedir=/run: This option is used so that the Kerberos runtime state information is located in /run instead of the deprecated /var/run.

--with-system-et: This switch causes the build to use the system-installed versions of the error-table support software.

--with-system-ss: This switch causes the build to use the system-installed versions of the subsystem command-line interface software.

--with-system-verto=no: This switch fixes a bug in the package: it does not recognize its own verto library installed previously. This is not a problem, if reinstalling the same version, but if you are updating, the old library is used as system's one, instead of installing the new version.

--enable-dns-for-realm: This switch allows realms to be resolved using the DNS server.

--with-ldap: Use this switch if you want to compile the OpenLDAP database backend module.

Configuring MIT Kerberos V5

Config Files

/etc/krb5.conf and /var/lib/krb5kdc/kdc.conf

Configuration Information

Kerberos Configuration

Tip

You should consider installing some sort of password checking dictionary so that you can configure the installation to only accept strong passwords. A suitable dictionary to use is shown in the CrackLib-2.9.7 instructions. Note that only one file can be used, but you can concatenate many files into one. The configuration file shown below assumes you have installed a dictionary to /usr/share/dict/words.

Create the Kerberos configuration file with the following commands issued by the root user:

cat > /etc/krb5.conf << "EOF"
# Begin /etc/krb5.conf

[libdefaults]
    default_realm = <EXAMPLE.ORG>
    encrypt = true

[realms]
    <EXAMPLE.ORG> = {
        kdc = <belgarath.example.org>
        admin_server = <belgarath.example.org>
        dict_file = /usr/share/dict/words
    }

[domain_realm]
    .<example.org> = <EXAMPLE.ORG>

[logging]
    kdc = SYSLOG:INFO:AUTH
    admin_server = SYSLOG:INFO:AUTH
    default = SYSLOG:DEBUG:DAEMON

# End /etc/krb5.conf
EOF

You will need to substitute your domain and proper hostname for the occurrences of the <belgarath> and <example.org> names.

default_realm should be the name of your domain changed to ALL CAPS. This isn't required, but both Heimdal and MIT recommend it.

encrypt = true provides encryption of all traffic between kerberized clients and servers. It's not necessary and can be left off. If you leave it off, you can encrypt all traffic from the client to the server using a switch on the client program instead.

The [realms] parameters tell the client programs where to look for the KDC authentication services.

The [domain_realm] section maps a domain to a realm.

Create the KDC database:

kdb5_util create -r <EXAMPLE.ORG> -s

Now you should populate the database with principals (users). For now, just use your regular login name or root.

kadmin.local
kadmin.local: add_policy dict-only
kadmin.local: addprinc -policy dict-only <loginname>

The KDC server and any machine running kerberized server daemons must have a host key installed:

kadmin.local: addprinc -randkey host/<belgarath.example.org>

After choosing the defaults when prompted, you will have to export the data to a keytab file:

kadmin.local: ktadd host/<belgarath.example.org>

This should have created a file in /etc named krb5.keytab (Kerberos 5). This file should have 600 (root rw only) permissions. Keeping the keytab files from public access is crucial to the overall security of the Kerberos installation.

Exit the kadmin program (use quit or exit) and return back to the shell prompt. Start the KDC daemon manually, just to test out the installation:

/usr/sbin/krb5kdc

Attempt to get a ticket with the following command:

kinit <loginname>

You will be prompted for the password you created. After you get your ticket, you can list it with the following command:

klist

Information about the ticket should be displayed on the screen.

To test the functionality of the keytab file, issue the following command as the root user:

ktutil
ktutil: rkt /etc/krb5.keytab
ktutil: l

This should dump a list of the host principal, along with the encryption methods used to access the principal.

Create an empty ACL file that can be modified later:

touch /var/lib/krb5kdc/kadm5.acl

At this point, if everything has been successful so far, you can feel fairly confident in the installation and configuration of the package.

Additional Information

For additional information consult the documentation for krb5-1.19.2 on which the above instructions are based.

Init Script

If you want to start Kerberos services at boot, install the /etc/rc.d/init.d/krb5 init script included in the blfs-bootscripts-20210826 package using the following command:

make install-krb5

Contents

Installed Programs: gss-client, gss-server, k5srvutil, kadmin, kadmin.local, kadmind, kdb5_ldap_util (optional), kdb5_util, kdestroy, kinit, klist, kpasswd, kprop, kpropd, kproplog, krb5-config, krb5-send-pr, krb5kdc, ksu, kswitch, ktutil, kvno, sclient, sim_client, sim_server, sserver, uuclient, and uuserver
Installed Libraries: libgssapi_krb5.so, libgssrpc.so, libk5crypto.so, libkadm5clnt_mit.so, libkadm5clnt.so, libkadm5srv_mit.so, libkadm5srv.so, libkdb_ldap.so (optional), libkdb5.so, libkrad.so, libkrb5.so, libkrb5support.so, libverto.so, and some plugins under the /usr/lib/krb5 tree
Installed Directories: /usr/include/{gssapi,gssrpc,kadm5,krb5}, /usr/lib/krb5, /usr/share/{doc/krb5-1.19.2,examples/krb5}, /var/lib/krb5kdc, and /run/krb5kdc

Short Descriptions

gss-client

is a GSSAPI test client

gss-server

is a GSSAPI test server

k5srvutil

is a host keytable manipulation utility

kadmin

is an utility used to make modifications to the Kerberos database

kadmin.local

is an utility similar to kadmin, but if the database is db2, the local client kadmin.local, is intended to run directly on the master KDC without Kerberos authentication

kadmind

is a server for administrative access to a Kerberos database

kdb5_ldap_util (optional)

allows an administrator to manage realms, Kerberos services and ticket policies

kdb5_util

is the KDC database utility

kdestroy

removes the current set of tickets

kinit

is used to authenticate to the Kerberos server as a principal and acquire a ticket granting ticket that can later be used to obtain tickets for other services

klist

reads and displays the current tickets in the credential cache

kpasswd

is a program for changing Kerberos 5 passwords

kprop

takes a principal database in a specified format and converts it into a stream of database records

kpropd

receives a database sent by kprop and writes it as a local database

kproplog

displays the contents of the KDC database update log to standard output

krb5-config

gives information on how to link programs against libraries

krb5kdc

is the Kerberos 5 server

krb5-send-pr

sends a problem report (PR) to a central support site

ksu

is the super user program using Kerberos protocol. Requires a properly configured /etc/shells and ~/.k5login containing principals authorized to become super users

kswitch

makes the specified credential cache the primary cache for the collection, if a cache collection is available

ktutil

is a program for managing Kerberos keytabs

kvno

prints keyversion numbers of Kerberos principals

sclient

is used to contact a sample server and authenticate to it using Kerberos 5 tickets, then display the server's response

sim_client

is a simple UDP-based sample client program, for demonstration

sim_server

is a simple UDP-based server application, for demonstration

sserver

is the sample Kerberos 5 server

uuclient

is another sample client

uuserver

is another sample server

libgssapi_krb5.so

contains the Generic Security Service Application Programming Interface (GSSAPI) functions which provides security services to callers in a generic fashion, supportable with a range of underlying mechanisms and technologies and hence allowing source-level portability of applications to different environments

libkadm5clnt.so

contains the administrative authentication and password checking functions required by Kerberos 5 client-side programs

libkadm5srv.so

contains the administrative authentication and password checking functions required by Kerberos 5 servers

libkdb5.so

is a Kerberos 5 authentication/authorization database access library

libkrad.so

contains the internal support library for RADIUS functionality

libkrb5.so

is an all-purpose Kerberos 5 library

Last updated on

Nettle-3.7.3

Introduction to Nettle

The Nettle package contains a low-level cryptographic library that is designed to fit easily in many contexts.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Nettle Dependencies

Optional

Valgrind-3.18.1 (optional for the tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/nettle

Installation of Nettle

Install Nettle by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install &&
chmod   -v   755 /usr/lib/lib{hogweed,nettle}.so &&
install -v -m755 -d /usr/share/doc/nettle-3.7.3 &&
install -v -m644 nettle.html /usr/share/doc/nettle-3.7.3

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: nettle-hash, nettle-lfib-stream, nettle-pbkdf2, pkcs1-conv and sexp-conv
Installed Libraries: libhogweed.so and libnettle.so
Installed Directory: /usr/include/nettle and /usr/share/doc/nettle-3.7.3

Short Descriptions

nettle-hash

calculates a hash value using a specified algorithm

nettle-lfib-stream

outputs a sequence of pseudorandom (non-cryptographic) bytes, using Knuth's lagged fibonacci generator. The stream is useful for testing, but should not be used to generate cryptographic keys or anything else that needs real randomness

nettle-pbkdf2

is a password-based key derivation function that takes a password or a passphrase as input and returns a strengthened password, which is protected against pre-computation attacks by using salting and other expensive computations.

pkcs1-conv

converts private and public RSA keys from PKCS #1 format to sexp format

sexp-conv

converts an s-expression to a different encoding

Last updated on

NSS-3.75

Introduction to NSS

The Network Security Services (NSS) package is a set of libraries designed to support cross-platform development of security-enabled client and server applications. Applications built with NSS can support SSL v2 and v3, TLS, PKCS #5, PKCS #7, PKCS #11, PKCS #12, S/MIME, X.509 v3 certificates, and other security standards. This is useful for implementing SSL and S/MIME or other Internet security standards into an application.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

NSS Dependencies

Required

NSPR-4.33

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/nss

Installation of NSS

Install NSS by running the following commands:

patch -Np1 -i ../nss-3.75-standalone-1.patch &&

cd nss &&

make BUILD_OPT=1                  \
  NSPR_INCLUDE_DIR=/usr/include/nspr  \
  USE_SYSTEM_ZLIB=1                   \
  ZLIB_LIBS=-lz                       \
  NSS_ENABLE_WERROR=0                 \
  $([ $(uname -m) = x86_64 ] && echo USE_64=1) \
  $([ -f /usr/include/sqlite3.h ] && echo NSS_USE_SYSTEM_SQLITE=1)

To run the tests, execute the following commands (4 tests related to PayPal certificates are known to fail):

cd tests &&
HOST=localhost DOMSUF=localdomain ./all.sh
cd ../

Note

Some information about the tests:

  • HOST=localhost and DOMSUF=localdomain are required. Without these variables, a FQDN is required to be specified and this generic way should work for everyone.

  • The tests take an extremely long time to run. If desired there is information in the all.sh script about running subsets of the total test suite.

  • When interrupting the tests, the test suite fails to spin down test servers that are run. This leads to an infinite loop in the tests where the test suite tries to kill a server that doesn't exist anymore because it pulls the wrong PID.

  • Test suite results (in HTML format!) can be found at ../../test_results/security/localhost.1/results.html

Now, as the root user:

cd ../dist                                                          &&

install -v -m755 Linux*/lib/*.so              /usr/lib              &&
install -v -m644 Linux*/lib/{*.chk,libcrmf.a} /usr/lib              &&

install -v -m755 -d                           /usr/include/nss      &&
cp -v -RL {public,private}/nss/*              /usr/include/nss      &&
chmod -v 644                                  /usr/include/nss/*    &&

install -v -m755 Linux*/bin/{certutil,nss-config,pk12util} /usr/bin &&

install -v -m644 Linux*/lib/pkgconfig/nss.pc  /usr/lib/pkgconfig

Command Explanations

BUILD_OPT=1: This option is passed to make so that the build is performed with no debugging symbols built into the binaries and the default compiler optimizations are used.

NSPR_INCLUDE_DIR=/usr/include/nspr: This option sets the location of the nspr headers.

USE_SYSTEM_ZLIB=1: This option is passed to make to ensure that the libssl3.so library is linked to the system installed zlib instead of the in-tree version.

ZLIB_LIBS=-lz: This option provides the linker flags needed to link to the system zlib.

$([ $(uname -m) = x86_64 ] && echo USE_64=1): The USE_64=1 option is required on x86_64, otherwise make will try (and fail) to create 32-bit objects. The [ $(uname -m) = x86_64 ] test ensures it has no effect on a 32 bit system.

([ -f /usr/include/sqlite3.h ] && echo NSS_USE_SYSTEM_SQLITE=1): This tests if sqlite is installed and if so it echos the option NSS_USE_SYSTEM_SQLITE=1 to make so that libsoftokn3.so will link against the system version of sqlite.

NSS_DISABLE_GTESTS=1: If you don't need to run NSS test suite, append this option to make command, to prevent the compilation of tests and save some build time.

Configuring NSS

If p11-kit-0.24.1 is installed, the p11-kit trust module (/usr/lib/pkcs11/p11-kit-trust.so) can be used as a drop-in replacement for /usr/lib/libnssckbi.so to transparently make the system CAs available to NSS aware applications, rather than the static list provided by /usr/lib/libnssckbi.so. As the root user, execute the following commands:

ln -sfv ./pkcs11/p11-kit-trust.so /usr/lib/libnssckbi.so

Additionally, for dependent applications that do not use the internal database (/usr/lib/libnssckbi.so), the /usr/sbin/make-ca script included on the make-ca-1.10 page can generate a system wide NSS DB with the -n switch, or by modifying the /etc/make-ca.conf file.

Contents

Installed Programs: certutil, nss-config, and pk12util
Installed Libraries: libcrmf.a, libfreebl3.so, libfreeblpriv3.so, libnss3.so, libnssckbi.so, libnssckbi-testlib.so, libnssdbm3.so, libnsssysinit.so, libnssutil3.so, libpkcs11testmodule.so, libsmime3.so, libsoftokn3.so, and libssl3.so
Installed Directories: /usr/include/nss

Short Descriptions

certutil

is the Mozilla Certificate Database Tool. It is a command-line utility that can create and modify the Netscape Communicator cert8.db and key3.db database files. It can also list, generate, modify, or delete certificates within the cert8.db file and create or change the password, generate new public and private key pairs, display the contents of the key database, or delete key pairs within the key3.db file

nss-config

is used to determine the NSS library settings of the installed NSS libraries

pk12util

is a tool for importing certificates and keys from pkcs #12 files into NSS or exporting them. It can also list certificates and keys in such files

Last updated on

OpenSSH-8.8p1

Introduction to OpenSSH

The OpenSSH package contains ssh clients and the sshd daemon. This is useful for encrypting authentication and subsequent traffic over a network. The ssh and scp commands are secure implementations of telnet and rcp respectively.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

OpenSSH Dependencies

Optional

GDB-11.2 (for tests), Linux-PAM-1.5.2, a graphical environment, MIT Kerberos V5-1.19.2, libedit, LibreSSL Portable, OpenSC, and libsectok

Optional Runtime (Used only to gather entropy)

Net-tools-2.10, and Sysstat-12.5.5

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/OpenSSH

Installation of OpenSSH

OpenSSH runs as two processes when connecting to other computers. The first process is a privileged process and controls the issuance of privileges as necessary. The second process communicates with the network. Additional installation steps are necessary to set up the proper environment, which are performed by issuing the following commands as the root user:

install  -v -m700 -d /var/lib/sshd &&
chown    -v root:sys /var/lib/sshd &&

groupadd -g 50 sshd        &&
useradd  -c 'sshd PrivSep' \
         -d /var/lib/sshd  \
         -g sshd           \
         -s /bin/false     \
         -u 50 sshd

Install OpenSSH by running the following commands:

./configure --prefix=/usr                            \
            --sysconfdir=/etc/ssh                    \
            --with-md5-passwords                     \
            --with-privsep-path=/var/lib/sshd        \
            --with-default-path=/usr/bin             \
            --with-superuser-path=/usr/sbin:/usr/bin \
            --with-pid-dir=/run
make

The testsuite requires an installed copy of scp to complete the multiplexing tests. To run the test suite, first copy the scp program to /usr/bin, making sure that you backup any existing copy first.

If you wish to run the tests, remove a test suite that is not valid on Linux-based platforms:

sed -i 's/conch-ciphers//' regress/Makefile

To test the results, issue: make -j1 tests.

Now, as the root user:

make install &&
install -v -m755    contrib/ssh-copy-id /usr/bin     &&

install -v -m644    contrib/ssh-copy-id.1 \
                    /usr/share/man/man1              &&
install -v -m755 -d /usr/share/doc/openssh-8.8p1     &&
install -v -m644    INSTALL LICENCE OVERVIEW README* \
                    /usr/share/doc/openssh-8.8p1

Command Explanations

--sysconfdir=/etc/ssh: This prevents the configuration files from being installed in /usr/etc.

--with-md5-passwords: This enables the use of MD5 passwords.

--with-default-path=/usr/bin and --with-superuser-path=/usr/sbin:/usr/bin: These set PATH consistent with LFS and BLFS Shadow package.

--with-pid-dir=/run: This prevents OpenSSH from referring to deprecated /var/run.

--with-pam: This parameter enables Linux-PAM support in the build.

--with-xauth=/usr/bin/xauth: Set the default location for the xauth binary for X authentication. Change the location if xauth will be installed to a different path. This can also be controlled from sshd_config with the XAuthLocation keyword. You can omit this switch if Xorg is already installed.

--with-kerberos5=/usr: This option is used to include Kerberos 5 support in the build.

--with-libedit: This option enables line editing and history features for sftp.

Configuring OpenSSH

Config Files

~/.ssh/*, /etc/ssh/ssh_config, and /etc/ssh/sshd_config

There are no required changes to any of these files. However, you may wish to view the /etc/ssh/ files and make any changes appropriate for the security of your system. One recommended change is that you disable root login via ssh. Execute the following command as the root user to disable root login via ssh:

echo "PermitRootLogin no" >> /etc/ssh/sshd_config

If you want to be able to log in without typing in your password, first create ~/.ssh/id_rsa and ~/.ssh/id_rsa.pub with ssh-keygen and then copy ~/.ssh/id_rsa.pub to ~/.ssh/authorized_keys on the remote computer that you want to log into. You'll need to change REMOTE_USERNAME and REMOTE_HOSTNAME for the username and hostname of the remote computer and you'll also need to enter your password for the ssh-copy-id command to succeed:

ssh-keygen &&
ssh-copy-id -i ~/.ssh/id_rsa.pub REMOTE_USERNAME@REMOTE_HOSTNAME

Once you've got passwordless logins working it's actually more secure than logging in with a password (as the private key is much longer than most people's passwords). If you would like to now disable password logins, as the root user:

echo "PasswordAuthentication no" >> /etc/ssh/sshd_config &&
echo "ChallengeResponseAuthentication no" >> /etc/ssh/sshd_config

If you added Linux-PAM support and you want ssh to use it then you will need to add a configuration file for sshd and enable use of LinuxPAM. Note, ssh only uses PAM to check passwords, if you've disabled password logins these commands are not needed. If you want to use PAM, issue the following commands as the root user:

sed 's@d/login@d/sshd@g' /etc/pam.d/login > /etc/pam.d/sshd &&
chmod 644 /etc/pam.d/sshd &&
echo "UsePAM yes" >> /etc/ssh/sshd_config

Additional configuration information can be found in the man pages for sshd, ssh and ssh-agent.

Boot Script

To start the SSH server at system boot, install the /etc/rc.d/init.d/sshd init script included in the blfs-bootscripts-20210826 package.

make install-sshd

Contents

Installed Programs: scp, sftp, ssh, ssh-add, ssh-agent, ssh-copy-id, ssh-keygen, ssh-keyscan, and sshd
Installed Libraries: None
Installed Directories: /etc/ssh, /usr/share/doc/openssh-8.8p1, and /var/lib/sshd

Short Descriptions

scp

is a file copy program that acts like rcp except it uses an encrypted protocol

sftp

is an FTP-like program that works over the SSH1 and SSH2 protocols

ssh

is an rlogin/rsh-like client program except it uses an encrypted protocol

sshd

is a daemon that listens for ssh login requests

ssh-add

is a tool which adds keys to the ssh-agent

ssh-agent

is an authentication agent that can store private keys

ssh-copy-id

is a script that enables logins on remote machines using local keys

ssh-keygen

is a key generation tool

ssh-keyscan

is a utility for gathering public host keys from a number of hosts

Last updated on

p11-kit-0.24.1

Introduction to p11-kit

The p11-kit package provides a way to load and enumerate PKCS #11 (a Cryptographic Token Interface Standard) modules.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

p11-kit Dependencies

Recommended
Optional

GTK-Doc-1.33.2, libxslt-1.1.35, and nss-3.75 (runtime)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/p11-kit

Installation of p11-kit

Prepare the distribution specific anchor hook:

sed '20,$ d' -i trust/trust-extract-compat &&
cat >> trust/trust-extract-compat << "EOF"
# Copy existing anchor modifications to /etc/ssl/local
/usr/libexec/make-ca/copy-trust-modifications

# Update trust stores
/usr/sbin/make-ca -r
EOF

Install p11-kit by running the following commands:

mkdir p11-build &&
cd    p11-build &&

meson --prefix=/usr       \
      --buildtype=release \
      -Dtrust_paths=/etc/pki/anchors &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install &&
ln -sfv /usr/libexec/p11-kit/trust-extract-compat \
        /usr/bin/update-ca-certificates

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dtrust_paths=/etc/pki/anchors: this switch sets the location of trusted certificates used by libp11-kit.so.

-Dhash_impl=freebl: Use this switch if you want to use the Freebl library from NSS for SHA1 and MD5 hashing.

-Dgtk_doc=true: Use this switch if you have installed GTK-Doc-1.33.2 and libxslt-1.1.35 and wish to rebuild the documentation and generate manual pages.

Configuring p11-kit

The p11-kit trust module (/usr/lib/pkcs11/p11-kit-trust.so) can be used as a drop-in replacement for /usr/lib/libnssckbi.so to transparently make the system CAs available to NSS aware applications, rather than the static list provided by /usr/lib/libnssckbi.so. As the root user, execute the following commands:

ln -sfv ./pkcs11/p11-kit-trust.so /usr/lib/libnssckbi.so

Contents

Installed Programs: p11-kit, trust, and update-ca-certificates
Installed Libraries: libp11-kit.so and p11-kit-proxy.so
Installed Directories: /etc/pkcs11, /usr/include/p11-kit-1, /usr/lib/pkcs11, /usr/libexec/p11-kit, /usr/share/gtk-doc/html/p11-kit, and /usr/share/p11-kit

Short Descriptions

p11-kit

is a command line tool that can be used to perform operations on PKCS#11 modules configured on the system

trust

is a command line tool to examine and modify the shared trust policy store

update-ca-certificates

is a command line tool to both extract local certificates from an updated anchor store, and regenerate all anchors and certificate stores on the system. This is done unconditionally on BLFS using the --force and --get flags to make-ca and should likely not be used for automated updates

libp11-kit.so

contains functions used to coordinate initialization and finalization of any PKCS#11 module

p11-kit-proxy.so

is the PKCS#11 proxy module

Last updated on

Polkit-0.120

Introduction to Polkit

Polkit is a toolkit for defining and handling authorizations. It is used for allowing unprivileged processes to communicate with privileged processes.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Polkit Dependencies

Required

GLib-2.70.4 and js78-78.15.0

Recommended

Note

Since elogind uses PAM to register user sessions, it is a good idea to build Polkit with PAM support so elogind can track Polkit sessions.

Optional

GTK-Doc-1.33.2

Optional Runtime Dependencies

One polkit authentication agent for using polkit in the graphical environment: polkit-kde-agent in Plasma-5.24.0 for KDE, the agent built in gnome-shell-41.4 for GNOME3, polkit-gnome-0.105 for XFCE, and lxpolkit in LXSession-0.5.5 for LXDE.

Note

If libxslt-1.1.35 is installed, then docbook-xml-4.5 and docbook-xsl-1.79.2 are required. If you have installed libxslt-1.1.35, but you do not want to install any of the DocBook packages mentioned, you will need to use -Dman=false in the instructions below.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/polkit

Installation of Polkit

There should be a dedicated user and group to take control of the polkitd daemon after it is started. Issue the following commands as the root user:

groupadd -fg 27 polkitd &&
useradd -c "PolicyKit Daemon Owner" -d /etc/polkit-1 -u 27 \
        -g polkitd -s /bin/false polkitd

First, fix problems with setting permissions during installation and with meson-0.60.0:

sed '/0,/s/^/#/' -i meson_post_install.py &&
sed '/policy,/d' -i actions/meson.build \
                 -i src/examples/meson.build

Apply a patch to fix a security issue:

patch -Np1 -i ../polkit-0.120-security_fix-1.patch

Install Polkit by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr                 \
      -Dman=true                    \
      -Dsession_tracking=libelogind \
      -Dsystemdsystemunitdir=/tmp   \
      --buildtype=release           \
      ..                            &&
ninja

This package does not ship with a working test suite.

Now, as the root user:

ninja install &&
rm -v /tmp/*.service

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dauthfw=shadow: This switch enables the package to use the Shadow rather than the Linux PAM Authentication framework. Use it if you have not installed Linux PAM.

-Dintrospection=false: Use this option if you are certain that you do not need gobject-introspection files for polkit, or do not have gobject-introspection installed.

-Dman=false: Use this option to disable generating and installing manual pages. This is useful if libxslt is not installed.

-Dexamples=true: Use this option to build the example programs.

-Dgtk_doc=true: Use this option to enable building and installing the API documentation.

Configuring Polkit

PAM Configuration

Note

If you did not build Polkit with Linux PAM support, you can skip this section.

If you have built Polkit with Linux PAM support, you need to modify the default PAM configuration file which was installed by default to get Polkit to work correctly with BLFS. Issue the following commands as the root user to create the configuration file for Linux PAM:

cat > /etc/pam.d/polkit-1 << "EOF"
# Begin /etc/pam.d/polkit-1

auth     include        system-auth
account  include        system-account
password include        system-password
session  include        system-session

# End /etc/pam.d/polkit-1
EOF

Contents

Installed Programs: pkaction, pkcheck, pkexec, pkttyagent and polkitd
Installed Libraries: libpolkit-agent-1.so and libpolkit-gobject-1.so
Installed Directories: /etc/polkit-1, /usr/include/polkit-1, /usr/lib/polkit-1, /usr/share/gtk-doc/html/polkit-1 and /usr/share/polkit-1

Short Descriptions

pkaction

is used to obtain information about registered PolicyKit actions

pkcheck

is used to check whether a process is authorized for action

pkexec

allows an authorized user to execute a command as another user

pkttyagent

is used to start a textual authentication agent for the subject

polkitd

provides the org.freedesktop.PolicyKit1 D-Bus service on the system message bus

libpolkit-agent-1.so

contains the Polkit authentication agent API functions

libpolkit-gobject-1.so

contains the Polkit authorization API functions

Last updated on

polkit-gnome-0.105

Introduction to Polkit GNOME

The Polkit GNOME package provides an Authentication Agent for Polkit that integrates well with the GNOME Desktop environment.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Polkit GNOME Dependencies

Required

AccountsService-22.07.5, GTK+-3.24.31, and Polkit-0.120

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/polkit-gnome

Installation of Polkit GNOME

First, apply some fixes that allow for the proper user icon to be used, as well as some security fixes:

patch -Np1 -i ../polkit-gnome-0.105-consolidated_fixes-1.patch

Install Polkit GNOME by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Configuring Polkit GNOME

Automatic Startup

For the authentification framework to work, polkit-gnome-authentification-agent-1 needs to be started. However, make install did not install a startup file for the Polkit GNOME so you have to create it by yourself.

Issue the following commands as the root user to create a startup file for Polkit GNOME:

mkdir -p /etc/xdg/autostart &&
cat > /etc/xdg/autostart/polkit-gnome-authentication-agent-1.desktop << "EOF"
[Desktop Entry]
Name=PolicyKit Authentication Agent
Comment=PolicyKit Authentication Agent
Exec=/usr/libexec/polkit-gnome-authentication-agent-1
Terminal=false
Type=Application
Categories=
NoDisplay=true
OnlyShowIn=GNOME;XFCE;Unity;
AutostartCondition=GNOME3 unless-session gnome
EOF

Contents

Installed Program: polkit-gnome-authentication-agent-1
Installed Libraries: None
Installed Directory: None

Short Descriptions

polkit-gnome-authentication-agent-1

is the Polkit authentication agent

Last updated on

Shadow-4.11.1

Introduction to Shadow

Shadow was indeed installed in LFS and there is no reason to reinstall it unless you installed CrackLib or Linux-PAM after your LFS system was completed. If you have installed CrackLib after LFS, then reinstalling Shadow will enable strong password support. If you have installed Linux-PAM, reinstalling Shadow will allow programs such as login and su to utilize PAM.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Shadow Dependencies

Required

Linux-PAM-1.5.2 or CrackLib-2.9.7

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/shadow

Installation of Shadow

Important

The installation commands shown below are for installations where Linux-PAM has been installed and Shadow is being reinstalled to support the Linux-PAM installation.

If you are reinstalling Shadow to provide strong password support using the CrackLib library without using Linux-PAM, ensure you add the --with-libcrack parameter to the configure script below and also issue the following command:

sed -i 's@DICTPATH.*@DICTPATH\t/lib/cracklib/pw_dict@' etc/login.defs

Reinstall Shadow by running the following commands:

sed -i 's/groups$(EXEEXT) //' src/Makefile.in          &&

find man -name Makefile.in -exec sed -i 's/groups\.1 / /'   {} \; &&
find man -name Makefile.in -exec sed -i 's/getspnam\.3 / /' {} \; &&
find man -name Makefile.in -exec sed -i 's/passwd\.5 / /'   {} \; &&

sed -e 's@#ENCRYPT_METHOD DES@ENCRYPT_METHOD SHA512@' \
    -e 's@/var/spool/mail@/var/mail@'                 \
    -e '/PATH=/{s@/sbin:@@;s@/bin:@@}'                \
    -i etc/login.defs                                 &&

./configure --sysconfdir=/etc               \
            --disable-static                \
            --with-group-name-max-length=32 &&
make

This package does not come with a test suite.

Now, as the root user:

make exec_prefix=/usr install

The man pages were installed in LFS, but if reinstallation is desired, run (as the root user):

make -C man install-man

Command Explanations

sed -i 's/groups$(EXEEXT) //' src/Makefile.in: This sed is used to suppress the installation of the groups program as the version from the Coreutils package installed during LFS is preferred.

find man -name Makefile.in -exec ... {} \;: The first command is used to suppress the installation of the groups man pages so the existing ones installed from the Coreutils package are not replaced. The two other commands prevent installation of manual pages that are already installed by Man-pages in LFS.

sed -e 's@#ENCRYPT_METHOD DES@ENCRYPT_METHOD SHA512@' -e 's@/var/spool/mail@/var/mail@' -e '/PATH=/{s@/sbin:@@;s@/bin:@@}' -i etc/login.defs: Instead of using the default 'DES' method, this command modifies the installation to use the more secure 'SHA512' method of hashing passwords, which also allows passwords longer than eight characters. It also changes the obsolete /var/spool/mail location for user mailboxes that Shadow uses by default to the /var/mail location. It also changes the default path to be consistent with that set in LFS.

--with-group-name-max-length=32: The maximum user name is 32 characters. Make the maximum group name the same.

Configuring Linux-PAM to Work with Shadow

Note

The rest of this page is devoted to configuring Shadow to work properly with Linux-PAM. If you do not have Linux-PAM installed, and you reinstalled Shadow to support strong passwords via the CrackLib library, no further configuration is required.

Config Files

/etc/pam.d/* or alternatively /etc/pam.conf, /etc/login.defs and /etc/security/*

Configuration Information

Configuring your system to use Linux-PAM can be a complex task. The information below will provide a basic setup so that Shadow's login and password functionality will work effectively with Linux-PAM. Review the information and links on the Linux-PAM-1.5.2 page for further configuration information. For information specific to integrating Shadow, Linux-PAM and libpwquality, you can visit the following link:

Configuring /etc/login.defs

The login program currently performs many functions which Linux-PAM modules should now handle. The following sed command will comment out the appropriate lines in /etc/login.defs, and stop login from performing these functions (a backup file named /etc/login.defs.orig is also created to preserve the original file's contents). Issue the following commands as the root user:

install -v -m644 /etc/login.defs /etc/login.defs.orig &&
for FUNCTION in FAIL_DELAY               \
                FAILLOG_ENAB             \
                LASTLOG_ENAB             \
                MAIL_CHECK_ENAB          \
                OBSCURE_CHECKS_ENAB      \
                PORTTIME_CHECKS_ENAB     \
                QUOTAS_ENAB              \
                CONSOLE MOTD_FILE        \
                FTMP_FILE NOLOGINS_FILE  \
                ENV_HZ PASS_MIN_LEN      \
                SU_WHEEL_ONLY            \
                CRACKLIB_DICTPATH        \
                PASS_CHANGE_TRIES        \
                PASS_ALWAYS_WARN         \
                CHFN_AUTH ENCRYPT_METHOD \
                ENVIRON_FILE
do
    sed -i "s/^${FUNCTION}/# &/" /etc/login.defs
done
Configuring the /etc/pam.d/ Files

As mentioned previously in the Linux-PAM instructions, Linux-PAM has two supported methods for configuration. The commands below assume that you've chosen to use a directory based configuration, where each program has its own configuration file. You can optionally use a single /etc/pam.conf configuration file by using the text from the files below, and supplying the program name as an additional first field for each line.

As the root user, create the following Linux-PAM configuration files in the /etc/pam.d/ directory (or add the contents to the /etc/pam.conf file) using the following commands:

'login'
cat > /etc/pam.d/login << "EOF"
# Begin /etc/pam.d/login

# Set failure delay before next prompt to 3 seconds
auth      optional    pam_faildelay.so  delay=3000000

# Check to make sure that the user is allowed to login
auth      requisite   pam_nologin.so

# Check to make sure that root is allowed to login
# Disabled by default. You will need to create /etc/securetty
# file for this module to function. See man 5 securetty.
#auth      required    pam_securetty.so

# Additional group memberships - disabled by default
#auth      optional    pam_group.so

# include system auth settings
auth      include     system-auth

# check access for the user
account   required    pam_access.so

# include system account settings
account   include     system-account

# Set default environment variables for the user
session   required    pam_env.so

# Set resource limits for the user
session   required    pam_limits.so

# Display date of last login - Disabled by default
#session   optional    pam_lastlog.so

# Display the message of the day - Disabled by default
#session   optional    pam_motd.so

# Check user's mail - Disabled by default
#session   optional    pam_mail.so      standard quiet

# include system session and password settings
session   include     system-session
password  include     system-password

# End /etc/pam.d/login
EOF
'passwd'
cat > /etc/pam.d/passwd << "EOF"
# Begin /etc/pam.d/passwd

password  include     system-password

# End /etc/pam.d/passwd
EOF
'su'
cat > /etc/pam.d/su << "EOF"
# Begin /etc/pam.d/su

# always allow root
auth      sufficient  pam_rootok.so

# Allow users in the wheel group to execute su without a password
# disabled by default
#auth      sufficient  pam_wheel.so trust use_uid

# include system auth settings
auth      include     system-auth

# limit su to users in the wheel group
auth      required    pam_wheel.so use_uid

# include system account settings
account   include     system-account

# Set default environment variables for the service user
session   required    pam_env.so

# include system session settings
session   include     system-session

# End /etc/pam.d/su
EOF
'chpasswd' and 'newusers'
cat > /etc/pam.d/chpasswd << "EOF"
# Begin /etc/pam.d/chpasswd

# always allow root
auth      sufficient  pam_rootok.so

# include system auth and account settings
auth      include     system-auth
account   include     system-account
password  include     system-password

# End /etc/pam.d/chpasswd
EOF

sed -e s/chpasswd/newusers/ /etc/pam.d/chpasswd >/etc/pam.d/newusers
'chage'
cat > /etc/pam.d/chage << "EOF"
# Begin /etc/pam.d/chage

# always allow root
auth      sufficient  pam_rootok.so

# include system auth and account settings
auth      include     system-auth
account   include     system-account

# End /etc/pam.d/chage
EOF
Other shadow utilities
for PROGRAM in chfn chgpasswd chsh groupadd groupdel \
               groupmems groupmod useradd userdel usermod
do
    install -v -m644 /etc/pam.d/chage /etc/pam.d/${PROGRAM}
    sed -i "s/chage/$PROGRAM/" /etc/pam.d/${PROGRAM}
done

Warning

At this point, you should do a simple test to see if Shadow is working as expected. Open another terminal and log in as root, and then run login and login as another user. If you do not see any errors, then all is well and you should proceed with the rest of the configuration. If you did receive errors, stop now and double check the above configuration files manually. Any error is the sign of an error in the above procedure. You can also run the test suite from the Linux-PAM package to assist you in determining the problem. If you cannot find and fix the error, you should recompile Shadow adding the --without-libpam switch to the configure command in the above instructions (also move the /etc/login.defs.orig backup file to /etc/login.defs). If you fail to do this and the errors remain, you will be unable to log into your system.

Configuring Login Access

Instead of using the /etc/login.access file for controlling access to the system, Linux-PAM uses the pam_access.so module along with the /etc/security/access.conf file. Rename the /etc/login.access file using the following command:

[ -f /etc/login.access ] && mv -v /etc/login.access{,.NOUSE}
Configuring Resource Limits

Instead of using the /etc/limits file for limiting usage of system resources, Linux-PAM uses the pam_limits.so module along with the /etc/security/limits.conf file. Rename the /etc/limits file using the following command:

[ -f /etc/limits ] && mv -v /etc/limits{,.NOUSE}

Caution

Be sure to test the login capabilities of the system before logging out. Errors in the configuration can cause a permanent lockout requiring a boot from an external source to correct the problem.

Contents

A list of the installed files, along with their short descriptions can be found at ../../../../lfs/view/11.1/chapter08/shadow.html#contents-shadow.

Last updated on

ssh-askpass-8.8p1

Introduction to ssh-askpass

The ssh-askpass is a generic executable name for many packages, with similar names, that provide a interactive X service to grab password for packages requiring administrative privileges to be run. It prompts the user with a window box where the necessary password can be inserted. Here, we choose Damien Miller's package distributed in the OpenSSH tarball.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

ssh-askpass Dependencies

Required

GTK+-2.24.33, Sudo-1.9.9 (runtime), Xorg Libraries, and a graphical environment (runtime)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/ssh-askpass

Installation of ssh-askpass

Install ssh-askpass by running the following commands:

cd contrib &&
make gnome-ssh-askpass2

Now, as the root user:

install -v -d -m755                    /usr/libexec/openssh/contrib  &&
install -v -m755    gnome-ssh-askpass2 /usr/libexec/openssh/contrib  &&
ln -sv -f contrib/gnome-ssh-askpass2   /usr/libexec/openssh/ssh-askpass

The use of /usr/libexec/openssh/contrib and a symlink is justified by the eventual necessity of a different program for that service.

Configuring ssh-askpass

Configuration Information

As the root user, configure Sudo-1.9.9 to use ssh-askpass:

cat >> /etc/sudo.conf << "EOF" &&
# Path to askpass helper program
Path askpass /usr/libexec/openssh/ssh-askpass
EOF
chmod -v 0644 /etc/sudo.conf

If a given graphical <application> requires administrative privileges, use sudo -A <application> from an x-terminal, from a Window Manager menu and/or replace "Exec=<application> ..." by "Exec=sudo -A <application> ..." in the <application>.desktop file.

Contents

Installed Programs: None
Installed Library: None
Installed Directory: /usr/libexec/openssh/contrib

Last updated on

stunnel-5.62

Introduction to stunnel

The stunnel package contains a program that allows you to encrypt arbitrary TCP connections inside SSL (Secure Sockets Layer) so you can easily communicate with clients over secure channels. stunnel can also be used to tunnel PPP over network sockets without changes to the server package source code.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

stunnel Dependencies

Optional

libnsl-2.0.0, netcat (required for tests), tcpwrappers, and TOR

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/stunnel

Installation of stunnel

The stunnel daemon will be run in a chroot jail by an unprivileged user. Create the new user and group using the following commands as the root user:

groupadd -g 51 stunnel &&
useradd -c "stunnel Daemon" -d /var/lib/stunnel \
        -g stunnel -s /bin/false -u 51 stunnel

Note

A signed SSL Certificate and a Private Key is necessary to run the stunnel daemon. After the package is installed, there are instructions to generate them. However, if you own or have already created a signed SSL Certificate you wish to use, copy it to /etc/stunnel/stunnel.pem before starting the build (ensure only root has read and write access). The .pem file must be formatted as shown below:

-----BEGIN PRIVATE KEY-----
<many encrypted lines of private key>
-----END PRIVATE KEY-----
-----BEGIN CERTIFICATE-----
<many encrypted lines of certificate>
-----END CERTIFICATE-----
-----BEGIN DH PARAMETERS-----
<encrypted lines of dh parms>
-----END DH PARAMETERS-----

Install stunnel by running the following commands:

./configure --prefix=/usr        \
            --sysconfdir=/etc    \
            --localstatedir=/var \
            --disable-systemd    &&
make

If you have installed the optional netcat application, the regression tests can be run with make check.

Now, as the root user:

make docdir=/usr/share/doc/stunnel-5.62 install

If you do not already have a signed SSL Certificate and Private Key, create the stunnel.pem file in the /etc/stunnel directory using the command below. You will be prompted to enter the necessary information. Ensure you reply to the

Common Name (FQDN of your server) [localhost]:

prompt with the name or IP address you will be using to access the service(s).

To generate a certificate, as the root user, issue:

make cert

Command Explanations

--disable-systemd: This switch disables systemd socket activation support which is not available in BLFS.

make docdir=... install: This command installs the package and changes the documentation installation directory to standard naming conventions.

Configuring stunnel

Config Files

/etc/stunnel/stunnel.conf

Configuration Information

As the root user, create the directory used for the .pid file created when the stunnel daemon starts:

install -v -m750 -o stunnel -g stunnel -d /var/lib/stunnel/run &&
chown stunnel:stunnel /var/lib/stunnel

Next, create a basic /etc/stunnel/stunnel.conf configuration file using the following commands as the root user:

cat > /etc/stunnel/stunnel.conf << "EOF"
; File: /etc/stunnel/stunnel.conf

; Note: The pid and output locations are relative to the chroot location.

pid    = /run/stunnel.pid
chroot = /var/lib/stunnel
client = no
setuid = stunnel
setgid = stunnel
cert   = /etc/stunnel/stunnel.pem

;debug = 7
;output = stunnel.log

;[https]
;accept  = 443
;connect = 80
;; "TIMEOUTclose = 0" is a workaround for a design flaw in Microsoft SSL
;; Microsoft implementations do not use SSL close-notify alert and thus
;; they are vulnerable to truncation attacks
;TIMEOUTclose = 0

EOF

Finally, add the service(s) you wish to encrypt to the configuration file. The format is as follows:

[<service>]
accept  = <hostname:portnumber>
connect = <hostname:portnumber>

For a full explanation of the commands and syntax used in the configuration file, issue man stunnel.

Boot Script

To automatically start the stunnel daemon when the system is booted, install the /etc/rc.d/init.d/stunnel bootscript from the blfs-bootscripts-20210826 package.

make install-stunnel

Contents

Installed Programs: stunnel and stunnel3
Installed Library: libstunnel.so
Installed Directories: /{etc,lib,var/lib}/stunnel and /usr/share/doc/stunnel-5.62

Short Descriptions

stunnel

is a program designed to work as an SSL encryption wrapper between remote clients and local or remote servers

stunnel3

is a Perl wrapper script to use stunnel 3.x syntax with stunnel 4.05 or later

libstunnel.so

contains the API functions required by stunnel

Last updated on

Sudo-1.9.9

Introduction to Sudo

The Sudo package allows a system administrator to give certain users (or groups of users) the ability to run some (or all) commands as root or another user while logging the commands and arguments.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Sudo Dependencies

Optional

Linux-PAM-1.5.2, MIT Kerberos V5-1.19.2, OpenLDAP-2.6.1, MTA (that provides a sendmail command), AFS, FWTK, and Opie

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/sudo

Installation of Sudo

Install Sudo by running the following commands:

./configure --prefix=/usr              \
            --libexecdir=/usr/lib      \
            --with-secure-path         \
            --with-all-insults         \
            --with-env-editor          \
            --docdir=/usr/share/doc/sudo-1.9.9 \
            --with-passprompt="[sudo] password for %p: " &&
make

To test the results, issue: env LC_ALL=C make check 2>&1 | tee make-check.log. Check the results with grep failed make-check.log.

Now, as the root user:

make install &&
ln -sfv libsudo_util.so.0.0.0 /usr/lib/sudo/libsudo_util.so.0

Command Explanations

--libexecdir=/usr/lib: This switch controls where private programs are installed. Everything in that directory is a library, so they belong under /usr/lib instead of /usr/libexec.

--with-secure-path: This switch transparently adds /sbin and /usr/sbin directories to the PATH environment variable.

--with-all-insults: This switch includes all the sudo insult sets.

--with-env-editor: This switch enables use of the environment variable EDITOR for visudo.

--with-passprompt: This switch sets the password prompt. The %p will be expanded to the name of the user whose password is being requested.

--without-pam: This switch avoids building Linux-PAM support when Linux-PAM is installed on the system.

Note

There are many options to sudo's configure command. Check the configure --help output for a complete list.

ln -sfv libsudo_util...: Works around a bug in the installation process, which links to the previously installed version (if there is one) instead of the new one.

Configuring Sudo

Config File

/etc/sudoers

Configuration Information

The sudoers file can be quite complicated. It is composed of two types of entries: aliases (basically variables) and user specifications (which specify who may run what). The installation installs a default configuration that has no privileges installed for any user.

A couple of common configuration changes are to set the path for the super user and to allow members of the wheel group to execute all commands after providing their own credientials. Use the following commands to create the /etc/sudoers.d/00-sudo configuration file as the root user:

cat > /etc/sudoers.d/00-sudo << "EOF"
Defaults secure_path="/usr/sbin:/usr/bin"
%wheel ALL=(ALL) ALL
EOF

Note

In very simple installations where there is only one user, it may be easier to just edit the /etc/sudoers file directly. In that case, the secure_path entry may not be needed and using sudo -E ... can import the non-privileged user's full environment into the privileged session.

The files in the /etc/sudoers.d directory are parsed in sorted lexical order. Be careful that entries in an added file do not overwrite previous entries.

For details, see man sudoers.

Note

The Sudo developers highly recommend using the visudo program to edit the sudoers file. This will provide basic sanity checking like syntax parsing and file permission to avoid some possible mistakes that could lead to a vulnerable configuration.

If PAM is installed on the system, Sudo is built with PAM support. In that case, issue the following command as the root user to create the PAM configuration file:

cat > /etc/pam.d/sudo << "EOF"
# Begin /etc/pam.d/sudo

# include the default auth settings
auth      include     system-auth

# include the default account settings
account   include     system-account

# Set default environment variables for the service user
session   required    pam_env.so

# include system session defaults
session   include     system-session

# End /etc/pam.d/sudo
EOF
chmod 644 /etc/pam.d/sudo

Contents

Installed Programs: cvtsudoers, sudo, sudo_logsrvd, sudo_sendlog, sudoedit (symlink), sudoreplay, and visudo
Installed Libraries: audit_json.so, group_file.so, libsudo_util.so, sample_approval.so, sudoers.so, sudo_noexec.so, and system_group.so
Installed Directories: /etc/sudoers.d, /usr/lib/sudo, /usr/share/doc/sudo-1.9.9, and /var/lib/sudo

Short Descriptions

cvtsudoers

converts between sudoers file formats

sudo

executes a command as another user as permitted by the /etc/sudoers configuration file

sudo_logsrvd

is a sudo event and I/O log server

sudo_sendlog

sends sudo I/O logs to the log server

sudoedit

is a symlink to sudo that implies the -e option to invoke an editor as another user

sudoreplay

is used to play back or list the output logs created by sudo

visudo

allows for safer editing of the sudoers file

Last updated on

Tripwire-2.4.3.7

Introduction to Tripwire

The Tripwire package contains programs used to verify the integrity of the files on a given system.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Tripwire Dependencies

Optional

An MTA

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/tripwire

Installation of Tripwire

Compile Tripwire by running the following commands:

sed -e '/^CLOBBER/s/false/true/'         \
    -e 's|TWDB="${prefix}|TWDB="/var|'   \
    -e '/TWMAN/ s|${prefix}|/usr/share|' \
    -e '/TWDOCS/s|${prefix}/doc/tripwire|/usr/share/doc/tripwire-2.4.3.7|' \
    -i installer/install.cfg                               &&

find . -name Makefile.am | xargs                           \
    sed -i 's/^[[:alpha:]_]*_HEADERS.*=/noinst_HEADERS =/' &&

sed '/dist/d' -i man/man?/Makefile.am                      &&
autoreconf -fi                                             &&

./configure --prefix=/usr --sysconfdir=/etc/tripwire       &&
make CPPFLAGS=-std=c++11

Note

The default configuration is to use a local MTA. If you don't have an MTA installed and have no wish to install one, modify install/install.cfg to use an SMTP server instead. Otherwise the install will fail.

This package does not come with a test suite.

Now, as the root user:

make install &&
cp -v policy/*.txt /usr/share/doc/tripwire-2.4.3.7

Note

During make install, several questions are asked, including passwords. If you want to make a script, you have to apply a sed before running make install:

sed -i -e 's@installer/install.sh@& -n -s <site-password> -l <local-password>@' Makefile

Of course, you should do this with dummy passwords and change them later.

Another issue when scripting is that the installer exits when the standard input is not a terminal. You may disable this behavior with the following sed:

sed '/-t 0/,+3d' -i installer/install.sh

Command Explanations

sed ... installer/install.cfg: This command tells the package to install the program database and reports in /var/lib/tripwire and sets the proper location for man pages and documentation.

find ..., sed ..., and autoreconf -fi: The build system is unusable as is, and has to be modified for the build to succeed.

CPPFLAGS=-std=c++11: Setting the C++ preprocessor flags to version 11 is necessary to prevent a confict with the default version which is c++17 in recent version of gcc.

make install: This command creates the Tripwire security keys as well as installing the binaries. There are two keys: a site key and a local key which are stored in /etc/tripwire/.

cp -v policy/*.txt /usr/doc/tripwire-2.4.3.7: This command installs the tripwire sample policy files with the other tripwire documentation.i

Configuring Tripwire

Config Files

/etc/tripwire/*

Configuration Information

Tripwire uses a policy file to determine which files are integrity checked. The default policy file (/etc/tripwire/twpol.txt) is for a default installation and will need to be updated for your system.

Policy files should be tailored to each individual distribution and/or installation. Some example policy files can be found in /usr/share/doc/tripwire/.

If desired, copy the policy file you'd like to try into /etc/tripwire/ instead of using the default policy file, twpol.txt. It is, however, recommended that you edit your policy file. Get ideas from the examples above and read /usr/share/doc/tripwire/policyguide.txt for additional information. twpol.txt is a good policy file for learning about Tripwire as it will note any changes to the file system and can even be used as an annoying way of keeping track of changes for uninstallation of software.

After your policy file has been edited to your satisfaction you may begin the configuration steps (perform as the root) user:

twadmin --create-polfile --site-keyfile /etc/tripwire/site.key \
    /etc/tripwire/twpol.txt &&
tripwire --init

Depending on your system and the contents of the policy file, the initialization phase above can take a relatively long time.

Usage Information

Tripwire will identify file changes in the critical system files specified in the policy file. Using Tripwire while making frequent changes to these directories will flag all these changes. It is most useful after a system has reached a configuration that the user considers stable.

To use Tripwire after creating a policy file to run a report, use the following command:

tripwire --check > /etc/tripwire/report.txt

View the output to check the integrity of your files. An automatic integrity report can be produced by using a cron facility to schedule the runs.

Reports are stored in binary and, if desired, encrypted. View reports, as the root user, with:

twprint --print-report -r /var/lib/tripwire/report/<report-name.twr>

After you run an integrity check, you should examine the report (or email) and then modify the Tripwire database to reflect the changed files on your system. This is so that Tripwire will not continually notify you hat files you intentionally changed are a security violation. To do this you must first ls -l /var/lib/tripwire/report/ and note the name of the newest file which starts with your system name as presented by the command uname -n and ends in .twr. These files were created during report creation and the most current one is needed to update the Tripwire database of your system. As the root user, type in the following command making the appropriate report name:

tripwire --update --twrfile /var/lib/tripwire/report/<report-name.twr>

You will be placed into Vim with a copy of the report in front of you. If all the changes were good, then just type :wq and after entering your local key, the database will be updated. If there are files which you still want to be warned about, remove the 'x' before the filename in the report and type :wq.

Changing the Policy File

If you are unhappy with your policy file and would like to modify it or use a new one, modify the policy file and then execute the following commands as the root user:

twadmin --create-polfile /etc/tripwire/twpol.txt &&
tripwire --init

Contents

Installed Programs: siggen, tripwire, twadmin, and twprint
Installed Libraries: None
Installed Directories: /etc/tripwire, /var/lib/tripwire, and /usr/share/doc/tripwire-2.4.3.7

Short Descriptions

siggen

is a signature gathering utility that displays the hash function values for the specified files

tripwire

is the main file integrity checking program

twadmin

administrative and utility tool used to perform certain administrative functions related to Tripwire files and configuration options

twprint

prints Tripwire database and report files in clear text format

Last updated on

volume_key-0.3.12

Introduction to volume_key

The volume_key package provides a library for manipulating storage volume encryption keys and storing them separately from volumes to handle forgotten passphrases.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

volume_key Dependencies

Required

cryptsetup-2.4.3, GLib-2.70.4, GPGME-1.17.0, and nss-3.75

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/volume_key

Installation of volume_key

Install volume_key by running the following commands:

Note

This package expands to the directory volume_key-volume_key-0.3.12.

autoreconf -fiv              &&
./configure --prefix=/usr    \
            --without-python &&
make

This package does not come with a functioning test suite.

Now, as the root user:

make install

Command Explanations

--without-python: This parameter prevents building the Python 2 bindings, if Python-2.7.18 is installed.

--without-python3: Use this option if you do not want to build the Python 3 bindings. In this case, SWIG-4.0.2 is not needed.

Contents

Installed Program: volume_key
Installed Library: libvolume_key.so
Installed Directory: /usr/include/volume_key

Short Descriptions

volume_key

manages encrypted volume keys and passphrases

volume_key.so

contains API functions for managing encrypted volume keys

Last updated on

Chapter 5. File Systems and Disk Management

Journaling file systems reduce the time needed to recover a file system that was not unmounted properly. While this can be extremely important in reducing downtime for servers, it has also become popular for desktop environments. This chapter contains other journaling file systems you can use instead of the default LFS extended file system (ext2/3/4). It also provides introductory material on managing disk arrays.

About initramfs

The only purpose of an initramfs is to mount the root filesystem. The initramfs is a complete set of directories that you would find on a normal root filesystem. It is bundled into a single cpio archive and compressed with one of several compression algorithms.

At boot time, the boot loader loads the kernel and the initramfs image into memory and starts the kernel. The kernel checks for the presence of the initramfs and, if found, mounts it as / and runs /init. The init program is typically a shell script. Note that the boot process takes longer, possibly significantly longer, if an initramfs is used.

For most distributions, kernel modules are the biggest reason to have an initramfs. In a general distribution, there are many unknowns such as file system types and disk layouts. In a way, this is the opposite of LFS where the system capabilities and layout are known and a custom kernel is normally built. In this situation, an initramfs is rarely needed.

There are only four primary reasons to have an initramfs in the LFS environment: loading the rootfs from a network, loading it from an LVM logical volume, having an encrypted rootfs where a password is required, or for the convenience of specifying the rootfs as a LABEL or UUID. Anything else usually means that the kernel was not configured properly.

Building an initramfs

If you do decide to build an initramfs, the following scripts will provide a basis to do it. The scripts will allow specifying a rootfs via partition UUID or partition LABEL or a rootfs on an LVM logical volume. They do not support an encrypted root file system or mounting the rootfs over a network card. For a more complete capability see the LFS Hints or dracut.

To install these scripts, run the following commands as the root user:

cat > /usr/sbin/mkinitramfs << "EOF"
#!/bin/bash
# This file based in part on the mkinitramfs script for the LFS LiveCD
# written by Alexander E. Patrakov and Jeremy Huntwork.

copy()
{
  local file

  if [ "$2" = "lib" ]; then
    file=$(PATH=/usr/lib type -p $1)
  else
    file=$(type -p $1)
  fi

  if [ -n "$file" ] ; then
    cp $file $WDIR/usr/$2
  else
    echo "Missing required file: $1 for directory $2"
    rm -rf $WDIR
    exit 1
  fi
}

if [ -z $1 ] ; then
  INITRAMFS_FILE=initrd.img-no-kmods
else
  KERNEL_VERSION=$1
  INITRAMFS_FILE=initrd.img-$KERNEL_VERSION
fi

if [ -n "$KERNEL_VERSION" ] && [ ! -d "/usr/lib/modules/$1" ] ; then
  echo "No modules directory named $1"
  exit 1
fi

printf "Creating $INITRAMFS_FILE... "

binfiles="sh cat cp dd killall ls mkdir mknod mount "
binfiles="$binfiles umount sed sleep ln rm uname"
binfiles="$binfiles readlink basename"

# Systemd installs udevadm in /bin. Other udev implementations have it in /sbin
if [ -x /usr/bin/udevadm ] ; then binfiles="$binfiles udevadm"; fi

sbinfiles="modprobe blkid switch_root"

# Optional files and locations
for f in mdadm mdmon udevd udevadm; do
  if [ -x /usr/sbin/$f ] ; then sbinfiles="$sbinfiles $f"; fi
done

# Add lvm if present (cannot be done with the others because it
# also needs dmsetup
if [ -x /usr/sbin/lvm ] ; then sbinfiles="$sbinfiles lvm dmsetup"; fi

unsorted=$(mktemp /tmp/unsorted.XXXXXXXXXX)

DATADIR=/usr/share/mkinitramfs
INITIN=init.in

# Create a temporary working directory
WDIR=$(mktemp -d /tmp/initrd-work.XXXXXXXXXX)

# Create base directory structure
mkdir -p $WDIR/{dev,run,sys,proc,usr/{bin,lib/{firmware,modules},sbin}}
mkdir -p $WDIR/etc/{modprobe.d,udev/rules.d}
touch $WDIR/etc/modprobe.d/modprobe.conf
ln -s usr/bin  $WDIR/bin
ln -s usr/lib  $WDIR/lib
ln -s usr/sbin $WDIR/sbin
ln -s lib      $WDIR/lib64

# Create necessary device nodes
mknod -m 640 $WDIR/dev/console c 5 1
mknod -m 664 $WDIR/dev/null    c 1 3

# Install the udev configuration files
if [ -f /etc/udev/udev.conf ]; then
  cp /etc/udev/udev.conf $WDIR/etc/udev/udev.conf
fi

for file in $(find /etc/udev/rules.d/ -type f) ; do
  cp $file $WDIR/etc/udev/rules.d
done

# Install any firmware present
cp -a /usr/lib/firmware $WDIR/usr/lib

# Copy the RAID configuration file if present
if [ -f /etc/mdadm.conf ] ; then
  cp /etc/mdadm.conf $WDIR/etc
fi

# Install the init file
install -m0755 $DATADIR/$INITIN $WDIR/init

if [  -n "$KERNEL_VERSION" ] ; then
  if [ -x /usr/bin/kmod ] ; then
    binfiles="$binfiles kmod"
  else
    binfiles="$binfiles lsmod"
    sbinfiles="$sbinfiles insmod"
  fi
fi

# Install basic binaries
for f in $binfiles ; do
  ldd /usr/bin/$f | sed "s/\t//" | cut -d " " -f1 >> $unsorted
  copy /usr/bin/$f bin
done

for f in $sbinfiles ; do
  ldd /usr/sbin/$f | sed "s/\t//" | cut -d " " -f1 >> $unsorted
  copy $f sbin
done

# Add udevd libraries if not in /usr/sbin
if [ -x /usr/lib/udev/udevd ] ; then
  ldd /usr/lib/udev/udevd | sed "s/\t//" | cut -d " " -f1 >> $unsorted
elif [ -x /usr/lib/systemd/systemd-udevd ] ; then
  ldd /usr/lib/systemd/systemd-udevd | sed "s/\t//" | cut -d " " -f1 >> $unsorted
fi

# Add module symlinks if appropriate
if [ -n "$KERNEL_VERSION" ] && [ -x /usr/bin/kmod ] ; then
  ln -s kmod $WDIR/usr/bin/lsmod
  ln -s kmod $WDIR/usr/bin/insmod
fi

# Add lvm symlinks if appropriate
# Also copy the lvm.conf file
if  [ -x /usr/sbin/lvm ] ; then
  ln -s lvm $WDIR/usr/sbin/lvchange
  ln -s lvm $WDIR/usr/sbin/lvrename
  ln -s lvm $WDIR/usr/sbin/lvextend
  ln -s lvm $WDIR/usr/sbin/lvcreate
  ln -s lvm $WDIR/usr/sbin/lvdisplay
  ln -s lvm $WDIR/usr/sbin/lvscan

  ln -s lvm $WDIR/usr/sbin/pvchange
  ln -s lvm $WDIR/usr/sbin/pvck
  ln -s lvm $WDIR/usr/sbin/pvcreate
  ln -s lvm $WDIR/usr/sbin/pvdisplay
  ln -s lvm $WDIR/usr/sbin/pvscan

  ln -s lvm $WDIR/usr/sbin/vgchange
  ln -s lvm $WDIR/usr/sbin/vgcreate
  ln -s lvm $WDIR/usr/sbin/vgscan
  ln -s lvm $WDIR/usr/sbin/vgrename
  ln -s lvm $WDIR/usr/sbin/vgck
  # Conf file(s)
  cp -a /etc/lvm $WDIR/etc
fi

# Install libraries
sort $unsorted | uniq | while read library ; do
# linux-vdso and linux-gate are pseudo libraries and do not correspond to a file
# libsystemd-shared is in /lib/systemd, so it is not found by copy, and
# it is copied below anyway
  if [[ "$library" == linux-vdso.so.1 ]] ||
     [[ "$library" == linux-gate.so.1 ]] ||
     [[ "$library" == libsystemd-shared* ]]; then
    continue
  fi

  copy $library lib
done

if [ -d /usr/lib/udev ]; then
  cp -a /usr/lib/udev $WDIR/usr/lib
fi
if [ -d /usr/lib/systemd ]; then
  cp -a /usr/lib/systemd $WDIR/usr/lib
fi
if [ -d /usr/lib/elogind ]; then
  cp -a /usr/lib/elogind $WDIR/usr/lib
fi

# Install the kernel modules if requested
if [ -n "$KERNEL_VERSION" ]; then
  find                                                                        \
     /usr/lib/modules/$KERNEL_VERSION/kernel/{crypto,fs,lib}                      \
     /usr/lib/modules/$KERNEL_VERSION/kernel/drivers/{block,ata,md,firewire}      \
     /usr/lib/modules/$KERNEL_VERSION/kernel/drivers/{scsi,message,pcmcia,virtio} \
     /usr/lib/modules/$KERNEL_VERSION/kernel/drivers/usb/{host,storage}           \
     -type f 2> /dev/null | cpio --make-directories -p --quiet $WDIR

  cp /usr/lib/modules/$KERNEL_VERSION/modules.{builtin,order}                     \
            $WDIR/usr/lib/modules/$KERNEL_VERSION

  depmod -b $WDIR $KERNEL_VERSION
fi

( cd $WDIR ; find . | cpio -o -H newc --quiet | gzip -9 ) > $INITRAMFS_FILE

# Prepare early loading of microcode if available
if ls /usr/lib/firmware/intel-ucode/* >/dev/null 2>&1 ||
   ls /usr/lib/firmware/amd-ucode/*   >/dev/null 2>&1; then

# first empty WDIR to reuse it
  rm -r $WDIR/*

  DSTDIR=$WDIR/kernel/x86/microcode
  mkdir -p $DSTDIR

  if [ -d /usr/lib/firmware/amd-ucode ]; then
    cat /usr/lib/firmware/amd-ucode/microcode_amd*.bin > $DSTDIR/AuthenticAMD.bin
  fi

  if [ -d /usr/lib/firmware/intel-ucode ]; then
    cat /usr/lib/firmware/intel-ucode/* > $DSTDIR/GenuineIntel.bin
  fi

  ( cd $WDIR; find . | cpio -o -H newc --quiet ) > microcode.img
  cat microcode.img $INITRAMFS_FILE > tmpfile
  mv tmpfile $INITRAMFS_FILE
  rm microcode.img
fi

# Remove the temporary directories and files
rm -rf $WDIR $unsorted
printf "done.\n"

EOF

chmod 0755 /usr/sbin/mkinitramfs
mkdir -p /usr/share/mkinitramfs &&
cat > /usr/share/mkinitramfs/init.in << "EOF"
#!/bin/sh

PATH=/usr/bin:/usr/sbin
export PATH

problem()
{
   printf "Encountered a problem!\n\nDropping you to a shell.\n\n"
   sh
}

no_device()
{
   printf "The device %s, which is supposed to contain the\n" $1
   printf "root file system, does not exist.\n"
   printf "Please fix this problem and exit this shell.\n\n"
}

no_mount()
{
   printf "Could not mount device %s\n" $1
   printf "Sleeping forever. Please reboot and fix the kernel command line.\n\n"
   printf "Maybe the device is formatted with an unsupported file system?\n\n"
   printf "Or maybe filesystem type autodetection went wrong, in which case\n"
   printf "you should add the rootfstype=... parameter to the kernel command line.\n\n"
   printf "Available partitions:\n"
}

do_mount_root()
{
   mkdir /.root
   [ -n "$rootflags" ] && rootflags="$rootflags,"
   rootflags="$rootflags$ro"

   case "$root" in
      /dev/*    ) device=$root ;;
      UUID=*    ) eval $root; device="/dev/disk/by-uuid/$UUID" ;;
      PARTUUID=*) eval $root; device="/dev/disk/by-partuuid/$PARTUUID" ;;
      LABEL=*   ) eval $root; device="/dev/disk/by-label/$LABEL" ;;
      ""        ) echo "No root device specified." ; problem ;;
   esac

   while [ ! -b "$device" ] ; do
       no_device $device
       problem
   done

   if ! mount -n -t "$rootfstype" -o "$rootflags" "$device" /.root ; then
       no_mount $device
       cat /proc/partitions
       while true ; do sleep 10000 ; done
   else
       echo "Successfully mounted device $root"
   fi
}

do_try_resume()
{
   case "$resume" in
      UUID=* ) eval $resume; resume="/dev/disk/by-uuid/$UUID"  ;;
      LABEL=*) eval $resume; resume="/dev/disk/by-label/$LABEL" ;;
   esac

   if $noresume || ! [ -b "$resume" ]; then return; fi

   ls -lH "$resume" | ( read x x x x maj min x
       echo -n ${maj%,}:$min > /sys/power/resume )
}

init=/sbin/init
root=
rootdelay=
rootfstype=auto
ro="ro"
rootflags=
device=
resume=
noresume=false

mount -n -t devtmpfs devtmpfs /dev
mount -n -t proc     proc     /proc
mount -n -t sysfs    sysfs    /sys
mount -n -t tmpfs    tmpfs    /run

read -r cmdline < /proc/cmdline

for param in $cmdline ; do
  case $param in
    init=*      ) init=${param#init=}             ;;
    root=*      ) root=${param#root=}             ;;
    rootdelay=* ) rootdelay=${param#rootdelay=}   ;;
    rootfstype=*) rootfstype=${param#rootfstype=} ;;
    rootflags=* ) rootflags=${param#rootflags=}   ;;
    resume=*    ) resume=${param#resume=}         ;;
    noresume    ) noresume=true                   ;;
    ro          ) ro="ro"                         ;;
    rw          ) ro="rw"                         ;;
  esac
done

# udevd location depends on version
if [ -x /sbin/udevd ]; then
  UDEVD=/sbin/udevd
elif [ -x /lib/udev/udevd ]; then
  UDEVD=/lib/udev/udevd
elif [ -x /lib/systemd/systemd-udevd ]; then
  UDEVD=/lib/systemd/systemd-udevd
else
  echo "Cannot find udevd nor systemd-udevd"
  problem
fi

${UDEVD} --daemon --resolve-names=never
udevadm trigger
udevadm settle

if [ -f /etc/mdadm.conf ] ; then mdadm -As                       ; fi
if [ -x /sbin/vgchange  ] ; then /sbin/vgchange -a y > /dev/null ; fi
if [ -n "$rootdelay"    ] ; then sleep "$rootdelay"              ; fi

do_try_resume # This function will not return if resuming from disk
do_mount_root

killall -w ${UDEVD##*/}

exec switch_root /.root "$init" "$@"

EOF

Using an initramfs

Required Runtime Dependency

cpio-2.13

Other Runtime Dependencies

LVM2-2.03.15 and/or mdadm-4.2 must be installed before generating the initramfs, if the system partition uses them.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/initramfs

To build an initramfs, run the following as the root user:

mkinitramfs [KERNEL VERSION]

The optional argument is the directory where the appropriate kernel modules are located. This must be a subdirectory of /lib/modules. If no modules are specified, then the initramfs is named initrd.img-no-kmods. If a kernel version is specified, the initrd is named initrd.img-$KERNEL_VERSION and is only appropriate for the specific kernel specified. The output file will be placed in the current directory.

If early loading of microcode is needed (see the section called “Microcode updates for CPUs”), you can install the appropriate blob or container in /lib/firmware. It will be automatically added to the initrd when running mkinitramfs.

After generating the initrd, copy it to the /boot directory.

Now edit /boot/grub/grub.cfg and add a new menuentry. Below are several examples.

# Generic initramfs and root fs identified by UUID
menuentry "LFS Dev (LFS-7.0-Feb14) initrd, Linux 3.0.4"
{
  linux  /vmlinuz-3.0.4-lfs-20120214 root=UUID=54b934a9-302d-415e-ac11-4988408eb0a8 ro
  initrd /initrd.img-no-kmods
}
# Generic initramfs and root fs on LVM partition
menuentry "LFS Dev (LFS-7.0-Feb18) initrd lvm, Linux 3.0.4"
{
  linux  /vmlinuz-3.0.4-lfs-20120218 root=/dev/mapper/myroot ro
  initrd /initrd.img-no-kmods
}
# Specific initramfs and root fs identified by LABEL
menuentry "LFS Dev (LFS-7.1-Feb20) initrd label, Linux 3.2.6"
{
  linux  /vmlinuz-3.2.6-lfs71-120220 root=LABEL=lfs71 ro
  initrd /initrd.img-3.2.6-lfs71-120220
}

Finally, reboot the system and select the desired system.

Last updated on

btrfs-progs-5.16.2

Introduction to btrfs-progs

The btrfs-progs package contains administration and debugging tools for the B-tree file system (btrfs).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Btrfs-progs Dependencies

Required

LZO-2.10

Recommended
Optional

LVM2-2.03.15 (dmsetup is used in tests) and reiserfsprogs-3.6.27 (for tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/btrfs-progs

Kernel Configuration

Enable the following option in the kernel configuration and recompile the kernel:

File systems --->
  <*/M> Btrfs filesystem support [CONFIG_BTRFS_FS]

In addition to the above and to the options required for LVM2-2.03.15 and reiserfsprogs-3.6.27, the following options must be enabled for running tests:

File systems  --->
  [*]   Btrfs POSIX Access Control Lists      [CONFIG_BTRFS_FS_POSIX_ACL]
  [*]   ReiserFS extended attributes          [CONFIG_REISERFS_FS_XATTR]
  [*]     ReiserFS POSIX Access Control Lists [CONFIG_REISERFS_FS_POSIX_ACL]

Installation of btrfs-progs

Install btrfs-progs by running the following commands:

./configure --prefix=/usr &&
make

Note

Some tests require grep built with perl regular expressions. To obtain this, rebuild grep with the LFS Chapter 8 instructions after installing PCRE-8.45.

Before running tests, build a support program:

make fssum

To test the results, issue (as the root user):

pushd tests
   ./fsck-tests.sh
   ./mkfs-tests.sh
   ./cli-tests.sh
   ./convert-tests.sh
   ./misc-tests.sh
   #./fuzz-tests.sh
popd

The fuzz-tests are currently broken.

Note

If the above mentioned kernel options are not enabled, some tests fail, and prevent all the remaining tests to run, because the test disk image is not cleanly unmounted.

Install the package as the root user:

make install

Command Explanations

--disable-documentation: This option is needed if the recommended dependencies are not installed.

Contents

Installed Programs: btrfs, btrfs-convert, btrfs-find-root, btrfs-image, btrfs-map-logical, btrfs-select-super, btrfsck (link to btrfs), btrfstune, fsck.btrfs, and mkfs.btrfs
Installed Libraries: libbtrfs.so and libbtrfsutil.so
Installed Directories: /usr/include/btrfs

Short Descriptions

btrfs

is the main interface into btrfs filesystem operations

btrfs-convert

converts from an ext2/3/4 or reiserfs filesystem to btrfs

btrfs-find-root

is a filter to find btrfs root

btrfs-map-logical

maps btrfs logical extent to physical extent

btrfs-select-super

overwrites the primary superblock with a backup copy

btrfstune

tunes various filesystem parameters

fsck.btrfs

does nothing, but is present for consistency with fstab

mkfs.btrfs

creates a btrfs file system

Last updated on

dosfstools-4.2

Introduction to dosfstools

The dosfstools package contains various utilities for use with the FAT family of file systems.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/dosfstools

Kernel Configuration

Enable the following option in the kernel configuration and recompile the kernel:

File systems --->
  <DOS/FAT/EXFAT/NT Filesystems --->
    <*/M> MSDOS fs support             [CONFIG_MSDOS_FS]
    <*/M> VFAT (Windows-95) fs support [CONFIG_VFAT_FS]

Installation of dosfstools

Install dosfstools by running the following commands:

./configure --prefix=/usr            \
            --enable-compat-symlinks \
            --mandir=/usr/share/man  \
            --docdir=/usr/share/doc/dosfstools-4.2 &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--enable-compat-symlinks: This switch creates the dosfsck, dosfslabel, fsck.msdos, fsck.vfat, mkdosfs, mkfs.msdos, and mkfs.vfat symlinks required by some programs.

Contents

Installed Programs: fatlabel, fsck.fat, and mkfs.fat

Short Descriptions

fatlabel

sets or gets a MS-DOS filesystem label from a given device

fsck.fat

checks and repairs MS-DOS filesystems

mkfs.fat

creates an MS-DOS filesystem under Linux

Last updated on

Fuse-3.10.5

Introduction to Fuse

FUSE (Filesystem in Userspace) is a simple interface for userspace programs to export a virtual filesystem to the Linux kernel. Fuse also aims to provide a secure method for non privileged users to create and mount their own filesystem implementations.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Fuse Dependencies

Optional

Doxygen-1.9.3 (to rebuild the API documentation) and pytest (required for tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/fuse

Kernel Configuration

Enable the following options in the kernel configuration and recompile the kernel if necessary:

File systems  --->
  <*/M> FUSE (Filesystem in Userspace) support [CONFIG_FUSE_FS]

Character devices in user space should be enabled too for running the tests:

File systems  --->
  <*/M> FUSE (Filesystem in Userspace) support  [CONFIG_FUSE_FS]
  <*/M>   Character device in Userspace support [CONFIG_CUSE]

Installation of Fuse

Install Fuse by running the following commands:

sed -i '/^udev/,$ s/^/#/' util/meson.build &&

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

The API documentation is included in the package, but if you have Doxygen-1.9.3 installed and wish to rebuild it, issue:

pushd .. &&
  doxygen doc/Doxyfile &&
popd

To test the results, run (as the root user):

python3 -m pytest test/

The pytest Python module is required for the tests.

Now, as the root user:

ninja install                  &&
chmod u+s /usr/bin/fusermount3 &&

cd ..                          &&
install -v -m755 -d /usr/share/doc/fuse-3.10.5 &&
install -v -m644    doc/{README.NFS,kernel.txt} \
                    /usr/share/doc/fuse-3.10.5 &&
cp -Rv doc/html     /usr/share/doc/fuse-3.10.5

Command Explanations

sed ... util/meson.build: This command disables the installation of a boot script and udev rule that are not needed.

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Configuring fuse

Config Files

Some options regarding mount policy can be set in the file /etc/fuse.conf. To install the file run the following command as the root user:

cat > /etc/fuse.conf << "EOF"
# Set the maximum number of FUSE mounts allowed to non-root users.
# The default is 1000.
#
#mount_max = 1000

# Allow non-root users to specify the 'allow_other' or 'allow_root'
# mount options.
#
#user_allow_other
EOF

Additional information about the meaning of the configuration options are found in the man page.

Contents

Installed Programs: fusermount3 and mount.fuse3
Installed Libraries: libfuse3.so
Installed Directory: /usr/include/fuse3 and /usr/share/doc/fuse-3.10.5

Short Descriptions

fusermount3

is a suid root program to mount and unmount Fuse filesystems

mount.fuse3

is the command mount calls to mount a Fuse filesystem

libfuse3.so

contains the FUSE API functions

Last updated on

jfsutils-1.1.15

Introduction to jfsutils

The jfsutils package contains administration and debugging tools for the jfs file system.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/jfs

Kernel Configuration

Enable the following option in the kernel configuration and recompile the kernel:

File systems  --->
  <*/M> JFS filesystem support [CONFIG_JFS_FS]

Installation of jfsutils

First, fix some issues exposed by GCC 10 and later:

patch -Np1 -i ../jfsutils-1.1.15-gcc10_fix-1.patch

Install jfsutils by running the following commands:

sed -i "/unistd.h/a#include <sys/types.h>"    fscklog/extract.c &&
sed -i "/ioctl.h/a#include <sys/sysmacros.h>" libfs/devices.c   &&

./configure &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

sed ...: Fixes building with glibc 2.28.

Contents

Installed Programs: fsck.jfs, jfs_debugfs, jfs_fsck, jfs_fscklog, jfs_logdump, jfs_mkfs, jfs_tune, mkfs.jfs
Installed Libraries: None
Installed Directories: None

Short Descriptions

fsck.jfs

is used to replay the JFS transaction log, check a JFS formatted device for errors, and fix any errors found

jfs_fsck

is a hard link to fsck.jfs

mkfs.jfs

constructs an JFS file system

jfs_mkfs

is a hard link to mkfs.jfs

jfs_debugfs

is a program which can be used to perform various low-level actions on a JFS formatted device

jfs_fscklog

extracts a JFS fsck service log into a file and/or formats and displays the extracted file

jfs_logdump

dumps the contents of the journal log from the specified JFS formatted device into output file ./jfslog.dmp

jfs_tune

adjusts tunable file system parameters on JFS file systems

Last updated on

LVM2-2.03.15

Introduction to LVM2

The LVM2 package is a set of tools that manage logical partitions. It allows spanning of file systems across multiple physical disks and disk partitions and provides for dynamic growing or shrinking of logical partitions, mirroring and low storage footprint snapshots.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

LVM2 Dependencies

Required

libaio-0.3.112

Optional

mdadm-4.2, reiserfsprogs-3.6.27, Valgrind-3.18.1, Which-2.21, xfsprogs-5.14.2 (all five may be used, but are not required, for tests), thin-provisioning-tools, and vdo

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lvm2

Kernel Configuration

Enable the following options in the kernel configuration and recompile the kernel:

Note

There are several other Device Mapper options in the kernel beyond those listed below. In order to get reasonable results if running the regression tests, all must be enabled either internally or as a module. The tests will all time out if Magic SysRq key is not enabled.

Device Drivers --->
  [*] Multiple devices driver support (RAID and LVM) ---> [CONFIG_MD]
    <*/M>   Device mapper support                         [CONFIG_BLK_DEV_DM]
    <*/M>   Crypt target support                          [CONFIG_DM_CRYPT]
    <*/M>   Snapshot target                               [CONFIG_DM_SNAPSHOT]
    <*/M>   Thin provisioning target                      [CONFIG_DM_THIN_PROVISIONING]
    <*/M>   Cache target (EXPERIMENTAL)                   [CONFIG_DM_CACHE]
    <*/M>   Mirror target                                 [CONFIG_DM_MIRROR]
    <*/M>   Zero target                                   [CONFIG_DM_ZERO]
    <*/M>   I/O delaying target                           [CONFIG_DM_DELAY]
  [*] Block devices --->
    <*/M>   RAM block device support                      [CONFIG_BLK_DEV_RAM]
Kernel hacking --->
  Generic Kernel Debugging Instruments --->
    [*] Magic SysRq key                                   [CONFIG_MAGIC_SYSRQ]

Installation of LVM2

Install LVM2 by running the following commands:

PATH+=:/usr/sbin                \
./configure --prefix=/usr       \
            --enable-cmdlib     \
            --enable-pkgconfig  \
            --enable-udev_sync  &&
make

The tests use udev for logical volume synchronization, so the LVM udev rules and some utilities need to be installed before running the tests. If you are installing LVM2 for the first time, and do not want to install the full package before running the tests, the minimal set of utilities can be installed by running the following instructions as the root user:

make -C tools install_tools_dynamic &&
make -C udev  install                 &&
make -C libdm install

To test the results, issue, as the root user:

LC_ALL=en_US.UTF-8 make S=lvconvert-repair-replace check_local

The S=... option allows to skip tests. The lvconvert-repair-replace test has been reported to hang. Other targets are available and can be listed with make -C test help. The test timings are very dependent on the speed of the disk(s), and on the number of enabled kernel options.

The tests do not implement the expected fail possibility, and a small number of test failures is expected by upstream. More failures may happen because some kernel options are missing. For example, the lack of the dm-delay device mapper target explains some failures. Some tests may fail if there is insufficient free space available in the partition with the /tmp directory. At least one test fails if 16 TB is not available. Some tests are flagged warned if thin-provisioning-tools are not installed. A workaround is to add the following flags to configure:

     --with-thin-check=    \
     --with-thin-dump=     \
     --with-thin-repair=   \
     --with-thin-restore=  \
     --with-cache-check=   \
     --with-cache-dump=    \
     --with-cache-repair=  \
     --with-cache-restore= \

Some tests may hang. They can be removed if necessary, for example: rm test/shell/lvconvert-raid-reshape.sh. The tests generate a lot of kernel messages, which may clutter your terminal. You can disable them by issuing dmesg -D before running the tests (do not forget to issue dmesg -E when tests are done).

Note

The checks create device nodes in the /tmp directory. The tests will fail if /tmp is mounted with the nodev option.

Now, as the root user:

make install
rm /usr/lib/udev/rules.d/69-dm-lvm.rules

Command Explanations

PATH+=:/usr/sbin: The path must contain /usr/sbin for proper system tool detection by the configure script. This instruction ensures that PATH is properly set even if you build as an unprivileged user.

--enable-cmdlib: This switch enables building of the shared command library. It is required when building the event daemon.

--enable-pkgconfig: This switch enables installation of pkg-config support files.

--enable-udev_sync: This switch enables synchronisation with Udev processing.

--enable-dmeventd: This switch enables building of the Device Mapper event daemon.

rm .../69-dm-lvm.rules: Under certain circumstances, this udev rule calls systemd-run, which is not available on sysv. It performs actions that are done by another boot script anyway, so it is not needed.

Contents

Installed Programs: blkdeactivate, dmeventd (optional), dmsetup, fsadm, lvm, lvmdump, and lvm_import_vdo. There are also numerous symbolic links to lvm that implement specific functionalities
Installed Libraries: libdevmapper.so and liblvm2cmd.so; optional: libdevmapper-event.so, libdevmapper-event-lvm2.so, libdevmapper-event-lvm2mirror.so, libdevmapper-event-lvm2raid.so, libdevmapper-event-lvm2snapshot.so, libdevmapper-event-lvm2thin.so, and libdevmapper-event-lvm2vdo.so
Installed Directories: /etc/lvm and /usr/lib/device-mapper (optional)

Short Descriptions

blkdeactivate

is a utility to deactivate block devices

dmeventd

(optional) is the Device Mapper event daemon

dmsetup

is a low level logical volume management tool

fsadm

is a utility used to resize or check filesystem on a device

lvm

provides the command-line tools for LVM2. Commands are implemented via sympolic links to this program to manage physical devices (pv*), volume groups (vg*) and logical volumes (lv*)

lvmdump

is a tool used to dump various information concerning LVM2

vgimportclone

is used to import a duplicated VG (e.g. hardware snapshot)

libdevmapper.so

contains the Device Mapper API functions

Last updated on

About Logical Volume Management (LVM)

LVM manages disk drives. It allows multiple drives and partitions to be combined into larger volume groups, assists in making backups through a snapshot, and allows for dynamic volume resizing. It can also provide mirroring similar to a RAID 1 array.

A complete discussion of LVM is beyond the scope of this introduction, but basic concepts are presented below.

To run any of the commands presented here, the LVM2-2.03.15 package must be installed. All commands must be run as the root user.

Management of disks with lvm is accomplished using the following concepts:

physical volumes

These are physical disks or partitions such as /dev/sda3 or /dev/sdb.

volume groups

These are named groups of physical volumes that can be manipulated by the administrator. The number of physical volumes that make up a volume group is arbitrary. Physical volumes can be dynamically added or removed from a volume group.

logical volumes

Volume groups may be subdivided into logical volumes. Each logical volume can then be individually formatted as if it were a regular Linux partition. Logical volumes may be dynamically resized by the administrator according to need.

To give a concrete example, suppose that you have two 2 TB disks. Also suppose a really large amount of space is required for a very large database, mounted on /srv/mysql. This is what the initial set of partitions would look like:

Partition  Use    Size      Partition Type
/dev/sda1  /boot  100MB     83 (Linux)
/dev/sda2  /       10GB     83 (Linux)
/dev/sda3  swap     2GB     82 (Swap)
/dev/sda4  LVM    remainder 8e (LVM)
/dev/sdb1  swap     2GB     82 (Swap)
/dev/sdb2  LVM    remainder 8e (LVM)

First initialize the physical volumes:

pvcreate /dev/sda4 /dev/sdb2

Note

A full disk can be used as part of a physical volume, but beware that the pvcreate command will destroy any partition information on that disk.

Next create a volume group named lfs-lvm:

vgcreate lfs-lvm /dev/sda4  /dev/sdb2

The status of the volume group can be checked by running the command vgscan. Now create the logical volumes. Since there is about 3900 GB available, leave about 900 GB free for expansion. Note that the logical volume named mysql is larger than any physical disk.

lvcreate --name mysql --size 2500G lfs-lvm
lvcreate --name home  --size  500G lfs-lvm

Finally the logical volumes can be formatted and mounted. In this example, the jfs file system (jfsutils-1.1.15) is used for demonstration purposes.

mkfs -t ext4 /dev/lfs-lvm/home
mkfs -t jfs  /dev/lfs-lvm/mysql
mount /dev/lfs-lvm/home /home
mkdir -p /srv/mysql
mount /dev/lfs-lvm/mysql /srv/mysql

It may be needed to activate those logical volumes, for them to appear in /dev. They can all be activated at the same time by issuing, as the root user:

vgchange -a y

The LFS boot scripts automatically make these logical volumes available to the system in the udev script. Edit the /etc/fstab file as required to automatically mount them.

A LVM logical volume can host a root filesystem, but requires the use of an initramfs (initial RAM file system). The initramfs proposed in the section called “About initramfs” allows to pass the lvm volume in the root= switch of the kernel command line.

For more information about LVM, see the LVM HOWTO and the lvm man pages. A good in-depth guide is available from RedHat®, although it makes sometimes reference to proprietary tools.

Last updated on

About RAID

The storage technology known as RAID (Redundant Array of Independent Disks) combines multiple physical disks into a logical unit. The drives can generally be combined to provide data redundancy or to extend the size of logical units beyond the capability of the physical disks or both. The technology also allows for providing hardware maintenance without powering down the system.

The types of RAID organization are described in the RAID Wiki.

Note that while RAID provides protection against disk failures, it is not a substitute for backups. A file deleted is still deleted on all the disks of a RAID array. Modern backups are generally done via rsync-3.2.3.

There are three major types of RAID implementation: Hardware RAID, BIOS-based RAID, and Software RAID.

Hardware RAID

Hardware based RAID provides capability through proprietary hardware and data layouts. The control and configuration is generally done via firmware in conjunction with executable programs made available by the device manufacturer. The capabilities are generally supplied via a PCI card, although there are some instances of RAID components integrated in to the motherboard. Hardware RAID may also be available in a stand-alone enclosure.

One advantage of hardware-based RAID is that the drives are offered to the operating system as a logical drive and no operating system dependent configuration is needed.

Disadvantages include difficulties in transferring drives from one system to another, updating firmware, or replacing failed RAID hardware.

BIOS-based RAID

Some computers offter a hardware-like RAID implementation in the system BIOS. Sometime this is referred to as 'fake' RAID as the capabilities are generally incorporated into firmware without any hardware acceleration.

The advantages and disadvantages of BIOS-based RAID are generally the same as hardware RAID with the additional disadvantage that there is no hardware acceleration.

In some cases, BIOS-based RAID firmware is enabled by default (e.g. some DELL systems). If software RAID is desired, this option must be explicitly disabled in the BIOS.

Software RAID

Software based RAID is the most flexible form of RAID. It is easy to install and update and provides full capability on all or part of any drives available to the system. In BLFS, the RAID software is found in mdadm-4.2.

Configuring a RAID device is straightforward using mdadm. Generally devices are created in the /dev directory as /dev/mdx where x is an integer.

The first step in creating a RAID array is to use partitioning software such as fdisk or parted-3.4 to define the partitions needed for the array. Usually, there will be one partition on each drive participating in the RAID array, but that is not strictly necessary. For this example, there will be four disk drives: /dev/sda, /dev/sdb, /dev/sdc, and /dev/sdd. They will be partitioned as follows:

Partition Size     Type                Use
sda1:     100 MB   fd Linux raid auto  /boot    (RAID 1) /dev/md0
sda2:      10 GB   fd Linux raid auto  /        (RAID 1) /dev/md1
sda3:       2 GB   83 Linux swap       swap
sda4      300 GB   fd Linux raid auto  /home    (RAID 5) /dev/md2

sdb1:     100 MB   fd Linux raid auto  /boot    (RAID 1) /dev/md0
sdb2:      10 GB   fd Linux raid auto  /        (RAID 1) /dev/md1
sdb3:       2 GB   83 Linux swap       swap
sdb4      300 GB   fd Linux raid auto  /home    (RAID 5) /dev/md2

sdc1:      12 GB   fd Linux raid auto  /usr/src (RAID 0) /dev/md3
sdc2:     300 GB   fd Linux raid auto  /home    (RAID 5) /dev/md2

sdd1:      12 GB   fd Linux raid auto  /usr/src (RAID 0) /dev/md3
sdd2:     300 GB   fd Linux raid auto  /home    (RAID 5) /dev/md2 

In this arrangement, a separate boot partition is created as the first small RAID array and a root filesystem as the secong RAID array, both mirrored. The third partition is a large (about 1TB) array for the /home directory. This provides an ability to stripe data across multiple devices, improving speed for both reading and writing large files. Finally, a fourth array is created that concatenates two partitions into a larger device.

Note

All mdadm commands must be run as the root user.

To create these RAID arrays the commands are:

/sbin/mdadm -Cv /dev/md0 --level=1 --raid-devices=2 /dev/sda1 /dev/sdb1
/sbin/mdadm -Cv /dev/md1 --level=1 --raid-devices=2 /dev/sda2 /dev/sdb2
/sbin/mdadm -Cv /dev/md3 --level=0 --raid-devices=2 /dev/sdc1 /dev/sdd1
/sbin/mdadm -Cv /dev/md2 --level=5 --raid-devices=4 \
        /dev/sda4 /dev/sdb4 /dev/sdc2 /dev/sdd2 

The devices created can be examined by device. For example, to see the details of /dev/md1, use /sbin/mdadm --detail /dev/md1:

        Version : 1.2
  Creation Time : Tue Feb  7 17:08:45 2012
     Raid Level : raid1
     Array Size : 10484664 (10.00 GiB 10.74 GB)
  Used Dev Size : 10484664 (10.00 GiB 10.74 GB)
   Raid Devices : 2
  Total Devices : 2
    Persistence : Superblock is persistent

    Update Time : Tue Feb  7 23:11:53 2012
          State : clean
 Active Devices : 2
Working Devices : 2
 Failed Devices : 0
  Spare Devices : 0

           Name : core2-blfs:0  (local to host core2-blfs)
           UUID : fcb944a4:9054aeb2:d987d8fe:a89121f8
         Events : 17

    Number   Major   Minor   RaidDevice State
       0       8        1        0      active sync   /dev/sda1
       1       8       17        1      active sync   /dev/sdb1

From this point, the partitions can be formated with the filesystem of choice (e.g. ext3, ext4, xfsprogs-5.14.2, reiserfsprogs-3.6.27, etc). The formatted partitions can then be mounted. The /etc/fstab file can use the devices created for mounting at boot time and the linux command line in /boot/grub/grub.cfg can specify root=/dev/md1.

Note

The swap devices should be specified in the /etc/fstab file as normal. The kernel normally stripes swap data across multiple swap files and should not be made part of a RAID array.

For further options and management details of RAID devices, refer to man mdadm.

Additional details for monitoring RAID arrays and dealing with problems can be found at the Linux RAID Wiki.

Last updated on

mdadm-4.2

Introduction to mdadm

The mdadm package contains administration tools for software RAID.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

mdadm Dependencies

Optional

A MTA

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/mdadm

Caution

Kernel versions in series 4.1 through 4.4.1 have a broken RAID implementation. Use a kernel with version at or above 4.4.2.

Kernel Configuration

Enable the following options in the kernel configuration and recompile the kernel, if necessary. Only the RAID types desired are required.

Device Drivers --->
  [*] Multiple devices driver support (RAID and LVM) ---> [CONFIG_MD]
    <*> RAID support                                      [CONFIG_BLK_DEV_MD]
    [*]   Autodetect RAID arrays during kernel boot       [CONFIG_MD_AUTODETECT]
    <*/M>  Linear (append) mode                           [CONFIG_MD_LINEAR]
    <*/M>  RAID-0 (striping) mode                         [CONFIG_MD_RAID0]
    <*/M>  RAID-1 (mirroring) mode                        [CONFIG_MD_RAID1]
    <*/M>  RAID-10 (mirrored striping) mode               [CONFIG_MD_RAID10]
    <*/M>  RAID-4/RAID-5/RAID-6 mode                      [CONFIG_MD_RAID456]

Installation of mdadm

Build mdadm by running the following command:

make

This package does not come with a working test suuite.

Now, as the root user:

make BINDIR=/usr/sbin install

Command Explanations

make everything: This optional target creates extra programs, particularly a statically-linked version of mdadm. This needs to be manually installed.

--keep-going: Run the tests to the end, even if one or more tests fail.

--logdir=test-logs: Defines the directory where test logs are saved.

--save-logs: Instructs the test suite to save the logs.

--tests=<test1,test2,...>: Optional comma separated list of tests to be executed (all tests, if this option is not passed).

Contents

Installed Programs: mdadm and mdmon
Installed Libraries: None
Installed Directory: None

Short Descriptions

mdadm

manages MD devices aka Linux Software RAID

mdmon

monitors MD external metadata arrays

Last updated on

ntfs-3g-2021.8.22

Introduction to Ntfs-3g

Note

A new read-write driver for NTFS, called NTFS3, has been added into the Linux kernel since the 5.15 release. The performance of NTFS3 is much better than ntfs-3g. To enable NTFS3, enable the following options in the kernel configuration and recompile the kernel if necessary:

File systems  --->
  <*/M> NTFS Read-Write file system support [CONFIG_NTFS3_FS]

To ensure the mount command uses NTFS3 for ntfs partitions, create a wrapper script:

cat >> /usr/sbin/mount.ntfs <<"EOF" &&
#!/bin/sh
exec mount -t ntfs3 "$@"
EOF
chmod -v 755 /usr/sbin/mount.ntfs

With the kernel support available, ntfs-3g is only needed if you need the utilities from it (for example, to create NTFS filesystems).

The Ntfs-3g package contains a stable, read-write open source driver for NTFS partitions. NTFS partitions are used by most Microsoft operating systems. Ntfs-3g allows you to mount NTFS partitions in read-write mode from your Linux system. It uses the FUSE kernel module to be able to implement NTFS support in user space. The package also contains various utilities useful for manipulating NTFS partitions.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Ntfs-3g Dependencies

Optional

fuse 2.x (this disables user mounts)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/ntfs-3g

Kernel Configuration

Enable the following options in the kernel configuration and recompile the kernel if necessary:

File systems  --->
  <*/M> FUSE (Filesystem in Userspace) support [CONFIG_FUSE_FS]

Installation of Ntfs-3g

Install Ntfs-3g by running the following commands:

./configure --prefix=/usr        \
            --disable-static     \
            --with-fuse=internal \
            --docdir=/usr/share/doc/ntfs-3g-2021.8.22 &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&

It's recommended to use the in-kernel NTFS3 driver for mounting NTFS filesystems, instead of ntfs-3g (see the note at the start of this page). However, if you want to use ntfs-3g to mount the NTFS filesystems anyway, create a symlink for mount command:

ln -sv ../bin/ntfs-3g /usr/sbin/mount.ntfs &&
ln -sv ntfs-3g.8 /usr/share/man/man8/mount.ntfs.8

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--with-fuse=internal: This switch dynamically forces ntfs-3g to use an internal copy of the fuse-2.x library. This is required if you wish to allow users to mount NTFS partitions.

--disable-ntfsprogs: Disables installation of various utilities used to manipulate NTFS partitions.

chmod -v 4755 /usr/bin/ntfs-3g: Making mount.ntfs setuid root allows non root users to mount NTFS partitions.

Using Ntfs-3g

To mount a Windows partition at boot time, put a line like this in /etc/fstab:

              /dev/sda1 /mnt/windows auto defaults 0 0

To allow users to mount a usb stick with an NTFS filesystem on it, put a line similar to this (change sdc1 to whatever a usb stick would be on your system) in /etc/fstab:

              /dev/sdc1 /mnt/usb auto user,noauto,umask=0,utf8 0 0

In order for a user to be able to mount the usb stick, they will need to be able to write to /mnt/usb, so as the root user:

chmod -v 777 /mnt/usb

Contents

Installed Programs: lowntfs-3g, mkfs.ntfs, mkntfs, mount.lowntfs-3g, mount.ntfs, mount.ntfs-3g, ntfs-3g, ntfs-3g.probe, ntfscat, ntfsclone, ntfscluster, ntfscmp, ntfscp, ntfsfix, ntfsinfo, ntfslabel, ntfsls, ntfsresize and ntfsundelete
Installed Library: libntfs-3g.so
Installed Directories: /usr/include/ntfs-3g and /usr/share/doc/ntfs-3g

Short Descriptions

lowntfs-3g

is similar to ntfs-3g but uses the Fuse low-level interface

mkfs.ntfs

is a symlink to mkntfs

mkntfs

creates an NTFS file system

mount.lowntfs-3g

is a symlink to lowntfs-3g

mount.ntfs

mounts an NTFS filesystem

mount.ntfs-3g

is a symbolic link to ntfs-3g

ntfs-3g

is an NTFS driver, which can create, remove, rename, move files, directories, hard links, and streams. It can also read and write files, including streams, sparse files and transparently compressed files. It can also handle special files like symbolic links, devices, and FIFOs; moreover it provides standard management of file ownership and permissions, including POSIX ACLs

ntfs-3g.probe

tests if an NTFS volume is mountable read only or read-write, and exits with a status value accordingly. The volume can be a block device or image file

ntfscluster

identifies files in a specified region of an NTFS volume

ntfscp

copies a file to an NTFS volume

ntfsfix

fixes common errors and forces Windows to check an NTFS partition

ntfsls

lists directory contents on an NTFS filesystem

ntfscat

prints NTFS files and streams on the standard output

ntfsclone

clones an NTFS filesystem

ntfscmp

compares two NTFS filesystems and shows the differences

ntfsinfo

dumps a file's attributes

ntfslabel

displays or changes the label on an ntfs file system

ntfsresize

resizes an NTFS filesystem without data loss

ntfsundelete

recovers a deleted file from an NTFS volume

libntfs-3g.so

contains the Ntfs-3g API functions

Last updated on

gptfdisk-1.0.8

Introduction to gptfdisk

The gptfdisk package is a set of programs for creation and maintenance of GUID Partition Table (GPT) disk drives. A GPT partitioned disk is required for drives greater than 2 TB and is a modern replacement for legacy PC-BIOS partitioned disk drives that use a Master Boot Record (MBR). The main program, gdisk, has an inteface similar to the classic fdisk program.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

gptfdisk Dependencies

Required

popt-1.18

Optional

ICU-70.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gptdisk

Installation of gptfdisk

The gptfdisk package comes with a rudimentary Makefile. First we update it to provide a simple build and install interface and fix the location of a header file. Install gptfdisk by running the following commands:

patch -Np1 -i ../gptfdisk-1.0.8-convenience-1.patch &&
sed -i 's|ncursesw/||' gptcurses.cc &&
sed -i 's|sbin|usr/sbin|' Makefile &&

make

To test the results, issue: make test.

Now, as the root user:

make install

Command Explanations

patch -Np1 ...: This patch modifies the Makefile file so that it provides an install target.

Contents

Installed Programs: cgdisk, gdisk, fixparts, and sgdisk

Short Descriptions

cgdisk

is an ncurses-based tool for manipulating GPT partitions

gdisk

is an interactive text-mode tool for manipulating GPT partitions

fixparts

repairs mis-formatted MBR based disk partitions

sgdisk

is a partition manipulation program for GPT partitions similar to sfdisk

Last updated on

parted-3.4

Introduction to parted

The Parted package is a disk partitioning and partition resizing tool.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Parted Dependencies

Recommended
Optional

dosfstools-4.2, Pth-2.0.7, texlive-20210325 (or install-tl-unx), and Digest::CRC (for tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/parted

Installation of parted

Install Parted by running the following commands:

./configure --prefix=/usr --disable-static &&
make &&

make -C doc html                                       &&
makeinfo --html      -o doc/html       doc/parted.texi &&
makeinfo --plaintext -o doc/parted.txt doc/parted.texi

If you have texlive-20210325 installed and wish to create PDF and Postcript documentation issue the following commands:

texi2pdf             -o doc/parted.pdf doc/parted.texi &&
texi2dvi             -o doc/parted.dvi doc/parted.texi &&
dvips                -o doc/parted.ps  doc/parted.dvi

To test the results, issue, as the root user:

make check

Note

Many tests are skipped if not run as the root user.

Now, as the root user:

make install &&
install -v -m755 -d /usr/share/doc/parted-3.4/html &&
install -v -m644    doc/html/* \
                    /usr/share/doc/parted-3.4/html &&
install -v -m644    doc/{FAT,API,parted.{txt,html}} \
                    /usr/share/doc/parted-3.4

Install the optional PDF and Postscript documentation by issuing the following command as the root user:

install -v -m644 doc/FAT doc/API doc/parted.{pdf,ps,dvi} \
                    /usr/share/doc/parted-3.4

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--disable-device-mapper: This option disables device mapper support. Add this parameter if you have not installed LVM2.

Contents

Installed Programs: parted and partprobe
Installed Libraries: libparted.so and libparted-fs-resize.so
Installed Directories: /usr/include/parted and /usr/share/doc/parted-3.4

Short Descriptions

parted

is a partition manipulation program

partprobe

informs the OS of partition table changes

libparted.so

contains the Parted API functions

Last updated on

reiserfsprogs-3.6.27

Introduction to reiserfsprogs

The reiserfsprogs package contains various utilities for use with the Reiser file system.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/reiser

Kernel Configuration

Enable the following option in the kernel configuration and recompile the kernel:

File systems --->
  <*/M> Reiserfs support [CONFIG_REISERFS_FS]

Installation of reiserfsprogs

Install reiserfsprogs by running the following commands:

sed -i '/parse_time.h/i #define _GNU_SOURCE' lib/parse_time.c &&
autoreconf -fiv           &&

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

sed ...: Ensure a variable is defined for use with recent include files.

Contents

Installed Programs: debugreiserfs, mkreiserfs, reiserfsck, reiserfstune, and resize_reiserfs
Installed Library: libreiserfscore.so
Installed Directory: /usr/include/reiserfs

Short Descriptions

debugreiserfs

can sometimes help to solve problems with ReiserFS file systems. If it is called without options, it prints the super block of any ReiserFS file system found on the device

mkreiserfs

creates a ReiserFS file system

reiserfsck

is used to check or repair a ReiserFS file system

reiserfstune

is used for tuning the ReiserFS journal. WARNING: Don't use this utility without first reading the man page thoroughly

resize_reiserfs

is used to resize an unmounted ReiserFS file system

Last updated on

smartmontools-7.2

Introduction to smartmontools

The smartmontools package contains utility programs (smartctl, smartd) to control/monitor storage systems using the Self-Monitoring, Analysis and Reporting Technology System (S.M.A.R.T.) built into most modern ATA and SCSI disks.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

smartmontools Dependencies

Optional (runtime)

cURL-7.81.0 or Lynx-2.8.9rel.1 or Wget-1.21.2 (download tools), and GnuPG-2.2.34 (encrypted hard disks)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/smartmontools

Installation of smartmontools

Install smartmontools by running the following commands:

./configure --prefix=/usr           \
            --sysconfdir=/etc       \
            --with-initscriptdir=no \
            --with-libsystemd=no    \
            --docdir=/usr/share/doc/smartmontools-7.2 &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--with-initscriptdir=no: This switch suppresses the default initialization script. See below for the BLFS script.

--with-libsystemd=no: This switch disables support for the sd-notify notification system provided by systemd.

Configuring smartmontools

Config File

/etc/smartd.conf

Configuration Information

See the embedded comments in /etc/smartd.conf for detailed instructions on customizing the smartd darmon.

Boot Script

If you want the smartd daemon to start automatically when the system is booted, install the /etc/rc.d/init.d/smartd init script included in the blfs-bootscripts-20210826 package.

make install-smartd

Contents

Installed Programs: smartctl, smartd, and update-smart-drivedb
Installed Libraries: None
Installed Directories: /usr/share/smartmontools, /usr/share/doc/smartmontools-6.4, and /etc/smartd_warning.d

Short Descriptions

smartctl

is the control and monitor utility for SMART Disks

smartd

is the SMART disk monitoring daemon

update-smart-drivedb

is the update tool for the smartmontools drive database

Last updated on

sshfs-3.7.2

Introduction to Sshfs

The Sshfs package contains a filesystem client based on the SSH File Transfer Protocol. This is useful for mounting a remote computer that you have ssh access to as a local filesystem. This allows you to drag and drop files or run shell commands on the remote files as if they were on your local computer.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Sshfs Dependencies

Required

Fuse-3.10.5, GLib-2.70.4, and OpenSSH-8.8p1.

Optional

docutils-0.18.1 (required to build the man page)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/sshfs

Installation of Sshfs

Install Sshfs by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Using Sshfs

To mount an ssh server you need to be able to log into the server. For example, to mount your remote home folder to the local ~/examplepath (the directory must exist and you must have permissions to write to it):

sshfs example.com:/home/userid ~/examplepath

When you've finished work and want to unmount it again:

fusermount3 -u ~/example

You can also mount an sshfs filesystem at boot by adding an entry similar to the following in the /etc/fstab file:

userid@example.com:/path /media/path fuse.sshfs _netdev,IdentityFile=/home/userid/.ssh/id_rsa 0 0

See man 1 sshfs and man 8 mount.fuse3 for all available mount options.

Contents

Installed Program: sshfs
Installed Libraries: None
Installed Directories: None

Short Descriptions

sshfs

mounts an ssh server as a local file system

Last updated on

xfsprogs-5.14.2

Introduction to xfsprogs

The xfsprogs package contains administration and debugging tools for the XFS file system.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

xfsprogs Dependencies

Required

inih-53 and liburcu-0.13.1

Optional

ICU-70.1 (for unicode name scanning in xfs_scrub)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xfs

Kernel Configuration

Enable the following options in the kernel configuration and recompile the kernel:

File systems --->
  <*/M> XFS filesystem support [CONFIG_XFS_FS]

Installation of xfsprogs

Install xfsprogs by running the following commands:

make DEBUG=-DNDEBUG     \
     INSTALL_USER=root  \
     INSTALL_GROUP=root

This package does not come with a test suite.

Now, as the root user:

make PKG_DOC_DIR=/usr/share/doc/xfsprogs-5.14.2 install     &&
make PKG_DOC_DIR=/usr/share/doc/xfsprogs-5.14.2 install-dev &&

rm -rfv /usr/lib/libhandle.{a,la}

Command Explanations

make DEBUG=-DNDEBUG: Turns off debugging symbols.

INSTALL_USER=root INSTALL_GROUP=root: This sets the owner and group of the installed files.

OPTIMIZER="...": Adding this parameter to the end of the make command overrides the default optimization settings.

Contents

Installed Programs: fsck.xfs, mkfs.xfs, xfs_admin, xfs_bmap, xfs_copy, xfs_db, xfs_estimate, xfs_freeze, xfs_fsr, xfs_growfs, xfs_info, xfs_io, xfs_logprint, xfs_mdrestore, xfs_metadump, xfs_mkfile, xfs_ncheck, xfs_quota, xfs_repair, xfs_rtcp, xfs_scrub, xfs_scrub_all, and xfs_spaceman
Installed Libraries: libhandle.so
Installed Directories: /usr/include/xfs, /usr/lib/xfsprogs, and /usr/share/doc/xfsprogs-5.14.2

Short Descriptions

fsck.xfs

simply exits with a zero status, since XFS partitions are checked at mount time

mkfs.xfs

constructs an XFS file system

xfs_admin

changes the parameters of an XFS file system

xfs_bmap

prints block mapping for an XFS file

xfs_copy

copies the contents of an XFS file system to one or more targets in parallel

xfs_estimate

for each directory argument, estimates the space that directory would take if it were copied to an XFS filesystem (does not cross mount points)

xfs_db

is used to debug an XFS file system

xfs_freeze

suspends access to an XFS file system

xfs_fsr

applicable only to XFS filesystems, improves the organization of mounted filesystems, the reorganization algorithm operates on one file at a time, compacting or othewise improving the layout of the file extents (contiguous blocks of file data)

xfs_growfs

expands an XFS file system

xfs_info

is equivalent to invoking xfs_growfs, but specifying that no change to the file system is to be made

xfs_io

is a debugging tool like xfs_db, but is aimed at examining the regular file I/O path rather than the raw XFS volume itself

xfs_logprint

prints the log of an XFS file system

xfs_mdrestore

restores an XFS metadump image to a filesystem image

xfs_metadump

copies XFS filesystem metadata to a file

xfs_mkfile

creates an XFS file, padded with zeroes by default

xfs_ncheck

generates pathnames from inode numbers for an XFS file system

xfs_quota

is a utility for reporting and editing various aspects of filesystem quotas

xfs_repair

repairs corrupt or damaged XFS file systems

xfs_rtcp

copies a file to the real-time partition on an XFS file system

xfs_scrub

checks and repairs the contents of a mounted XFS file system

xfs_scrub_all

scrubs all mounted XFS file systems

xfs_spaceman

reports and controls free space usage in an XFS file system

libhandle.so

contains XFS-specific functions that provide a way to perform certain filesystem operations without using a file descriptor to access filesystem objects

Last updated on

Packages for UEFI Boot

Last updated on

efivar-38

Introduction to efivar

The efivar package provides tools and libraries to manipulate EFI variables.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

efivar Dependencies

Required

mandoc-1.14.6

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/efivar

Installation of efivar

First, fix an issue in Makefile causing the package to be rebuilt during installation:

sed '/prep :/a\\ttouch prep' -i src/Makefile

Build efivar with the following commands:

make

The test suite of this package is dangerous. Running it may trigger firmware bugs and make your system unusable without using some special hardware to reprogram the firmware.

Now, as the root user:

make install LIBDIR=/usr/lib

Command Explanations

LIBDIR=/usr/lib: This option overrides the default library directory of the package (/usr/lib64, which is not used by LFS.)

Contents

Installed Programs: efisecdb and efivar
Installed Libraries: libefiboot.so, libefisec.so, and libefivar.so
Installed Directories: /usr/include/efivar

Short Descriptions

efisecdb

is an utility for managing UEFI signature lists

efivar

is a tool to manipulate UEFI variables

libefiboot.so

is a library used by efibootmgr

libefisec.so

is a library for managing UEFI signature lists

libefivar.so

is a library for the manipulation of EFI variables

Last updated on

efibootmgr-17

Introduction to efibootmgr

The efibootmgr package provides tools and libraries to manipulate EFI variables.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

efibootmgr Dependencies

Required

efivar-38 and popt-1.18

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/efibootmgr

Installation of efibootmgr

At first, fix an outdated hotfix declaration causing compilation failure:

sed -e '/extern int efi_set_verbose/d' -i src/efibootmgr.c

Fix an issue building this package with efivar-38 or later:

sed 's/-Werror//' -i Make.defaults

Build efibootmgr with the following commands:

make EFIDIR=LFS EFI_LOADER=grubx64.efi

This package does not have a test suite.

Now, as the root user:

make install EFIDIR=LFS

Command Explanations

EFIDIR=LFS: This option specifies the distro's subdirectory name under /boot/efi/EFI. The building system of this package needs it to be set explicitly.

EFI_LOADER=grubx64.efi: This option specifies the name of the default EFI boot loader. It is set to match the EFI boot loader provided by GRUB .

Contents

Installed Programs: efibootdump and efibootmgr

Short Descriptions

efibootdump

is a tool to display individual UEFI boot options, from a file or an UEFI variable

efibootmgr

is a tool to manipulate the UEFI Boot Manager

Last updated on

GRUB-2.06 for EFI

Introduction to GRUB

The GRUB package provides GRand Unified Bootloader. In this page it will be built with UEFI support, which is not enabled for GRUB built in LFS.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Unicode font data used to display GRUB menu

GCC (only needed if building on 32-bit LFS)

GRUB Dependencies

Required (runtime)

efibootmgr-17

Recommended
Optional

LVM2-2.03.15

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/grub-efi

Installation of GRUB

First, install font data as the root user:

mkdir -pv /usr/share/fonts/unifont &&
gunzip -c ../unifont-14.0.01.pcf.gz > /usr/share/fonts/unifont/unifont.pcf

Warning

Unset any environment variables which may affect the build:

unset {C,CPP,CXX,LD}FLAGS

Don't try tuning this package with custom compilation flags: this package is a bootloader, with low-level operations in the source code which is likely to be broken by some aggressive optimizations.

If you are running a 32-bit LFS, prepare a 64-bit compiler:

case $(uname -m) in i?86 )
    tar xf ../gcc-11.2.0.tar.xz
    mkdir gcc-11.2.0/build
    pushd gcc-11.2.0/build
        ../configure --prefix=$PWD/../../x86_64-gcc \
                     --target=x86_64-linux-gnu      \
                     --with-system-zlib             \
                     --enable-languages=c,c++       \
                     --with-ld=/usr/bin/ld
        make all-gcc
        make install-gcc
    popd
    export TARGET_CC=$PWD/x86_64-gcc/bin/x86_64-linux-gnu-gcc
esac

Build GRUB with the following commands:

./configure --prefix=/usr        \
            --sysconfdir=/etc    \
            --disable-efiemu     \
            --enable-grub-mkfont \
            --with-platform=efi  \
            --target=x86_64      \
            --disable-werror     &&
unset TARGET_CC &&
make

This package does not have a test suite providing meaningful results.

Now, as the root user:

make install &&
mv -v /etc/bash_completion.d/grub /usr/share/bash-completion/completions

Command Explanations

--enable-grub-mkfont: Build the tool named grub-mkfont to generate the font file for the boot loader from the font data we've installed.

Warning

If the recommended dependency FreeType-2.11.1 is not installed, it is possible to omit this option and build GRUB. However, if grub-mkfont is not built, or the unicode font data is not available at the time GRUB is built, GRUB won't install any font for the boot loader. The GRUB boot menu will be displayed using a coarse font and the early stage of kernel initialization will be in blind mode — you can't see any kernel messages before the graphics card driver is initialized. It will be very difficult to diagnose some boot issues, especially if the graphics driver is built as module.

--with-platform=efi: Ensures building GRUB with EFI enabled.

--target=x86_64: Ensures building GRUB for x86_64 even if building on a 32-bit LFS system. Most EFI firmwares on x86_64 does not support 32-bit bootloaders.

--target=i386: A few 32-bit x86 platforms have EFI support. And, some x86_64 platforms have a 32-bit EFI implementation, but they are very old and rare. Use this instead of --target=x86_64 if you are absolutely sure that LFS is running on such a system.

Configuring GRUB

Using GRUB to make the LFS system bootable on UEFI platform will be discussed in Using GRUB to Set Up the Boot Process with UEFI.

Contents

See the page for GRUB in LFS book.

Last updated on

Using GRUB to Set Up the Boot Process with UEFI

Turn Off Secure Boot

BLFS does not have the essential packages to support Secure Boot. To set up the boot process with GRUB for UEFI installed in BLFS, Secure Boot must be turned off from the configuration interface of the firmware. Read the documentation provided by the manufacturer of your system to find out how.

Create an Emergency Boot Disk

Ensure that an emergency boot disk is ready to rescue the system in case the system becomes un-bootable. To make an emergency boot disk with GRUB for an EFI based system, find a spare USB flash drive and create a vfat file system on it. Install dosfstools-4.2 first, then as the root user:

Warning

The following command will erase all directories and files in the partition. Make sure your USB flash drive contains no data which will be needed, and change sdx1 to the device node corresponding to the first partition of the USB flash drive. Be careful not to overwrite your hard drive with a typo!

mkfs.vfat /dev/sdx1

Still as the root user, use the fdisk utility to set the first parition of the USB flash drive to be an EFI system partition (change sdx to the device node corresponding to your USB flash drive):

fdisk /dev/sdx

Welcome to fdisk (util-linux 2.37.4).
Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.


Command (m for help): t
Partition number (1-9, default 9): 1
Partition type or alias (type L to list all): uefi
Changed type of partition 'Linux filesystem' to 'EFI System'.

Command (m for help): w
The partition table has been altered.
Calling ioctl() to re-read partition table.
Syncing disks.

Still as the root user, create a mount point for the EFI partition on the USB flash drive and mount it:

mkdir -pv /mnt/rescue &&
mount -v -t vfat /dev/sdx1 /mnt/rescue

Install GRUB for EFI on the partition:

grub-install --removable --efi-directory=/mnt/rescue --boot-directory=/mnt/rescue/grub

Unmount the partition:

umount /mnt/rescue

Now the USB flash drive can be used as a emergency boot disk on x86-64 UEFI platform. It will boot the system and show the GRUB shell. Then you can type commands to boot your operating systems on the hard drive. To learn how to select the boot device, read the manual of your motherboard or laptop.

Kernel Configuration for UEFI support

Enable the following options in the kernel configuration and recompile the kernel if necessary:

Processor type and features --->
  [*] EFI runtime service support                              [CONFIG_EFI]
  [*]   EFI stub support                                       [CONFIG_EFI_STUB]
Firmware Drivers --->
  EFI (Extensible Firmware Interface) Support --->
    < > EFI Variable Support via sysfs                         [CONFIG_EFI_VARS]
    [*] Export efi runtime maps to sysfs                       [CONFIG_EFI_RUNTIME_MAP]
Enable the block layer --->
  Partition Types --->
    [*] Advanced partition selection                           [CONFIG_PARTITION_ADVANCED]
    [*] EFI GUID Partition support                             [CONFIG_EFI_PARTITION]
Device Drivers --->
  Graphics support --->
    Frame buffer Devices --->
      Support for frame buffer devices --->                    [CONFIG_FB]
        [*] EFI-based Framebuffer support                      [CONFIG_FB_EFI]
    Console display driver support --->
      [*] Framebuffer Console support                          [CONFIG_FRAMEBUFFER_CONSOLE]
File systems --->
  Pseudo filesystems --->
    <*/M> EFI Variable filesystem                              [CONFIG_EFIVAR_FS]

The meaning of the configure options:

CONFIG_EFI_STUB

Although the EFI stub is designed to boot a kernel directly from the UEFI firmware (without a bootloader like GRUB), GRUB needs the kernel to be loaded to support the EFI handover protocol enabled by this option.

CONFIG_EFI_VARS

Don't use this deprecated option because of a 1024-byte variable size limit. Its function is replaced by CONFIG_EFIVAR_FS.

CONFIG_FB_EFI and CONFIG_FRAMEBUFFER_CONSOLE

The combination of these two options allows the kernel to print debug messages (along with Tux logos) at the early stage of the boot process with UEFI.

Find or Create the EFI System Partition

On EFI based system, the bootloaders are installed in a special FAT32 partition called an EFI System Partition (ESP). If your system supports EFI, and a recent version of Linux distribution or Windows is pre-installed, it's likely that the ESP is already created. As the root user, list all the partitions on your hard drive (replace sda with the device corresponding to the appropriate hard drive):

fdisk -l /dev/sda

The Type column of the ESP should be EFI System.

If the system or the hard drive is new, or it's a first time install an UEFI booted OS on the system, the ESP may not exist. In that case, create a new partition, make a vfat file system on it, and set the partition type to EFI system. See the instructions for the emergency boot device above as a reference.

Warning

Some (old) UEFI implementations may demand the ESP to be the first partition on the disk.

Now, as the root user, create the mount point for the ESP, and mount it (replace sda1 with the device node corresponding to the ESP):

mkdir -pv /boot/efi &&
mount -v -t vfat /dev/sda1 /boot/efi

Add an entry for the ESP in /etc/fstab, so it will be mounted automatically during system boot:

cat >> /etc/fstab << EOF
/dev/sda1 /boot/efi vfat defaults 0 1
EOF

Mount the EFI Variable File System

The installation of GRUB on a UEFI platform requires that the EFI Variable file system, efivarfs, to be mounted. As the root user, mount it if it's not already mounted:

mountpoint /sys/firmware/efi/efivars || mount -v -t efivarfs efivarfs /sys/firmware/efi/efivars

Now add an entry for the efivarfs in /etc/fstab so it will be mounted automatically during system boot:

cat >> /etc/fstab << EOF
efivarfs /sys/firmware/efi/efivars efivarfs defaults 0 0
EOF

Warning

If the system is not booted with UEFI, the directory /sys/firmware/efi will be missing. In this case you should boot the system in UEFI mode with the emergency boot disk created as above.

Setting Up the Configuration

On UEFI based systems, GRUB works by installing an EFI application (a special kind of executable) into /boot/efi/EFI/[id]/grubx64.efi, where /boot/efi is the mount point of the ESP, and [id] is replaced with an identifier specified in the grub-install command line. GRUB will create an entry in the EFI variables containing the path EFI/[id]/grubx64.efi so the EFI firmware can find grubx64.efi and load it.

grubx64.efi is very lightweight (136 KB with GRUB-2.06~rc1) so it will not use much space in the ESP. A typical ESP size is 100 MB (for Windows boot manager, which uses about 50 MB in the ESP). Once grubx64.efi loaded by the firmware, it will load GRUB modules in the boot partition. The default location is /boot/grub.

As the root user, install the GRUB files into /boot/efi/EFI/LFS/grubx64.efi and /boot/grub. Then set up the boot entry in the EFI variables:

grub-install --bootloader-id=LFS --recheck

If the installation is successful, the output should be:

Installing for x86_64-efi platform.
Installation finished. No error reported.

Issue efibootmgr to recheck the EFI boot configuration. An example of the output is:

BootCurrent: 0000
Timeout: 1 seconds
BootOrder: 0005,0000,0002,0001,0003,0004
Boot0000* ARCH
Boot0001* UEFI:CD/DVD Drive
Boot0002* Windows Boot Manager
Boot0003* UEFI:Removable Device
Boot0004* UEFI:Network Device
Boot0005* LFS

Note that 0005 is the first in the BootOrder, and Boot0005 is LFS. This means that on the next boot, the version of GRUB installed by LFS will be used to boot the system.

Creating the GRUB Configuration File

Generate /boot/grub/grub.cfg to configure the boot menu of GRUB:

cat > /boot/grub/grub.cfg << EOF
# Begin /boot/grub/grub.cfg
set default=0
set timeout=5

insmod part_gpt
insmod ext2
set root=(hd0,2)

if loadfont /boot/grub/fonts/unicode.pf2; then
  set gfxmode=auto
  insmod all_video
  terminal_output gfxterm
fi

menuentry "GNU/Linux, Linux 5.10.17-lfs-10.1"  {
  linux   /boot/vmlinuz-5.10.17-lfs-10.1 root=/dev/sda2 ro
}

menuentry "Firmware Setup" {
  fwsetup
}
EOF

(hd0,2), sda2, and 5.10.17-lfs-10.1 should be replaced to match your configuration.

Note

From GRUB's perspective, the files are relative to the partition are used. If you used a separate /boot partition, remove /boot from the above paths (to kernel and to unicode.pf2). You will also need to change the set root line to point to the boot partition.

The Firmware Setup entry can be used to enter the configuration interface provided by the firmware (sometimes called BIOS configuration).

Dual-booting with Windows

Add a menu entry for Windows into grub.cfg:

cat >> /boot/grub/grub.cfg << EOF
# Begin Windows addition

menuentry "Windows 10" {
  insmod fat
  insmod chain
  set root=(hd0,1)
  chainloader /EFI/Microsoft/Boot/bootmgfw.efi
}
EOF

(hd0,1) should be replaced with the GRUB designated name for the ESP. The chainloader directive can be used to tell GRUB to run another EFI executable, in this case the Windows Boot Manager. You may put more usable tools in EFI executable format (for example, an EFI shell) into the ESP and create GRUB entries for them.

Last updated on

Chapter 6. Editors

This chapter is referenced in the LFS book for those wishing to use other editors on their LFS system. You're also shown how some LFS installed programs benefit from being recompiled after GUI libraries have been installed.

Bluefish-2.2.12

Introduction to Bluefish

Bluefish is a GTK+ text editor targeted towards programmers and web designers, with many options to write websites, scripts and programming code. Bluefish supports many programming and markup languages, and it focuses on editing dynamic and interactive websites.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Bluefish Dependencies

Required

GTK+-2.24.33 or GTK+-3.24.31 (If both are installed, configure defaults to using GTK+ 3)

Recommended
Optional

enchant-2.3.2 (for spell checking), Gucharmap-14.0.2, PCRE-8.45 and Jing

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/bluefish

Installation of Bluefish

Install Bluefish by running the following commands:

./configure --prefix=/usr --docdir=/usr/share/doc/bluefish-2.2.12 &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Note

This package installs icon files into the /usr/share/icons/hicolor hierarchy and desktop files into the /usr/share/applications hierarchy. You can improve system performance and memory usage by updating /usr/share/icons/hicolor/icon-theme.cache and /usr/share/applications/mimeinfo.cache. To perform the update you must have desktop-file-utils-0.26 (for the desktop cache) and issue the following commands as the root user:

gtk-update-icon-cache -t -f --include-image-data /usr/share/icons/hicolor &&
update-desktop-database

Contents

Installed Program: bluefish
Installed Libraries: several under /usr/lib/bluefish/
Installed Directories: /usr/lib/bluefish, /usr/share/bluefish, /usr/share/doc/bluefish-2.2.12, and /usr/share/xml/bluefish

Short Descriptions

bluefish

is a GTK+ text editor for markup and programming

Last updated on

Ed-1.18

Introduction to Ed

Ed is a line-oriented text editor. It is used to create, display, modify and otherwise manipulate text files, both interactively and via shell scripts. Ed isn't something which many people use. It's described here because it can be used by the patch program if you encounter an ed-based patch file. This happens rarely because diff-based patches are preferred these days.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Ed Dependencies

Required to uncompress the tarball

libarchive-3.6.0 (for bsdtar)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/ed

Installation of Ed

Install Ed by running the following commands:

./configure --prefix=/usr &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Contents

Installed Programs: ed and red
Installed Libraries: None
Installed Directories: None

Short Descriptions

ed

is a line-oriented text editor

red

is a restricted ed—it can only edit files in the current directory and cannot execute shell commands

Last updated on

Emacs-27.2

Introduction to Emacs

The Emacs package contains an extensible, customizable, self-documenting real-time display editor.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Emacs Dependencies

Recommended
Optional

a graphical environment, alsa-lib-1.2.6.1, Cairo-1.17.4, dbus-1.12.20, GConf-3.2.6, gobject-introspection-1.70.0, gsettings-desktop-schemas-41.0, GPM-1.20.7, GTK+-2.24.33 or GTK+-3.24.31, ImageMagick-7.1.0-25, Little CMS-2.13.1, libjpeg-turbo-2.1.2, libpng-1.6.37, librsvg-2.52.6, libxml2-2.9.13, MIT Kerberos V5-1.19.2, Valgrind-3.18.1, intlfonts, libungif, libotf, and m17n-lib - to correctly display such complex scripts as Indic and Khmer, and also for scripts that require Arabic shaping support (Arabic and Farsi), mailutils, and libXaw3d

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/emacs

Installation of Emacs

First, work around a portability bug in glibc 2.34, which no longer defines SIGSTKSZ.

sed -e '/SIGSTKSZ/ s|^.*$|static max_align_t sigsegv_stack[\
   (64 * 1024 + sizeof (max_align_t) - 1) / sizeof (max_align_t)];|' \
    -i src/sysdep.c

Install Emacs by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite. If make succeeds, you can test the result by running src/emacs -Q, which is the program that will be installed, with its auxiliary files. This should start and display the application opening screen.

Now, as the root user:

make install &&
chown -v -R root:root /usr/share/emacs/27.2 &&
rm -vf /usr/lib/systemd/user/emacs.service

Note

This package installs icon files into the /usr/share/icons/hicolor hierarchy and you can improve system performance and memory usage by updating /usr/share/icons/hicolor/index.theme. To perform the update you must have GTK+-2.24.33 or GTK+-3.24.31 installed and issue the following command as the root user:

gtk-update-icon-cache -qtf /usr/share/icons/hicolor

Command Explanations

--with-imagemagick: Use this if you have installed ImageMagick-7.1.0-25 and wish to link against it.

--with-gif=no: Use this if you have not installed giflib-5.2.1 or libungif.

--with-tiff=no: Use this if you have not installed libtiff-4.3.0.

--with-gnutls=no: Use this if you have not installed GnuTLS-3.7.3.

--without-harfbuzz: Use this if you have not installed HarfBuzz-3.4.0.

--with-json=no: Use this if you have not installed jansson-2.14.

Contents

Installed Programs: ctags, ebrowse, emacs (symlink), emacs-27.2, emacsclient, and etags
Installed Libraries: None
Installed Directories: /usr/libexec/emacs and /usr/share/emacs

Short Descriptions

ctags

creates cross-reference tagfile database files for source code

ebrowse

permits browsing of C++ class hierarchies from within emacs

emacs

is an editor

emacsclient

attaches an emacs session to an already running emacsserver instance

etags

is another program to generate source code cross-reference tagfiles

Last updated on

Gedit-41.0

Introduction to Gedit

The Gedit package contains a lightweight UTF-8 text editor for the GNOME Desktop.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Gedit Dependencies

Required

git-2.35.1, gsettings-desktop-schemas-41.0, gtksourceview4-4.8.2, itstool-2.0.7, and libpeas-1.30.0

Recommended
Optional

GTK-Doc-1.33.2, Vala-0.54.7, and zeitgeist

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gedit

Installation of Gedit

Install Gedit by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Note

If you installed the package to your system using a DESTDIR method, /usr/share/glib-2.0/schemas/gschemas.compiled was not updated/created. Create (or update) the file using the following command as the root user:

glib-compile-schemas /usr/share/glib-2.0/schemas

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Duser_documentation=false: This switch disables generating the user documentation. Omit this switch if you have GTK-Doc-1.33.2 installed and wish to generate the user documentation.

-Dgtk_doc=true: Use this option to build the reference manual (needs GTK-Doc-1.33.2).

Contents

Installed Program: gedit
Installed Libraries: libgedit-41.0.so
Installed Directories: /usr/include/gedit-41 and /usr/{lib,share,share/gtk-doc/html,share/help/*}/gedit

Short Descriptions

gedit

is a lightweight text editor integrated with the GNOME Desktop

Last updated on

JOE-4.6

Introduction to JOE

JOE (Joe's own editor) is a small text editor capable of emulating WordStar, Pico, and Emacs.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/joe

Installation of JOE

Install JOE by running the following commands:

./configure --prefix=/usr     \
            --sysconfdir=/etc \
            --docdir=/usr/share/doc/joe-4.6 &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&

install -vm 755 joe/util/{stringify,termidx,uniproc} /usr/bin

Configuring JOE

Config Files

/etc/joe/jmacsrc, /etc/joe/joerc, /etc/joe/jpicorc, /etc/joe/jstarrc, /etc/joe/rjoerc, and ~/.joerc

Contents

Installed Programs: jmacs, joe, jpico, jstar, rjoe, stringify, termidx, and uniproc
Installed Libraries: None
Installed Directories: /etc/joe, /usr/share/joe, and /usr/share/doc/joe-4.6

Short Descriptions

jmacs

is a symbolic link to joe used to launch Emacs emulation mode

joe

is a small text editor capable of emulating WordStar, Pico, and Emacs

jpico

is a symbolic link to joe used to launch Pico emulation mode

jstar

is a symbolic link to joe used to launch WordStar emulation mode

rjoe

is a symbolic link to joe that restricts JOE to editing only files which are specified on the command-line

stringify

is a program used by joe to convert rc and .jsf files into a C file (see /usr/share/doc/joe-4.6/util/README)

termidx

is a program used by joe to generate the termcap index file (see /usr/share/doc/joe-4.6/util/README)

uniproc

is a program used by joe to generate joe's unicode database file unicat.c from Blocks.txt CaseFolding.txt EastAsianWidth.txt and UnicodeData.txt (find them at /usr/share/doc/joe-4.6/util; see usr/share/doc/joe-4.6/util/README)

Last updated on

Kate-21.12.2

Introduction to Kate

The Kate package contains an advanced KF5 based graphical text editor.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Kate Dependencies

Required

KDE Frameworks-5.91.0

Optional

libgit2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/kate5

Installation of Kate

Install Kate by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=$KF5_PREFIX  \
      -DCMAKE_BUILD_TYPE=Release          \
      -DBUILD_TESTING=OFF                 \
      -Wno-dev .. &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: kate and kwrite
Installed Libraries: Several plugins under $KF5_PREFIX/lib/plugins
Installed Directories: $KF5_PREFIX/lib/plugins/ktexteditor, $KF5_PREFIX/lib/plugins/plasma/dataengine, $KF5_PREFIX/share/doc/HTML/*/{kate,katepart,kwrite}, $KF5_PREFIX/share/{kateproject,katexmltools}, and $KF5_PREFIX/share/plasma/plasmoids/org.kde.plasma.katesessions

Short Descriptions

kate

is an advanced text editor for kde

kwrite

is a text editor for KDE, that is a light version of kate

Last updated on

Mousepad-0.5.8

Introduction to Mousepad

Mousepad is a simple GTK+ 3 text editor for the Xfce desktop environment.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Mousepad Dependencies

Required

gtksourceview4-4.8.2

Optional

DConf-0.40.0 (runtime) and dbus-glib-0.112

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/mousepad

Installation of Mousepad

Install Mousepad by running the following commands:

./configure --prefix=/usr --enable-keyfile-settings &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--enable-keyfile-settings: Use the GSettings keyfile backend rather than the default DConf-0.40.0.

Contents

Installed Program: mousepad
Installed Libraries: None
Installed Directories: None

Short Descriptions

mousepad

is a simple GTK+ 3 text editor

Last updated on

Nano-6.2

Introduction to Nano

The Nano package contains a small, simple text editor which aims to replace Pico, the default editor in the Pine package.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Nano

Installation of Nano

Install Nano by running the following commands:

./configure --prefix=/usr     \
            --sysconfdir=/etc \
            --enable-utf8     \
            --docdir=/usr/share/doc/nano-6.2 &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&
install -v -m644 doc/{nano.html,sample.nanorc} /usr/share/doc/nano-6.2

Command Explanations

--enable-utf8: This switch enables unicode support in Nano.

Configuring nano

Config Files

/etc/nanorc and ~/.nanorc

Configuration Information

Example configuration (create as a system-wide /etc/nanorc or a personal ~/.nanorc file)

set autoindent
set constantshow
set fill 72
set historylog
set multibuffer
set nohelp
set positionlog
set quickblank
set regexp
set suspend

Check the sample.nanorc file in the installed documentation directory. It includes color configurations and has some documentation included in the comments.

Syntax highlighting is provided for several file types, in /usr/share/nano/ directory. E.g., for shell scripts, you can insert include /usr/share/nano/sh.nanorc in the personal or global configuration file. If you wish highlighting for all supported files, use include /usr/share/nano/*.nanorc. This include does not descend into the extra directory. Move required files one level up.

Contents

Installed Programs: nano and rnano (symlink)
Installed Libraries: None
Installed Directories: /usr/share/nano and /usr/share/doc/nano-6.2

Short Descriptions

nano

is a small, simple text editor which aims to replace Pico, the default editor in the Pine package

rnano

is a restricted mode for nano

Last updated on

Vim-8.2.4383

Introduction to Vim

The Vim package, which is an abbreviation for VI IMproved, contains a vi clone with extra features as compared to the original vi.

The default LFS instructions install vim as a part of the base system. If you would prefer to link vim against X, you should recompile vim to enable GUI mode. There is no need for special instructions since X support is automatically detected.

Note

The version of vim changes daily. To get the latest version, go to https://github.com/vim/vim/releases.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Vim Dependencies

Recommended
Optional

GPM-1.20.7, Lua-5.4.4, rsync-3.2.3, and Ruby-3.1.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/vim

Installation of Vim

Note

If you recompile Vim to link against X and your X libraries are not on the root partition, you will no longer have an editor for use in emergencies. You may choose to install an additional editor, not link Vim against X, or move the current vim executable to the /bin directory under a different name such as vi.

Install Vim by running the following commands:

Note

If you intend to run the tests and have not installed Xorg in /usr, append LDFLAGS='-L$XORG_PREFIX/lib' to the configure line below.

echo '#define SYS_VIMRC_FILE  "/etc/vimrc"' >>  src/feature.h &&
echo '#define SYS_GVIMRC_FILE "/etc/gvimrc"' >> src/feature.h &&

./configure --prefix=/usr        \
            --with-features=huge \
            --enable-gui=gtk3    \
            --with-tlib=ncursesw &&
make

Note

If the global configuration file /etc/vimrc references the VIMRUNTIME environment variable, some tests may complain about being unable to find the corresponding directory and wait for user input. If this is the case, this file should be saved and removed before running the tests.

To test the results, issue: make -j1 test. Even if one of the tests fails to produce the file test.out in src/testdir, the remaining tests will still be executed. If all goes well, the log will report ALL DONE. Some tests labelled as flaky may fail occasionally and can be ignored. The tests are known to fail if the output is redirected to a file.

Note

Some color tests expect to be executed under the xterm terminal emulator.

Now, as the root user:

make install

By default, Vim's documentation is installed in /usr/share/vim. The following symlink allows the documentation to be accessed via /usr/share/doc/vim-8.2.4383, making it consistent with the location of documentation for other packages:

ln -snfv ../vim/vim82/doc /usr/share/doc/vim-8.2.4383

If you wish to update the runtime files, issue the following command (requires rsync-3.2.3):

rsync -avzcP --exclude="/dos/" --exclude="/spell/" \
    ftp.nluug.nl::Vim/runtime/ ./runtime/

To install the runtime files and regenerate the tags file, as the root user issue:

make -C src installruntime &&
vim -c ":helptags /usr/share/doc/vim-8.2.4383" -c ":q"

Command Explanations

--with-features=huge: This switch enables all the additional features available in Vim, including support for multibyte characters.

--with-tlib=ncursesw: This switch forces Vim to link against the libncursesw library.

--enable-gui=no: This will prevent compilation of the GUI. Vim will still link against X, so that some features such as the client-server model or the x11-selection (clipboard) are still available.

--without-x: If you prefer not to link Vim against X, use this switch.

--enable-luainterp, --enable-perlinterp, --enable-python3interp=dynamic, --enable-tclinterp --with-tclsh=tclsh, --enable-rubyinterp: These options include the Lua, Perl, Python3, Tcl, or Ruby interpreters that allow using other application code in vim scripts. All the --enable-... options can accept =dynamic to dynamically load the interpreter when needed. This is required for Python 3 to prevent segmentation faults. For tcl, it is necessary to indicate the name of the tclsh executable, since configure only searches versioned names with old versions.

Configuring Vim

Config Files

/etc/vimrc and ~/.vimrc

Configuration Information

Vim has an integrated spell checker which you can enable by issuing the following in a vim window:

:setlocal spell spelllang=ru

This setting will enable spell checking for the Russian language for the current session.

By default, Vim only installs spell files for the English language. If a spell file is not available for a language, then Vim will call the $VIMRUNTIME/plugin/spellfile.vim plugin and will try to obtain the *.spl and optionally *.sug from the vim ftp server, by using the $VIMRUNTIME/plugin/netrwPlugin.vim plugin.

Alternatively you can manually download the *.spl and *.sug files from: ftp://ftp.vim.org/pub/vim/runtime/spell/ and save them to ~/.vim/spell or in /usr/share/vim/vim82/spell/.

To find out what's new in Vim-8.2.4383 issue the following command:

:help version-8.2.4383

For additional information on setting up Vim configuration files, see The vimrc Files and http://vim.wikia.com/wiki/Example_vimrc.

Contents

A list of the reinstalled files, along with their short descriptions can be found in the LFS Vim Installation Instructions.

Installed Programs: gview, gvim, gvimdiff, gvimtutor, rgview, and rgvim
Installed Libraries: None
Installed Directory: /usr/share/vim

Short Descriptions

gview

starts gvim in read-only mode

gvim

is the editor that runs under X and includes a GUI

gvimdiff

edits two or three versions of a file with gvim and shows the differences

gvimtutor

teaches the basic keys and commands of gvim

rgview

is a restricted version of gview

rgvim

is a restricted version of gvim

Last updated on

Chapter 7. Shells

We are all familiar with the Bourne Again SHell, but there are two other user interfaces that are considered useful modern shells – the Berkeley Unix C shell and the Korn shell. This chapter installs packages compatible with these additional shell types.

Dash-0.5.11.5

Introduction to Dash

Dash is a POSIX compliant shell. It can be installed as /bin/sh or as the default shell for either root or a second user with a userid of 0. It depends on fewer libraries than the Bash shell and is therefore less likely to be affected by an upgrade problem or disk failure. Dash is also useful for checking that a script is completely compatible with POSIX syntax.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Dash Dependencies

Optional

libedit (command line editor library)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/dash

Installation of Dash

Install Dash by running the following commands:

./configure --bindir=/bin --mandir=/usr/share/man &&
make

This package does not come with a test suite.

Now, as the root user:

make install

If you would like to make dash the default sh, recreate the /bin/sh symlink as the root user:

Note

If you create the symbolic link from dash to sh, you will need to reset the link to bash to build LFS.

ln -svf dash /bin/sh

Command Explanations

--bindir=/bin: This parameter places the dash binary into the root filesystem.

--with-libedit: To compile Dash with libedit support.

Configuring Dash

Config Files

Dash sources /etc/profile and ~/.profile

Configuration Information

Update /etc/shells to include the Dash shell by issuing the following command as the root user:

cat >> /etc/shells << "EOF"
/bin/dash
EOF

Contents

Installed Program: dash
Installed Libraries: None
Installed Directories: None

Short Description

dash

is a POSIX compliant shell

Last updated on

Tcsh-6.24.00

Introduction to Tcsh

The Tcsh package contains an enhanced but completely compatible version of the Berkeley Unix C shell (csh). This is useful as an alternative shell for those who prefer C syntax to that of the bash shell, and also because some programs require the C shell in order to perform installation tasks.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/tcsh

Installation of Tcsh

Install Tcsh by running the following commands:

./configure --prefix=/usr --bindir=/bin &&

make &&
sh ./tcsh.man2html

To test the results, issue: make check.

Now, as the root user:

make install install.man &&

ln -v -sf tcsh   /bin/csh &&
ln -v -sf tcsh.1 /usr/share/man/man1/csh.1 &&

install -v -m755 -d          /usr/share/doc/tcsh-6.24.00/html &&
install -v -m644 tcsh.html/* /usr/share/doc/tcsh-6.24.00/html &&
install -v -m644 FAQ         /usr/share/doc/tcsh-6.24.00

Command Explanations

--bindir=/bin: This installs the tcsh program in /bin instead of /usr/bin.

sh ./tcsh.man2html: This creates HTML documentation from the formatted man page.

ln -v -sf tcsh /bin/csh: The FHS states that if there is a C shell installed, there should be a symlink from /bin/csh to it. This creates that symlink.

Configuring Tcsh

Config Files

There are numerous configuration files for the C shell. Examples of these are /etc/csh.cshrc, /etc/csh.login, /etc/csh.logout, ~/.tcshrc, ~/.cshrc, ~/.history, ~/.cshdirs, ~/.login, and ~/.logout. More information on these files can be found in the tcsh(1) man page.

Configuration Information

Update /etc/shells to include the C shell program names (as the root user):

cat >> /etc/shells << "EOF"
/bin/tcsh
/bin/csh
EOF

The following ~/.cshrc provides two alternative colour prompts and coloured ls output. If you prefer a global modification, issue the command as the root user, replacing ~/.cshrc by /etc/csh.cshrc.

cat > ~/.cshrc << "EOF"
# Original at:
# https://www.cs.umd.edu/~srhuang/teaching/code_snippets/prompt_color.tcsh.html

# Modified by the BLFS Development Team.

# Add these lines to your ~/.cshrc (or to /etc/csh.cshrc).

# Colors!
set     red="%{\033[1;31m%}"
set   green="%{\033[0;32m%}"
set  yellow="%{\033[1;33m%}"
set    blue="%{\033[1;34m%}"
set magenta="%{\033[1;35m%}"
set    cyan="%{\033[1;36m%}"
set   white="%{\033[0;37m%}"
set     end="%{\033[0m%}" # This is needed at the end...

# Setting the actual prompt.  Two separate versions for you to try, pick
# whichever one you like better, and change the colors as you want.
# Just don't mess with the ${end} guy in either line...  Comment out or
# delete the prompt you don't use.

set prompt="${green}%n${blue}@%m ${white}%~ ${green}%%${end} "
set prompt="[${green}%n${blue}@%m ${white}%~ ]${end} "

# This was not in the original URL above
# Provides coloured ls
alias ls ls --color=always

# Clean up after ourselves...
unset red green yellow blue magenta cyan yellow white end
EOF

Contents

Installed Program: tcsh
Installed Libraries: None
Installed Directory: /usr/share/doc/tcsh-6.24.00

Short Descriptions

tcsh

is an enhanced but completely compatible version of the Berkeley Unix C shell, csh. It is usable as both an interactive shell and a script processor

Last updated on

zsh-5.8.1

Introduction to zsh

The zsh package contains a command interpreter (shell) usable as an interactive login shell and as a shell script command processor. Of the standard shells, zsh most closely resembles ksh but includes many enhancements.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://www.zsh.org/pub/zsh-5.8.1.tar.xz

  • Download MD5 sum: 063a98c256ee0584b3c115924e41a332

  • Download size: 3.1 MB

  • Estimated disk space required: 47 MB (includes documentation and tests)

  • Estimated build time: 1.4 SBU (Using parallelism=4; includes documentation and tests)

Additional Downloads

Note

When there is a new zsh release, the old files shown above are moved to a new server directory: https://www.zsh.org/pub/old/.

zsh Dependencies

Optional

libcap-2.63 with PAM, PCRE-8.45, and Valgrind-3.18.1,

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/zsh

Installation of zsh

If you downloaded the optional documentation, unpack it with the following command:

tar --strip-components=1 -xvf ../zsh-5.8.1-doc.tar.xz

Install zsh by running the following commands:

./configure --prefix=/usr         \
            --sysconfdir=/etc/zsh \
            --enable-etcdir=/etc/zsh                  &&
make                                                  &&

makeinfo  Doc/zsh.texi --plaintext -o Doc/zsh.txt     &&
makeinfo  Doc/zsh.texi --html      -o Doc/html        &&
makeinfo  Doc/zsh.texi --html --no-split --no-headers -o Doc/zsh.html

If you have texlive-20210325 installed, you can build PDF format of the documentation by issuing the following command:

texi2pdf  Doc/zsh.texi -o Doc/zsh.pdf

To test the results, issue: make check.

Now, as the root user:

make install                              &&
make infodir=/usr/share/info install.info &&

install -v -m755 -d                 /usr/share/doc/zsh-5.8.1/html &&
install -v -m644 Doc/html/*         /usr/share/doc/zsh-5.8.1/html &&
install -v -m644 Doc/zsh.{html,txt} /usr/share/doc/zsh-5.8.1

If you downloaded the optional documentation, install it by issuing the following commands as the root user:

make htmldir=/usr/share/doc/zsh-5.8.1/html install.html &&
install -v -m644 Doc/zsh.dvi /usr/share/doc/zsh-5.8.1

If you built the PDF format of the documentation, install it by issuing the following command as the root user:

install -v -m644 Doc/zsh.pdf /usr/share/doc/zsh-5.8.1

Command Explanations

--sysconfdir=/etc/zsh and --enable-etcdir=/etc/zsh: These parameters are used so that all the zsh configuration files are consolidated into the /etc/zsh directory. Omit these parameters if you wish to retain historical compatibility by having all the files located in the /etc directory.

--enable-cap: This option enables POSIX capabilities.

--disable-gdbm: This option disables the use of the GDBM library.

--enable-pcre: This option allows zsh to use the PCRE regular expression library in shell builtins.

Configuring zsh

Config Files

There are a whole host of configuration files for zsh including /etc/zsh/zshenv, /etc/zsh/zprofile, /etc/zsh/zshrc, /etc/zsh/zlogin and /etc/zsh/zlogout. You can find more information on these in the zsh(1) and related manual pages.

The first time zsh is executed, you will be prompted by messages asking several questions. The answers will be used to create a ~/.zshrc file. If you wish to run these questions again, run zsh /usr/share/zsh/5.8.1/functions/zsh-newuser-install -f.

There are several built-in advanced prompts. In the zsh shell, start advanced prompt support with autoload -U promptinit, then promptinit. Available prompt names are listed with prompt -l. Select a particular one with prompt <prompt-name>. Display all available prompts with prompt -p. Except for the list and display commands above, you can insert the other ones in ~/.zshrc to be automatically executed at shell start, with the prompt you chose.

Configuration Information

Update /etc/shells to include the zsh shell program names (as the root user):

cat >> /etc/shells << "EOF"
/bin/zsh
EOF

Contents

Installed Programs: zsh and zsh-5.8.1 (hardlinked to each other)
Installed Libraries: Numerous plugin helper modules under /usr/lib/zsh/5.8.1/
Installed Directories: /usr/{lib,share}/zsh and /usr/share/doc/zsh-5.8.1

Short Description

zsh

is a shell which has command-line editing, built-in spelling correction, programmable command completion, shell functions (with autoloading), a history mechanism, and a host of other features

Last updated on

Chapter 8. Virtualization

Virtualization allows running a complete operating system, or virtual machine (VM), within another operating environment as a task. There are several commercial and open source environments that either emulate another processor or utilize the hardware virtualization features of the host processor.

qemu-6.2.0

Introduction to qemu

qemu is a full virtualization solution for Linux on x86 hardware containing virtualization extensions (Intel VT or AMD-V).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://download.qemu-project.org/qemu-6.2.0.tar.xz

  • Download MD5 sum: a077669ce58b6ee07ec355e54aad25be

  • Download size: 110 MB

  • Estimated disk space required: 1.9 GB

  • Estimated build time: 1.4 SBU (using parallelism=4; add 0.5 SBU for tests)

Qemu Dependencies

Required

GLib-2.70.4, and a graphical environment

Recommended
Optional

Depending on the sound system, various packages in ALSA-1.2.6, Python-3.10.2, PulseAudio-15.0, BlueZ-5.63, cURL-7.81.0, Cyrus SASL-2.1.27, GnuTLS-3.7.3, GTK+-2.24.33, GTK+-3.24.31, libusb-1.0.25, libgcrypt-1.10.0, libssh2-1.10.0, LZO-2.10, Nettle-3.7.3, Mesa-21.3.6, SDL-1.2.15, VTE-0.66.2 or Vte-0.28.2, and libcacard

Optional dependencies for installing the documentation

sphinx with the sphinx-rtd-theme theme

Note

This optional dependencies list is not comprehensive. See the output of ./configure --help for a more complete list.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/qemu

KVM Prerequisites

Before building qemu, check to see if your processor supports Virtualization Technology (VT):

egrep '^flags.*(vmx|svm)' /proc/cpuinfo

If you get any output, you have VT technology (vmx for Intel processors and svm for AMD processors). You then need to go into your system BIOS and ensure it is enabled. After enabing, reboot back to your LFS instance.

Kernel Configuration

Enable the following options in the kernel configuration and recompile the kernel if necessary:

[*] Virtualization:  --->                                             [CONFIG_VIRTUALIZATION]
  <*/M>   Kernel-based Virtual Machine (KVM) support [CONFIG_KVM]
  <*/M>     KVM for Intel (and compatible) processors support         [CONFIG_KVM_INTEL]
  <*/M>     KVM for AMD processors support                            [CONFIG_KVM_AMD]

The Intel or AMD settings are not both required, but the one matching your system processor is required.

To use the bridge network device, as explained below, check that bridge-utils-1.7.1 is installed and the following options in the kernel configuration are enabled:

[*] Networking support  --->                         [CONFIG_NET]
  Networking options  --->
    <*/M> 802.1d Ethernet Bridging                   [CONFIG_BRIDGE]
Device Drivers  --->
  [*] Network device support  --->                   [CONFIG_NETDEVICES]
    <*/M>    Universal TUN/TAP device driver support [CONFIG_TUN]

Installation of qemu

Add any users that might use the KVM device to that group:

usermod -a -G kvm <username>

Install qemu by running the following commands:

Note

Qemu is capable of running many targets. The build process is also capable of building multiple targets at one time in a comma delimited list assigned to --target-list. Run ./configure --help to get a complete list of available targets.

if [ $(uname -m) = i686 ]; then
   QEMU_ARCH=i386-softmmu
else
   QEMU_ARCH=x86_64-softmmu
fi


mkdir -vp build &&
cd        build &&

../configure --prefix=/usr               \
             --sysconfdir=/etc           \
             --localstatedir=/var        \
             --target-list=$QEMU_ARCH    \
             --audio-drv-list=alsa       \
             --docdir=/usr/share/doc/qemu-6.2.0 &&

unset QEMU_ARCH &&

make

qemu uses ninja as a subprocess when building. To run the tests, issue: ninja test.

Now, as the root user:

make install

You will also need to add an Udev rule so that the KVM device gets correct permissions:

cat > /lib/udev/rules.d/65-kvm.rules << "EOF"
KERNEL=="kvm", GROUP="kvm", MODE="0660"
EOF

Change the permissions and ownership of a helper script, which is needed when using the bridge network device (see below):

chgrp kvm  /usr/libexec/qemu-bridge-helper &&
chmod 4750 /usr/libexec/qemu-bridge-helper

Note

For convenience you may want to create a symbolic link to run the installed program. For instance:

ln -sv qemu-system-`uname -m` /usr/bin/qemu

Command Explanations

--audio-drv-list=alsa: This switch sets the audio driver to ALSA. See below for enabling other audio drivers.

--audio-drv-list=pa: This switch sets the audio driver to pulseaudio. For other drivers see the --audio-drv-list list in configure's help output. The default audio driver is OSS. To enable support for both alsa and pulseaudio, use --audio-drv-list=alsa,pa.

Using Qemu

Since using qemu means using a virtual computer, the steps to set up the virtual machine are in close analogy with those to set up a real computer. You'll need to decide about CPU, memory, disk, USB devices, network card(s), screen size, etc. Once the hardware is decided, you'll have for example to choose how to connect the machine to internet, and/or to install an OS. In the following, we show basic ways of performing those steps. But qemu is much more than this, and it is strongly advised to read the qemu documentation in /usr/share/doc/qemu-6.2.0/qemu-doc.html.

Note

It is standard practice to name the computer running qemu host and the emulated machine running under qemu the guest. We'll use those notations in the following.

Note

The following instructions assume the optional symbolic link, qemu, has been created. Additionally, qemu must be run from an X Window System based terminal (either locally or over ssh).

Disk

A virtual disk may be set up in the following way:

VDISK_SIZE=50G
VDISK_FILENAME=vdisk.img
qemu-img create -f qcow2 $VDISK_FILENAME $VDISK_SIZE

The virtual disk size and filename should be adjusted as desired. The actual size of the file will be less than specified, but will expand as needed, so it is safe to put a high value.

Operating System

To install an operating system, download an iso image from your preferred Linux distribution. For the purposes of this example, we'll use Fedora-16-x86_64-Live-LXDE.iso in the current directory. Run the following:

qemu -enable-kvm                           \
     -drive file=$VDISK_FILENAME           \
     -cdrom Fedora-16-x86_64-Live-LXDE.iso \
     -boot d                               \
     -m 1G

Follow the normal installation procedures for the chosen distribution. The -boot option specifies the boot order of drives as a string of drive letters. Valid drive letters are: a, b (floppy 1 and 2), c (first hard disk), d (first CD-ROM). The -m option is the amount of memory to use for the virtual machine. The choice depends on the load of the host. Modern distributions should be comfortable with 1GB. The -enable-kvm option allows hardware acceleration. Without this switch, the emulation is much slower.

Defining the virtual hardware

The virtual machine hardware is defined by the qemu command line. An example command is given below:

qemu -enable-kvm                     \
     -smp 4                          \
     -cpu host                       \
     -m 1G                           \
     -drive file=$VDISK_FILENAME     \
     -cdrom grub-img.iso             \
     -boot order=c,once=d,menu=on    \
     -net nic,netdev=net0            \
     -netdev user,id=net0            \
     -device ac97                    \
     -vga std                        \
     -serial mon:stdio               \
     -name "fedora-16"

Meaning of the command line options

-enable-kvm: enable full KVM virtualization support. On some hardware, it may be necessary to add the undocumented -machine smm=off option in order to enable KVM.

-smp <N>: enable symmetric multiprocessing with <N> CPUs.

-cpu <model>: simulate CPU <model>. the list of supported models can be obtained with -cpu help.

-drive file=<filename>: defines a virtual disk whose image is stored in <filename>.

-cdrom grub-img.iso: defines an iso formated file to use as a cdrom. Here we use a grub rescue disk, which may turn handy when something goes wrong at boot time.

-boot order=c,once=d,menu=on: defines the boot order for the virtual BIOS.

-net nic,netdev=<netid>: defines a network card connected to the network device with id <netid>.

-netdev user,id=<netid>: defines the network user device. This is a virtual local network with addresses 10.0.2.0/24, where the host has address 10.0.2.2 and acts as a gateway to internet, and with a name server at address 10.0.2.3, and an smb server at address 10.0.2.4. A builtin DHCP server can allocate addresses between 10.0.2.15 and 10.0.2.31.

-soundhw <model>: defines the soundcard model. The list may be obtained with -soundhw help.

-vga <type>: defines the type of vga card to emulate.

-serial mon:stdio: sends the serial port of the guest (/dev/ttyS0 on linux guests), multiplexed with the qemu monitor, to the standard input and output of the qemu process.

-name <name>: sets the name of the guest. This name is displayed in the guest window caption. It may be useful if you run several guests at the same time.

Controlling the Emulated Display

It may happen that the guest window displayed by qemu does not correspond to the full capability of the emulated vga card. For example, the vmware card is 1600x900 capable, but only 1024x768 is displayed by default. A suitable Xorg configuration on the guest allows to use the full size (Note that the Xorg video driver to use is Xorg VMware Driver-13.3.0):

cat > /usr/share/X11/xorg.conf.d/20-vmware.conf << "EOF"
Section         "Monitor"
  Identifier    "Monitor0"
  # cvt 1600 900
  # 1600x900 59.95 Hz (CVT 1.44M9) hsync: 55.99 kHz; pclk: 118.25 MHz
  Modeline      "1600x900"  118.25  1600 1696 1856 2112  900 903 908 934 -hsync +vsync
  Option        "PreferredMode" "1600x900"
  HorizSync     1-200
  VertRefresh   1-200
EndSection

Section         "Device"
  Identifier    "VMware SVGA II Adapter"
  Option        "Monitor" "default"
  Driver        "vmware"
EndSection

Section         "Screen"
  Identifier    "Default Screen"
  Device        "VMware SVGA II Adapter"
  Monitor       "Monitor0"

  SubSection    "Display"
    Depth       24
    Modes       "1600x900" "1440x900" "1366x768" "1280x720" "800x480"
  EndSubSection

EndSection
EOF

New sizes will be available besides the native ones. You need to restart X in order to have the new sizes available.

Networking

The below solution for networking allows the guest to access the local network through the host (and possibly to access internet through the local routers), but the converse is not true. Not even the host can access the guest, unless port forwarding is enabled. And in the case several guests are running, they cannot communicate with each other. Other network devices can be used for this purpose. For example, there is the socket device, which allows several guests to share a common virtual network. In the following, we describe in more details how to set up the bridge device, which allows the guests to appear as if connected to the local network. All the commands below should be run as the root user.

Set up bridging with bridge-utils-1.7.1. Only the physical interface(s) should be set up at boot. The virtual interface(s) will be added as needed when qemu is started.

Set up a required configuration file:

install -vdm 755 /etc/qemu &&
echo allow br0 > /etc/qemu/bridge.conf

In the command above, replace the switch -netdev user,... with -netdev bridge,id=net0.

Contents

Installed Programs: elf2dmp, qemu (symlink), qemu-edid, qemu-ga, qemu-img, qemu-io, qemu-keymap, qemu-nbd, qemu-pr-helper, qemu-storage-daemon, and qemu-system-<arch>
Installed Library: None
Installed Directories: /usr/share/qemu and /usr/share/doc/qemu-6.2.0 (optional)

Short Description

elf2dmp

Converts files from elf to dmp format

qemu-edid

is a test tool for the qemu EDID generator

qemu-ga

implements support for QMP (QEMU Monitor Protocol) commands and events that terminate and originate respectively within the guest using an agent built as part of QEMU

qemu-img

provides commands to manage QEMU disk images

qemu-io

is a diagnostic and manipulation program for (virtual) memory media. It is still at an early stage of development

qemu-keymap

generates qemu reverse keymaps from xkb keymaps, which can be used with the qemu "-k" command line switch

qemu-nbd

exports Qemu disk images using the QEMU Disk Network Block Device (NBD) protocol

qemu-pr-helper

Implements the persistent reservation helper for QEMU

qemu-storage-daemon

allows to modify disk images using the QEMU Monitor Protocol (QMP) without running a VM

qemu-system-x86_64

is the QEMU PC System emulator

Last updated on

Part III. General Libraries and Utilities

Chapter 9. General Libraries

Libraries contain code which is often required by more than one program. This has the advantage that each program doesn't need to duplicate code (and risk introducing bugs), it just has to call functions from the libraries installed on the system. The most obvious example of a set of libraries is Glibc which is installed during the LFS book. This contains all of the C library functions which programs use.

There are two types of libraries: static and shared. Shared libraries (usually libXXX.so) are loaded into memory from the shared copy at runtime (hence the name). Static libraries ( libXXX.a) are actually linked into the program executable file itself, thus making the program file larger. Quite often, you will find both static and shared copies of the same library on your system.

Generally, you only need to install libraries when you are installing software that needs the functionality they supply. In the BLFS book, each package is presented with a list of (known) dependencies. Thus, you can figure out which libraries you need to have before installing that program. If you are installing something without using BLFS instructions, usually the README or INSTALL file will contain details of the program's requirements.

There are certain libraries which nearly everyone will need at some point. In this chapter these and some others are listed and it is explained why you may want to install them.

Apr-1.7.0

Introduction to Apr

The Apache Portable Runtime (APR) is a supporting library for the Apache web server. It provides a set of application programming interfaces (APIs) that map to the underlying Operating System (OS). Where the OS doesn't support a particular function, APR will provide an emulation. Thus programmers can use the APR to make a program portable across different platforms.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/apr

Installation of Apr

First, fix a security issue:

sed -e "/shift/i \
\    if (xt->tm_mon < 0 || xt->tm_mon >= 12) return APR_EBADDATE;" \
    -i time/unix/time.c

Install Apr by running the following commands:

./configure --prefix=/usr    \
            --disable-static \
            --with-installbuilddir=/usr/share/apr-1/build &&
make

To test the results, issue: make test.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Program: apr-1-config
Installed Library: libapr-1.so
Installed Directories: /usr/include/apr-1 and /usr/share/apr-1

Short Descriptions

apr-1-config

is a shell script used to retrieve information about the apr library in the system. It is typically used to compile and link against the library

libapr-1.so

is the Apache Portable Runtime library

Last updated on

Apr-Util-1.6.1

Introduction to Apr Util

The Apache Portable Runtime Utility Library provides a predictable and consistent interface to underlying client library interfaces. This application programming interface assures predictable if not identical behaviour regardless of which libraries are available on a given platform.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Apr Util Dependencies

Required

Apr-1.7.0

Optional

Berkeley DB-5.3.28, FreeTDS, MariaDB-10.6.7 or MySQL, OpenLDAP-2.6.1, PostgreSQL-14.2, SQLite-3.37.2 and unixODBC-2.3.9

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/apr-util

Installation of Apr Util

Install Apr Util by running the following commands:

./configure --prefix=/usr       \
            --with-apr=/usr     \
            --with-gdbm=/usr    \
            --with-openssl=/usr \
            --with-crypto &&
make

To test the results, issue: make -j1 test. One test, testdbm, is known to fail.

Now, as the root user:

make install

Command Explanations

--with-gdbm=/usr: This switch enables the apr_dbm_gdbm-1.so plugin.

--with-openssl=/usr --with-crypto: These switches enable the apr_crypto_openssl-1.so plugin.

--with-berkeley-db=/usr: If you have installed Berkeley DB-5.3.28, use this switch to compile the apr_dbm_db-1.so plugin.

--with-ldap: If you have installed OpenLDAP-2.6.1, use this switch to compile the apr_ldap.so plugin.

Contents

Installed Program: apu-1-config
Installed Library: libaprutil-1.so
Installed Directory: /usr/lib/apr-util-1

Short Descriptions

apu-1-config

is an APR-util script designed to allow easy command line access to APR-util configuration parameters

libaprutil-1.so

contains functions that provide a predictable and consistent interface to underlying client library interfaces

Last updated on

Aspell-0.60.8

Introduction to Aspell

The Aspell package contains an interactive spell checking program and the Aspell libraries. Aspell can either be used as a library or as an independent spell checker.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

You'll need to download at least one dictionary. The link below will take you to a page containing links to dictionaries in many languages.

Aspell Dependencies

Required

Which-2.21 (for the dictionaries)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/aspell

Installation of Aspell

Install Aspell by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&
ln -svfn aspell-0.60 /usr/lib/aspell &&

install -v -m755 -d /usr/share/doc/aspell-0.60.8/aspell{,-dev}.html &&

install -v -m644 manual/aspell.html/* \
    /usr/share/doc/aspell-0.60.8/aspell.html &&

install -v -m644 manual/aspell-dev.html/* \
    /usr/share/doc/aspell-0.60.8/aspell-dev.html

If you do not plan to install Ispell, then copy the wrapper script ispell:

install -v -m 755 scripts/ispell /usr/bin/

If you do not plan to install Spell, then copy the wrapper script spell:

install -v -m 755 scripts/spell /usr/bin/

Command Explanations

ln -svfn aspell-0.60 /usr/lib/aspell: This command is useful for configuration of other applications, such as enchant-2.3.2.

Configuring Aspell

Configuration Information

After Aspell is installed, you must set up at least one dictionary. Install one or more dictionaries by running the following commands:

./configure &&
make

Now, as the root user:

make install

Contents

Installed Programs: aspell, aspell-import, precat, preunzip, prezip, prezip-bin, pspell-config, run-with-aspell, word-list-compress and optionally, ispell and spell.
Installed Libraries: libaspell.so and libpspell.so
Installed Directories: /usr/include/pspell and /usr/lib/aspell-0.60

Short Descriptions

aspell

is a utility that can function as an ispell -a replacement, as an independent spell checker, as a test utility to test out Aspell features, and as a utility for managing dictionaries

ispell

is a wrapper around aspell to invoke it in ispell compatible mode

spell

is a wrapper around aspell to invoke it in spell compatible mode

aspell-import

imports old personal dictionaries into Aspell

precat

decompresses a prezipped file to stdout

preunzip

decompresses a prezipped file

prezip

is a prefix delta compressor, used to compress sorted word lists or other similar text files

prezip-bin

is called by the various wrapper scripts to perform the actual compressing and decompressing

pspell-config

displays information about the libpspell installation, mostly for use in build scripts

run-with-aspell

is a script to help use Aspell as an ispell replacement

word-list-compress

compresses or decompresses sorted word lists for use with the Aspell spell checker

libaspell.so

contains spell checking API functions

libpspell.so

is an interface to the libaspell library. All the spell checking functionality is now in libaspell but this library is included for backward compatibility

Last updated on

Boost-1.78.0

Introduction to Boost

Boost provides a set of free peer-reviewed portable C++ source libraries. It includes libraries for linear algebra, pseudorandom number generation, multithreading, image processing, regular expressions and unit testing.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Boost Dependencies

Recommended
Optional

ICU-70.1 and Open MPI

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/boost

Installation of Boost

This package can be built with several jobs running in parallel. In the instructions below, <N> stands for the number of jobs. Install Boost by running the following commands:

./bootstrap.sh --prefix=/usr --with-python=python3 &&
./b2 stage -j<N> threading=multi link=shared

To run the Boost.Build's regression test, issue pushd tools/build/test; python3 test_all.py; popd. All 166 tests should pass.

To run every library's regression tests, issue pushd status; ../b2; popd. A few tests may fail. They take a very long time (over 119 SBU at -j4) and use a very large amount of disk space (46 GB). You should use the -jN switch to speed them up.

Note

Boost installs many versioned directories in /usr/lib/cmake. If a new version of Boost is installed over a previous version, the older cmake directories need to be explicitly removed. To do this, run as the root user:

rm -rf /usr/lib/cmake/[Bb]oost*

before installing the new version.

Now, as the root user:

./b2 install threading=multi link=shared   

Command Explanations

threading=multi: This parameter ensures that Boost is built with multithreading support.

link=shared: This parameter ensures that only shared libraries are created, except for libboost_exception and libboost_test_exec_monitor which are created as static. Most people will not need the static libraries, and most programs using Boost only use the headers. Omit this parameter if you do need static libraries.

-jN: This switch may be added to the b2 command lines, to run up to N processes in parallel.

--with-python=python3: Add this switch to the bootstrap command, if you want Boost to use Python3 instead of Python2. Using Python3 is known to cause the installation to fail on some systems.

Contents

Installed Programs: None
Installed Libraries: libboost_atomic.so, libboost_chrono.so, libboost_container.so, libboost_context.so, libboost_contract.so, libboost_coroutine.so, libboost_date_time.so, libboost_exception.a, libboost_fiber.so, libboost_filesystem.so, libboost_graph.so, libboost_iostreams.so, libboost_json.so, libboost_locale.so, libboost_log_setup.so, libboost_log.so, libboost_math_c99.so, libboost_math_c99f.so, libboost_math_c99l.so, libboost_math_tr1.so, libboost_math_tr1f.so, libboost_math_tr1l.so, libboost_nowide.so, libboost_numpy39.so, libboost_prg_exec_monitor.so, libboost_program_options.so, libboost_python310.so, libboost_random.so, libboost_regex.so, libboost_serialization.so, libboost_stacktrace_addr2line.so, libboost_stacktrace_basic.so, libboost_stacktrace_noop.so, libboost_system.so, libboost_test_exec_monitor.a, libboost_thread.so, libboost_timer.so, libboost_type_erasure.so, libboost_unit_test_framework.so, libboost_wave.so, and libboost_wserialization.so
Installed Directory: /usr/include/boost

Last updated on

brotli-1.0.9

Introduction to Brotli

Brotli provides a general-purpose lossless compression algorithm that compresses data using a combination of a modern variant of the LZ77 algorithm, Huffman coding and 2nd order context modeling. Its libraries are particularly used for WOFF2 fonts on webpages.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Brotli Dependencies

Required

CMake-3.22.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/brotli

Installation of Brotli

At first, fix an issue in pkg-config files:

sed -i 's@-R..libdir.@@' scripts/*.pc.in

Install brotli by running the following commands:

mkdir out &&
cd    out &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_BUILD_TYPE=Release  \
      ..  &&
make

To test the results, issue: make test.

If desired, build the Python3 bindings:

pushd ..               &&
python3 setup.py build &&
popd

The python tests are missing most of the necessary testdata files and therefore 240 of 311 tests fail. If you nevertheless wish to test the bindings, go back to the top-level directory and issue: python3 setup.py test.

Now, as the root user:

make install &&
cd ..

If you have built the python bindings, install them as the root user:

python3 setup.py install --optimize=1

Contents

Installed Programs: brotli
Installed Libraries: libbrotlicommon{-static.a,.so}, libbrotlidec{,-static.a,.so}, and libbrotlienc{,-static.a,.so}
Installed Directory: /usr/include/brotli

Short Descriptions

brotli

can compress or decompress files, or test the integrity of compressed files

libbrotlicommon{-static.a,.so}

is the Brotli common dictionary library

libbrotlidec{-static.a,.so}

is the Brotli decoder library

libbrotlienc{-static.a,.so}

is the Brotli common encoder library

Last updated on

CLucene-2.3.3.4

Introduction to CLucene

CLucene is a C++ version of Lucene, a high performance text search engine.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

CLucene Dependencies

Required

CMake-3.22.2

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/clucene

Installation of CLucene

Install CLucene by running the following commands:

patch -Np1 -i ../clucene-2.3.3.4-contribs_lib-1.patch &&

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DBUILD_CONTRIBS_LIB=ON .. &&
make

Now, as the root user:

make install

Command Explanations

-DBUILD_CONTRIBS_LIB=ON: This cmake variable enables building the CLucene contribs library necessary for running applications that use language specific text analyzers like LibreOffice for example.

Contents

Installed Programs: None
Installed Libraries: libclucene-contribs-lib.so, libclucene-core.so, and libclucene-shared.so
Installed Directories: /usr/include/CLucene and /usr/lib/CLuceneConfig.cmake

Last updated on

dbus-glib-0.112

Introduction to D-Bus GLib

The D-Bus GLib package contains GLib interfaces to the D-Bus API.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

D-Bus GLib Dependencies

Required

dbus-1.12.20 and GLib-2.70.4

Optional

GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/dbus-glib

Installation of D-Bus GLib

Install D-Bus GLib by running the following commands:

./configure --prefix=/usr     \
            --sysconfdir=/etc \
            --disable-static &&
make

To test the results, issue: make check. Note that more comprehensive tests can be run by following the same method used in D-Bus instructions, which requires building the package twice.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Program: dbus-binding-tool
Installed Library: libdbus-glib-1.so
Installed Directories: /usr/share/gtk-doc/html/dbus-glib

Short Descriptions

dbus-binding-tool

is a tool used to interface with the D-Bus API

libdbus-glib-1.so

contains GLib interface functions to the D-Bus API

Last updated on

Double-conversion-3.2.0

Introduction to Double-conversion

The Double-conversion package contains a library that facilitates binary-to-decimal and decimal-to-binary routines for IEEE doubles.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Double-conversion Dependencies

Required

CMake-3.22.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/double-conversion

Installation of Double-conversion

Install Double-conversion by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DBUILD_SHARED_LIBS=ON      \
      -DBUILD_TESTING=ON          \
      ..                          &&
make

To test the results, issue: make test.

Now, as the root user:

make install

Command Explanations

-DBUILD_SHARED_LIBS=ON: This switch forces cmake to build a shared version of the library instead of the static version.

-DBUILD_TESTING=ON: This switch builds the test programs.

Contents

Installed Programs: None
Installed Libraries: libdouble-conversion.so
Installed Directories: /usr/include/double-conversion

Short Descriptions

libdouble-conversion.so

provides binary-to-decimal and decimal-to-binary routines for IEEE doubles

Last updated on

enchant-2.3.2

Introduction to enchant

The enchant package provides a generic interface into various existing spell checking libraries.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

enchant Dependencies

Required

GLib-2.70.4

Recommended
Optional

dbus-glib-0.112, Doxygen-1.9.3, Hspell, Hunspell, Nuspell, Voikko, and unittest-cpp (required for tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/enchant

Installation of enchant

Install enchant by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To run tests, unittest-cpp must be installed and the --enable-relocatable option passed to configure above. If these conditions are present, the tests may be run with make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Configuring enchant

Config Files

~/.enchant and /usr/share/enchant/enchant.ordering

Configuration Information

You can test your installation and configuration by creating a test file and running the following commands (you can replace the en_GB dictionary by any other downloaded when installing Aspell-0.60.8):

cat > /tmp/test-enchant.txt << "EOF"
Tel me more abot linux
Ther ar so many commads
EOF

enchant-2 -d en_GB -l /tmp/test-enchant.txt &&
enchant-2 -d en_GB -a /tmp/test-enchant.txt

You will see a list of the misspelled words followed by a list of alternatives for them.

See more details in the enchant manual page.

Contents

Installed Programs: enchant-2 and enchant-lsmod-2
Installed Libraries: libenchant-2.so
Installed Directories: /usr/include/enchant-2, /usr/lib/enchant-2, and /usr/share/enchant

Short Descriptions

enchant-2

is a spellchecker

enchant-lsmod-2

lists available backends, languages, and dictionaries

libenchant-2.so

contains spell checking interface API functions

Last updated on

Exempi-2.6.1

Introduction to Exempi

Exempi is an implementation of XMP (Adobe's Extensible Metadata Platform).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Exempi Dependencies

Required

Boost-1.78.0

Optional

Valgrind-3.18.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/exempi

Installation of Exempi

If you intend to run the regression tests, first remove a test that depends on an apparently proprietary Adobe SDK:

sed -i -r '/^\s?testadobesdk/d' exempi/Makefile.am &&
autoreconf -fiv

Install Exempi by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Program: exempi
Installed Library: libexempi.so
Installed Directory: /usr/include/exempi-2.0

Short Descriptions

exempi

is a command line tool to manipulate XMP metadata

libexempi.so

is a library used to parse XMP metadata

Last updated on

fftw-3.3.10

Introduction to fftw

FFTW is a C subroutine library for computing the discrete Fourier transform (DFT) in one or more dimensions, of arbitrary input size, and of both real and complex data (as well as of even/odd data, i.e. the discrete cosine/sine transforms or DCT/DST).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/fftw

Installation of fftw

Note

We build fftw three times for different libraries in different numerical precisions: the default double precision floating point, the older 32-bit (single precision) version named float which sacrifices precision for speed, and the long double which offers increased precision at the cost of slower execution.

The first build is for double precision arithmetic. Install fftw by running the following commands:

./configure --prefix=/usr    \
            --enable-shared  \
            --disable-static \
            --enable-threads \
            --enable-sse2    \
            --enable-avx     &&
make

To test the results, issue: make check. On 32-bit systems, the tests can take substantially longer than they would on 64-bit machines.

Now, as the root user:

make install

Now build single precision:

make clean &&

./configure --prefix=/usr    \
            --enable-shared  \
            --disable-static \
            --enable-threads \
            --enable-sse2    \
            --enable-avx     \
            --enable-float   &&
make

As the root user:

make install

Finally, build long double precision:

make clean &&

./configure --prefix=/usr    \
            --enable-shared  \
            --disable-static \
            --enable-threads \
            --enable-long-double &&
make

As the root user:

make install

Command Explanations

--enable-shared --disable-static: Use shared libs instead of static libs.

--enable-threads: This enables libfftw3_threads.so to be compiled. It is used by e.g. the gimp plugin from G'MIC.

--enable-float: This enables building the library that uses single precision floating point arithmetic. It is faster but less precise than the default double precision library. The library will be called libfftw3f.so needed by PulseAudio-15.0.

--enable-long-double: This enables building the library that uses higher precision long-double floating point arithmetic. The library will be called libfftw3l.so.

Contents

Installed Programs: fftw-wisdom and fftw-wisdom-to-conf
Installed Libraries: libfftw3.so, libfftw3_threads.so, libfftw3f.so, libfftw3f_threads.so, libfftw3l.so and libfftw3l_threads.so
Installed Directories: None

Short Descriptions

fftw-wisdom

is a utility to generate FFTW wisdom files, which contain saved information about how to optimally compute (Fourier) transforms of various sizes

fftw-wisdom-to-conf

is a utility to generate C configuration routines from FFTW wisdom files, where the latter contain saved information about how to optimally compute (Fourier) transforms of various sizes

libfftw3.so

is the Fast Fourier Transform library

libfftw3_threads.so

is the threaded Fast Fourier Transform library

libfftw3f.so

is the single-precision Fast Fourier Transform library, described as float for historic reasons

libfftw3f_threads.so

is the threaded single-precision Fast Fourier Transform library

libfftw3l.so

is the long double Fast Fourier Transform library

libfftw3l_threads.so

is the threaded long double Fast Fourier Transform library

Last updated on

GLib-2.70.4

Introduction to GLib

The GLib package contains low-level libraries useful for providing data structure handling for C, portability wrappers and interfaces for such runtime functionality as an event loop, threads, dynamic loading and an object system.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

GLib Dependencies

Recommended
Optional

dbus-1.12.20 and bindfs (both may be used in some tests), GDB-11.2 (for bindings), docbook-xml-4.5, docbook-xsl-1.79.2, GTK-Doc-1.33.2 (to build API documentation), glib-networking-2.70.1 (for some tests, but this is a circular dependency), and sysprof-3.42.1

Additional Runtime Dependencies

Quoted directly from the INSTALL file: Some of the mimetype-related functionality in GIO requires the update-mime-database and update-desktop-database utilities, which are part of shared-mime-info-2.1 and desktop-file-utils-0.26, respectively. These two utilities are also needed for some tests.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/glib2

Installation of GLib

If desired, apply the optional patch. In many cases, applications that use this library, either directly or indirectly via other libraries such as GTK+-3.24.31, output numerous warnings when run from the command line. This patch enables the use of an environment variable, GLIB_LOG_LEVEL, that suppresses unwanted messages. The value of the variable is a digit that corresponds to:

1 Alert
2 Critical
3 Error
4 Warning
5 Notice

For instance export GLIB_LOG_LEVEL=4 will skip output of Warning and Notice messages (and Info/Debug messages if they are turned on). If GLIB_LOG_LEVEL is not defined, normal message output will not be affected.

patch -Np1 -i ../glib-2.70.4-skip_warnings-1.patch

Warning

If a previous version of glib is installed, move the headers out of the way so that later packages do not encounter conflicts:

if [ -e /usr/include/glib-2.0 ]; then
    rm -rf /usr/include/glib-2.0.old &&
    mv -vf /usr/include/glib-2.0{,.old}
fi

Install GLib by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr       \
      --buildtype=release \
      -Dman=true          \
      ..                  &&
ninja

Note

If libxslt-1.1.35 is installed, the above command may indicate several (about 33) errors that start with "Error: no ID for constraint linkend:" when generating the man pages. These are harmless.

The GLib test suite requires desktop-file-utils for some tests. However, desktop-file-utils requires GLib in order to compile; therefore, you must first install GLib and then run the test suite.

Now, as the root user:

ninja install &&

mkdir -p /usr/share/doc/glib-2.70.4 &&
cp -r ../docs/reference/{gio,glib,gobject} /usr/share/doc/glib-2.70.4

You should now install desktop-file-utils-0.26 and shared-mime-info-2.1 and proceed to run the test suite.

To test the results, after having installed the package, issue: ninja test. One test named gio / file is known to fail if the test is run as the root user.

Finally, if this is a reinstall from glib2-2.64.x or earlier, remove (as the root user) an obsolete header file that interferes with some packages:

rm -f /usr/include/glib-2.0/glib/gurifuncs.h

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dman=true: This switch causes the build to create and install the package man pages.

-Dgtk_doc=true: This switch causes the build to create and install the API documentation.

Contents

Installed Programs: gapplication, gdbus, gdbus-codegen, gio, gio-querymodules, glib-compile-resources, glib-compile-schemas, glib-genmarshal, glib-gettextize, glib-mkenums, gobject-query, gresource, gsettings, gtester, and gtester-report
Installed Libraries: libgio-2.0.so, libglib-2.0.so, libgmodule-2.0.so, libgobject-2.0.so, and libgthread-2.0.so
Installed Directories: /usr/include/gio-unix-2.0, /usr/include/glib-2.0, /usr/lib/glib-2.0, /usr/share/glib-2.0, /usr/share/doc/glib-2.70.4, and /usr/share/gtk-doc/html/{gio,glib,gobject} (optional)

Short Descriptions

gapplication

can be used to start applications and to send messages to already-running instances of other applications

gdbus

is a simple tool used for working with D-Bus objects

gdbus-codegen

is used to generate code and/or documentation for one or more D-Bus interfaces

gio

is a utility that makes many GIO features available from the command line

gio-querymodules

is used to create a giomodule.cache file in the listed directories. This file lists the implemented extension points for each module that has been found

glib-compile-resources

is used to read the resource description from a file and the files that it references to create a binary resource bundle that is suitable for use with the GResource API

glib-compile-schemas

is used to compile all the GSettings XML schema files in a directory into a binary file with the name gschemas.compiled that can be used by GSettings

glib-genmarshal

is a C code marshaller generation utility for GLib closures

glib-gettextize

is a variant of the gettext internationalization utility

glib-mkenums

is a C language enum description generation utility

gobject-query

is a small utility that draws a tree of types

gresource

offers a simple command line interface to GResource

gsettings

offers a simple command line interface to GSettings

gtester

is a test running utility

gtester-report

is a test report formatting utility

GLib libraries

contain low-level core libraries for the GIMP Toolkit

Last updated on

GLibmm-2.66.2

Introduction to GLibmm

The GLibmm package is a set of C++ bindings for GLib.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GLibmm Dependencies

Required

GLib-2.70.4 and libsigc++-2.10.8

Optional

Doxygen-1.9.3, glib-networking-2.70.1 (for tests), GnuTLS-3.7.3 (for tests), libxslt-1.1.35, and mm-common

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/glibmm

Installation of GLibmm

Install GLibmm by running the following commands:

mkdir bld &&
cd    bld &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Contents

Installed Programs: None
Installed Libraries: libgiomm-2.4.so, libglibmm-2.4.so and libglibmm_generate_extra_defs-2.4.so
Installed Directories: /usr/lib/g{io,lib}mm-2.4 and /usr/include/g{io,lib}mm-2.4

Short Descriptions

libgiomm-2.4.so

contains the GIO API classes

libglibmm-2.4.so

contains the GLib API classes

Last updated on

GMime-3.2.7

Introduction to GMime

The GMime package contains a set of utilities for parsing and creating messages using the Multipurpose Internet Mail Extension (MIME) as defined by the applicable RFCs. See the GMime web site for the RFCs resourced. This is useful as it provides an API which adheres to the MIME specification as closely as possible while also providing programmers with an extremely easy to use interface to the API functions.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GMime Dependencies

Required

GLib-2.70.4 and libgpg-error-1.44

Recommended
Optional

DocBook-utils-0.6.14, GPGME-1.17.0, GTK-Doc-1.33.2, libnsl-2.0.0, Vala-0.54.7, and Gtk# (requires Mono)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gmime

Installation of GMime

Install GMime by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Library: libgmime-3.0.so
Installed Directories: /usr/include/gmime-3.0 and /usr/share/gtk-doc/html/gmime-3.0

Short Descriptions

libgmime-3.0.so

contains API functions used by programs that need to comply to the MIME standards

Last updated on

gobject-introspection-1.70.0

Introduction to GObject Introspection

The GObject Introspection is used to describe the program APIs and collect them in a uniform, machine readable format.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

GObject Introspection Dependencies

Required

GLib-2.70.4

Optional

Cairo-1.17.4 (required for the tests), Gjs-1.70.1 (to satisfy one test), GTK-Doc-1.33.2, Mako-1.1.6, and Markdown (to satisfy one test)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gobject-introspection

Installation of GObject Introspection

First apply a patch that allows building with meson version 0.61 or above:

patch -Np1 -i ../gobject-introspection-1.70.0-build_fix-1.patch

Install GObject Introspection by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test. If Mako-1.1.6 is installed but the Python 3 module named Markdown (not in BLFS) is not, one test named test_docwriter.py will fail.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dgtk_doc=true: Build and install the documentation.

-Dcairo=enabled: Use cairo for tests.

-Ddoctool=enabled: Install g-ir-doc-tool and run related tests.

Contents

Installed Program: g-ir-annotation-tool, g-ir-compiler, g-ir-doc-tool, g-ir-generate, g-ir-inspect, and g-ir-scanner
Installed Libraries: libgirepository-1.0.so and _giscanner.cpython-310-<arch>-linux-gnu.so
Installed Directories: /usr/include/gobject-introspection-1.0, /usr/lib/girepository-1.0, /usr/lib/gobject-introspection, /usr/share/gir-1.0, and /usr/share/gobject-introspection-1.0

Short Descriptions

g-ir-annotation-tool

creates or extracts annotation data from GI typelibs

g-ir-compiler

converts one or more GIR files into one or more typelib

g-ir-doc-tool

generates Mallard files that can be viewed with yelp or rendered to HTML with yelp-build from yelp-tools

g-ir-inspect

is a utility that gives information about a GI typelib

g-ir-generate

is a GIR generator that uses the repository API

g-ir-scanner

is a tool which generates GIR XML files by parsing headers and introspecting GObject based libraries

libgirepository-1.0.so

provides an API to access the typelib metadata

Last updated on

Gsl-2.7.1

Introduction to Gsl

The GNU Scientific Library (GSL) is a numerical library for C and C++ programmers. It provides a wide range of mathematical routines such as random number generators, special functions and least-squares fitting.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Gsl Dependencies

Optional

Sphinx with sphinx_rtd_theme

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gsl

Installation of Gsl

Install Gsl by running the following commands:

./configure --prefix=/usr --disable-static &&
make

If you have the optional Sphinx package installed, buid the documentation with:

make html

To test the results, issue: make check.

Now, as the root user:

make install

If you built the documentation, install it (as root) with:

mkdir                   /usr/share/doc/gsl-2.7.1 &&
cp -R doc/_build/html/* /usr/share/doc/gsl-2.7.1

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: gsl-config, gsl-histogram, and gsl-randist
Installed Libraries: libgslcblas.so and libgsl.so
Installed Directory: /usr/include/gsl and /usr/share/doc/gsl-2.7.1

Short Descriptions

gsl-config

is a shell script to get the version number and compiler flags of the installed Gsl library

gsl-histogram

is a demonstration program for the GNU Scientific Library that computes a histogram from data taken from stdin

gsl-randist

is a demonstration program for the GNU Scientific Library that generates random samples from various distributions

libgslcblas.so

contains functions that implement a C interface to Basic Linear Algebra Subprograms

libgsl.so

contains functions that provide a collection of numerical routines for scientific computing

Last updated on

gspell-1.8.4

Introduction to gspell

The gspell package provides a flexible API to add spell checking to a GTK+ application.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

gspell Dependencies

Required

enchant-2.3.2 and GTK+-3.24.31

Optional

gobject-introspection-1.70.0, GTK-Doc-1.33.2, ISO Codes-4.9.0, Vala-0.54.7, and Valgrind-3.18.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gspell

Installation of gspell

Install gspell by running the following commands:

./configure --prefix=/usr &&
make

To test the results, issue: make check. One test, test-checker, is known to fail if the external package Hunspell is not installed. The tests also must be run in an X session.

Now, as the root user:

make install

Contents

Installed Programs: gspell-app1
Installed Libraries: libgspell-1.so
Installed Directories: /usr/include/gspell-1 and /usr/share/gtk-doc/html/gspell-1.0

Short Descriptions

gspell-app1

checks the spelling of a text entered in a window

libgspell-1.so

is the gspell API library

Last updated on

ICU-70.1

Introduction to ICU

The International Components for Unicode (ICU) package is a mature, widely used set of C/C++ libraries providing Unicode and Globalization support for software applications. ICU is widely portable and gives applications the same results on all platforms.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

ICU Dependencies

Optional

LLVM-13.0.1 (with Clang), and Doxygen-1.9.3 (for documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/icu

Installation of ICU

Note

If clang++ is available, it will be used in the mistaken belief that g++ might not support C++11, even though configure has tested for that. If using g++ there will be an unnecessary warning at the end of configure. Building with g++ also takes longer than the estimated SBU shown.

Install ICU by running the following commands:

cd source                                    &&

./configure --prefix=/usr                    &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Contents

Installed Programs: derb, escapesrc, genbrk, genccode, gencfu, gencmn, gencnval, gendict, gennorm2, genrb, gensprep, icu-config, icuexportdata, icuinfo, icupkg, makeconv, pkgdata, and uconv
Installed Libraries: libicudata.so, libicui18n.so, libicuio.so, libicutest.so, libicutu.so, and libicuuc.so
Installed Directories: /usr/include/unicode, /usr/lib/icu, and /usr/share/icu

Short Descriptions

derb

disassembles a resource bundle

escapesrc

converts \u escaped characters into unicode characters

genbrk

compiles ICU break iteration rules source files into binary data files

genccode

generates C or platform specific assembly code from an ICU data file

gencfu

reads in Unicode confusable character definitions and writes out the binary data

gencmn

generates an ICU memory-mappable data file

gencnval

compiles the converter's aliases file

gendict

compiles word lists into ICU string trie dictionaries

gennorm2

builds binary data files with Unicode normalization data

genrb

compiles a resource bundle

gensprep

compiles StringPrep data from filtered RFC 3454 files

icu-config

outputs ICU build options

icuinfo

outputs configuration information about the current ICU

icupkg

extracts or modifies an ICU .dat archive

makeconv

compiles a converter table

pkgdata

packages data for use by ICU

uconv

converts data from one encoding to another

libicudata.so

is the data library

libicui18n.so

is the internationalization (i18n) library

libicuio.so

is the ICU I/O (unicode stdio) library

libicutest.so

is the test library

libicutu.so

is the tool utility library

libicuuc.so

is the common library

Last updated on

inih-53

Introduction to inih

This package is a simple .INI file parser written in C.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/inih

Installation of inih

Install inih by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Contents

Installed Program: None
Installed Libraries: libinih.so, libINIReader.so
Installed Directories: None

Last updated on

Jansson-2.14

Introduction to Jansson

The Jansson package contains a library used to encode, decode, and manipulate JSON data.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/jansson

Installation of Jansson

First fix one of the tests:

sed -e "/DT/s;| sort;| sed 's/@@libjansson.*//' &;" \
    -i test/suites/api/check-exports

Install jansson by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Library: libjansson.so
Installed Directories: None

Short Descriptions

libjansson.so

contains an API for encoding, decoding, and manipulating JSON data

Last updated on

JS-78.15.0

Introduction to JS

JS is Mozilla's JavaScript engine written in C. JS78 is taken from Firefox.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

JS78 Dependencies

Required

Autoconf-2.13, ICU-70.1, rustc-1.58.1, and Which-2.21

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/js78

Installation of JS

Note

Unlike most other packages in BLFS, the instructions below require you to untar firefox-78.15.0esr.tar.xz and change into the firefox-78.15.0 folder.

Extracting the tarball will reset the permissions of the current directory to 0755 if you have permission to do that. If you do this in a directory where the sticky bit is set, such as /tmp it will end with error messages:

tar: .: Cannot utime: Operation not permitted
tar: .: Cannot change mode to rwxr-xr-t: Operation not permitted
tar: Exiting with failure status due to previous errors

This does finish with non-zero status, but it does NOT mean there is a real problem. Do not untar as the root user in a directory where the sticky bit is set - that will unset it.

Apply a patch to allow building this package with Python-3.10 or later:

patch -Np1 -i ../js-78.15.0-python_3_10-1.patch

Install JS by running the following commands:

Note

If you are compiling this package in chroot you must do two things. First, as the root user, ensure that /dev/shm is mounted. If you do not do this, the Python configury will fail with a traceback report referencing /usr/lib/pythonN.N/multiprocessing/synchronize.py. Run:

mountpoint -q /dev/shm || mount -t tmpfs devshm /dev/shm

Second, either as the root user export the $SHELL environment variable using export SHELL=/bin/sh or else prepend SHELL=/bin/sh when running the configure command.

Compiling the C++ code respects $MAKEFLAGS and defaults to 'j1', the rust code will use all processors.

mkdir obj &&
cd    obj &&

CC=gcc CXX=g++ \
../js/src/configure --prefix=/usr            \
                    --with-intl-api          \
                    --with-system-zlib       \
                    --with-system-icu        \
                    --disable-jemalloc       \
                    --disable-debug-symbols  \
                    --enable-readline        &&
make

To run the JS test suite, issue: make -C js/src check-jstests JSTESTS_EXTRA_ARGS="--timeout 300 --wpt=disabled". It's recommended to redirect the output into a log. More than a hundred tests fail after upgrading to icu-70.1 or above, out of a total of more than 40,000.

To run the JIT test suite, issue: make -C js/src check-jit-test JITTEST_EXTRA_ARGS="--timeout 300". One test may fail.

Caution

An issue in the installation process causes any running program which links to JS78 shared library (for example, GNOME Shell) to crash if JS78 is upgraded or reinstalled. To work around this issue, remove the old version of the JS78 shared library before installation:

rm -fv /usr/lib/libmozjs-78.so

Now, as the root user:

make install &&
rm -v /usr/lib/libjs_static.ajs &&
sed -i '/@NSPR_CFLAGS@/d' /usr/bin/js78-config

Command Explanations

CC=gcc CXX=g++: Upstream now prefers clang, override it like other Mozilla packages in BLFS book.

--with-*: These parameters allow the build system to use system versions of the above libraries. These are required for stability.

--enable-readline: This switch enables Readline support in the JS shell.

--disable-jemalloc: This switch disables the internal memory allocator used in JS78. jemalloc is only intended for the Firefox browser environment. For other applications using JS78, if JS78 uses jemalloc, the application may crash as items allocated in jemalloc allocator are freed on system (glibc) allocator.

--disable-debug-symbols: Don't generate debug symbols since they are very large and most users won't need it. Remove it if you want to debug JS78.

rm -v /usr/lib/libjs_static.ajs: Remove a large static library which is not used by any BLFS package.

sed -i '/@NSPR_CFLAGS@/d' /usr/bin/js78-config: Prevent js78-config from using buggy CFLAGS.

Contents

Installed Programs: js78 and js78-config
Installed Libraries: libmozjs-78.so
Installed Directories: /usr/include/mozjs-78

Short Descriptions

js78

provides a command line interface to the JavaScript engine

js78-config

is used to find the JS compiler and linker flags

libmozjs-78.so

contains the Mozilla JavaScript API functions

Last updated on

JSON-C-0.15

Introduction to JSON-C

The JSON-C implements a reference counting object model that allows you to easily construct JSON objects in C, output them as JSON formatted strings and parse JSON formatted strings back into the C representation of JSON objects.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

JSON-C Dependencies

Required

CMake-3.22.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/json-c

Installation of JSON-C

Install JSON-C by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_BUILD_TYPE=Release \
      -DBUILD_STATIC_LIBS=OFF    \
      .. &&
make

To test the results, issue: make test.

Now, as the root user:

make install

Command Explanations

-DCMAKE_BUILD_TYPE=Release: This switch is used to apply a higher level of compiler optimizations.

Contents

Installed Programs: None
Installed Libraries: libjson-c.so
Installed Directories: /usr/include/json-c

Short Descriptions

libjson-c.so

contains the JSON-C API functions

Last updated on

JSON-GLib-1.6.6

Introduction to JSON GLib

The JSON GLib package is a library providing serialization and deserialization support for the JavaScript Object Notation (JSON) format described by RFC 4627.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

JSON-GLib Dependencies

Required

GLib-2.70.4

Optional (Required if building GNOME)

gobject-introspection-1.70.0

Optional

GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/json-glib

Installation of JSON GLib

Install JSON GLib by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: json-glib-format and json-glib-validate
Installed Library: libjson-glib-1.0.so
Installed Directories: /usr/{include,share/installed-tests}/json-glib-1.0, /usr/libexec/installed-tests/json-glib-1.6.6, and /usr/share/gtk-doc/html/json-glib

Short Descriptions

json-glib-format

is a simple command line interface to format JSON data

json-glib-validate

is a simple command line interface to validate JSON data

libjson-glib-1.0.so

contains the JSON GLib API functions

Last updated on

keyutils-1.6.1

Introduction to keyutils

Keyutils is a set of utilities for managing the key retention facility in the kernel, which can be used by filesystems, block devices and more to gain and retain the authorization and encryption keys required to perform secure operations.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

keyutils Dependencies

Required

MIT Kerberos V5-1.19.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/keyutils

Installation of keyutils

Install keyutils by running the following commands:

sed -i 's:$(LIBDIR)/$(PKGCONFIG_DIR):/usr/lib/pkgconfig:' Makefile &&
make

To test the results, issue, as the root user:

make -k test

Note that several tests will fail if certain uncommon kernel options were not used when the kernel was built. These include CONFIG_BIG_KEYS, CONFIG_KEY_DH_OPERATIONS, and CONFIG_CRYPTO_DH.

Now, as the root user:

make NO_ARLIB=1 LIBDIR=/usr/lib BINDIR=/usr/bin SBINDIR=/usr/sbin install

Command Explanations

sed ... Makefile: This command ensures the pkgconfig file is placed in the correct directory.

NO_ARLIB=1: This make flag disables installing the static library.

Configuring keyutils

Config Files

/etc/request-key.conf and /etc/request-key.d/*

Contents

Installed Programs: keyctl, key.dns_resolver, and request-key
Installed Library: libkeyutils.so
Installed Directory: /etc/request-key.d and /usr/share/keyutils

Short Descriptions

keyctl

controls the key management facility with a variety of subcommands

key.dns_resolver

is invoked by request-key on behalf of the kernel when kernel services (such as NFS, CIFS and AFS) need to perform a hostname lookup and the kernel does not have the key cached. It is not ordinarily intended to be called directly

request-key

is invoked by the kernel when the kernel is asked for a key that it doesn't have immediately available. The kernel creates a temporary key and then calls out to this program to instantiate it. It is not intended to be called directly

libkeyutils.so

contains the keyutils library API instantiation

Last updated on

libaio-0.3.112

Introduction to libaio

The libaio package is an asynchronous I/O facility ("async I/O", or "aio") that has a richer API and capability set than the simple POSIX async I/O facility. This library, libaio, provides the Linux-native API for async I/O. The POSIX async I/O facility requires this library in order to provide kernel-accelerated async I/O capabilities, as do applications which require the Linux-native async I/O API.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libaio

Installation of libaio

First, disable the installation of the static library:

sed -i '/install.*libaio.a/s/^/#/' src/Makefile

Build libaio by running the following command:

make

If you want to run the testsuite, fix an issue with Glibc-2.34 or later:

sed 's/-Werror//' -i harness/Makefile

To test the results, issue: make partcheck.

Now, install the package as the root user:

make install

Contents

Installed Programs: None
Installed Library: libaio.so
Installed Directories: None

Short Descriptions

libaio.so

is the libaio library

Last updated on

libarchive-3.6.0

Introduction to libarchive

The libarchive library provides a single interface for reading/writing various compression formats.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libarchive Dependencies

Optional

libxml2-2.9.13, LZO-2.10, and Nettle-3.7.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libarchive

Installation of libarchive

First, fix a bug caused by a behavior change in OpenSSL-3:

sed -i '436a if ((OSSL_PROVIDER_load(NULL, "legacy")) == NULL) \
      return (ARCHIVE_FAILED);' libarchive/archive_digest.c

Install libarchive by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: LC_ALL=C make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--without-xml2: This switch sets expat for xar archive format support instead of preferred libxml2 if both packages are installed.

--without-nettle: This switch sets OpenSSL for crypto support instead of preferred Nettle if both packages are installed.

Contents

Installed Programs: bsdcat, bsdcpio, and bsdtar
Installed Libraries: libarchive.so
Installed Directories: None

Short Descriptions

bsdcat

expands files to standard output

bsdcpio

is a tool similar to cpio

bsdtar

is a tool similar to GNU tar

libarchive.so

is a library that can create and read several streaming archive formats

Last updated on

libassuan-2.5.5

Introduction to libassuan

The libassuan package contains an inter process communication library used by some of the other GnuPG related packages. libassuan's primary use is to allow a client to interact with a non-persistent server. libassuan is not, however, limited to use with GnuPG servers and clients. It was designed to be flexible enough to meet the demands of many transaction based environments with non-persistent servers.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libassuan Dependencies

Required

libgpg-error-1.44

Optional

texlive-20210325 (or install-tl-unx)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libassuan

Installation of libassuan

Install libassuan by running the following commands:

./configure --prefix=/usr &&
make                      &&

make -C doc html                                                       &&
makeinfo --html --no-split -o doc/assuan_nochunks.html doc/assuan.texi &&
makeinfo --plaintext       -o doc/assuan.txt           doc/assuan.texi

The above commands build the documentation in html and plaintext formats. If you wish to build alternate formats of the documentation, you must have texlive-20210325 installed and issue the following commands:

make -C doc pdf ps

To test the results, issue: make check.

Now, as the root user:

make install &&

install -v -dm755   /usr/share/doc/libassuan-2.5.5/html &&
install -v -m644 doc/assuan.html/* \
                    /usr/share/doc/libassuan-2.5.5/html &&
install -v -m644 doc/assuan_nochunks.html \
                    /usr/share/doc/libassuan-2.5.5      &&
install -v -m644 doc/assuan.{txt,texi} \
                    /usr/share/doc/libassuan-2.5.5

If you built alternate formats of the documentation, install them by running the following commands as the root user:

install -v -m644  doc/assuan.{pdf,ps,dvi} \
                  /usr/share/doc/libassuan-2.5.5

Contents

Installed Program: libassuan-config
Installed Library: libassuan.so
Installed Directory: /usr/share/doc/libassuan-2.5.5

Short Descriptions

libassuan-config

is a libassuan build information script

libassuan.so

is an inter process communication library which implements the Assuan protocol

Last updated on

libatasmart-0.19

Introduction to libatasmart

The libatasmart package is a disk reporting library. It only supports a subset of the ATA S.M.A.R.T. functionality.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libatasmart

Installation of libatasmart

Install libatasmart by running the following commands:

./configure --prefix=/usr --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make docdir=/usr/share/doc/libatasmart-0.19 install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: skdump and sktest
Installed Library: libatasmart.so
Installed Directory: /usr/share/doc/libatasmart-0.19

Short Descriptions

skdump

is a utility that reports on the status of the disk

sktest

is a utility to issue disks tests

libatasmart.so

contains the ATA S.M.A.R.T API functions

Last updated on

libatomic_ops-7.6.12

Introduction to libatomic_ops

libatomic_ops provides implementations for atomic memory update operations on a number of architectures. This allows direct use of these in reasonably portable code. Unlike earlier similar packages, this one explicitly considers memory barrier semantics, and allows the construction of code that involves minimum overhead across a variety of architectures.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libatomic_ops

Installation of libatomic_ops

Install libatomic_ops by running the following commands:

./configure --prefix=/usr    \
            --enable-shared  \
            --disable-static \
            --docdir=/usr/share/doc/libatomic_ops-7.6.12 &&
make

To check the results, issue make check.

Now, as the root user:

make install

Command Explanations

--enable-shared: This switch enables building of the libatomic_ops shared libraries.

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Libraries: libatomic_ops.so and libatomic_ops_gpl.so
Installed Directory: /usr/include/libatomic_ops and /usr/share/doc/libatomic_ops-7.6.12

Short Descriptions

libatomic_ops.so

contains functions for atomic memory operations

Last updated on

libblockdev-2.26

Introduction to libblockdev

libblockdev is a C library supporting GObject Introspection for manipulation of block devices. It has a plugin-based architecture where each technology (like LVM, Btrfs, MD RAID, Swap,...) is implemented in a separate plugin, possibly with multiple implementations (e.g. using LVM CLI or the new LVM DBus API).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libblockdev Dependencies

Required

gobject-introspection-1.70.0, libbytesize-2.6, libyaml-0.2.5, parted-3.4, and volume_key-0.3.12

Optional

btrfs-progs-5.16.2, GTK-Doc-1.33.2, mdadm-4.2, dmraid, bcachefs, and ndctl

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libblockdev

Installation of libblockdev

Install libblockdev by running the following commands:

./configure --prefix=/usr     \
            --sysconfdir=/etc \
            --with-python3    \
            --without-gtk-doc \
            --without-nvdimm  \
            --without-dm      &&
make

This package does not come with a working test suite.

Now, as the root user:

make install

Contents

Installed Programs: lvm-cache-stats
Installed Libraries: libbd_btrfs.so, libbd_crypto.so, libbd_fs.so, libbd_kbd.so, libbd_loop.so, libbd_lvm.so, libbd_lvm-dbus.so, libbd_mdraid.so, libbd_mpath.so, libbd_part.so, libbd_part_err.so, libbd_swap.so, libbd_utils.so, libbd_vdo.so, and libblockdev.so
Installed Directories: /etc/libblockdev, /usr/include/blockdev, and /usr/share/gtk-doc/html/libblockdev

Short Descriptions

lvm-cache-stats

prints statistics on caches on LVM Logical Volumes

Last updated on

libbytesize-2.6

Introduction to libbytesize

The libbytesize package is a library which facilitates the common operations with sizes in bytes.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libbytesize Dependencies

Required

pcre2-10.39 and Pygments-2.11.2

Optional

GTK-Doc-1.33.2, six-1.16.0 (needed for tests and python bindings), pocketlint (python module for one test), and polib (python module for one test)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libbytesize

Installation of libbytesize

Install libbytesize by running the following commands:

./configure --prefix=/usr &&
make

If you have the optional python modules installed, the regression tests can be run with: make check.

Now, as the root user:

make install

Contents

Installed Programs: bscalc
Installed Library: libbytesize.so
Installed Directories: /usr/include/bytesize, /usr/share/gtk-doc/html/libbytesize, and /usr/lib/python3.10/site-packages/bytesize

Short Descriptions

bscalc

converts from a larger unit, such as MB or TB, back to a value in bytes

libbytesize.so

contains functions used to handle common read/write operations with sizes in bytes

Last updated on

libdaemon-0.14

Introduction to libdaemon

The libdaemon package is a lightweight C library that eases the writing of UNIX daemons.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libdaemon Dependencies

Optional

Doxygen-1.9.3 and Lynx-2.8.9rel.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libdaemon

Installation of libdaemon

Install libdaemon by running the following commands:

./configure --prefix=/usr --disable-static &&
make

If you have Doxygen installed and wish to build the API documentation, issue the following command:

make -C doc doxygen

This package does not come with a test suite.

Now, as the root user:

make docdir=/usr/share/doc/libdaemon-0.14 install

If you built the API documentation, install it using the following commands as the root user:

install -v -m755 -d /usr/share/doc/libdaemon-0.14/reference/html &&
install -v -m644 doc/reference/html/* /usr/share/doc/libdaemon-0.14/reference/html &&
install -v -m644 doc/reference/man/man3/* /usr/share/man/man3

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Library: libdaemon.so
Installed Directories: /usr/include/libdaemon and /usr/share/doc/libdaemon-0.14

Short Descriptions

libdaemon.so

contains the libdaemon API functions

Last updated on

libgcrypt-1.10.0

Introduction to libgcrypt

The libgcrypt package contains a general purpose crypto library based on the code used in GnuPG. The library provides a high level interface to cryptographic building blocks using an extendable and flexible API.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libgcrypt Dependencies

Required

libgpg-error-1.44

Optional

Pth-2.0.7 and texlive-20210325 (or install-tl-unx)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libgcrypt

Installation of libgcrypt

Install libgcrypt by running the following commands:

./configure --prefix=/usr &&
make                      &&

make -C doc html                                                       &&
makeinfo --html --no-split -o doc/gcrypt_nochunks.html doc/gcrypt.texi &&
makeinfo --plaintext       -o doc/gcrypt.txt           doc/gcrypt.texi

The above commands build the documentation in html and plaintext formats. If you wish to build alternate formats of the documentation, you need texlive-20210325 (or install-tl-unx). Issue the following command:

make -C doc pdf ps

To test the results, issue: make check.

Now, as the root user:

make install &&
install -v -dm755   /usr/share/doc/libgcrypt-1.10.0 &&
install -v -m644    README doc/{README.apichanges,fips*,libgcrypt*} \
                    /usr/share/doc/libgcrypt-1.10.0 &&

install -v -dm755   /usr/share/doc/libgcrypt-1.10.0/html &&
install -v -m644 doc/gcrypt.html/* \
                    /usr/share/doc/libgcrypt-1.10.0/html &&
install -v -m644 doc/gcrypt_nochunks.html \
                    /usr/share/doc/libgcrypt-1.10.0      &&
install -v -m644 doc/gcrypt.{txt,texi} \
                    /usr/share/doc/libgcrypt-1.10.0

If you built alternate formats of the documentation, install them by issuing the following command as the root user:

install -v -m644 doc/gcrypt.{pdf,ps,dvi} \
                    /usr/share/doc/libgcrypt-1.10.0

Command Explanations

--with-capabilities: This option enables libcap2 support. Note that this breaks cryptsetup-2.4.3

Contents

Installed Programs: dumpsexp, hmac256, libgcrypt-config, and mpicalc
Installed Library: libgcrypt.so
Installed Directory: /usr/share/doc/libgcrypt-1.10.0

Short Descriptions

dumpsexp

is a debug tool for S-expressions

hmac256

is a standalone HMAC-SHA-256 implementation used to compute an HMAC-SHA-256 authentication code

libgcrypt-config

determines the compile and linker flags that should be used to compile and link programs that use libgcrypt

mpicalc

is a RPN (Reverse Polish Notation) calculator

libgcrypt.so

contains the cryptographic API functions

Last updated on

libgpg-error-1.44

Introduction to libgpg-error

The libgpg-error package contains a library that defines common error values for all GnuPG components.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libgpg-error

Installation of libgpg-error

Install libgpg-error by running the following commands:

./configure --prefix=/usr &&
make

To test the results, issue: make check.

Now, as the root user:

make install &&
install -v -m644 -D README /usr/share/doc/libgpg-error-1.44/README

Contents

Installed Programs: gpg-error, gpg-error-config, gpgrt-config, and yat2m
Installed Library: libgpg-error.so
Installed Directories: /usr/share/common-lisp/source/gpg-error, /usr/share/libgpg-error, and /usr/share/doc/libgpg-error-1.44

Short Descriptions

gpg-error

is used to determine libgpg-error error codes

gpg-error-config

is a utility used to configure and build applications based on the libgpg-error library. It can be used to query the C compiler and linker flags which are required to correctly compile and link the application against the libgpg-error library

gpgrt-config

is the same script as gpg-error-config

yat2m

extracts man pages from a Texinfo source

libgpg-error.so

contains the libgpg-error API functions

Last updated on

libgrss-0.7.0

Introduction to libgrss

The libgrss package contains a library designed to manipulate RSS and Atom feeds.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

libgrss Dependencies

Required

libsoup-2.74.2

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libgrss

Installation of libgrss

Install libgrss by running the following commands:

patch -Np1 -i ../libgrss-0.7.0-bugfixes-2.patch &&
autoreconf -fv &&
./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Library: libgrss.so
Installed Directories: /usr/include/libgrss and /usr/share/doc/libgrss-0.7.0

Short Descriptions

libgrss.so

provides API functions for handling RSS feeds

Last updated on

libgsf-1.14.48

Introduction to libgsf

The libgsf package contains a library used for providing an extensible input/output abstraction layer for structured file formats.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libgsf Dependencies

Required

GLib-2.70.4 and libxml2-2.9.13

Recommended
Optional

gobject-introspection-1.70.0 and GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libgsf

Installation of libgsf

Install libgsf by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: gsf, gsf-office-thumbnailer, and gsf-vba-dump
Installed Library: libgsf-1.so
Installed Directories: /usr/include/libgsf-1, /usr/share/gtk-doc/html/gsf and /usr/share/thumbnailers

Short Descriptions

gsf

is a simple archive utility, somewhat similar to tar(1)

gsf-office-thumbnailer

is used internally by GNOME applications such as Nautilus to generate thumbnails of several types of office application files

gsf-vba-dump

is used to extract Visual Basic for Applications macros from files

libgsf-1.so

contains the libgsf API functions

Last updated on

libgudev-237

Introduction to libgudev

The libgudev package contains GObject bindings for libudev.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Required

GLib-2.70.4

Optional

gobject-introspection-1.70.0 (for gir-data, needed for GNOME), GTK-Doc-1.33.2, and umockdev-0.17.6 (for testing)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libgudev

Installation of libgudev

Install libgudev by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dgtk_doc=true: Use this option if GTK-Doc is installed and you wish to build and install the API documentation.

Contents

Installed Program: None
Installed Libraries: libgudev-1.0.so
Installed Directories: /usr/include/gudev-1.0 and /usr/share/gtk-doc/html/gudev

Short Descriptions

libgudev-1.0.so

is a GObject-based wrapper library for libudev

Last updated on

libgusb-0.3.10

Introduction to libgusb

The libgusb package contains the GObject wrappers for libusb-1.0 that makes it easy to do asynchronous control, bulk and interrupt transfers with proper cancellation and integration into a mainloop.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libgusb Dependencies

Required

libusb-1.0.25

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libgusb

Installation of libgusb

Install libgusb by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release -Ddocs=false .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Ddocs=true: Use this option if GTK-Doc is installed and you wish to install the documentation.

Contents

Installed Programs: gusbcmd
Installed Library: libgusb.so
Installed Directories: /usr/include/gusb-1 and /usr/share/gtk-doc/html/gusb (if gtk-doc is used)

Short Descriptions

gusbcmd

is a debugging tool for the libgusb library

libgusb.so

contains the libgusb API functions

Last updated on

libical-3.0.14

Introduction to libical

The libical package contains an implementation of the iCalendar protocols and data formats.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libical Dependencies

Required

CMake-3.22.2

Recommended
Optional

Berkeley DB-5.3.28, Doxygen-1.9.3 (for the API documentation), Graphviz-2.50.0 (for the API documentation), GTK-Doc-1.33.2 (for the API documentation), ICU-70.1, and PyGObject-3.42.0 (for some tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libical

Installation of libical

Install libical by running the following commands:

Note

This package may occasionally fail when building with multiple processors. See Using Multiple Processors for more information.

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr  \
      -DCMAKE_BUILD_TYPE=Release   \
      -DSHARED_ONLY=yes            \
      -DICAL_BUILD_DOCS=false      \
      -DGOBJECT_INTROSPECTION=true \
      -DICAL_GLIB_VAPI=true        \
      .. &&
make -j1

If you have Doxygen-1.9.3, Graphviz-2.50.0, and GTK-Doc-1.33.2 installed and wish to build the API documentation, you should remove the -DICAL_BUILD_DOCS=false switch and issue:

make docs

To test the results, issue: make test.

Now, as the root user:

make install

If you have built the API documentation, install by issuing, as root user:

install -vdm755 /usr/share/doc/libical-3.0.14/html &&
cp -vr apidocs/html/* /usr/share/doc/libical-3.0.14/html

Command Explanations

-DCMAKE_BUILD_TYPE=Release: This switch is used to apply higher level of the compiler optimizations.

-DSHARED_ONLY=yes: This switch is used in order to only build the shared libraries.

-DICAL_BUILD_DOCS=false: This switch prevents building the GTK documentation. Remove if you want to build the documentation.

-DGOBJECT_INTROSPECTION=true: This switch is used to generate GObject metadata bindings.

-DICAL_GLIB_VAPI=true: This switch is used in order to build bindings for Vala-0.54.7.

-DUSE_BUILTIN_TZDATA=yes: This switch is used in order to build using your own timezone data.

Contents

Installed Programs: None
Installed Libraries: libical_cxx.so, libical.so, libical-glib.so, libicalss_cxx.so, libicalss.so, and libicalvcal.so
Installed Directory: /usr/include/libical, /usr/include/libical-glib, /usr/lib/cmake/LibIcal, /usr/libexec/libical, /usr/share/gtk-doc/html/libical-glib (optional), and /usr/share/doc/libical-3.0.14/html

Short Descriptions

libical.so

contains the libical API functions

libical_cxx.so

contains the libical C++ bindings

libical-glib.so

contains the libical glib bindings

libicalss.so

is a library that allows you to store iCal component data to disk in a variety of ways

libicalss_cxx.so

contains the libicalss C++ bindings

libicalvcal.so

is a vCard/vCalendar C interface

Last updated on

libidn-1.38

Introduction to libidn

libidn is a package designed for internationalized string handling based on the Stringprep, Punycode and IDNA specifications defined by the Internet Engineering Task Force (IETF) Internationalized Domain Names (IDN) working group, used for internationalized domain names. This is useful for converting data from the system's native representation into UTF-8, transforming Unicode strings into ASCII strings, allowing applications to use certain ASCII name labels (beginning with a special prefix) to represent non-ASCII name labels, and converting entire domain names to and from the ASCII Compatible Encoding (ACE) form.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libidn Dependencies

Optional

Pth-2.0.7, Emacs-27.2, GTK-Doc-1.33.2, OpenJDK-17.0.2, Valgrind-3.18.1, and Mono

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libidn

Installation of libidn

Install libidn by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, run:

pushd tests  &&
  make check &&
popd 

Now, as the root user:

make install &&

find doc -name "Makefile*" -delete            &&
rm -rf -v doc/{gdoc,idn.1,stamp-vti,man,texi} &&
mkdir -v       /usr/share/doc/libidn-1.38     &&
cp -r -v doc/* /usr/share/doc/libidn-1.38

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Program: idn
Installed Library: libidn.so
Installed Directories: /usr/share/doc/libidn-1.38 and /usr/share/gtk-doc/html/libidn

Short Descriptions

idn

is a command line interface to the internationalized domain name library

libidn.so

contains a generic Stringprep implementation that does Unicode 3.2 NFKC normalization, mapping and prohibition of characters, and bidirectional character handling. Profiles for Nameprep, iSCSI, SASL and XMPP are included as well as support for Punycode and ASCII Compatible Encoding (ACE) via IDNA. A mechanism to define Top-Level Domain (TLD) specific validation tables, and to compare strings against those tables, as well as default tables for some TLDs are included

Last updated on

libidn2-2.3.2

Introduction to libidn2

libidn2 is a package designed for internationalized string handling based on standards from the Internet Engineering Task Force (IETF)'s IDN working group, designed for internationalized domain names.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libidn2 Dependencies

Required

libunistring-1.0

Optional

git-2.35.1 and GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libidn2

Installation of libidn2

Install libidn2 by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Program: idn2
Installed Library: libidn2.so
Installed Directory: /usr/share/gtk-doc/html/libidn2

Short Descriptions

idn2

is a command line interface to the internationalized domain library

libidn2.so

contains a generic Stringprep implementation used for internationalized string handling

Last updated on

libiodbc-3.52.15

Introduction to libiodbc

libiodbc is an API to ODBC compatible databases.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libiodbc Dependencies

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libiodbc

Installation of libiodbc

Install libiodbc by running the following commands:

./configure --prefix=/usr                   \
            --with-iodbc-inidir=/etc/iodbc  \
            --includedir=/usr/include/iodbc \
            --disable-libodbc               \
            --disable-static                &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--with-iodbc-inidir=/etc/iodbc: libiodbc will install configuration files in this directory.

--includedir=/usr/include/iodbc: This installs the interface headers to a private directory to avoid a conflict with headers installed by unixODBC.

--disable-libodbc: This prevents the installation of the libodbc.so symbolic link to avoid a conflict with unixODBC.

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: iodbc-config, iodbctest, iodbctestw, and iodbcadm-gtk
Installed Libraries: libdrvproxy.so, libiodbc.so, libiodbcinst.so, and libiodbcadm.so
Installed Directory: /usr/include/iodbc, /usr/share/libiodbc, and /etc/iodbc

Short Descriptions

iodbc-config

is a utility for retrieving the installation options of libiodbc

iodbctest{,w}

are interactive SQL processors

iodbcadm-gtk

is a graphical administration utility

Last updated on

libksba-1.6.0

Introduction to Libksba

The Libksba package contains a library used to make X.509 certificates as well as making the CMS (Cryptographic Message Syntax) easily accessible by other applications. Both specifications are building blocks of S/MIME and TLS. The library does not rely on another cryptographic library but provides hooks for easy integration with Libgcrypt.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Libksba Dependencies

Required

libgpg-error-1.44

Optional

Valgrind-3.18.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libksba

Installation of Libksba

Install Libksba by running the following commands:

./configure --prefix=/usr &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Contents

Installed Program: ksba-config
Installed Library: libksba.so
Installed Directory: None

Short Descriptions

ksba-config

is a utility used to configure and build applications based on the libksba(3) library. It can be used to query the C compiler and linker flags which are required to correctly compile and link the application against the libksba(3) library

libksba.{so,a}

contains the cryptographic API functions

Last updated on

liblinear-243

Introduction to liblinear

This package provides a library for learning linear classifiers for large scale applications. It supports Support Vector Machines (SVM) with L2 and L1 loss, logistic regression, multi class classification and also Linear Programming Machines (L1-regularized SVMs). Its computational complexity scales linearly with the number of training examples making it one of the fastest SVM solvers around.

This package is known to build and work properly using an LFS-11.1 platform.

Note

After updating this package from liblinear-1.96 or earlier, you need to reinstall Nmap-7.92, in order to link to the new library.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/liblinear

Installation of liblinear

Install liblinear by running the following commands:

make lib

This package does not come with a test suite.

Now, as the root user:

install -vm644 linear.h /usr/include &&
install -vm755 liblinear.so.4 /usr/lib &&
ln -sfv liblinear.so.4 /usr/lib/liblinear.so

Contents

Installed Programs: None
Installed Library: liblinear.so
Installed Directories: None

Short Descriptions

liblinear.so

is a large linear classification library

Last updated on

libmbim-1.26.2

Introduction to libmbim

The libmbim package contains a GLib-based library for talking to WWAN modems and devices which speak the Mobile Interface Broadband Model (MBIM) protocol.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libmbim Dependencies

Recommended
Optional

GTK-Doc-1.33.2 and help2man

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libmbim

Installation of libmbim

Install libmbim by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: mbimcli and mbim-network
Installed Libraries: libmbim-glib.so
Installed Directories: /usr/include/libmbim-glib and /usr/share/gtk-doc/html/libmbim-glib

Short Descriptions

mbimcli

is an utility used to control MBIM devices

mbim-network

is an utility used for simple network management of MBIM devices

libmbim-glib.so

contains API functions for talking to WWAN modems and devices which speak the Mobile Interface Broadband Model (MBIM) protocol

Last updated on

libpaper-1.1.24+nmu5

Introduction to libpaper

This package is intended to provide a simple way for applications to take actions based on a system or user-specified paper size.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libpaper

Installation of libpaper

Install libpaper by running the following commands:

autoreconf -fi                &&
./configure --prefix=/usr     \
            --sysconfdir=/etc \
            --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&
mkdir -vp /etc/libpaper.d

The /etc/libpaper.d directory contains scripts to run after the paper size has been changed. This package puts no scripts here, but other packages may. If the fcron package has not been installed, create the run-parts script as shown in the Fcron Configuration Information section.

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

mkdir -pv /etc/libpaper.d: libpaper expects that packages will install files into this directory.

Configuring libpaper

Configuration Information

Create /etc/papersize to set the default system paper size. Issue the following command as the root user to set this to 'A4' (libpaper prefers the lowercase form). You may wish to use a different size, such as letter.

cat > /etc/papersize << "EOF"
a4
EOF

Contents

Installed Programs: paperconf, paperconfig, run-parts
Installed Library: libpaper.so
Installed Directories: /etc/libpaper.d

Short Descriptions

paperconf

prints paper configuration information

paperconfig

configures the system default paper size

libpaper.so

contains functions for interrogating the paper library

Last updated on

libportal-0.5

Introduction to libportal

The libportal package provides a library that contains GIO-style async APIs for most Flatpak portals.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libportal Dependencies

Required

gobject-introspection-1.70.0

Recommended
Optional

Vala-0.54.7 and gi-docgen

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libportal

Installation of libportal

Warning

If a previous version of libportal is installed, move the headers out of the way so that later packages do not encounter conflicts:

if [ -e /usr/include/libportal ]; then
    rm -rf /usr/include/libportal.old &&
    mv -vf /usr/include/libportal{,.old}
fi

Install libportal by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release -Ddocs=false .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Ddocs=false: Remove this parameter if gi-docgen is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Libraries: libportal.so, libportal-gtk3.so, libportal-gtk4.so, and libportal-qt5.so
Installed Directories: /usr/include/libportal and /usr/share/gtk-doc/html/libportal

Short Descriptions

libportal.so

provides GIO-style async APIs for most Flatpak portals

libportal-gtk3.so

provides GTK+-3 specific functions for interacting with Flatpak portals.

libportal-gtk4.so

provides GTK-4 specific functions for interacting with Flatpak portals.

libportal-qt5.so

provides Qt5 specific functions for interacting with Flatpak portals.

Last updated on

libptytty-2.0

Introduction to libptytty

The libptytty package provides a library that allows for OS independent and secure pty/tty and utmp/wtmp/lastlog handling.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libptytty Dependencies

Required

CMake-3.22.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libptytty

Installation of libptytty

Install libptytty by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr     \
      -DCMAKE_BUILD_TYPE=Release      \
      -DPT_UTMP_FILE:STRING=/run/utmp \
      .. &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: libptytty.so
Installed Directories: None

Short Descriptions

libptytty.so

provides for OS independent and secure pty/tty and utmp/wtmp/lastlog handling

Last updated on

libqalculate-4.0.0

Introduction to libqalculate

The libqalculate package contains a library that provides functions for a multi-purpose calculator.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libqalculate Dependencies

Required

cURL-7.81.0 and libxml2-2.9.13

Optional

Doxygen-1.9.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libqalculate

Installation of libqalculate

Install libqalculate by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: qalc
Installed Library: libqalculate.so
Installed Directories: /usr/include/libqalculate and /usr/share/qalculate

Short Descriptions

qalc

is a powerful and easy to use command line calculator

libqalculate.so

contains the libqalculate API functions

Last updated on

libqmi-1.30.4

Introduction to libqmi

The libqmi package contains a GLib-based library for talking to WWAN modems and devices which speak the Qualcomm MSM Interface (QMI) protocol.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libqmi Dependencies

Required

GLib-2.70.4 and libgudev-237

Recommended
Optional

GTK-Doc-1.33.2, help2man, and libqrtr-glib

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libqmi

Installation of libqmi

Install libqmi by running the following commands:

PYTHON=python3 ./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

--disable-mbim-qmux: This switch disables support for using a MBIM control device for QMI messages. Use this switch if you did not install libmbim.

Contents

Installed Programs: qmicli, qmi-firmware-update, and qmi-network
Installed Libraries: libqmi-glib.so
Installed Directories: /usr/include/libqmi-glib and /usr/share/gtk-doc/html/libqmi-glib

Short Descriptions

qmicli

is an utility used to control QMI devices

qmi-firmware-update

is an utility used to perform firmware updates on QMI devices

qmi-network

is an utility used for simple network management of QMI devices

libqmi-glib.so

contains API functions for talking to WWAN modems and devices which speak the Qualcomm MSM Interface (QMI) protocol

Last updated on

libseccomp-2.5.3

Introduction to libseccomp

The libseccomp package provides an easy to use and platform independent interface to the Linux kernel's syscall filtering mechanism.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libseccomp Dependencies

Optional

Which-2.21 (needed for tests), Valgrind-3.18.1, Cython, and LCOV

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libseccomp

Installation of libseccomp

Install libseccomp by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Program: scmp_sys_resolver
Installed Library: libseccomp.so
Installed Directories: None

Short Descriptions

scmp_sys_resolver

is used to resolve system calls for applications

libseccomp.so

contains API functions for translating syscalls

Last updated on

libsigc++-2.10.8

Introduction to libsigc++

The libsigc++ package implements a typesafe callback system for standard C++.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libsigc++ Dependencies

Recommended
Optional

DocBook-utils-0.6.14, docbook-xml-5.0, Doxygen-1.9.3, and mm-common

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libsigc++

Installation of libsigc++

Install libsigc++ by running the following commands:

mkdir bld &&
cd    bld &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Command Explanations

-Dbuild_documentation=true: Use this switch if Doxygen-1.9.3 is installed and you wish to build and install the API documentation.

Contents

Installed Programs: None
Installed Library: libsigc-2.0.so
Installed Directories: /usr/{include,lib}/sigc++-2.0 and /usr/share/{devhelp/books,doc}/libsigc++-2.0 (if the documentation is enabled)

Short Descriptions

libsigc-2.0.so

contains the libsigc++ API functions

Last updated on

libsigsegv-2.14

Introduction to libsigsegv

libsigsegv is a library for handling page faults in user mode. A page fault occurs when a program tries to access to a region of memory that is currently not available. Catching and handling a page fault is a useful technique for implementing pageable virtual memory, memory-mapped access to persistent databases, generational garbage collectors, stack overflow handlers, and distributed shared memory.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libsigsegv

Installation of libsigsegv

Install libsigsegv by running the following commands:

./configure --prefix=/usr   \
            --enable-shared \
            --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--enable-shared: This switch ensures that shared libraries are compiled.

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Library: libsigsegv.so
Installed Directories: None

Short Descriptions

libsigsegv.so

is a library for handling page faults in user mode

Last updated on

libssh2-1.10.0

Introduction to libssh2

Libssh2 package is a client-side C library implementing the SSH2 protocol.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libssh2 Dependencies

Optional

GnuPG-2.2.34, libgcrypt-1.10.0, and OpenSSH-8.8p1 (all three are required for the testsuite)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libssh2

Installation of libssh2

Install libssh2 by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Library: libssh2.so
Installed Directories: None

Short Descriptions

libssh2.so

contains functions to use the SSH2 protocol

Last updated on

libstatgrab-0.92.1

Introduction to libstatgrab

This is a library that provides cross platform access to statistics about the system on which it's run. It's written in C and presents a selection of useful interfaces which can be used to access key system statistics. The current list of statistics includes CPU usage, memory utilisation, disk usage, process counts, network traffic, disk I/O, and more.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libstatgrab

Installation of libstatgrab

Install libstatgrab by running the following commands:

./configure --prefix=/usr   \
            --disable-static \
            --docdir=/usr/share/doc/libstatgrab-0.92.1 &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: saidar, statgrab, statgrab-make-mrtg-config, and statgrab-make-mrtg-index
Installed Library: libstatgrab.so
Installed Directories: /usr/share/doc/libstatgrab-0.92.1

Short Descriptions

saidar

is a curses-based tool for viewing system statistics

statgrab

is a sysctl-style interface to system statistics

statgrab-make-mrtg-config

generates MRTG configuration

statgrab-make-mrtg-index

generates an XHTML index page from MRTG configuration files or stdin

libstatgrab.so

contains the libstatgrab API functions

Last updated on

libtasn1-4.18.0

Introduction to libtasn1

libtasn1 is a highly portable C library that encodes and decodes DER/BER data following an ASN.1 schema.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libtasn1 Dependencies

Optional

GTK-Doc-1.33.2 and Valgrind-3.18.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libtasn1

Installation of libtasn1

Install libtasn1 by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

If you did not pass the --enable-gtk-doc parameter to the configure script, you can install the API documentation using the following command as the root user:

make -C doc/reference install-data-local

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: This parameter is normally used if GTK-Doc is installed and you wish to rebuild and install the API documentation. It is broken for this package due to the use of a long deprecated gtk-doc program that is no longer available.

Contents

Installed Programs: asn1Coding, asn1Decoding and asn1Parser
Installed Library: libtasn1.so
Installed Directory: /usr/share/gtk-doc/html/libtasn1

Short Descriptions

asn1Coding

is an ASN.1 DER encoder

asn1Decoding

is an ASN.1 DER decoder

asn1Parser

is an ASN.1 syntax tree generator for libtasn1

libtasn1.so

is a library for Abstract Syntax Notation One (ASN.1) and Distinguish Encoding Rules (DER) manipulation

Last updated on

libuninameslist-20211114

Introduction to libuninameslist

Libuninameslist provides a Library of Unicode names and annotation data

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libuninameslist

Installation of libuninameslist

Install libuninameslist by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-frenchlib: This option adds a library of french translations of the names and attributes, libuninameslist-fr.so.

Contents

Installed Programs: None
Installed Library: libuninameslist.so
Installed Directories: None

Short Descriptions

libuninameslist.so

provides a library of Unicode names and annotation data

Last updated on

libunique-1.1.6

Introduction to libunique

The libunique package contains a library for writing single instance applications.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

libunique Dependencies

Required

GTK+-2.24.33, also GTK-Doc-1.33.2 (for autoreconf)

Optional

gobject-introspection-1.70.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libunique

Installation of libunique

Install libunique by running the following commands:

patch -Np1 -i ../libunique-1.1.6-upstream_fixes-1.patch &&
autoreconf -fi &&

./configure --prefix=/usr  \
            --disable-dbus \
            --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-dbus: This switch disables D-Bus backend in favor of the GDBus backend.

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Library: libunique-1.0.so
Installed Directories: /usr/include/unique-1.0 and /usr/share/gtk-doc/html/unique

Short Descriptions

libunique-1.0.so

contains the libunique API functions for single instance support

Last updated on

libunistring-1.0

Introduction to libunistring

libunistring is a library that provides functions for manipulating Unicode strings and for manipulating C strings according to the Unicode standard.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libunistring Dependencies

Optional

texlive-20210325 (or install-tl-unx) (to rebuild the documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libunistring

Installation of libunistring

Install libunistring by running the following commands:

./configure --prefix=/usr    \
            --disable-static \
            --docdir=/usr/share/doc/libunistring-1.0 &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Libraries: libunistring.so
Installed Directory: /usr/include/unistring and /usr/share/doc/libunistring-1.0

Short Descriptions

libunistring.so

provides the unicode string library API

Last updated on

liburcu-0.13.1

Introduction to liburcu

The userspace-rcu package provides a set of userspace RCU (read-copy-update) libraries. These data synchronization libraries provide read-side access which scales linearly with the number of cores. It does so by allowing multiples copies of a given data structure to live at the same time, and by monitoring the data structure accesses to detect grace periods after which memory reclamation is possible.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/liburcu

Installation of liburcu

Install liburcu by running the following commands:

./configure --prefix=/usr    \
            --disable-static \
            --docdir=/usr/share/doc/liburcu-0.13.1 &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: liburcu.so, liburcu-bp.so, liburcu-cds.so, liburcu-common.so, liburcu-mb.so, liburcu-memb.so, liburcu-qsbr.so, and liburcu-signal.so
Installed Directories: /usr/share/doc/liburcu-0.13.1

Last updated on

libusb-1.0.25

Introduction to libusb

The libusb package contains a library used by some applications for USB device access.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libusb Dependencies

Optional

Doxygen-1.9.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libusb

Installation of libusb

Note

This package does not support parallel build.

Install libusb by running the following commands:

./configure --prefix=/usr --disable-static &&
make

If Doxygen is installed and you wish to build the API documentation, issue the following command:

sed -i "s/^TCL_SUBST/#&/; s/wide//" doc/doxygen.cfg &&
make -C doc docs

This package does not come with a test suite.

Now, as the root user:

make install

If you built the API documentation, install it using the following commands as the root user:

install -v -d -m755 /usr/share/doc/libusb-1.0.25/apidocs &&
install -v -m644    doc/api-1.0/* \
                    /usr/share/doc/libusb-1.0.25/apidocs

Command Explanations

sed -i ...: This sed prevents some warnings when building the documentation.

Configuring Libusb

To access raw USB devices (those not treated as a disk by the mass-storage driver), appropriate support must be available in the kernel. Check your kernel configuration:

Device Drivers --->
  [*] USB support --->                   [CONFIG_USB_SUPPORT]
    <*/M> Support for Host-side USB      [CONFIG_USB]
    (Select any USB hardware device drivers you may need on the same page)

For more details on setting up USB devices, see the section called “USB Device Issues”.

Contents

Installed Programs: None
Installed Library: libusb-1.0.so
Installed Directories: /usr/include/libusb-1.0 and /usr/share/doc/libusb-1.0.25

Short Descriptions

libusb-1.0.so

contains API functions used for accessing USB hardware

Last updated on

libuv-1.43.0

Introduction to libuv

The libuv package is a multi-platform support library with a focus on asynchronous I/O.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://dist.libuv.org/dist/v1.43.0/libuv-v1.43.0.tar.gz

  • Download MD5 sum: 2e2fd46f60ff73b17a04add5a934b2e9

  • Download size: 1.2 MB

  • Estimated disk space required: 14 MB (add 13 MB for tests)

  • Estimated build time: less than 0.1 SBU (Using parallelism=4; add 0.5 SBU for tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libuv

Installation of libuv

Install libuv by running the following commands:

Caution

The sh autogen.sh command below fails if the ACLOCAL environment variable is set as specified in Xorg-7. If it is used, ACLOCAL needs to be unset for this package and then reset for other packages.

sh autogen.sh                              &&
./configure --prefix=/usr --disable-static &&
make 

If you want to run the tests, run: make check as a non-root user.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Library: libuv.so
Installed Directory: /usr/include/uv

Short Descriptions

libuv.so

contains API functions for asynchronous I/O operations

Last updated on

libxkbcommon-1.4.0

Introduction to libxkbcommon

libxkbcommon is a keymap compiler and support library which processes a reduced subset of keymaps as defined by the XKB specification.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libxkbcommon Dependencies

Required

xkeyboard-config-2.35.1

Recommended
Optional

Doxygen-1.9.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libxkbcommon

Installation of libxkbcommon

Install libxkbcommon by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release -Denable-docs=false .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Denable-docs=false: This switch disables documentation generation. Remove it if Doxygen-1.9.3 is installed.

mv -v /usr/share/doc/libxkbcommon{,-1.4.0}: If you removed -Denable-docs=false, use this command to install the documentation in a versioned directory.

Contents

Installed Programs: xkbcli
Installed Libraries: libxkbcommon.so, libxkbcommon-x11.so, and libxkbregistry.so
Installed Directories: /usr/include/xkbcommon, /usr/libexec/xkbcommon, and /usr/share/doc/libxkbcommon-1.4.0

Short Descriptions

xkbcli

provides a debugger and compiler for XKB keymaps

libxkbcommon.so

contains the libxkbcommon API functions

libxkbcommon-x11.so

contains the libxkbcommon X11 specific API functions

libxkbregistry.so

contains a list of available XKB models, layouts, and variants for a given ruleset

Last updated on

libxml2-2.9.13

Introduction to libxml2

The libxml2 package contains libraries and utilities used for parsing XML files.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

libxml2 Dependencies

Optional

ICU-70.1 (see below) and Valgrind-3.18.1 (may be used in the tests)

Note

The old Python2 module can be built after libxml2.so has been installed, see Python2 libxml2-2.9.13 module.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libxml2

Installation of libxml2

Install libxml2 by running the following commands:

./configure --prefix=/usr    \
            --disable-static \
            --with-history   \
            --with-python=/usr/bin/python3 \
            --docdir=/usr/share/doc/libxml2-2.9.13 &&
make

If you downloaded the testsuite, issue the following command:

tar xf ../xmlts20130923.tar.gz

To test the results, issue: make check > check.log. A summary of the results can be obtained with grep -E '^Total|expected' check.log. If Valgrind-3.18.1 is installed and you want to check for memory leaks, replace check with check-valgrind.

Note

The tests use http://localhost/ to test parsing of external entities. If the machine where you run the tests serves as a web site, the tests may hang, depending on the content of the file served. It is therefore recommended to shut down the server during the tests, as the root user:

/etc/init.d/httpd stop

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--with-history: This switch enables Readline support when running xmlcatalog or xmllint in shell mode.

--with-python=/usr/bin/python3: Allows building the libxml2 module with Python3 instead of Python2.

--with-icu: Add this switch if you have built ICU-70.1, for better unicode support.

Contents

Installed Programs: xml2-config, xmlcatalog, and xmllint
Installed Libraries: libxml2.so and libxml2mod.so (Python3 module)
Installed Directories: /usr/include/libxml2, /usr/lib/cmake/libxml2, /usr/share/doc/libxml2-2.9.13, /usr/share/doc/libxml2-python-2.9.13, and /usr/share/gtk-doc/html/libxml2

Short Descriptions

xml2-config

determines the compile and linker flags that should be used to compile and link programs that use libxml2

xmlcatalog

is used to monitor and manipulate XML and SGML catalogs

xmllint

parses XML files and outputs reports (based upon options) to detect errors in XML coding

libxml2.so

provides functions for programs to parse files that use the XML format

libxml2mod.so

is the interface for Python3 to use libxml2.so

Last updated on

libxslt-1.1.35

Introduction to libxslt

The libxslt package contains XSLT libraries used for extending libxml2 libraries to support XSLT files.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libxslt Dependencies

Required

libxml2-2.9.13

Recommended (at runtime)

Note

Although it is not a direct dependency, many applications using libxslt will expect docbook-xml-4.5 and docbook-xsl-1.79.2 to be present.

Optional

libgcrypt-1.10.0 and Python2 libxml2-2.9.13 module

Note

The Python2 libxml2-2.9.13 module dependency is only appropriate if the Python2 module for this package is needed. The libxslt Python2 module is not needed for any package in BLFS but various non-BLFS packages may install Python2 modules which reference it.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libxslt

Installation of libxslt

Install libxslt by running the following commands:

sed -i s/3000/5000/ libxslt/transform.c doc/xsltproc.{1,xml} &&

./configure --prefix=/usr --disable-static --without-python  &&
make

Fix the date field in a shipped man page:

sed -e 's@\$Date\$@16 February 2022@' -i doc/xsltproc.1

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

sed -i s/3000/5000/ ...: this increases the recursion limit in libxslt. This is needed by some packages for their documentation.

--without-python: This parameter disables the libxslt python module since it does not support Python3. If you wish to enable this module, make sure that Python2 libxml2-2.9.13 module is installed, and remove this parameter.

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: xslt-config and xsltproc
Installed Libraries: libexslt.so, libxslt.so and optionally, libxsltmod.so Python module
Installed Directories: /usr/include/libexslt, /usr/include/libxslt, /usr/lib/libxslt-plugins, /usr/share/doc/libxslt-1.1.35, and /usr/share/doc/libxslt-python-1.1.35

Short Descriptions

xslt-config

is used to find out the pre-processor, linking and compiling flags necessary to use the libxslt libraries in 3rd-party programs

xsltproc

is used to apply XSLT stylesheets to XML documents

libexslt.so

is used to provide extensions to XSLT functions

libxslt.so

provides extensions to the libxml2 libraries to parse files that use the XSLT format

Last updated on

libwacom-2.1.0

Introduction to libwacom

The libwacom package contains a library used to identify wacom tablets and their model-specific features.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libwacom Dependencies

Required

libgudev-237

Recommended
Optional

Doxygen-1.9.3, git-2.35.1, librsvg-2.52.6, Valgrind-3.18.1 (optional for some tests), and pytest

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libwacom

Installation of libwacom

Install libwacom by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release -Dtests=disabled .. &&
ninja

To test the results, issue: ninja test. To run additional tests, install pytest and remove the "-Dtests=disabled" option from the meson line above.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dtests=disabled: This parameter disables some of the more advanced tests because they require pytest to work properly.

Contents

Installed Programs: libwacom-list-devices, libwacom-list-local-devices, libwacom-show-stylus, and libwacom-update-db
Installed Libraries: libwacom.so
Installed Directories: /usr/include/libwacom-1.0 and /usr/share/libwacom

Short Descriptions

libwacom-list-devices

lists all tablet devices that are supported by libwacom

libwacom-list-local-devices

lists tablet devices that are connected to the system

libwacom-show-stylus

lists tablet stylus IDs

libwacom-update-db

updates the system according to the current set of tablet data files

libwacom.so

contains functions used for accessing Wacom information

Last updated on

libwpe-1.12.0

Introduction to libwpe

The libwpe package contains a general purpose library for WPE WebKit and the WPE Renderer.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libwpe Dependencies

Required

libxkbcommon-1.4.0 and Mesa-21.3.6

Optional

hotdoc

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libwpe

Installation of libwpe

Install libwpe by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: None
Installed Libraries: libwpe-1.0.so
Installed Directories: /usr/include/wpe-1.0

Short Descriptions

libwpe-1.0.so

contains functions that provide a general purpose library for WPEWebKit and the WPE Renderer

Last updated on

libyaml-0.2.5

Introduction to libyaml

The yaml package contains a C library for parsing and emitting YAML (YAML Ain't Markup Language) code.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libyaml Dependencies

Optional

Doxygen-1.9.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libyaml

Installation of libyaml

Install libyaml by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Libraries: libyaml.so
Installed Directories: None

Short Descriptions

libyaml.so

contains API functions for parsing and emitting YAML code

Last updated on

LZO-2.10

Introduction to LZO

LZO is a data compression library which is suitable for data decompression and compression in real-time. This means it favors speed over compression ratio.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lzo

Installation of LZO

Install LZO by running the following commands:

./configure --prefix=/usr                    \
            --enable-shared                  \
            --disable-static                 \
            --docdir=/usr/share/doc/lzo-2.10 &&
make

To test the results, issue: make check. All the checks should pass. Now issue make test to run the full suite of tests.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Libraries: liblzo2.so
Installed Directories: /usr/include/lzo and /usr/share/doc/lzo

Short Descriptions

liblzo2.so

is a data compression and decompression library

Last updated on

mtdev-1.1.6

Introduction to mtdev

The mtdev package contains Multitouch Protocol Translation Library which is used to transform all variants of kernel MT (Multitouch) events to the slotted type B protocol.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/mtdev

Installation of mtdev

Install mtdev by running the following commands:

./configure --prefix=/usr --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Program: mtdev-test
Installed Library: libmtdev.so
Installed Directories: None

Short Descriptions

mtdev-test

is a tool to test libmtdev

libmtdev.so

contains Multitouch Protocol Translation API functions

Last updated on

Node.js-16.14.0

Introduction to Node.js

Node.js is a JavaScript runtime built on Chrome's V8 JavaScript engine.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://nodejs.org/dist/v16.14.0/node-v16.14.0.tar.xz

  • Download MD5 sum: 46a63d98585a4b76542776e5d5b50d15

  • Download size: 33 MB

  • Estimated disk space required: 750 MB (add 27 MB for tests)

  • Estimated build time: 14 SBU (add 2.6 SBU for tests: both using parallelism=4 and 4 CPUs online, parts of the tests will use all online CPUs)

Node.js Dependencies

Required

Which-2.21

Recommended
Optional

http-parser and npm (an internal copy of npm will be installed if not present)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/nodejs

Installation of Node.js

Build Node.js by running the following commands:

./configure --prefix=/usr          \
            --shared-cares         \
            --shared-libuv         \
            --shared-openssl       \
            --shared-nghttp2       \
            --shared-zlib          \
            --with-intl=system-icu &&
make

To test the results, issue: make test-only.

Now, as the root user:

make install &&
ln -sf node /usr/share/doc/node-16.14.0

Command Explanations

--with-intl=system-icu: use the system version of icu. Other values are full-icu (to build a local, full icu library) and small-icu (to build a local, minimal icu library).

--shared-{cares,libuv,nghttp2,openssl,zlib}: use the system installed libraries instead of local copies.

--without-npm: do not build npm (use if you'd like to build a separate npm later).

--shared-http-parser: use the system installed library instead of a local copy.

Contents

Installed Programs: node, npm, and npx
Installed Library: None
Installed Directories: /usr/include/node, /usr/lib/node_modules/npm, /usr/share/doc/{node,node-16.14.0}, and /usr/share/systemtap/tapset

Short Descriptions

node

is the server-side JavaScript runtime

npm

is the Node.js package manager

/usr/lib/node_modules/npm/

is the installation root for Node.js executables and libraries

Last updated on

npth-1.6

Introduction to NPth

The NPth package contains a very portable POSIX/ANSI-C based library for Unix platforms which provides non-preemptive priority-based scheduling for multiple threads of execution (multithreading) inside event-driven applications. All threads run in the same address space of the server application, but each thread has its own individual program-counter, run-time stack, signal mask and errno variable.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/npth

Installation of NPth

Install NPth by running the following commands:

./configure --prefix=/usr &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Contents

Installed Program: npth-config
Installed Library: libnpth.so
Installed Directory: None

Short Descriptions

npth-config

is a utility used to configure and build applications based on the npth library. It can be used to query the C compiler and linker flags which are required to correctly compile and link the application against the npth library

libnpth.so

contains the API functions used by the New Portable Threads Library

Last updated on

NSPR-4.33

Introduction to NSPR

Netscape Portable Runtime (NSPR) provides a platform-neutral API for system level and libc like functions.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/nspr

Installation of NSPR

Install NSPR by running the following commands:

cd nspr                                                     &&
sed -ri '/^RELEASE/s/^/#/' pr/src/misc/Makefile.in &&
sed -i 's#$(LIBRARY) ##'   config/rules.mk         &&

./configure --prefix=/usr \
            --with-mozilla \
            --with-pthreads \
            $([ $(uname -m) = x86_64 ] && echo --enable-64bit) &&
make

The testsuite is designed for testing changes to nss or nspr and is not particularly useful for checking a released version (e.g. it needs to be run on a non-optimized build with both nss and nspr directories existing alongside each other). For further details, see the User Notes for nss at https://wiki.linuxfromscratch.org/blfs/wiki/nss

Now, as the root user:

make install

Command Explanations

sed -ri '/^RELEASE/s/^/#/' pr/src/misc/Makefile.in: This sed disables installing two unneeded scripts.

sed -i 's#$(LIBRARY) ##' config/rules.mk: This sed disables installing the static libraries.

--with-mozilla: This parameter adds Mozilla support to the libraries (required if you want to build any other Mozilla products and link them to these libraries).

--with-pthreads: This parameter forces use of the system pthread library.

$([ $(uname -m) = x86_64 ] && echo --enable-64bit): The --enable-64bit parameter is required on an x86_64 system to prevent configure failing with a claim that this is a system without pthread support. The [ $(uname -m) = x86_64 ] test ensures it has no effect on a 32 bit system.

Contents

Installed Programs: nspr-config
Installed Libraries: libnspr4.so, libplc4.so and libplds4.so
Installed Directories: /usr/include/nspr

Short Descriptions

nspr-config

provides compiler and linker options to other packages that use NSPR

libnspr4.so

contains functions that provide platform independence for non-GUI operating system facilities such as threads, thread synchronization, normal file and network I/O, interval timing and calendar time, basic memory management and shared library linking

libplc4.so

contains functions that implement many of the features offered by libnspr4

libplds4.so

contains functions that provide data structures

Last updated on

PCRE-8.45

Introduction to PCRE

The PCRE package contains Perl Compatible Regular Expression libraries. These are useful for implementing regular expression pattern matching using the same syntax and semantics as Perl 5.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

PCRE Dependencies

Optional

Valgrind-3.18.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pcre

Installation of PCRE

Install PCRE by running the following commands:

./configure --prefix=/usr                     \
            --docdir=/usr/share/doc/pcre-8.45 \
            --enable-unicode-properties       \
            --enable-pcre16                   \
            --enable-pcre32                   \
            --enable-pcregrep-libz            \
            --enable-pcregrep-libbz2          \
            --enable-pcretest-libreadline     \
            --disable-static                 &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--enable-unicode-properties: This switch enables Unicode properties support and includes the code for handling UTF-8/16/32 character strings in the library. You need this switch if you are going to build GLib-2.70.4 with the --with-pcre=system switch.

--enable-pcre16: This switch enables 16 bit character support.

--enable-pcre32: This switch enables 32 bit character support.

--enable-pcregrep-libz: This switch adds support to pcregrep to read .gz compressed files.

--enable-pcregrep-libbz2: This switch adds support to pcregrep to read .bz2 compressed files.

--enable-pcretest-libreadline: This switch adds line editing and history features to pcretest program.

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-jit: this option enables Just-in-time compiling, which can greatly speed up pattern matching.

Contents

Installed Programs: pcregrep, pcretest, and pcre-config
Installed Libraries: libpcre.so, libpcre16.so, libpcre32.so, libpcrecpp.so and libpcreposix.so
Installed Directory: /usr/share/doc/pcre-8.45

Short Descriptions

pcregrep

is a grep that understands Perl compatible regular expressions

pcretest

can test a Perl compatible regular expression

pcre-config

is used during the compile process of programs linking to the PCRE libraries

Last updated on

PCRE2-10.39

Introduction to PCRE2

The PCRE2 package contains a new generation of the Perl Compatible Regular Expression libraries. These are useful for implementing regular expression pattern matching using the same syntax and semantics as Perl.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

PCRE2 Dependencies

Optional

Valgrind-3.18.1 and libedit

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pcre2

Installation of PCRE2

Install PCRE2 by running the following commands:

./configure --prefix=/usr                       \
            --docdir=/usr/share/doc/pcre2-10.39 \
            --enable-unicode                    \
            --enable-jit                        \
            --enable-pcre2-16                   \
            --enable-pcre2-32                   \
            --enable-pcre2grep-libz             \
            --enable-pcre2grep-libbz2           \
            --enable-pcre2test-libreadline      \
            --disable-static                    &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--enable-unicode: This switch enables Unicode support and includes the functions for handling UTF-8/16/32 character strings in the library.

--enable-pcre2-16: This switch enables 16 bit character support.

--enable-pcre2-32: This switch enables 32 bit character support.

--enable-pcre2grep-libz: This switch adds support for reading .gz compressed files to pcre2grep.

--enable-pcre2grep-libbz2: This switch adds support for reading .bz2 compressed files to pcre2grep.

--enable-pcre2test-libreadline: This switch adds line editing and history features to the pcre2test program.

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-jit: this option enables Just-in-time compiling, which can greatly speed up pattern matching.

Contents

Installed Programs: pcre2-config, pcre2grep, and pcre2test.
Installed Libraries: libpcre2-8.so, libpcre2-16.so, libpcre2-32.so, and libpcre2-posix.so
Installed Directory: /usr/share/doc/pcre2-10.39

Short Descriptions

pcre2grep

is a version of grep that understands Perl compatible regular expressions.

pcre2test

can test a Perl compatible regular expression.

pcre2-config

outputs compilation information to programs linking against the PCRE2 libraries

Last updated on

Popt-1.18

Introduction to Popt

The popt package contains the popt libraries which are used by some programs to parse command-line options.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

popt Dependencies

Optional

Doxygen-1.9.3 (for generating documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/popt

Installation of Popt

Install popt by running the following commands:

./configure --prefix=/usr --disable-static &&
make

If you have Doxygen-1.9.3 installed and wish to build the API documentation, issue:

sed -i 's@\./@src/@' Doxyfile &&
doxygen

To test the results, issue: make check.

Now, as the root user:

make install

If you built the API documentation, install it using the following commands issued by the root user:

install -v -m755 -d /usr/share/doc/popt-1.18 &&
install -v -m644 doxygen/html/* /usr/share/doc/popt-1.18

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Library: libpopt.so
Installed Directories: /usr/share/doc/popt-1.18

Short Descriptions

libpopt.so

is used to parse command-line options

Last updated on

Pth-2.0.7

Introduction to Pth

The Pth package contains a very portable POSIX/ANSI-C based library for Unix platforms which provides non-preemptive priority-based scheduling for multiple threads of execution (multithreading) inside event-driven applications. All threads run in the same address space of the server application, but each thread has its own individual program-counter, run-time stack, signal mask and errno variable.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Pth Dependencies

Optional

GCC-11.2.0 (for gfortran) and libnsl-2.0.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pth

Installation of Pth

Caution

Don't add the --enable-pthread parameter to the configure command below else you will overwrite the pthread library and interface header installed by the Glibc package in LFS.

Install Pth by running the following commands:

sed -i 's#$(LOBJS): Makefile#$(LOBJS): pth_p.h Makefile#' Makefile.in &&
./configure --prefix=/usr           \
            --disable-static        \
            --mandir=/usr/share/man &&
make

To test the results, issue: make test.

Now, as the root user:

make install &&
install -v -m755 -d /usr/share/doc/pth-2.0.7 &&
install -v -m644    README PORTING SUPPORT TESTS \
                    /usr/share/doc/pth-2.0.7

Command Explanations

sed -i 's#$(LOBJS) ...: This sed fixes a race condition in the Makefile. It allows running make with multiple jobs (e.g., make -j4).

--disable-static: This switch prevents installation of static versions of the libraries.

--mandir=/usr/share/man: This switch puts the man pages in /usr/share/man instead of /usr/man.

Contents

Installed Program: pth-config
Installed Library: libpth.so
Installed Directory: /usr/share/doc/pth-2.0.7

Short Descriptions

pth-config

is a utility used to configure and build applications based on the pth(3) library. It can be used to query the C compiler and linker flags which are required to correctly compile and link the application against the pth(3) library

libpth.so

contains the API functions used by the GNU Portable Threads Library

Last updated on

Qca-2.3.4

Introduction to Qca

Qca aims to provide a straightforward and cross-platform crypto API, using Qt datatypes and conventions. Qca separates the API from the implementation, using plugins known as Providers.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Qca Dependencies

Required

make-ca-1.10, CMake-3.22.2, Qt-5.15.2, and Which-2.21

Optional

Cyrus SASL-2.1.27, GnuPG-2.2.34, libgcrypt-1.10.0, libgpg-error-1.44, nss-3.75, NSPR-4.33, p11-kit-0.24.1, Doxygen-1.9.3, Which-2.21, and Botan

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/qca

Installation of Qca

Fix the location of the CA certificates:

sed -i 's@cert.pem@certs/ca-bundle.crt@' CMakeLists.txt

Install Qca by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=$QT5DIR            \
      -DCMAKE_BUILD_TYPE=Release                \
      -DQCA_MAN_INSTALL_DIR:PATH=/usr/share/man \
      .. &&
make

To test the results, issue make test.

Now, as the root user:

make install

Command Explanations

-DCMAKE_BUILD_TYPE=Release: This switch is used to apply a higher level of compiler optimizations.

-DQCA_MAN_INSTALL_DIR:PATH=/usr/share/man: Install the qca man page in the normal location.

Contents

Installed Programs: mozcerts-qt5 and qcatool-qt5
Installed Libraries: libqca-qt5.so, libqca-cyrus-sasl.so, libqca-gcrypt.so, libqca-gnupg.so, libqca-logger.so, libqca-nss.so, libqca-ossl.so, and libqca-softstore.so
Installed Directories: $QT5DIR/include/Qca-qt5, $QT5DIR/lib/cmake/Qca-qt5, and $QT5DIR/lib/qca-qt5

Short Descriptions

mozcerts-qt5

is a command line tool for converting certdata.txt into outfile.pem files

qcatool-qt5

is a command line tool for performing various cryptographic operations with Qca

libqca-qt5.so

is the Qt Cryptography Architecture (Qca) library

Last updated on

Talloc-2.3.3

Introduction to Talloc

Talloc provides a hierarchical, reference counted memory pool system with destructors. It is the core memory allocator used in Samba.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Talloc Dependencies

Optional

docbook-xml-4.5, docbook-xsl-1.79.2 and libxslt-1.1.35 (To generate man pages), GDB-11.2, git-2.35.1, libnsl-2.0.0, libtirpc-1.3.2, Valgrind-3.18.1, and xfsprogs-5.14.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/talloc

Installation of Talloc

Install Talloc by running the following commands:

./configure --prefix=/usr &&
make

To check the results, issue make check.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: libpytalloc-util.cpython-310-<arch>-linux-gnu.so, libtalloc.so, talloc.so (Python-2 Module) and talloc.cpython-310-<arch>-linux-gnu.so (Python-3 Module)
Installed Directories: None

Short Descriptions

libtalloc.so

contains a replacement for the Glibc malloc function

Last updated on

telepathy-glib-0.24.2

Introduction to Telepathy GLib

The Telepathy GLib contains a library used by GLib based Telepathy components. Telepathy is a D-Bus framework for unifying real time communication, including instant messaging, voice calls and video calls. It abstracts differences between protocols to provide a unified interface for applications.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Telepathy GLib Dependencies

Required

dbus-glib-0.112 and libxslt-1.1.35

Recommended
Optional

GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/telepathy-glib

Installation of Telepathy Glib

If you intend to run the tests, one of them defaults to invoking /usr/bin/python and fails if it is absent, causing the second batch of tests to not run - unlike the other tests which can be overridden from the environment. Fix it with the following command:

sed -i 's%/usr/bin/python%&3%' tests/all-errors-documented.py

Install Telepathy GLib by running the following commands:

PYTHON=/usr/bin/python3 ./configure --prefix=/usr          \
                                    --enable-vala-bindings \
                                    --disable-static       &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--enable-vala-bindings: This switch enables building of the Vala bindings. Remove if you don't have Vala-0.54.7 installed.

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Libraries: libtelepathy-glib.so
Installed Directories: /usr/include/telepathy-1.0 and /usr/share/gtk-doc/html/telepathy-glib

Short Descriptions

libtelepathy-glib.so

contains the Telepathy GLib API functions

Last updated on

Uchardet-0.0.7

Introduction to Uchardet

The Uchardet package contains an encoding detectory library which takes a sequence of bytes in an unknown character encoding and attempts to determine the encoding of the text.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Uchardet Dependencies

Required

CMake-3.22.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/uchardet

Installation of Uchardet

Install Uchardet by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DBUILD_STATIC=OFF          \
      -Wno-dev ..                 &&
make

To test the results, issue: make test.

Now, as the root user:

make install

Command Explanations

-DBUILD_STATIC=OFF: This switch disables building the static version of the library.

Contents

Installed Programs: uchardet
Installed Libraries: libuchardet.so
Installed Directories: /usr/include/uchardet

Short Descriptions

uchardet

detects what character set is used inside of a file

libuchardet.so

provides an API for detecting the encoding of text in a file

Last updated on

Umockdev-0.17.6

Introduction to Umockdev

The Umockdev package contains a framework that allows a developer to mock devices for use in unit testing.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Umockdev Dependencies

Required

libgudev-237, libpcap-1.10.1, and Vala-0.54.7

Optional

GTK-Doc-1.33.2 and libgphoto2 (optional for tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/umockdev

Installation of Umockdev

Install Umockdev by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: PATH=$PATH:/usr/sbin ninja test. The addition to PATH is needed if you use the starting scripts in The Bash Shell Startup Files, because some tests need to run udevadm. One test needs to be run in an X session.

Now, as the root user:

ninja install

Command Explanations

-Dgtk_doc=true: Use this switch if you have GTK-Doc-1.33.2 installed and wish to rebuild and install the API documentation.

Contents

Installed Programs: umockdev-record, umockdev-run, and umockdev-wrapper
Installed Libraries: libumockdev-preload.so and libumockdev.so
Installed Directories: /usr/include/umockdev-1.0

Short Descriptions

umockdev-record

records Linux devices and their ancestors from sysfs/udev or records ioctls for a device

umockdev-run

runs a program under an umockdev testbed

umockdev-wrapper

wraps a program around libumockdev-preload.so.0 through LD_PRELOAD

libumockdev.so

provides API functions that allow mocking hardware devices for unit testing

Last updated on

Wayland-1.20.0

Introduction to Wayland

Wayland is a project to define a protocol for a compositor to talk to its clients as well as a library implementation of the protocol.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Wayland Dependencies

Required

libxml2-2.9.13

Optional

Doxygen-1.9.3, Graphviz-2.50.0 and xmlto-0.0.28 (to build the API documentation) and docbook-xml-4.5, docbook-xsl-1.79.2 and libxslt-1.1.35 (to build the manual pages)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/wayland

Installation of Wayland

Install Wayland by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr       \
      --buildtype=release \
      -Ddocumentation=false &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--disable-documentation: This switch is used to disable building of the API documentation. Remove it if you have installed optional dependencies.

Contents

Installed Programs: wayland-scanner
Installed Libraries: libwayland-client.so, libwayland-cursor.so, libwayland-egl.so, and libwayland-server.so
Installed Directories: /usr/share/wayland

Short Descriptions

wayland-scanner

is a tool to generate proxy methods in wayland-client-protocol.h and wayland-server-protocol.h

libwayland-client.so

contains API functions for writing Wayland applications

libwayland-cursor.so

contains API functions for managing cursors in Wayland applications

libwayland-egl.so

contains API functions for handling OpenGL calls in Wayland applications

libwayland-server.so

contains API functions for writing Wayland compositors

Last updated on

Wayland-Protocols-1.25

Introduction to Wayland-Protocols

The Wayland-Protocols package contains additional Wayland protocols that add functionality outside of protocols already in the Wayland core.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Wayland-protocols Dependencies

Required

Wayland-1.20.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/wayland-protocols

Installation of Wayland-protocols

Install Wayland-protocols by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Contents

Installed Programs: None
Installed Libraries: None
Installed Directories: /usr/share/wayland-protocols

Last updated on

wpebackend-fdo-1.12.0

Introduction to wpebackend-fdo

The wpebackend-fdo package contains the Freedesktop.org backend for WPE WebKit and the WPE renderer.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

wpebackend-fdo Dependencies

Required

libepoxy-1.5.9, libwpe-1.12.0, and wayland-protocols-1.25

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/wpebackend-fdo

Installation of wpebackend-fdo

Install wpebackend-fdo by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release ..
ninja

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: None
Installed Libraries: libWPEBackend-fdo-1.0.so
Installed Directories: /usr/include/wpe-fdo-1.0

Short Descriptions

libWPEBackend-fdo-1.0.so

contains functions that provide the freedesktop.org backend for WPE WebKit and the WPE renderer

Last updated on

wv-1.2.9

Introduction to wv

The wv package contains tools for reading information from an MS Word document.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

wv Dependencies

Required

libgsf-1.14.48 and libpng-1.6.37

Optional

libwmf

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/wv

Installation of wv

Install wv by running the following commands:

./configure --prefix=/usr --disable-static &&
make

This package does not have a testsuite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: wvSummary and several other wv* programs which are deprecated in favour of abiword: see http://wvware.sourceforge.net/
Installed Library: libwv-1.2.so
Installed Directory: /usr/share/wv

Short Descriptions

wvSummary

displays the summary information from an MS Word document

libwv-1.2.so

provides functions to access MS Word documents

Last updated on

Xapian-1.4.19

Introduction to xapian

Xapian is an open source search engine library.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Xapian Dependencies

Optional

Valgrind-3.18.1 (for tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xapian

Installation of Xapian

Install Xapian by running the following commands:

./configure --prefix=/usr    \
            --disable-static \
            --docdir=/usr/share/doc/xapian-core-1.4.19 &&
make

To run the test suite, issue: make check.

Now, as the root user:

make install

Contents

Installed Programs: copydatabase, quest, simpleexpand, simpleindex, simplesearch, xapian-check, xapian-compact, xapian-config, xapian-delve, xapian-metadata, xapian-pos, xapian-progsrv, xapian-replicate, xapian-replicate-server and xapian-tcpsrv
Installed Libraries: libxapian.so
Installed Directories: /usr/include/xapian, /usr/lib/cmake/xapian, /usr/share/doc/xapian-core-1.4.19, and /usr/share/xapian-core

Short Descriptions

copydatabase

performs a document-by-document copy of one or more Xapian databases

quest

is a command line tool to search through a database

simpleexpand

is a simple example program demonstrating query expansion

simpleindex

indexes each paragraph of a text file as a Xapian document

simplesearch

is a simple command line search utility

xapian-check

checks the consistency of a database or table

xapian-compact

compacts a database, or merges and compacts several databases

xapian-config

reports information about the installed xapian

xapian-delve

inspects the contents of a Xapian database

xapian-metadata

reads and writes user metadata

xapian-pos

inspects the contents of a flint table for development or debugging

xapian-progsrv

is a remote server for use with ProgClient

xapian-replicate

replicates a database from a master server to a local copy

xapian-replicate-server

services database replication requests from clients

xapian-tcpsrv

is the TCP daemon for use with Xapian's remote backend

Last updated on

Chapter 10. Graphics and Font Libraries

Depending on what your system will be used for, you may or may not require the graphics and font libraries. Most desktop machines will want them for use with graphical applications. Most servers on the other hand, will not require them.

AAlib-1.4rc5

Introduction to AAlib

AAlib is a library to render any graphic into ASCII Art.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

AAlib Dependencies

Optional

Xorg Libraries, Xorg Legacy Fonts (runtime), slang-2.3.2, and GPM-1.20.7

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/aalib

Installation of AAlib

Fix a minor problem with the included m4 file:

sed -i -e '/AM_PATH_AALIB,/s/AM_PATH_AALIB/[&]/' aalib.m4

Install AAlib by running the following commands:

./configure --prefix=/usr             \
            --infodir=/usr/share/info \
            --mandir=/usr/share/man   \
            --with-ncurses=/usr       \
            --disable-static          &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: aafire, aainfo, aalib-config, aasavefont, and aatest
Installed Library: libaa.so
Installed Directories: None

Short Descriptions

aafire

is a demo of AAlib, rendering an animated fire in ASCII Art

aainfo

provides information for your current settings related to AAlib

aalib-config

provides configuration info for AAlib

aasavefont

saves a font to a file

aatest

shows the abilities of AAlib in a little test

libaa.so

is a collection of routines to render any graphical input in portable format to ASCII Art. It can be used through many programs and has a very well documented API, so you can easily put it into your own programs

Last updated on

babl-0.1.88

Introduction to Babl

The Babl package is a dynamic, any to any, pixel format translation library.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Babl Dependencies

Recommended
Optional

Little CMS-2.13.1 and w3m

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/babl

Installation of Babl

Install Babl by running the following commands:

mkdir bld &&
cd    bld &&

meson --prefix=/usr --buildtype=release .. &&
ninja 

To test the results, issue: ninja test.

Now, as the root user:

ninja install &&

install -v -m755 -d                         /usr/share/gtk-doc/html/babl/graphics &&
install -v -m644 docs/*.{css,html}          /usr/share/gtk-doc/html/babl          &&
install -v -m644 docs/graphics/*.{html,svg} /usr/share/gtk-doc/html/babl/graphics

Command Explanations

install -v -m755 -d /usr/share/gtk-doc/html/babl/graphics: This and the subsequent commands install the library html documentation under /usr/share/gtk-doc/html where other gtk packages put the programmer-oriented documentation.

Contents

Installed Programs: None
Installed Libraries: libbabl-0.1.so and libraries in /usr/lib/babl-0.1
Installed Directories: /usr/{include,lib}/babl-0.1 and /usr/share/gtk-doc/html/babl

Short Descriptions

libbabl-0.1.so

contains functions to access BablFishes to convert between formats

Last updated on

Exiv2-0.27.5

Introduction to Exiv2

Exiv2 is a C++ library and a command line utility for managing image and video metadata.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Exiv2 dependencies

Required

CMake-3.22.2

Recommended
Optional

libssh

Optional for documentation

Doxygen-1.9.3, Graphviz-2.50.0, and libxslt-1.1.35

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/exiv2

Installation of Exiv2

Install Exiv2 by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr  \
      -DCMAKE_BUILD_TYPE=Release   \
      -DEXIV2_ENABLE_VIDEO=yes     \
      -DEXIV2_ENABLE_WEBREADY=yes  \
      -DEXIV2_ENABLE_CURL=yes      \
      -DEXIV2_BUILD_SAMPLES=no     \
      -G "Unix Makefiles" .. &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

-DEXIV2_ENABLE_VIDEO=yes: This switch enables managing video metadata.

-DEXIV2_ENABLE_WEBREADY=yes: This switch enables managing web image metadata.

-DEXIV2_BUILD_SAMPLES=no: This switch is necessary to suppress building and installing sample programs. If the sample programs are built, 34 additional programs are installed in /usr/bin.

-DEXIV2_ENABLE_CURL=yes: This switch is necessary to enable network/http capabilities.

Contents

Installed Program: exiv2
Installed Library: libexiv2.so and libexiv2-xmp.a
Installed Directories: /usr/include/exiv2

Short Descriptions

exiv2

is a utility used to dump Exif data

Last updated on

FreeType-2.11.1

Introduction to FreeType2

The FreeType2 package contains a library which allows applications to properly render TrueType fonts.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Additional Documentation

FreeType2 Dependencies

Recommended
Optional

Brotli-1.0.9

Optional (for documentation)

docwriter

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/freetype2

Installation of FreeType2

If you downloaded the additional documentation, unpack it into the source tree using the following command:

tar -xf ../freetype-doc-2.11.1.tar.xz --strip-components=2 -C docs

Install FreeType2 by running the following commands:

sed -ri "s:.*(AUX_MODULES.*valid):\1:" modules.cfg &&

sed -r "s:.*(#.*SUBPIXEL_RENDERING) .*:\1:" \
    -i include/freetype/config/ftoption.h  &&

./configure --prefix=/usr --enable-freetype-config --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install

If you downloaded the optional documentation, install it as the root user:

install -v -m755 -d /usr/share/doc/freetype-2.11.1 &&
cp -v -R docs/*     /usr/share/doc/freetype-2.11.1 &&
rm -v /usr/share/doc/freetype-2.11.1/freetype-config.1

Command Explanations

sed -ri ...: First command enables GX/AAT and OpenType table validation and second command enables Subpixel Rendering. Note that Subpixel Rendering may have patent issues. Be sure to read the 'Other patent issues' part of http://www.freetype.org/patents.html before enabling this option.

--enable-freetype-config: This switch ensure that the man page for freetype-config is installed.

--without-harfbuzz: If harfbuzz is installed prior to freetype without freetype support, use this switch to avoid a build failure.

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Program: freetype-config
Installed Library: libfreetype.so
Installed Directories: /usr/include/freetype2 and /usr/share/doc/freetype-2.11.1

Short Descriptions

freetype-config

is used to get FreeType compilation and linking information

libfreetype.so

contains functions for rendering various font types, such as TrueType and Type1

Last updated on

Fontconfig-2.13.1

Introduction to Fontconfig

The Fontconfig package contains a library and support programs used for configuring and customizing font access.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Fontconfig Dependencies

Required

FreeType-2.11.1

Optional

JSON-C-0.15, DocBook-utils-0.6.14 and libxml2-2.9.13, texlive-20210325 (or install-tl-unx)

Note

If you have DocBook Utils installed and you remove the --disable-docs parameter from the configure command below, you must have SGMLSpm-1.1 and texlive-20210325 installed also, or the Fontconfig build will fail.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Fontconfig

Installation of Fontconfig

Install Fontconfig by running the following commands:

./configure --prefix=/usr        \
            --sysconfdir=/etc    \
            --localstatedir=/var \
            --disable-docs       \
            --docdir=/usr/share/doc/fontconfig-2.13.1 &&
make

To test the results, issue: make check.

Now, as the root user:

make install

If you did not remove the --disable-docs parameter from the configure command, you can install the pre-generated documentation by using the following commands as the root user:

install -v -dm755 \
        /usr/share/{man/man{1,3,5},doc/fontconfig-2.13.1/fontconfig-devel} &&
install -v -m644 fc-*/*.1         /usr/share/man/man1 &&
install -v -m644 doc/*.3          /usr/share/man/man3 &&
install -v -m644 doc/fonts-conf.5 /usr/share/man/man5 &&
install -v -m644 doc/fontconfig-devel/* \
                                  /usr/share/doc/fontconfig-2.13.1/fontconfig-devel &&
install -v -m644 doc/*.{pdf,sgml,txt,html} \
                                  /usr/share/doc/fontconfig-2.13.1

Command Explanations

--disable-docs: This switch avoids building the documentation (the release tarball includes pre-generated documentation).

Configuring Fontconfig

Config Files

/etc/fonts/*, /etc/fonts/conf.d/* and /usr/share/fontconfig/conf.avail/*

Configuration Information

The main configuration file for Fontconfig is /etc/fonts/fonts.conf. Generally you do not want to edit this file. It will also read /etc/fonts/local.conf and any files in /etc/fonts/conf.d. To put a new font directory in the configuration, create (or update) the /etc/fonts/local.conf file with your local information or add a new file in /etc/fonts/conf.d. The default location of fonts in Fontconfig is:

  • /usr/share/fonts

  • ~/.local/share/fonts

  • ~/.fonts (this is now deprecated, but for the moment it still works)

Fontconfig also ships many example configuration files in the /usr/share/fontconfig/conf.avail directory. Symlinking specific files to /etc/fonts/conf.d will enable them. The default setup is generally good enough for most users. See /etc/fonts/conf.d/README for a description of the configuration files.

More information about configuring Fontconfig can be found in the user's manual in file:///usr/share/doc/fontconfig-2.13.1/fontconfig-user.html.

Contents

Installed Programs: fc-cache, fc-cat, fc-conflist, fc-list, fc-match, fc-pattern, fc-query, fc-scan, and fc-validate
Installed Library: libfontconfig.so
Installed Directories: /etc/fonts, /usr/include/fontconfig, /usr/share/doc/fontconfig-2.13.1, /usr/share/fontconfig, /usr/share/xml/fontconfig, and /var/cache/fontconfig

Short Descriptions

fc-cache

is used to create font information caches

fc-cat

is used to read font information caches

fc-conflist

shows the ruleset files' information on the system

fc-list

is used to create font lists

fc-match

is used to match available fonts, or find fonts that match a given pattern

fc-pattern

is used to parse pattern (empty pattern by default) and show the parsed result

fc-query

is used to query fonts files and print resulting patterns

fc-scan

is used to scan font files and directories, and print resulting patterns

fc-validate

is used to validate font files

libfontconfig.so

contains functions used by the Fontconfig programs and also by other programs to configure or customize font access

Last updated on

FriBidi-1.0.11

Introduction to FriBidi

The FriBidi package is an implementation of the Unicode Bidirectional Algorithm (BIDI). This is useful for supporting Arabic and Hebrew alphabets in other packages.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

FriBidi Dependencies

Optional

c2man (to build man pages)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/fribidi

Installation of FriBidi

Install FriBidi by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Program: fribidi
Installed Library: libfribidi.so
Installed Directory: /usr/include/fribidi

Short Descriptions

fribidi

is a command-line interface to the libfribidi library and can be used to convert a logical string to visual output

libfribidi.so

contains functions used to implement the Unicode Bidirectional Algorithm

Last updated on

gegl-0.4.34

Introduction to gegl

This package provides the GEneric Graphics Library, which is a graph based image processing format.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

gegl Dependencies

Required

babl-0.1.88, JSON-GLib-1.6.6, libjpeg-turbo-2.1.2, and libpng-1.6.37

Recommended
Optional

asciidoc-10.1.1, Cairo-1.17.4, Exiv2-0.27.5, FFmpeg-4.4.1, gdk-pixbuf-2.42.6, gexiv2-0.14.0, GTK-Doc-1.33.2, JasPer-2.0.33, Little CMS-2.13.1, librsvg-2.52.6, libtiff-4.3.0, libwebp-1.2.2, Pango-1.50.4, Ruby-3.1.0, SDL2-2.0.20, v4l-utils-1.22.1, Vala-0.54.7, libspiro-20200505, lensfun, libopenraw, libumfpack, LuaJIT, MRG, and OpenEXR

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gegl

Installation of gegl

If installing over a previous version of gegl, one module needs to be removed. As the root user, run:

rm -f /usr/lib/gegl-0.4/vector-fill.so

Install gegl by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

-Ddocs=true: Build and install documentation (requires GTK-Doc-1.33.2,).

Contents

Installed Programs: gegl and gegl-imgcmp
Installed Libraries: libgegl-0.4.so, libgegl-npd-0.4.so, libgegl-sc-0.4.so, and modules in /usr/lib/gegl-0.4
Installed Directories: /usr/lib/gegl-0.4 and /usr/include/gegl-0.4

Short Descriptions

gegl

is a commandline tool for working with the XML data model

gegl-imgcmp

is a simple image difference detection tool for use in regression testing

libgegl-0.4.so

provides infrastructure to do demand based cached non destructive image editing on larger than RAM buffers

libgegl-npd-0.4.so

is the GEGL N-point image deformation library

libgegl-sc-0.4.so

is the GEGL Seamless Cloning library

Last updated on

giflib-5.2.1

Introduction to giflib

The giflib package contains libraries for reading and writing GIFs as well as programs for converting and working with GIF files.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

giflib Dependencies

Required

xmlto-0.0.28

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/giflib

Installation of giflib

Install giflib by running the following commands:

make

This package does not come with a test suite.

Now, as the root user:

make PREFIX=/usr install &&

rm -fv /usr/lib/libgif.a &&

find doc \( -name Makefile\* -o -name \*.1 \
         -o -name \*.xml \) -exec rm -v {} \; &&

install -v -dm755 /usr/share/doc/giflib-5.2.1 &&
cp -v -R doc/* /usr/share/doc/giflib-5.2.1

Command Explanations

rm -fv /usr/lib/libgif.a: This command removes a static library which is not used by any BLFS package.

find doc ... -exec rm -v {} \;: This command removes Makefiles, man and xml files from the documentation directory that would otherwise be installed by the commands that follow.

Contents

Installed Programs: gif2rgb, gifbuild, gifclrmp, giffix, giftext, and giftool
Installed Library: libgif.so
Installed Directory: /usr/share/doc/giflib-5.2.1

Short Descriptions

gif2rgb

converts images saved as GIF to 24-bit RGB images

gifbuild

dumps GIF data in a textual format, or undumps it to a GIF

gifclrmp

modifies GIF image colormaps

giffix

clumsily attempts to fix truncated GIF images

giftext

prints (text only) general information about a GIF file

giftool

is a GIF transformation tool

libgif.so

contains API functions required by the giflib programs and any other programs needing library functionality to read, write and manipulate GIF images

Last updated on

GLM-0.9.9.8

Introduction to GLM

OpenGL Mathematics (GLM) is a header-only C++ mathematics library for graphics software based on the OpenGL Shading Language (GLSL) specifications. An extension system provides extended capabilities such as matrix transformations and quaternions.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/GLM

Installation of GLM

Note

This package is unusual as it includes its functionality in header files. We just copy them into position.

As the root user:

cp -r glm /usr/include/ &&
cp -r doc /usr/share/doc/glm-0.9.9.8

Contents

Installed Program: None
Installed Library: None
Installed Directory: /usr/include/glm

Last updated on

Graphite2-1.3.14

Introduction to Graphite2

Graphite2 is a rendering engine for graphite fonts. These are TrueType fonts with additional tables containing smart rendering information and were originally developed to support complex non-Roman writing systems. They may contain rules for e.g. ligatures, glyph substitution, kerning, justification - this can make them useful even on text written in Roman writing systems such as English. Note that firefox by default provides an internal copy of the graphite engine and cannot use a system version (although it can now be patched to use it), but it too should benefit from the availability of graphite fonts.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Graphite2 Dependencies

Required

CMake-3.22.2

Optional

FreeType-2.11.1, silgraphite to build the comparerender test and benchmarking tool, and if that is present, and HarfBuzz-3.4.0 to add more functionality to it (this is a circular dependency, you would need to first build graphite2 without harfbuzz).

To build the documentation: asciidoc-10.1.1, Doxygen-1.9.3, texlive-20210325 (or install-tl-unx), and dblatex (for PDF docs)

To execute the test suite you will need FontTools (Python 3 module), otherwise, the "cmp" tests fail.

Optional (at runtime)

You will need at least one suitable graphite font for the package to be useful.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/graphite2

Installation of Graphite2

Some tests fail if FontTools (Python 3 module) is not installed. These tests can be removed with:

sed -i '/cmptest/d' tests/CMakeLists.txt

Install Graphite2 by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr .. &&
make

If you wish to build the documentation, issue:

make docs

To test the results, issue: make test.

Now, as the root user:

make install

If you built the documentation, install, as the root user:

install -v -d -m755 /usr/share/doc/graphite2-1.3.14 &&

cp      -v -f    doc/{GTF,manual}.html \
                    /usr/share/doc/graphite2-1.3.14 &&
cp      -v -f    doc/{GTF,manual}.pdf \
                    /usr/share/doc/graphite2-1.3.14

Command Explanations

-DCMAKE_VERBOSE_MAKEFILE=ON: This switch turns on build verbose mode.

Contents

Installed Programs: gr2fonttest, and optionally comparerender
Installed Libraries: libgraphite2.so
Installed Directories: /usr/{include,share}/graphite2 and optionally /usr/share/doc/graphite2-1.3.14

Short Descriptions

comparerender

is a test and benchmarking tool

gr2fonttest

is a diagnostic console tool for graphite fonts

libgraphite2.so

is a rendering engine for graphite fonts

Last updated on

HarfBuzz-3.4.0

Introduction to Harfbuzz

The HarfBuzz package contains an OpenType text shaping engine.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

HarfBuzz Dependencies

Recommended
Optional

Cairo-1.17.4 (circular: build cairo and all its recommended dependencies, including harfbuzz, first, then rebuild harfbuzz if the cairo backend is needed), git-2.35.1, GTK-Doc-1.33.2, FontTools (Python 3 module, for the testsuite), and ragel

Warning

Recommended dependencies are not strictly required to build the package. However, you might not get expected results at runtime if you don't install them. Please do not report bugs with this package if you have not installed the recommended dependencies.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/harfbuzz

Installation of HarfBuzz

Install HarfBuzz by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr        \
      --buildtype=release  \
      -Dgraphite2=enabled  &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dgraphite2=enabled: This switch enables Graphite2 support, which is required for building texlive-20210325 or LibreOffice-7.3.0.3 with system harfbuzz.

-Ddocs=false: If GTK-Doc-1.33.2 is installed, the documentation is built and installed. This switch prevents that.

Contents

Installed Programs: hb-ot-shape-closure, hb-shape, hb-subset, and hb-view (only if cairo is installed)
Installed Libraries: libharfbuzz.so, libharfbuzz-gobject.so, libharfbuzz-icu.so, and libharfbuzz-subset.so
Installed Directories: /usr/{include,lib/cmake,share/gtk-doc/html}/harfbuzz

Short Descriptions

hb-ot-shape-closure

gives the set of characters contained in a string, represented as single characters and/or single character names. Example: hb-ot-shape-closure /usr/share/fonts/dejavu/DejaVuSans.ttf "Hello World."

hb-shape

is used for the conversion of text strings into positioned glyphs

hb-subset

is used to create subsets of fonts, and display text using them

hb-view

displays a graphical view of a string shape using a particular font as a set of glyphs. The output format is automatically defined by the file extension, the supported ones being ansi/png/svg/pdf/ps/eps. For example: hb-view --output-file=hello.png /usr/share/fonts/dejavu/DejaVuSans.ttf "Hello World."

libharfbuzz.so

is the HarfBuzz text shaping library

libharfbuzz-gobject.so

provides GObject integration for the HarfBuzz text shaping library

libharfbuzz-icu.so

provides ICU integration for the HarfBuzz text shaping library

Last updated on

JasPer-2.0.33

Introduction to JasPer

The JasPer Project is an open-source initiative to provide a free software-based reference implementation of the JPEG-2000 codec.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

JasPer Dependencies

Required

CMake-3.22.2

Recommended
Optional

Freeglut-3.2.2 (required for jiv), Doxygen-1.9.3 (needed for generating html documentation), and texlive-20210325 (needed to regnerate the pdf documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/jasper

Installation of JasPer

Note

The tarball jasper-2.0.33.tar.gz will extract to jasper-version-2.0.33.

First, fix a problem that happens due to cmake-3.22:

sed -i '/GLUT_glut_LIBRARY/s/^/#/' build/cmake/modules/JasOpenGL.cmake

Install JasPer by running the following commands:

mkdir BUILD &&
cd    BUILD &&

cmake -DCMAKE_INSTALL_PREFIX=/usr    \
      -DCMAKE_BUILD_TYPE=Release     \
      -DCMAKE_SKIP_INSTALL_RPATH=YES \
      -DJAS_ENABLE_DOC=NO            \
      -DCMAKE_INSTALL_DOCDIR=/usr/share/doc/jasper-2.0.33 \
      ..  &&
make

To test the results, issue: make test.

Now, as the root user:

make install

Command Explanations

-DCMAKE_SKIP_INSTALL_RPATH=YES: This option removes embedded library search paths.

-DJAS_ENABLE_DOC=NO: This option disables rebuilding the pdf documentation if texlive-20210325 is installed.

Contents

Installed Programs: imgcmp, imginfo, jasper, and jiv
Installed Library: libjasper.so
Installed Directories: /usr/include/jasper and /usr/share/doc/jasper-2.0.33

Short Descriptions

imgcmp

compares two images of the same geometry

imginfo

displays information about an image

jasper

converts images between formats (BMP, JPS, JPC, JPG, PGX, PNM, MIF, and RAS)

jiv

displays images

libjasper.so

is a library used by programs for reading and writing JPEG2000 format files

Last updated on

Little CMS-1.19

Introduction to Little CMS

The Little CMS library is used by other programs to provide color management facilities.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Little CMS Dependencies

Optional

libtiff-4.3.0, libjpeg-turbo-2.1.2, and Python-2.7.18 (with SWIG-4.0.2 also)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lcms

Installation of Little CMS

Install Little CMS by running the following commands:

patch -Np1 -i ../lcms-1.19-cve_2013_4276-1.patch &&

./configure --prefix=/usr --disable-static       &&
make

To test the results, issue: make check.

Now, as the root user:

make install &&
install -v -m755 -d /usr/share/doc/lcms-1.19 &&
install -v -m644    README.1ST doc/* \
                    /usr/share/doc/lcms-1.19

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--with-python: Use this parameter if Python and SWIG are installed.

Contents

Installed Programs: icc2ps, icclink, icctrans, wtpt and optionally, jpegicc, tiffdiff and tifficc
Installed Libraries: liblcms.so and the optional _lcms.so Python module
Installed Directory: /usr/share/doc/lcms-1.19

Short Descriptions

icc2ps

generates PostScript CRD or CSA from ICC profiles

icclink

links two or more profiles into a single device link profile

icctrans

is a color space conversion calculator

jpegicc

is an ICC profile applier for JPEG files

tifficc

is an ICC profile applier for TIFF files

tiffdiff

is a TIFF compare utility

wtpt

shows media white of profiles, identifying black body locus

liblcms.so

is used by the lcms programs as well as other programs to provide color management facilities

Last updated on

Little CMS-2.13.1

Introduction to Little CMS2

The Little Color Management System is a small-footprint color management engine, with special focus on accuracy and performance. It uses the International Color Consortium standard (ICC), which is the modern standard for color management.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Little CMS2 Dependencies

Optional

libjpeg-turbo-2.1.2 and libtiff-4.3.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lcms2

Installation of Little CMS2

Install Little CMS2 by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: jpgicc, linkicc, psicc, tificc, and transicc
Installed Library: liblcms2.so
Installed Directories: None

Short Descriptions

jpgicc

is the Little CMS ICC profile applier for JPEG

linkicc

is the Little CMS ICC device link generator

psicc

is the Little CMS ICC PostScript generator

tificc

is the Little CMS ICC tiff generator

transicc

is the Little CMS ColorSpace conversion calculator

liblcms2.so

contains functions that implement the lcms2 API

Last updated on

libexif-0.6.24

Introduction to libexif

The libexif package contains a library for parsing, editing, and saving EXIF data. Most digital cameras produce EXIF files, which are JPEG files with extra tags that contain information about the image. All EXIF tags described in EXIF standard 2.1 are supported.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libexif Dependencies

Optional (to Build Documentation)

Doxygen-1.9.3 and Graphviz-2.50.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libexif

Installation of libexif

Install libexif by running the following commands:

./configure --prefix=/usr    \
            --disable-static \
            --with-doc-dir=/usr/share/doc/libexif-0.6.24 &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Documentation was built and installed if you have the dependencies shown above installed. If you don't have the dependencies installed, there is a compressed tarball in the source tree doc directory that can be unpacked into /usr/share/doc/libexif-0.6.24.

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Library: libexif.so
Installed Directories: /usr/include/libexif and /usr/share/doc/libexif-0.6.24

Short Descriptions

libexif.so

contains functions used for parsing, editing, and saving EXIF data

Last updated on

Libgxps-0.3.2

Introduction to libgxps

The libgxps package provides an interface to manipulate XPS documents.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Libgxps Dependencies

Required

GTK+-3.24.31, Little CMS-2.13.1, libarchive-3.6.0, libjpeg-turbo-2.1.2, libtiff-4.3.0, and libxslt-1.1.35

Optional

git-2.35.1 and GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libgxps

Installation of Libgxps

Install Libgxps by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: xpstojpeg, xpstopdf, xpstopng, xpstops, and xpstosvg
Installed Library: libgxps.so
Installed Directories: /usr/include/libgxps

Short Descriptions

xpstojpeg

converts XPS documents to a JPEG image

xpstopdf

converts XPS documents to PDF format

xpstopng

converts XPS documents to a PNG image

xpstops

converts XPS documents to PostScript

xpstosvg

converts XPS documents to SVG images

libgxps.so

contains API functions for manipulating XPS documents

Last updated on

libjpeg-turbo-2.1.2

Introduction to libjpeg-turbo

libjpeg-turbo is a fork of the original IJG libjpeg which uses SIMD to accelerate baseline JPEG compression and decompression. libjpeg is a library that implements JPEG image encoding, decoding and transcoding.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libjpeg-turbo Dependencies

Required

CMake-3.22.2 and NASM-2.15.05 or yasm-1.3.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libjpeg-turbo

Installation of libjpeg-turbo

Install libjpeg-turbo by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_BUILD_TYPE=RELEASE  \
      -DENABLE_STATIC=FALSE       \
      -DCMAKE_INSTALL_DOCDIR=/usr/share/doc/libjpeg-turbo-2.1.2 \
      -DCMAKE_INSTALL_DEFAULT_LIBDIR=lib  \
      .. &&
make

To test the results, issue: make test.

Note

If installing libjpeg-turbo over an older jpeg installation, not all library symbolic links are updated properly. To fix this before installation, run the following as the root user:

rm -f /usr/lib/libjpeg.so*

Now, as the root user:

make install

Command Explanations

-DWITH_JPEG8=ON: This switch enables compatibility with libjpeg version 8.

Contents

Installed Programs: cjpeg, djpeg, jpegtran, rdjpgcom, tjbench, and wrjpgcom
Installed Libraries: libjpeg.so and libturbojpeg.so
Installed Directories: /usr/share/doc/libjpeg-turbo-2.1.2

Short Descriptions

cjpeg

compresses image files to produce a JPEG/JFIF file on the standard output. Currently supported input file formats are: PPM (PBMPLUS color format), PGM (PBMPLUS gray-scale format), BMP, and Targa

djpeg

decompresses image files from JPEG/JFIF format to either PPM (PBMPLUS color format), PGM (PBMPLUS gray-scale format), BMP, or Targa format

jpegtran

is used for lossless transformation of JPEG files

rdjpgcom

displays text comments from within a JPEG file

tjbench

is used to benchmark the performance of libjpeg-turbo

wrjpgcom

inserts text comments into a JPEG file

libjpeg.so

contains functions used for reading and writing JPEG images

Last updated on

libmng-2.0.3

Introduction to libmng

The libmng libraries are used by programs wanting to read and write Multiple-image Network Graphics (MNG) files which are the animation equivalents to PNG files.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libmng Dependencies

Required

libjpeg-turbo-2.1.2 and Little CMS-2.13.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libmng

Installation of libmng

Install libmng by running the following commands:

./configure --prefix=/usr --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&

install -v -m755 -d        /usr/share/doc/libmng-2.0.3 &&
install -v -m644 doc/*.txt /usr/share/doc/libmng-2.0.3

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Library: libmng.so
Installed Directory: /usr/share/doc/libmng-2.0.3

Short Descriptions

libmng.so

provides functions for programs wishing to read and write MNG files which are animation files without the patent problems associated with certain other formats

Last updated on

libmypaint-1.6.1

Introduction to libmypaint

The libmypaint package, a.k.a. "brushlib", is a library for making brushstrokes which is used by MyPaint and other projects.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libmypaint Dependencies

Required

JSON-C-0.15

Recommended
Optional

Doxygen-1.9.3 (to create XML docs), gegl (0.3 versions only) and gperftools

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libmypaint

Installation of libmypaint

Install libmypaint by running the following commands:

./configure --prefix=/usr &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Contents

Installed Programs: None.
Installed Libraries: libmypaint.so (and optionally libmypaint-gegl.so which is not used by any packages in this book).
Installed Directory: /usr/include/libmypaint

Short Descriptions

libmypaint.so

contains functions for making brushstrokes

Last updated on

libpng-1.6.37

Introduction to libpng

The libpng package contains libraries used by other programs for reading and writing PNG files. The PNG format was designed as a replacement for GIF and, to a lesser extent, TIFF, with many improvements and extensions and lack of patent problems.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libpng

Installation of libpng

If you want to patch libpng to support apng files, apply it here:

gzip -cd ../libpng-1.6.37-apng.patch.gz | patch -p1

Install libpng by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install &&
mkdir -v /usr/share/doc/libpng-1.6.37 &&
cp -v README libpng-manual.txt /usr/share/doc/libpng-1.6.37

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: libpng-config (symlink), libpng16-config, pngfix and png-fix-itxt
Installed Libraries: libpng.so
Installed Directories: /usr/include/libpng16 and /usr/share/doc/libpng-1.6.37

Short Descriptions

pngfix

tests, optimizes and optionally fixes the zlib header in PNG files. Optionally, when fixing, strips ancillary chunks from the file

png-fix-itxt

fixes PNG files that have an incorrect length field in the iTXt chunks

libpng-config

is a shell script that provides configuration information for applications wanting to use libpng

libpng.so

contain routines used to create and manipulate PNG format graphics files

Last updated on

libraw-0.20.2

Introduction to libraw

Libraw is a library for reading RAW files obtained from digital photo cameras (CRW/CR2, NEF, RAF, DNG, and others).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libraw Dependencies

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libraw

Installation of libraw

Install libraw by running the following commands:

autoreconf -fiv              &&
./configure --prefix=/usr    \
            --enable-jpeg    \
            --enable-jasper  \
            --enable-lcms    \
            --disable-static \
            --docdir=/usr/share/doc/libraw-0.20.2 &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--enable-jpeg: This switch enables support for jpeg. Remove if you don't have libjpeg-turbo-2.1.2 installed.

--enable-jasper: This switch enables support for jasper. Remove if you don't have JasPer-2.0.33 installed.

--enable-lcms: This switch enables support for Little CMS2. Remove if you don't have Little CMS-2.13.1 installed.

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Note

All the installed programs are examples of using libraw.

Installed Programs: 4channels, dcraw_emu, dcraw_half, half_mt, mem_image, multirender_test, postprocessing_benchmark, raw-identify, simple_dcraw, and unprocessed_raw
Installed Library: libraw.so and libraw_r.so
Installed Directories: /usr/include/libraw and /usr/share/doc/libraw-0.20.2

Short Descriptions

4channels

generates four TIFF files from RAW data, one file per channel

dcraw_half

emulates "dcraw -h" (see DCRAW manpage)

mem_image

emulates "dcraw [-4] [-6] [-e]" (see DCRAW manpage)

postprocessing_benchmark

creates eight different renderings from one source file. The first and fourth one should be identical

simple_dcraw

emulates call to "dcraw [-D] [-T] [-v] [-e] [-4]" (see DCRAW manpage)

dcraw_emu

is an almost complete dcraw emulator (see DCRAW manpage)

half_mt

emulates call to "dcraw -h [-w] [-a] [-v]" (see DCRAW manpage)

multirender_test

creates eight different renderings from one source file. The first and fourth one should be identical

raw-identify

emulates call to "dcraw -i [-v]" (see DCRAW manpage)

unprocessed_raw

generates unprocessed raw image: with masked pixels and without black subtraction

Last updated on

librsvg-2.52.6

Introduction to librsvg

The librsvg package contains a library and tools used to manipulate, convert and view Scalable Vector Graphic (SVG) images.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

librsvg Dependencies

Required

gdk-pixbuf-2.42.6, Cairo-1.17.4, Pango-1.50.4, and rustc-1.58.1

Recommended
Optional

GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/librsvg

Installation of librsvg

Install librsvg by running the following commands:

./configure --prefix=/usr    \
            --enable-vala    \
            --disable-static \
            --docdir=/usr/share/doc/librsvg-2.52.6 &&
make

To test the results, issue: make -k check.

Now, as the root user:

make install

Note

If you installed the package on to your system using a DESTDIR method, an important file was not installed and should be copied and/or generated. Generate it using the following command as the root user:

gdk-pixbuf-query-loaders --update-cache

Command Explanations

--enable-vala: This switch enables building of the Vala bindings. Remove this switch if you don't have Vala-0.54.7 installed.

--disable-static: This switch prevents installation of static versions of the libraries.

--disable-introspection: Use this switch if you have not installed Gobject Introspection.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: rsvg-convert
Installed Library: librsvg-2.so and libpixbufloader-svg.so
Installed Directories: /usr/include/librsvg-2.0, /usr/share/doc/librsvg-2.52.6, and /usr/share/gtk-doc/html/rsvg-2.0

Short Descriptions

rsvg-convert

is used to convert images into PNG, PDF, PS, SVG and other formats

librsvg-2.so

provides the functions to render Scalable Vector Graphics

libpixbufloader-svg.so

is the Gdk Pixbuf plugin that allows GTK+ applications to render Scalable Vector Graphics images

Last updated on

Libspiro-20200505

Introduction to libspiro

Libspiro will take an array of spiro control points and convert them into a series of bezier splines which can then be used in the myriad of ways the world has come to use beziers.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libspiro

Installation of libspiro

Install libspiro by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Library: libspiro.so
Installed Directories: None

Short Descriptions

libspiro.so

is a shareable library that can be used by programs to do the Spiro computations for you

Last updated on

libtiff-4.3.0

Introduction to libtiff

The libtiff package contains the TIFF libraries and associated utilities. The libraries are used by many programs for reading and writing TIFF files and the utilities are used for general work with TIFF files.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libtiff Dependencies

Recommended
Optional

Freeglut-3.2.2 (required for tiffgt), libjpeg-turbo-2.1.2, libwebp-1.2.2, and JBIG-KIT

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libtiff

Installation of libtiff

Install libtiff by running the following commands:

mkdir -p libtiff-build &&
cd       libtiff-build &&

cmake -DCMAKE_INSTALL_DOCDIR=/usr/share/doc/libtiff-4.3.0 \
      -DCMAKE_INSTALL_PREFIX=/usr -G Ninja .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install
sed -i /Version/s/\$/$(cat ../VERSION)/ /usr/lib/pkgconfig/libtiff-4.pc

Command Explanations

sed -i /Version/...: When building with cmake/ninja, the Version field in the pkgconfig file is empty. This command fixes that field.

Contents

Installed Programs: fax2ps, fax2tiff, pal2rgb, ppm2tiff, raw2tiff, tiff2bw, tiff2pdf, tiff2ps, tiff2rgba, tiffcmp, tiffcp, tiffcrop, tiffdither, tiffdump, tiffgt, tiffinfo, tiffmedian, tiffset and tiffsplit
Installed Libraries: libtiff.so and libtiffxx.so
Installed Directory: /usr/share/doc/tiff-4.3.0

Short Descriptions

fax2ps

converts a TIFF facsimile to compressed PostScript file

fax2tiff

creates a TIFF Class F fax file from raw fax data

pal2rgb

converts a palette color TIFF image to a full color image

ppm2tiff

creates a TIFF file from a PPM image file

raw2tiff

converts a raw byte sequence into TIFF

tiff2bw

converts a color TIFF image to grayscale

tiff2pdf

converts a TIFF image to a PDF document

tiff2ps

converts a TIFF image to a PostScript file

tiff2rgba

converts a wide variety of TIFF images into an RGBA TIFF image

tiffcmp

compares two TIFF files

tiffcp

copies (and possibly converts) a TIFF file

tiffcrop

selects, copies, crops, converts, extracts and/or processes one or more TIFF files

tiffdither

converts a grayscale image to bilevel using dithering

tiffdump

prints verbatim information about TIFF files

tiffgt

displays an image stored in a TIFF file

tiffinfo

prints information about TIFF files

tiffmedian

applies the median cut algorithm to data in a TIFF file

tiffset

sets the value of a TIFF header to a specified value

tiffsplit

splits a multi-image TIFF into single-image TIFF files

libtiff.so

contains the API functions used by the libtiff programs as well as other programs to read and write TIFF files

libtiffxx.so

contains the C++ API functions used by programs to read and write TIFF files

Last updated on

libwebp-1.2.2

Introduction to libwebp

The libwebp package contains a library and support programs to encode and decode images in WebP format.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libwebp Dependencies

Recommended
Optional

Freeglut-3.2.2 and giflib-5.2.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libwebp

Installation of libwebp

Install libwebp by running the following commands:

./configure --prefix=/usr           \
            --enable-libwebpmux     \
            --enable-libwebpdemux   \
            --enable-libwebpdecoder \
            --enable-libwebpextras  \
            --enable-swap-16bit-csp \
            --disable-static        &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--enable-swap-16bit-csp: This switch enables byte swap for 16 bit colorspaces.

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: cwebp, dwebp, gif2webp, img2webp, vwebp, webpinfo, and webpmux
Installed Library: libwebpdecoder.so, libwebpdemux.so, libwebpmux.so, and libwebp.so
Installed Directory: /usr/include/webp

Short Descriptions

cwebp

compresses an image using the WebP format

dwebp

decompresses WebP files into PNG, PAM, PPM or PGM images

gif2webp

converts a GIF image to a WebP image

img2webp

creates an animated WebP file from a sequence of input images

vwebp

decompresses a WebP file and displays it in a window

webpinfo

prints out the cunk level structure of WebP files along with performing basic integrity checks

webpmux

creates animated WebP files from non-animated WebP images, extracts frames from animated WebP images, and manages XMP/EXIF metadata and ICC profile

libwebp.so

contains the API functions for WebP encoding and decoding

Last updated on

mypaint-brushes-1.3.1

Introduction to mypaint-brushes

The mypaint-brushes package contains brushes used by packages which use libmypaint.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

mypaint-brushes Dependencies

Required at runtime

libmypaint-1.6.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/mypaint-brushes

Installation of mypaint-brushes

Install mypaint-brushes by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None.
Installed Libraries: None.
Installed Directories: /usr/share/mypaint-data.

Last updated on

newt-0.52.21

Introduction to newt

Newt is a programming library for color text mode, widget based user interfaces. It can be used to add stacked windows, entry widgets, checkboxes, radio buttons, labels, plain text fields, scrollbars, etc., to text mode user interfaces. Newt is based on the S-Lang library.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Newt Dependencies

Required

popt-1.18 and slang-2.3.2

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/newt

Installation of newt

Install newt by running the following command:

sed -e 's/^LIBNEWT =/#&/'                   \
    -e '/install -m 644 $(LIBNEWT)/ s/^/#/' \
    -e 's/$(LIBNEWT)/$(LIBNEWTSONAME)/g'    \
    -i Makefile.in                          &&

./configure --prefix=/usr           \
            --with-gpm-support      \
            --with-python=python3.10 &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

sed -e ... -i Makefile.in: Disables installation of a static library.

--with-gpm-support: This switch enables mouse support for newt applications through GPM.

--with-python=python3.10: By giving explicitly the name of the directory where python modules reside, this switch prevents building the python2 module.

Contents

Installed Programs: whiptail
Installed Library: libnewt.so, whiptcl.so, and /usr/lib/python3.10/site-packages/_snack.so
Installed Directories: None

Short Descriptions

whiptail

displays dialog boxes from shell scripts

libnewt.so

is the library for color text mode, widget based user interfaces

Last updated on

opencv-4.5.5

Introduction to opencv

The opencv package contains graphics libraries mainly aimed at real-time computer vision.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Note

One additional file that starts with "ippicv" (integrated performance primitives) will be automatically downloaded during the cmake portion of the build procedure. This download is specific to the system architecture.

opencv Dependencies

Required

CMake-3.22.2 and UnZip-6.0

Recommended
Optional

apache-ant-1.10.12, Doxygen-1.9.3, Java-17.0.2, Python-2.7.18, blas, Cuda, Eigen, OpenEXR, GDAL, lapack, libdc1394, NumPy, Threading Building Blocks (TBB), and VTK - The Visualization Toolkit,

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/opencv

Installation of opencv

If needed, unpack the additional modules package:

tar xf ../opencv_contrib-4.5.5.tar.gz

Install opencv by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr      \
      -DCMAKE_BUILD_TYPE=Release       \
      -DENABLE_CXX11=ON                \
      -DBUILD_PERF_TESTS=OFF           \
      -DWITH_XINE=ON                   \
      -DBUILD_TESTS=OFF                \
      -DENABLE_PRECOMPILED_HEADERS=OFF \
      -DCMAKE_SKIP_RPATH=ON            \
      -DBUILD_WITH_DEBUG_INFO=OFF      \
      -Wno-dev  ..                     &&
make

The package does not come with an operable test suite.

Now, as the root user:

make install

Command Explanations

-DWITH_XINE=ON: This option instructs the make procedure to use xine-lib-1.2.11.

-DENABLE_PRECOMPILED_HEADERS=OFF: This option is needed for compatibiiity with gcc-6.1 and later.

-DOPENCV_EXTRA_MODULES_PATH=../opencv_contrib-4.5.5/modules: instructs the build system to build additional modules.

Contents

Installed Programs: opencv_annotation, opencv_interactive-calibration, opencv_model_diagnostics, opencv_version, opencv_visualisation, and setup_vars_opencv4.sh
Installed Libraries: libopencv_calib3d.so, libopencv_core.so, libopencv_dnn.so, libopencv_features2d.so, libopencv_flann.so, libopencv_gapi.so, libopencv_highgui.so, libopencv_imgcodecs.so, libopencv_imgproc.so, libopencv_ml.so, libopencv_objdetect.so, libopencv_photo.so, libopencv_stitching.so, libopencv_video.so, and libopencv_videoio.so
Installed Directories: /usr/include/opencv4, /usr/lib/cmake/opencv4, /usr/lib/python3.10/site-packages/cv2, /usr/share/licenses/opencv4, /usr/share/opencv4, and /usr/share/java/opencv4

Last updated on

OpenJPEG-2.4.0

Introduction to OpenJPEG

OpenJPEG is an open-source implementation of the JPEG-2000 standard. OpenJPEG fully respects the JPEG-2000 specifications and can compress/decompress lossless 16-bit images.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

OpenJPEG Dependencies

Required

CMake-3.22.2

Optional

Little CMS-2.13.1, libpng-1.6.37, libtiff-4.3.0, and Doxygen-1.9.3 (to build the API documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/openjpeg2

Installation of OpenJPEG

Install OpenJPEG by running the following commands:

mkdir -v build &&
cd       build &&

cmake -DCMAKE_BUILD_TYPE=Release \
      -DCMAKE_INSTALL_PREFIX=/usr \
      -DBUILD_STATIC_LIBS=OFF .. &&
make

This package does not come with a working test suite.

Now, as the root user:

make install &&

pushd ../doc &&
  for man in man/man?/* ; do
      install -v -D -m 644 $man /usr/share/$man
  done
popd

Contents

Installed Programs: opj_compress, opj_decompress, and opj_dump
Installed Libraries: libopenjp2.so
Installed Directories: /usr/include/openjpeg-2.4 and /usr/lib/openjpeg-2.4

Short Descriptions

opj_compress

converts various image formats to the jpeg2000 format

opj_decompress

converts jpeg2000 images to other image types

opj_dump

reads in a jpeg2000 image and dumps the contents to stdout

Last updated on

Pixman-0.40.0

Introduction to Pixman

The Pixman package contains a library that provides low-level pixel manipulation features such as image compositing and trapezoid rasterization.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Pixman Dependencies

Optional

GTK+-2.24.33 and libpng-1.6.37 (for tests and demos)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pixman

Installation of Pixman

Install Pixman by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: None
Installed Library: libpixman-1.so
Installed Directory: /usr/include/pixman-1

Short Descriptions

libpixman-1.so

contains functions that provide low-level pixel manipulation features

Last updated on

Poppler-22.02.0

Introduction to Poppler

The Poppler package contains a PDF rendering library and command line tools used to manipulate PDF files. This is useful for providing PDF rendering functionality as a shared library.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://poppler.freedesktop.org/poppler-22.02.0.tar.xz

  • Download MD5 sum: 5f167d859b0ec3f416dbd929892c3c4d

  • Download size: 1.7 MB

  • Estimated disk space required: 109 MB (with Qt5 library and tests)

  • Estimated build time: 0.8 SBU (with parallelism=4, Qt5 library, and tests)

Additional Downloads

Poppler Encoding Data

The additional package consists of encoding files for use with Poppler. The encoding files are optional and Poppler will automatically read them if they are present. When installed, they enable Poppler to render CJK and Cyrillic properly.

Poppler Dependencies

Required

CMake-3.22.2 and Fontconfig-2.13.1

Recommended
Optional

cURL-7.81.0, gdk-pixbuf-2.42.6, git-2.35.1 (for downloading test files), gobject-introspection-1.70.0, GTK-Doc-1.33.2, GTK+-3.24.31, libtiff-4.3.0, Qt-5.15.2 (required for PDF support in Okular-21.12.2), and Qt-6.1 or later.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/poppler

Installation of Poppler

Install Poppler by running the following commands:

mkdir build                         &&
cd    build                         &&

cmake  -DCMAKE_BUILD_TYPE=Release   \
       -DCMAKE_INSTALL_PREFIX=/usr  \
       -DTESTDATADIR=$PWD/testfiles \
       -DENABLE_UNSTABLE_API_ABI_HEADERS=ON \
       ..                           &&
make

In order to run the test suite, some testcases are needed and can be obtained only from a git repository. The command to download them is: git clone --depth 1 git://git.freedesktop.org/git/poppler/test testfiles. Then issue: LC_ALL=en_US.UTF-8 make test.

Now, as the root user:

make install

To install the documentation, run the following commands as root:

install -v -m755 -d           /usr/share/doc/poppler-22.02.0 &&
cp -vr ../glib/reference/html /usr/share/doc/poppler-22.02.0

Poppler Data

If you downloaded the additional encoding data package, install it by issuing the following commands:

tar -xf ../../poppler-data-0.4.11.tar.gz &&
cd poppler-data-0.4.11

Now, as the root user:

make prefix=/usr install

Command Explanations

-DCMAKE_BUILD_TYPE=Release: This switch is used to apply a higher level of compiler optimizations.

-DTESTDATADIR=$PWD/testfiles: Tells the test programs where the auxiliary files are located.

-DENABLE_UNSTABLE_API_ABI_HEADERS=ON: Installs some old Xpdf headers required by certain programs.

-DENABLE_GTK_DOC=ON: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

-DENABLE_BOOST=OFF: Use this parameter if you have not installed boost (the Splash backend for Qt5 recommends boost).

LC_ALL=en_US.UTF-8 make test: Runs the test suite. The environment variable LC_ALL=en_US.UTF-8 is only needed if the default locale does not include UTF-8.

Contents

Installed Programs: pdfattach, pdfdetach, pdffonts, pdfimages, pdfinfo, pdfseparate, pdfsig, pdftocairo, pdftohtml, pdftoppm, pdftops, pdftotext, and pdfunite
Installed Libraries: libpoppler.so, libpoppler-cpp.so, libpoppler-glib.so, and libpoppler-qt5.so
Installed Directories: /usr/include/poppler, /usr/share/poppler, and /usr/share/doc/poppler-22.02.0

Short Descriptions

pdfattach

adds a new embedded file to an existing PDF file

pdfdetach

lists or extracts embedded files from PDF files

pdffonts

lists the fonts used in a PDF file along with various information for each font

pdfimages

saves images from a PDF file as PPM, PBM, or JPEG files

pdfinfo

prints the contents of the 'Info' dictionary (plus some other useful information) from a PDF file

pdfseparate

extracts single pages from a PDF file

pdfsig

verifies the digital signatures in a PDF document

pdftocairo

converts a PDF file to one of several formats (PNG, JPEG, PDF, PS, EPS, SVG) using the cairo output device of the poppler library

pdftohtml

converts a PDF file to HTML

pdftoppm

converts PDF files to PBM, PGM and PPM formats

pdftops

converts PDF files to Postscript format

pdftotext

converts PDF files to plain text

pdfunite

merges several PDF files, in the order of their occurrence on the command line, to one PDF output file

libpoppler.so

contains the API functions to render PDF files

libpoppler-cpp.so

is a C++ backend for rendering PDF files

libpoppler-glib.so

is a wrapper library used to interface the PDF rendering functions with GTK+

libpoppler-qt5.so

is a wrapper library used to interface the PDF rendering functions with Qt5

Last updated on

Potrace-1.16

Introduction to Potrace

Potrace™ is a tool for transforming a bitmap (PBM, PGM, PPM, or BMP format) into one of several vector file formats.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Potrace Dependencies

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/potrace

Installation of Potrace

Install Potrace by running the following commands:

./configure --prefix=/usr                        \
            --disable-static                     \
            --docdir=/usr/share/doc/potrace-1.16 \
            --enable-a4                          \
            --enable-metric                      \
            --with-libpotrace                    &&
make

To run the test suite, issue: make check.

Now, as the root user:

make install

Command Explanations

--enable-a4: Use A4 as the default paper size.

--enable-metric: Use metric units (centimeters) as default

--disable-static: This switch prevents installation of static versions of the libraries.

--with-libpotrace: Install the library and headers.

Contents

Installed Programs: mkbitmap, potrace
Installed Libraries: libpotrace.so
Installed Directories: /usr/share/doc/potrace-1.16

Short Descriptions

mkbitmap

transforms images into bitmaps with scaling and filtering

potrace

transforms bitmaps into vector graphics

libpotrace.so

is a library for transforming bitmaps into vector graphics

Last updated on

Qpdf-10.6.2

Introduction to Qpdf

The Qpdf package contains command-line programs and a library that does structural, content-preserving transformations on PDF files.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Qpdf Dependencies

Required

libjpeg-turbo-2.1.2

Optional

fop-2.7, GnuTLS-3.7.3, and libxslt-1.1.35

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/qpdf

Installation of Qpdf

Install Qpdf by running the following commands:

./configure --prefix=/usr    \
            --disable-static \
            --docdir=/usr/share/doc/qpdf-10.6.2 &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: fix-qdf, qpdf, and zlib-flate
Installed Library: libqpdf.so
Installed Directories: /usr/include/qpdf and /usr/share/doc/qpdf-10.6.2

Short Descriptions

fix-qdf

is used to repair PDF files in QDF form after editing

qpdf

is used to convert one PDF file to another equivalent PDF file

zlib-flate

is a raw zlib compression program

libqpdf.so

contains the Qpdf API functions

Last updated on

qrencode-4.1.1

Introduction to qrencode

Qrencode is a fast and compact library for encoding data in a QR Code symbol, a 2D symbology that can be scanned by handheld terminals such as a mobile phone with a CCD sensor.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://fukuchi.org/works/qrencode/qrencode-4.1.1.tar.bz2

  • Download MD5 sum: de7185bcab635a34730e1b73d4efa705

  • Download size: 451 KB

  • Estimated disk space required: 5.0 MB (with documentation, add 5 MB for tests)

  • Estimated build time: less than 0.1 SBU, add 0.1 SBU for tests

Qrencode Dependencies

Recommended
Optional

Doxygen-1.9.3 for generating documentation, and SDL2-2.0.20 for tests

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/qrencode

Installation of qrencode

Install libqrencode by running the following commands:

./configure --prefix=/usr &&
make

If you have installed Doxygen-1.9.3, you can build the documentation by issuing:

doxygen

The tests must be run after installing the package.

Now, as the root user:

make install

If you have built the optional documentation, install it as the root user:

install -vdm 755 /usr/share/doc/qrencode-4.1.1 &&
mv html/* /usr/share/doc/qrencode-4.1.1

To test the results, if you have passed the --with-tests option to configure, issue: make check.

Command Explanations

--with-tests: This option allows building the test programs. It requires SDL2-2.0.20.

--without-tools: This option prevents building the qrencode executable, removing the need for libpng-1.6.37.

Contents

Installed Program: qrencode
Installed Library: libqrencode.so
Installed Directory: /usr/share/doc/qrencode-4.1.1 (optional)

Short Descriptions

qrencode

encodes input data in a QR Code and saves it as a PNG or EPS image

libqrencode.so

contains functions for encoding data in a QR code symbol

Last updated on

sassc-3.6.2

Introduction to sassc

SassC is a wrapper around libsass, a CSS pre-processor language.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/sassc

Installation of sassc

First, build the library:

tar -xf ../libsass-3.6.5.tar.gz &&
pushd libsass-3.6.5 &&

autoreconf -fi &&

./configure --prefix=/usr --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Build the command line wrapper:

popd &&
autoreconf -fi &&

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: sassc
Installed Libraries: libsass.so
Installed Directories: /usr/include/sass

Short Descriptions

sassc

provides a command line interface to the libsass library

Last updated on

woff2-1.0.2

Introduction to WOFF2

WOFF2 is a library for converting fonts from the TTF format to the WOFF 2.0 format. It also allows decompression from WOFF 2.0 to TTF. The WOFF 2.0 format uses the Brotli compression algorithm to compress fonts suitable for downloading in CSS @font-face rules.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

WOFF2 Dependencies

Required

Brotli-1.0.9 and CMake-3.22.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/woff2

Installation of WOFF2

Install WOFF2 by running the following commands:

mkdir out                           &&
cd    out                           &&
cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_BUILD_TYPE=Release .. &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Program: None
Installed Libraries: libwoff2common.so, libwoff2dec.so and libwoff2enc.so
Installed Directory: /usr/include/woff2

Short Descriptions

libwoff2common.so

provides shared data used by the libwoff2dec and libwoff2enc libraries

libwoff2dec.so

is the WOFF2 decoder library

libwoff2enc.so

is the WOFF2 encoder library

Last updated on

Chapter 11. General Utilities

This chapter contains various utilities that do not fit conveniently into other chapters. Programs include some documentation generators, several utilities for manipulating text and graphics, programs for listing files, a program for entering PIN numbers and pass-phrases, and a connection manager.

Asciidoctor-2.0.17

Introduction to Asciidoctor

Asciidoctor is a fast, open source text processor and publishing toolchain for converting AsciiDoc content to HTML5, DocBook, PDF, and other formats.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Asciidoctor Dependencies

Required

Ruby-3.1.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/asciidoctor

Installation of Asciidoctor

Build the Ruby gem:

gem build asciidoctor.gemspec

The test suite needs many Ruby gems beyond the scope of BLFS.

Now, as the root user:

gem install asciidoctor-2.0.17.gem &&
install -vm644 man/asciidoctor.1 /usr/share/man/man1

Contents

Installed Programs: asciidoctor
Installed Libraries: None
Installed Directories: /usr/lib/ruby/gems/3.1.0/gems/asciidoctor-2.0.17 and /usr/lib/ruby/gems/3.1.0/doc/asciidoctor-2.0.17

Short Descriptions

asciidoctor

converts AsciiDoc source files to HTML, DocBook, and other formats

Last updated on

Bogofilter-1.2.5

Introduction to Bogofilter

The Bogofilter application is a mail filter that classifies mail as spam or ham (non-spam) by a statistical analysis of the message's header and content (body).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Bogofilter Dependencies

Required

Berkeley DB-5.3.28

Recommended
Optional

lmdb-0.9.29, SQLite-3.37.2, xmlto-0.0.28, QDBM and TokyoCabinet

Note

If you do not install the recommended Gsl-2.7.1 package then a statically linked shipped version will be used instead.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/bogofilter

Installation of Bogofilter

Note

If you plan to change the version of your database library on an existing installation, or to change to a different database, read the warning at the top of the RELEASE.NOTES file.

Install Bogofilter by running the following commands:

./configure --prefix=/usr --sysconfdir=/etc/bogofilter &&
make

To test the results, issue make check.

Now, as the root user:

make install

Command Explanations

--with-database=: This switch allows you to change the default database from db to either qdbm, sqlite3 or tokyocabinet.

Contents

Installed Programs: bf_compact, bf_copy, bf_tar, bogofilter, bogolexer, bogotune, bogoupgrade and bogoutil
Installed Libraries: None
Installed Directories: /etc/bogofilter

Short Descriptions

bf_compact

creates a more compact bogofilter working directory with a dump/load cycle

bf_copy

copies a bogofilter working directory to another directory

bf_tar

bundles a bogofilter working directory in tar format and copies it to standard output

bogofilter

is a fast Bayesian spam filter

bogolexer

is used to separate messages into tokens and to test new versions of the lexer.l code

bogotune

attempts to find optimum parameter settings for bogofilter

bogoupgrade

upgrades the bogofilter database to the current version

bogoutil

dumps, loads, and maintains bogofilter database files

Last updated on

Compface-1.5.2

Introduction to Compface

Compface provides utilities and a library to convert from/to X-Face format, a 48x48 bitmap format used to carry thumbnails of email authors in a mail header.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/compface

Installation of Compface

Install Compface by running the following commands:

./configure --prefix=/usr --mandir=/usr/share/man &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&
install -m755 -v xbm2xface.pl /usr/bin

Contents

Installed Programs: compface, uncompface and xbm2xface.pl
Installed Library: libcompface.{so,a}
Installed Directories: None

Short Descriptions

compface

is a filter for generating highly compressed representations of 48x48x1 face image files

uncompface

is an inverse filter which performs an inverse transformation with no loss of data

xbm2xface.pl

is a script to generate xfaces

libcompface.{so,a}

allows the compression and decompression algorithms to be used in other programs such as MTAs

Last updated on

desktop-file-utils-0.26

Introduction to Desktop File Utils

The Desktop File Utils package contains command line utilities for working with Desktop entries. These utilities are used by Desktop Environments and other applications to manipulate the MIME-types application databases and help adhere to the Desktop Entry Specification.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Desktop File Utils Dependencies

Required

GLib-2.70.4

Optional

Emacs-27.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/desktop-file-utils

Installation of Desktop File Utils

Warning

If you are upgrading from a previous version of desktop-file-utils that used the Autotools method of installing and configuring the package, you must remove the desktop-file-edit symlink by using the following commands.

rm -fv /usr/bin/desktop-file-edit

Install Desktop File Utils by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Configuring Desktop File Utils

Configuration Information

The XDG Base Directory specification defines the standard locations for applications to place data and configuration files. These files can be used, for instance, to define the menu structure and menu items in a desktop environment.

The default location for configuration files to be installed is /etc/xdg, and the default locations for data files are /usr/local/share and /usr/share. These locations can be extended with the environment variables XDG_CONFIG_DIRS and XDG_DATA_DIRS, respectively. The GNOME, KDE and XFCE environments respect these settings.

When a package installs a .desktop file to a location in one of the base data directories, the database that maps MIME-types to available applications can be updated. For instance, the cache file at /usr/share/applications/mimeinfo.cache can be rebuilt by executing the following command as the root user:

install -vdm755 /usr/share/applications &&
update-desktop-database /usr/share/applications

Contents

Installed Programs: desktop-file-edit, desktop-file-install, desktop-file-validate and update-desktop-database
Installed Libraries: None
Installed Directories: None

Short Descriptions

desktop-file-edit

is used to modify an existing desktop file entry

desktop-file-install

is used to install a new desktop file entry. It is also used to rebuild or modify the MIME-types application database

desktop-file-validate

is used to verify the integrity of a desktop file

update-desktop-database

is used to update the MIME-types application database

Last updated on

Graphviz-2.50.0

Introduction to Graphviz

The Graphviz package contains graph visualization software. Graph visualization is a way of representing structural information as diagrams of abstract graphs and networks. Graphviz has several main graph layout programs. It also has web and interactive graphical interfaces, auxiliary tools, libraries, and language bindings.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Graphviz Dependencies

Note

Graphviz basic usage does not need any libraries out of what is found in the LFS book. Its core rendering engine allows to generate several graphic formats, such as Postscript, SVG, VML, .fig, and Tk. Those formats can be converted to almost any other format using for example tools from ImageMagick-7.1.0-25. The dependencies below add the ability to generate graph images in bitmap format, to display the graph image on screen, to edit a graph by viewing the resulting image directly, or to view large graphs. Since Graphviz is a dependency of several other packages in this book, it is suggested to first build it without most dependencies, then to rebuild it when you have built enough packages to suit your needs.

Recommended
Optional, for various bitmap outputs

Pango-1.50.4, with Cairo-1.17.4, Xorg Libraries, and Fontconfig-2.13.1

Adding GTK+-2.24.33 with libjpeg-turbo-2.1.2 allows to add JPEG, BMP, TIF, and ICO formats, and to display the image in a GTK+ window

GD Library may be used instead of Pango. It adds the ability to generate images in GIF, VRML, and GD formats, but Pango provides better outputs for the other formats, and is needed for displaying images

Other formats may be added with libwebp-1.2.2 (WebP support is considered experimental), DevIL, libLASi, glitz, and libming (Adobe Flash)

Optional, to load graphic images that may be displayed inside the nodes of a graph

libgs.so from ghostscript-9.55.0, librsvg-2.52.6, and Poppler-22.02.0

Optional, to build more tools

Freeglut-3.2.2 (with libglade-2.6.4, GtkGLExt, and libGTS, for building the smyrna large graph viewer, which is considered experimental), Qt-5.15.2, for building the gvedit graph editor. Another graph editor, dotty needs only Xorg Libraries

Optional (To Build Language Bindings)

SWIG-4.0.2 (SWIG must be installed or no bindings will be built), GCC-11.2.0 (for the go language), Guile-3.0.8, OpenJDK-17.0.2, Lua-5.4.4, PHP-8.1.3, Ruby-3.1.0, Tk-8.6.12, Io, Mono, OCaml, and R

Optional (building tools)

Criterion (framework for tests) and Electric Fence

Optional (for building the pdf documentation)

ghostscript-9.55.0 (for the ps2pdf command)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/graphviz

Installation of Graphviz

Install Graphviz by running the following commands:

sed -i '/LIBPOSTFIX="64"/s/64//' configure.ac &&

./autogen.sh                            &&
./configure --prefix=/usr --disable-php &&
make

This package does not come with a test suite that provides meaningful results.

Now, as the root user:

make install

If desired, create a symbolic link in the system documents directory to the documentation installed in /usr/share/graphviz/doc using the following command as the root user:

ln -svr /usr/share/graphviz/doc /usr/share/doc/graphviz-2.50.0

Command Explanations

sed ... configure.ac: This command is needed to avoid installing files in /usr/lib64.

--disable-php: This version of graphviz does not support php version 8.

--with-javaincludedir="$JAVA_HOME/include -I$JAVA_HOME/include/linux": If you have built OpenJDK-17.0.2 in /opt, and you want to build the JAVA bindings, it is necessary to specify the location of the JAVA header files to configure. The configure switch is designed for only one directory, but two directories need to be included. This is possible nevertheless by using the -I switch inside the variable.

--with-webp: Even if libwebp-1.2.2 is installed, it is not included in the build without this option.

--with-smyrna: Even if the needed dependencies are installed, the interactive graph viewer smyrna is not built without this option.

Configuring Graphviz

Config Files

/usr/lib/graphviz/config

Configuration Information

There are no specific configuration requirements for Graphviz. You may consider installing the additional plugins and tools available from the download page at https://graphviz.org/download/source/ for additional capabilities. If additional plugins are installed, you can run dot -c (as the root user) to update the config file in /usr/lib/graphviz.

Contents

Installed Programs: acyclic, bcomps, ccomps, circo, cluster, diffimg, dijkstra, dot, dot2gxl, dot_builtins, dotty, edgepaint, fdp, gc, gml2gv, graphml2gv, gv2gml, gv2gxl, gvcolor, gvedit, gvgen, gvmap, gvmap.sh, gvpack, gvpr, gxl2dot, gxl2gv, lneato, mm2gv, neato, nop, osage, patchwork, prune, sccmap, sfdp, tred, twopi, unflatten, and vimdot
Installed Libraries: libcdt.so, libcgraph.so, libgvc.so, libgvpr.so, liblab_gamut.so, libpathplan.so, libxdot.so, and several plugins in /usr/lib/graphviz. There are also several in subdirectories of /usr/lib/{lua,perl5, python3.10,tcl8.6}. Unfortunately, some libraries are duplicated.
Installed Directories: /usr/include/graphviz, /usr/lib/graphviz, /usr/lib/tcl8.6/graphviz, /usr/share/doc/graphviz-2.50.0, and /usr/share/graphviz

Short Descriptions

acyclic

is a filter that takes a directed graph as input and outputs a copy of the graph with sufficient edges reversed to make the graph acyclic

bcomps

decomposes graphs into their biconnected components, printing the components to standard output

ccomps

decomposes graphs into their connected components, printing the components to standard output

circo

draws graphs using a circular layout

cluster

takes a graph in DOT format as input, finds node clusters and then augments the graph with this information

diffimg

(needs GD Library) generates an image where each pixel is the difference between the corresponding pixel in each of the two source images

dijkstra

reads a stream of graphs and for each computes the distance of every node from sourcenode

dot

draws directed graphs. It works well on DAGs and other graphs that can be drawn as hierarchies. It reads attributed graph files and writes drawings. By default, the output format dot is the input file with layout coordinates appended

dot2gxl

converts between graphs represented in GXL and in the DOT language. Unless a conversion type is specified using a flag, gxl2dot will deduce the type of conversion from the suffix of the input file, a .dot suffix causing a conversion from DOT to GXL, and a .gxl suffix causing a conversion from GXL to DOT

dotty

is a graph editor for the X Window System. It may be run as a standalone editor, or as a front end for applications that use graphs. It can control multiple windows viewing different graphs

edgepaint

performs edge coloring to disambiguate crossing edges

fdp

draws undirected graphs using a spring model. It relies on a force-directed approach in the spirit of Fruchterman and Reingold

gc

is a graph analogue to wc in that it prints to standard output the number of nodes, edges, connected components or clusters contained in the input files. It also prints a total count for all graphs if more than one graph is given

gml2gv

converts a graph specified in the GML format to a graph in the GV (formerly DOT) format

graphml2gv

converts a graph specified in the GRAPHML format to a graph in the GV (formerly DOT) format

gv2gml

converts a graph specified in the GV format to a graph in the GML format

gv2gxl

converts a graph specified in the GV format to a graph in the GXL format

gvcolor

is a filter that sets node colors from initial seed values. Colors flow along edges from tail to head, and are averaged (as HSB vectors) at nodes

gvedit

provides a simple graph editor and viewer. It allows many graphs to be viewed at the same time. The text of each graph is displayed in its own text window

gvgen

generates a variety of simple, regularly-structured abstract graphs

gvmap

takes as input a graph in DOT format, finds node clusters and produces a rendering of the graph as a geographic-style map, with clusters highlighted, in xdot format

gvmap.sh

is a pipeline for running gvmap

gvpack

reads in a stream of graphs, combines the graphs into a single layout, and produces a single graph serving as the union of the input graphs

gvpr

is a graph stream editor inspired by awk. It copies input graphs to its output, possibly transforming their structure and attributes, creating new graphs, or printing arbitrary information

gxl2dot

converts between graphs represented in GXL and in the DOT language. Unless a conversion type is specified using a flag, gxl2dot will deduce the type of conversion from the suffix of the input file, a .dot suffix causing a conversion from DOT to GXL, and a .gxl suffix causing a conversion from GXL to DOT

gxl2gv

converts between graphs represented in GXL and in the GV language

lefty

is a two-view graphics editor for technical pictures

lneato

is a graph editor for the X Window System. It may be run as a standalone editor, or as a front end for applications that use graphs. It can control multiple windows viewing different graphs

mm2gv

converts a sparse matrix of the Matrix Market format to a graph in the GV (formerly DOT) format

neato

draws undirected graphs using spring models. Input files must be formatted in the dot attributed graph language. By default, the output of neato is the input graph with layout coordinates appended

nop

reads a stream of graphs and prints each in pretty-printed (canonical) format on stdout. If no files are given, it reads from stdin

osage

draws clustered graphs. It takes any graph in DOT format as input

patchwork

draws clustered graphs using a squarified treemap layout. It takes any graph in DOT format as input

prune

reads directed graphs in the same format used by dot and removes subgraphs rooted at nodes specified on the command line via options

sccmap

decomposes digraphs into strongly connected components and an auxiliary map of the relationship between components. In this map, each component is collapsed into a node. The resulting graphs are printed to stdout

sfdp

draws undirected graphs using the spring model, but it uses a multi-scale approach to produce layouts of large graphs in a reasonably short time

tred

computes the transitive reduction of directed graphs, and prints the resulting graphs to standard output. This removes edges implied by transitivity. Nodes and subgraphs are not otherwise affected

twopi

draws graphs using a radial layout. Basically, one node is chosen as the center and put at the origin. The remaining nodes are placed on a sequence of concentric circles centered about the origin, each a fixed radial distance from the previous circle

unflatten

is a preprocessor to dot that is used to improve the aspect ratio of graphs having many leaves or disconnected nodes. The usual layout for such a graph is generally very wide or tall

vimdot

is a simple script which launches the gvim or vim editor along with a GUI window showing the dot output of the edited file

libcdt.so

manages run-time dictionaries using standard container data types: unordered set/multiset, ordered set/multiset, list, stack, and queue

libcgraph.so

supports graph programming by maintaining graphs in memory and reading and writing graph files. Graphs are composed of nodes, edges, and nested subgraphs

libgvc.so

provides a context for applications wishing to manipulate and render graphs. It provides command line parsing interfaces, common rendering code, and a plugin mechanism for renderers

libpathplan.so

contains functions to find the shortest path between two points in a simple polygon

libxdot.so

provides support for parsing and deparsing graphical operations specificed by the xdot language

Last updated on

GTK-Doc-1.33.2

Introduction to GTK-Doc

The GTK-Doc package contains a code documenter. This is useful for extracting specially formatted comments from the code to create API documentation. This package is optional; if it is not installed, packages will not build the documentation. This does not mean that you will not have any documentation. If GTK-Doc is not available, the install process will copy any pre-built documentation to your system.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GTK-Doc Dependencies

Required

docbook-xml-4.5, docbook-xsl-1.79.2, itstool-2.0.7, and libxslt-1.1.35

Recommended
Optional

For tests: dblatex or fop-2.7 (XML PDF support), GLib-2.70.4, Which-2.21, and Python modules lxml-4.7.1, parameterized, and yelp-tools

Note

The optional python modules above can be easily installed with the pip3 command.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gtk-doc

Installation of GTK-Doc

Install GTK-Doc by running the following commands:

autoreconf -fiv           &&
./configure --prefix=/usr &&
make

The test suite will hang if the package (or a previous version) is not already installed.

Now, as the root user:

make install

To test the results, issue: make check. Some tests will fail depending on optionally installed packages.

Contents

Installed Programs: gtkdocize, gtkdoc-check, gtkdoc-depscan, gtkdoc-fixxref, gtkdoc-mkdb, gtkdoc-mkhtml, gtkdoc-mkhtml2, gtkdoc-mkman, gtkdoc-mkpdf, gtkdoc-rebase, gtkdoc-scan, and gtkdoc-scangobj
Installed Libraries: None
Installed Directories: /usr/share/gtk-doc and /usr/share/cmake/GtkDoc

Short Descriptions

gtkdoc*

these are all shell, or Python scripts used by package Makefile scripts to generate documentation for the package being built

Last updated on

Hd2u-1.0.4

Introduction to Hd2u

The hd2u package contains an any to any text format converter.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Hd2u Dependencies

Required

popt-1.18

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/hd2u

Installation of Hd2u

Install hd2u by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Program: dos2unix
Installed Libraries: None
Installed Directories: None

Short Descriptions

dos2unix

converts text between various OS formats (such as converting from DOS format to Unix)

Last updated on

Highlight-4.1

Introduction to Highlight

Highlight is an utility that converts source code to formatted text with syntax highlighting.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Highlight Dependencies

Required

Boost-1.78.0 and Lua-5.4.4

Optional

Qt-5.15.2 (to build the GUI front-end)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/highlight

Installation of Highlight

For consistency, do not compress man pages.

sed -i '/GZIP/s/^/#/' makefile

To build Highlight run the following command:

make

To build the Qt5 GUI front-end, run the following command:

make doc_dir=/usr/share/doc/highlight-4.1/ gui

This package does not come with a test suite.

To install Highlight, run the following command as the root user:

make doc_dir=/usr/share/doc/highlight-4.1/ install

To install the GUI program, run the following command as the root user:

make install-gui

Command Explanations

doc_dir=/usr/share/doc/highlight-4.1/: installs the highlight documentation into a versioned directory. This parameter is also needed for make gui, because its value would be hardcoded into the gui executable. Note that the trailing / is necessary.

Contents

Installed Programs: highlight and highlight-gui (optional)
Installed Libraries: None
Installed Directories: /etc/highlight, /usr/share/doc/highlight/4.1, and /usr/share/highlight

Short Descriptions

highlight

is a universal source code to formatted text converter

highlight-gui

is the Qt5 interface to highlight.

Last updated on

ibus-1.5.25

Introduction to ibus

ibus is an Intelligent Input Bus. It is a new input framework for the Linux OS. It provides a fully featured and user friendly input method user interface.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Optional Download

Unicode Character Database

ibus Dependencies

Required

DConf-0.40.0, ISO Codes-4.9.0, and Vala-0.54.7

Recommended
Optional

GTK+-3.24.31 (to build IM module for it), GTK-4.6.1 (to build IM module for it), D-Bus Python-1.2.18 and PyGObject-3.42.0 (both to build the Python support library), GTK-Doc-1.33.2, PyXDG-0.27 (runtime, for the ibus-setup), and libxkbcommon-1.4.0, Wayland-1.20.0 (both to build the Wayland support programs), and EmojiOne

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/ibus

Installation of ibus

If the optional Unicode Character Database was downloaded, install it now as the root user:

mkdir -p                /usr/share/unicode/ucd &&
unzip -uo ../UCD.zip -d /usr/share/unicode/ucd

Note

Be sure to also remove the --disable-unicode-dict in the configure step below.

Fix an issue with deprecated schema entries:

sed -i 's@/desktop/ibus@/org/freedesktop/ibus@g' \
    data/dconf/org.freedesktop.ibus.gschema.xml

Install ibus by running the following commands:

./configure --prefix=/usr             \
            --sysconfdir=/etc         \
            --disable-unicode-dict    \
            --disable-emoji-dict      &&
rm -f tools/main.c                    &&
make

To test the results, issue: make -k check. The test named ibus-compose fails because it uses some locales not installed in LFS. The test named ibus-keypress is known to fail in Wayland based desktop environment.

Now, as the root user:

make install &&
gzip -dfv /usr/share/man/man{{1,5}/ibus*.gz,5/00-upstream-settings.5.gz}

Command Explanations

--disable-emoji-dict: This switch disables the use of emoticon dictionaries. Omit if you installed the optional package.

--disable-unicode-dict: This switch disables the use of unicode dictionaries. Omit if you installed the optional Unicode Character Database.

rm -f tools/main.c: This command removes a generated file that was not removed when packaging.

--disable-gtk2: This switch disables building the GTK+ 2 immodule. Use it if you have not installed GTK+ 2.

--enable-gtk4: This switch enables building the GTK 4 immodule. Use it if you have installed GTK 4.

--enable-python-library: This switch enables building the Python support library. Use it if you have installed the optional dependencies.

--enable-wayland: This switch enables building the Wayland support programs. Use it if you have installed the optional dependencies.

--with-python=python3: This switch makes the configure script look for Python 3. Use it if you want to build the Python 3 support library alongside the Python 2 one.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

gzip -dfv ...: Decompress installed man pages in accordance with other man pages.

Contents

Installed Programs: ibus, ibus-daemon, and ibus-setup
Installed Library: libibus-1.0.so and im-ibus.so (GTK+ Immodule)
Installed Directories: /etc/dconf/db/ibus.d, /usr/include/ibus-1.0, /usr/share/gtk-doc/html/ibus, and /usr/share/ibus

Short Descriptions

ibus-daemon

is the Intelligent Input Bus Daemon

ibus-setup

is the GTK+ program used to configure the ibus-daemon

libibus-1.0.so

contains the ibus API functions

Last updated on

ImageMagick-7.1.0-25

Introduction to ImageMagick

ImageMagick is a collection of tools and libraries to read, write, and manipulate an image in various image formats. Image processing operations are available from the command line. Bindings for Perl and C++ are also available.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Note

The ImageMagick source releases are updated frequently and the version shown above may no longer be available from the download locations. You can download a more recent version and use the existing BLFS instructions to install it. Chances are that it will work just fine, but this has not been tested by the BLFS team. If the package version shown above is not available from the locations shown above, or from the legacy/ directory at ftp.ImageMagick.org/pub/ImageMagick you can download it from the BLFS package server at Oregon State University: ftp://ftp.osuosl.org/pub/blfs/conglomeration/ImageMagick/.

ImageMagick Dependencies

Recommended

The optional dependencies listed below should be installed if you need support for the specific format or the conversion tool the dependency provides. Additional information about the dependencies can be found in the Install-unix.txt file located in the source tree as well as issuing the ./configure --help command. A summary of this information, as well as some additional notes can be viewed on-line at https://imagemagick.org/script/install-source.php.

Optional System Utilities

Clang from LLVM-13.0.1, Cups-2.4.1, cURL-7.81.0, FFmpeg-4.4.1, fftw-3.3.10, p7zip-17.04 (LZMA), SANE-1.0.32, Wget-1.21.2, xdg-utils-1.1.3, xterm-370, Dmalloc, Electric Fence, PGP or GnuPG-2.2.34 (you'll have to do some hacking to use GnuPG), Profiles, and ufraw (for raw formats listed in https://imagemagick.org/script/formats.php)

Optional Graphics Libraries

JasPer-2.0.33, Little CMS-1.19 or Little CMS-2.13.1, libgxps-0.3.2, libjpeg-turbo-2.1.2, libpng-1.6.37, libraw-0.20.2 (RAW_R), librsvg-2.52.6, libtiff-4.3.0, libwebp-1.2.2, OpenJPEG-2.4.0, Pango-1.50.4, DjVuLibre, FlashPIX (libfpx), FLIF, JBIG-KIT, libheif with libde265 (both needed if converting macOS heic images), libjxl, libraqm, Liquid Rescale, OpenEXR, and RALCGM (or ralcgm)

Optional Graphics Utilities

Dejavu fonts, ghostscript-9.55.0, Gimp-2.10.30, Graphviz-2.50.0, Inkscape-1.1.2, Blender, corefonts, GhostPCL, Gnuplot, POV-Ray, and Radiance

Optional Conversion Tools

Enscript-1.6.6, texlive-20210325 (or install-tl-unx) AutoTrace, GeoExpress Command Line Utilities, AKA MrSID Utilities (binary package), hp2xx, html2ps, libwmf, UniConvertor, and Utah Raster Toolkit (or URT-3.1b)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/imagemagick

Installation of ImageMagick

Install ImageMagick by running the following commands:

./configure --prefix=/usr     \
            --sysconfdir=/etc \
            --enable-hdri     \
            --with-modules    \
            --with-perl       \
            --disable-static  &&
make

Now, as the root user:

make DOCUMENTATION_PATH=/usr/share/doc/imagemagick-7.1.0 install

To test the installation, issue: make check. Note that the EPS, PS, and PDF tests require a working Ghostscript. One test in 'make check' needs Helvetica from Ghostscript Standard Fonts, which are optionally installed in ghostscript-9.55.0 - that test, and one other, might fail, but all the validation can still pass.

Command Explanations

--enable-hdri: Enables building of a high dynamic range version of ImageMagick.

--with-modules: Enables support for dynamically loadable modules.

--with-perl: Enables building and installing of PerlMagick.

--disable-static: This switch prevents installation of static versions of the libraries.

--with-gslib: Enables support to use the Ghostscript shared library.

--with-rsvg: Enables support to use the librsvg library.

--with-autotrace: Enables support to use the Autotrace library.

--with-wmf: Enables support to use the libwmf library.

--with-gvc: Enables support to use GraphViz.

--with-windows-font-dir= <Some/Directory>: This option specifies the directory where the Windows CoreFonts are installed.

--with-dejavu-font-dir= <Some/Directory>: This option specifies the directory where the DejaVu fonts are installed.

The options and parameters listed above are the only ones you should have to pass to the configure script to activate all the delegate dependencies. All other dependencies will be automatically detected and utilized in the build if they are installed.

Contents

Installed Programs: magick, Magick++-config, MagickCore-config, and MagickWand-config. (animate, compare, composite, conjure, convert, display, identify, import, magick-script, mogrify, montage, and stream are all symbolic links to magick)
Installed Libraries: libMagickCore-7.Q16HDRI.so, libMagickWand-7.Q16HDRI.so and libMagick++-7.Q16HDRI.so
Installed Directories: /etc/ImageMagick-7, /usr/include/ImageMagick-7, /usr/lib/ImageMagick-7.1.0, /usr/lib/perl5/site_perl/5.34/{,auto}/Image/Magick, /usr/share/doc/ImageMagick-7.1.0, and /usr/share/ImageMagick-7

Short Descriptions

animate

animates a sequence of images

compare

compares an image to a reconstructed image

composite

composites various images into the given base image

conjure

processes a MSL script to create an image

convert

converts image(s) from one format to another

display

displays an image

identify

describes the format and characteristics of an image file

import

captures an X window

magick

convert between image formats as well as resize an image, blur, crop, despeckle, dither, draw on, flip, join, re-sample and much more

Magick{++,Core,Wand}-config

show information about the installed versions of the ImageMagick libraries

mogrify

transforms an image

montage

composites various images into a new image

stream

streams one or more pixel components of an image or portion of the image to your choice of storage formats

Image::Magick

allows the reading, manipulation and writing of a large number of image file formats using the ImageMagick library. Run make in the PerlMagick/demo directory of the package source tree after the package is installed to see a nice demo of the module's capabilities

libMagickCore-7.Q16HDRI.so

provides the C API for ImageMagick

libMagickWand-7.Q16HDRI.so

is the recommended C API for ImageMagick. Unlike the MagickCore API it uses only a few opaque types

libMagick++-7.Q16HDRI.so

provides the C++ API for ImageMagick

Last updated on

ISO Codes-4.9.0

Introduction to ISO Codes

The ISO Codes package contains a list of country, language and currency names and it is used as a central database for accessing this data.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/iso-codes

Installation of ISO Codes

The directory is called iso-codes-4.9.0.

Install ISO Codes by running the following commands:

./configure --prefix=/usr &&
make

To test the results, issue: make check.

Note

If you install ISO codes over a previous installed version, the install step will fail when creating some symlinks. In order to properly update them, run:

sed -i '/^LN_S/s/s/sfvn/' */Makefile

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: None
Installed Directory: /usr/share/iso-codes, /usr/share/xml/iso-codes

Last updated on

lsof-4.94.0

Introduction to lsof

The lsof package is useful to LiSt Open Files for a given running application or process.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

lsof Dependencies

Required

libtirpc-1.3.2

Optional

Nmap-7.92 (with a symbolic link nc pointing to ncat in /usr/bin; used in tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lsof

Kernel Configuration

To run the tests, the following option should be enabled in the kernel configuration:

General setup  --->
  [*] POSIX Message Queues    [CONFIG_POSIX_MQUEUE]

Installation of lsof

Install lsof by running the following commands:

./Configure -n linux &&
make

The tests should be run as the root user. They require that the POSIX message queues are enabled in the kernel, and that Nmap-7.92 be installed with a symbolic link /usr/bin/nc pointing to ncat.

make check

Two tests fail if the tests are run from a script instead of an interactive session.

Now, as the root user:

install -v -m4755 -o root -g root lsof /usr/bin &&
install -v lsof.8 /usr/share/man/man8

Command Explanations

./Configure -n linux: Avoid AFS, customization, and inventory checks, and use the linux dialect.

install -m4755 ...: lsof should be suid root to allwo users to list all files. This may be a security threat on some systems. In that case change to -m755 and use sudo to run the program.

Contents

Installed Program: lsof
Installed Libraries: None
Installed Directories: None

Short Descriptions

lsof

lists open files for running processes

Last updated on

mandoc-1.14.6

Introduction to mandoc

mandoc is an utility to format manual pages.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of mandoc

Many utilities provided by mandoc conflicts with Man-DB in LFS. Only build the mandoc command:

./configure &&
make mandoc

To test the package, issue: make regress.

Now, as the root user:

install -vm755 mandoc   /usr/bin &&
install -vm644 mandoc.1 /usr/share/man/man1

Contents

Installed Programs: mandoc

Short Descriptions

mandoc

Formats manual pages

Last updated on

pinentry-1.2.0

Introduction to PIN-Entry

The PIN-Entry package contains a collection of simple PIN or pass-phrase entry dialogs which utilize the Assuan protocol as described by the Ägypten project. PIN-Entry programs are usually invoked by the gpg-agent daemon, but can be run from the command line as well. There are programs for various text-based and GUI environments, including interfaces designed for Ncurses (text-based), and for the common GTK and Qt toolkits.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

PIN-Entry Dependencies

Required

libassuan-2.5.5 and libgpg-error-1.44

Optional

Emacs-27.2, FLTK-1.3.8, Gcr-3.40.0, GTK+-2.24.33, libsecret-0.20.5, Qt-5.15.2, and efl

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pinentry

Installation of PIN-Entry

Install PIN-Entry by running the following commands:

./configure --prefix=/usr --enable-pinentry-tty &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--enable-inside-emacs=yes/no: Default is no.

--enable-pinentry-qt=yes/no: Default is yes.

--enable-pinentry-gtk2=yes/no: Default is yes. Even if other pinentry-* is installed, pinentry will be a symlink to pinentry-gtk-2.

--enable-pinentry-gnome3=yes/no: Default is yes. Actually, it uses Gcr for the pinentry dialog.

--enable-pinentry-tty: Default is 'maybe'.

Contents

Installed Programs: pinentry (symlink), pinentry-curses, pinentry-emacs, pinentry-fltk, pinentry-gnome3, pinentry-gtk-2, pinentry-qt, and pinentry-tty
Installed Libraries: None
Installed Directory: None

Short Descriptions

pinentry

is a symbolic link to the default PIN-Entry program

pinentry-curses

is an Ncurses text-based PIN-Entry helper program

pinentry-emacs

is an Emacs version of the PIN-Entry helper program

pinentry-fltk

is a FLTK PIN-Entry helper program

pinentry-gnome3

is a GNOME-3 PIN-Entry helper program

pinentry-gtk-2

is a GTK+2 PIN-Entry program program

pinentry-qt

is a Qt4 or 5 PIN-Entry helper program

pinentry-tty

is a tty PIN-Entry helper program

Last updated on

Rep-gtk-0.90.8.3

Introduction to Rep-gtk

The rep-gtk package contains a Lisp and GTK binding. This is useful for extending GTK-2 and GDK libraries with Lisp. Starting at rep-gtk-0.15, the package contains the bindings to GTK and uses the same instructions. Both can be installed, if needed.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Rep-gtk Dependencies

Required

GTK+-2.24.33 and librep-0.92.7

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/rep-gtk

Installation of Rep-gtk

Install rep-gtk by running the following commands:

./autogen.sh --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: Lisp bindings
Installed Directory: /usr/include/rep-gtk and /usr/lib/rep/gui

Short Descriptions

Lisp bindings

are libraries stored in /usr/lib/rep/gui/ that assist communication between Lisp and the GTK libraries

Last updated on

Screen-4.9.0

Introduction to Screen

Screen is a terminal multiplexor that runs several separate processes, typically interactive shells, on a single physical character-based terminal. Each virtual terminal emulates a DEC VT100 plus several ANSI X3.64 and ISO 2022 functions and also provides configurable input and output translation, serial port support, configurable logging, multi-user support, and many character encodings, including UTF-8. Screen sessions can be detached and resumed later on a different terminal.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Screen Dependencies

Optional

Linux-PAM-1.5.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/screen

Installation of Screen

Install Screen by running the following commands:

sh autogen.sh                                 &&
./configure --prefix=/usr                     \
            --infodir=/usr/share/info         \
            --mandir=/usr/share/man           \
            --with-socket-dir=/run/screen     \
            --with-pty-group=5                \
            --with-sys-screenrc=/etc/screenrc &&

sed -i -e "s%/usr/local/etc/screenrc%/etc/screenrc%" {etc,doc}/* &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&
install -m 644 etc/etcscreenrc /etc/screenrc

Command Explanations

--with-socket-dir=/run/screen: This option places the per-user sockets in a standard location.

--with-sys-screenrc=/etc/screenrc: This option places the global screenrc file in /etc.

--with-pty-group=5: This option sets the gid to the value used by LFS.

sed -i -e "s%/usr/local/etc/screenrc%/etc/screenrc%" {etc,doc}/*: This command corrects the configuration and documentation files to the location that is used here for the global screenrc file.

Configuring Screen

Config Files

/etc/screenrc and ~/.screenrc

Configuration Information

You may want to look at the example configuration file that was installed and customize it for your needs.

Contents

Installed Program: screen (symlink) and screen-4.9.0
Installed Libraries: None
Installed Directory: /usr/share/screen and /run/screen

Short Descriptions

screen

is a terminal multiplexor with VT100/ANSI terminal emulation

Last updated on

shared-mime-info-2.1

Introduction to Shared Mime Info

The Shared Mime Info package contains a MIME database. This allows central updates of MIME information for all supporting applications.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Shared Mime Info Dependencies

Required

GLib-2.70.4, itstool-2.0.7, libxml2-2.9.13, and xmlto-0.0.28

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/shared-mime-info

Installation of Shared Mime Info

Install Shared Mime Info by running the following commands:

If you wish to run the test suite, you must first extract the xdgmime tarball into the current directory, and compile it so that meson can find it:

tar -xf ../xdgmime.tar.xz &&
make -C xdgmime

One of the changes in meson-0.60 broke this package. To fix that apply a patch:

patch -p1 -i ../shared-mime-info-2.1-meson_0.60_fix-1.patch

Now build the package:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release -Dupdate-mimedb=true .. &&
ninja

If you have followed the instructions above to build xdgmime, to test the result issue ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dupdate-mimedb=true: This parameter tells the build system to run update-mime-database during installation. Otherwise, this must be done manually in order to be able to use the MIME database.

Contents

Installed Program: update-mime-database
Installed Library: None
Installed Directory: /usr/share/mime

Short Descriptions

update-mime-database

assists in adding MIME data to the database

Last updated on

Sharutils-4.15.2

Introduction to Sharutils

The Sharutils package contains utilities that can create 'shell' archives.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/sharutils

Installation of Sharutils

Fix a heap buffer overflow, and an issue exposed by GCC-10:

sed -i 's/BUFSIZ/rw_base_size/' src/unshar.c &&
sed -i '/program_name/s/^/extern /' src/*opts.h

Install Sharutils by running the following commands:

sed -i 's/IO_ftrylockfile/IO_EOF_SEEN/' lib/*.c        &&
echo "#define _IO_IN_BACKUP 0x100" >> lib/stdio-impl.h &&

./configure --prefix=/usr &&
make

To test the results, issue make check.

Now, as the root user:

make install

Contents

Installed Programs: shar, unshar, uudecode and uuencode
Installed Libraries: None
Installed Directories: None

Short Descriptions

shar

creates "shell archives" (or shar files) which are in text format and can be mailed

unshar

unpacks a shar file

uudecode

reads a file (or by default the standard input) and writes an encoded version to the standard output. The encoding uses only printing ASCII characters

uuencode

reads a file (or by default the standard input) and decodes the uuencoded version to the standard output

Last updated on

telepathy-logger-0.8.2

Introduction to Telepathy Logger

The Telepathy Logger package is a headless observer client that logs information received by the Telepathy framework. It features pluggable backends to log different sorts of messages in different formats.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Telepathy Logger Dependencies

Required

Python-2.7.18 (only during build), SQLite-3.37.2, and telepathy-glib-0.24.2

Recommended
Optional

GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/telepathy-logger

Installation of Telepathy Logger

Fix a deprecated schema entry:

sed 's@/apps/@/org/freedesktop/@' \
    -i data/org.freedesktop.Telepathy.Logger.gschema.xml.in

Install Telepathy Logger by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: This parameter is normally used if GTK-Doc is installed and you wish to rebuild and install the API documentation. It is broken for this package due to the use of a long deprecated gtk-doc program that is no longer available.

Contents

Installed Programs: telepathy-logger
Installed Libraries: libtelepathy-logger.so
Installed Directories: /usr/include/telepathy-logger-0.2, /usr/share/gtk-doc/html/telepathy-logger and /usr/share/telepathy

Short Descriptions

telepathy-logger

is the Telepathy Logger D-Bus service

libtelepathy-logger.so

contains the Telepathy Logger API functions

Last updated on

telepathy-mission-control-5.16.6

Introduction to Telepathy Mission Control

Telepathy Mission Control is an account manager and channel dispatcher for the Telepathy framework, allowing user interfaces and other clients to share connections to real-time communication services without conflicting.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Telepathy Mission Control Dependencies

Required

telepathy-glib-0.24.2

Recommended
Optional

D-Bus Python-1.2.18 (for the twisted tests), GTK-Doc-1.33.2, UPower-0.99.13, and Twisted (for the twisted tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/telepathy-mission-control

Installation of Telepathy Mission Control

Install Telepathy Mission Control by running the following commands:

PYTHON=python3 \
./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

PYTHON=python3: prevents using Python2 if it is installed.

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: mc-tool, mc-wait-for-name and mission-control-5 (library executable)
Installed Libraries: libmission-control-plugins.so
Installed Directories: /usr/include/mission-control-5.5 and /usr/share/gtk-doc/html/mission-control-plugins

Short Descriptions

mc-tool

is a command line tool used to manipulate Mission Control accounts

mc-wait-for-name

waits for a D-Bus bus name that will be provided automatically by the desktop session

mission-control-5

is a D-Bus service which runs on the session bus to implement AccountManager and ChannelDispatcher services described in the Telepathy D-Bus specification

libmission-control-plugins.so

contains Telepathy Mission Control plugin API functions

Last updated on

tidy-html5-5.8.0

Introduction to Tidy HTML5

The Tidy HTML5 package contains a command line tool and libraries used to read HTML, XHTML and XML files and write cleaned up markup. It detects and corrects many common coding errors and strives to produce visually equivalent markup that is both W3C compliant and compatible with most browsers.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Tidy HTML5 Dependencies

Required

CMake-3.22.2

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/tidy

Installation of Tidy HTML5

Install Tidy HTML5 by running the following commands:

cd build/cmake &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_BUILD_TYPE=Release  \
      -DBUILD_TAB2SPACE=ON        \
      ../..    &&

make

This package does not come with a test suite.

Now, as the root user:

make install &&
rm -fv /usr/lib/libtidy.a &&
install -v -m755 tab2space /usr/bin

Command Explanations

-DCMAKE_BUILD_TYPE=Release: This switch is used to build the release library without any debug `assert` in the code.

-DBUILD_TAB2SPACE=ON: This switch is used to enable building the tab2space utility.

Configuring Tidy HTML5

Config Files

The absolute path of the file specified in HTML_TIDY.

Configuration Information

The default configuration options can be set in the file defined in HTML_TIDY. Additional configuration options can be passed to tidy via command line parameters or the -config <file> parameter.

Contents

Installed Programs: tab2space and tidy
Installed Library: libtidy.so
Installed Directory: /usr/share/doc/tidy-5.8.0

Short Descriptions

tab2space

is a utility to expand tabs and ensure consistent line endings

tidy

validates, corrects, and pretty-prints HTML files

libtidy.so

library provides the Tidy HTML5 API functions to tidy and can also be called by other programs

Last updated on

Time-1.9

Introduction to Time

The time utility is a program that measures many of the CPU resources, such as time and memory, that other programs use. The GNU version can format the output in arbitrary ways by using a printf-style format string to include various resource measurements.

Although the shell has a builtin command providing similar functionalities, this utility is required by the LSB.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/time

Installation of Time

Install Time by running the following commands:

./configure --prefix=/usr &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Contents

Installed Program: time
Installed Library: None
Installed Directory: None

Short Descriptions

time

reports various statistics about an executed command

Last updated on

tree-2.0.2

Introduction to tree

The tree application is useful to display a dictionary tree's contents, including files, directories, and links.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/tree

Installation of tree

Install tree by running the following commands:

make

This package does not come with a test suite.

Now, as the root user:

make PREFIX=/usr MANDIR=/usr/share/man install &&
chmod -v 644 /usr/share/man/man1/tree.1

Contents

Installed Program: tree
Installed Libraries: None
Installed Directories: None

Short Descriptions

tree

displays a directory tree in a terminal

Last updated on

unixODBC-2.3.9

Introduction to unixODBC

The unixODBC package is an Open Source ODBC (Open DataBase Connectivity) sub-system and an ODBC SDK for Linux, Mac OSX, and UNIX. ODBC is an open specification for providing application developers with a predictable API with which to access data sources. Data sources include optional SQL Servers and any data source with an ODBC Driver. unixODBC contains the following components used to assist with the manipulation of ODBC data sources: a driver manager, an installer library and command line tool, command line tools to help install a driver and work with SQL, drivers and driver setup libraries.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

unixODBC Dependencies

Optional

Mini SQL and Pth-2.0.7

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/unixodbc

Installation of unixODBC

Install unixODBC by running the following commands:

./configure --prefix=/usr \
            --sysconfdir=/etc/unixODBC &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&

find doc -name "Makefile*" -delete                &&
chmod 644 doc/{lst,ProgrammerManual/Tutorial}/*   &&

install -v -m755 -d /usr/share/doc/unixODBC-2.3.9 &&
cp      -v -R doc/* /usr/share/doc/unixODBC-2.3.9

Command Explanations

--enable-drivers: This parameter enables building the drivers that were installed by default in previous versions.

--enable-drivers-conf: This parameter enables building the driver configuration libraries that were installed by default in previous versions.

Configuring unixODBC

Config Files

/etc/unixODBC/*

Configuration Information

The files in /etc/unixODBC are meant to be configured by the system administrator (or the ODBC site administrator if appropriate privileges are granted to /etc/unixODBC). These files are not meant to be directly edited. The ODBC installer library is responsible for reading and writing the unixODBC config files.

Unfortunately, there are not many man, or any info pages for the various programs available in the unixODBC package. Along with the information in the Short Descriptions below and the documentation installed in /usr/share/doc/unixODBC-2.3.9, there are many README files throughout the source tree where the use and functionality of the programs can be found. Additionally, you can use the parameter -? for syntax and usage information. Lastly, the unixODBC web site at http://www.unixodbc.org/ has very good information.

Contents

Installed Programs: dltest, isql, iusql, odbc_config, odbcinst, and slencheck
Installed Libraries: libodbc.so, libodbccr.so, and libodbcinst.so
Installed Directories: /etc/unixODBC and /usr/share/doc/unixODBC-2.3.9

Short Descriptions

dltest

is a utility used to check a shared library to see if it can be loaded and if a given symbol exists in it

isql

is a utility which can be used to submit SQL to a data source and to format/output results. It can be used in batch or interactive mode

iusql

provides the same functionality as the isql program

odbc_config

is used to find out details about the installation of the unixODBC package

odbcinst

is a utility created for install script/RPM writers. It is a command line interface to key functionality in the libodbcinst library. It does not copy any files (i.e., libraries) but it will modify the ODBC System Information for the user

slencheck

is a utility which attempts to check whether an ODBC driver was built with 32-bit or 64-bit SQLLEN types

Last updated on

Xdg-user-dirs-0.17

Introduction to Xdg-user-dirs

Xdg-user-dirs is a tool to help manage well known user directories like the desktop folder and the music folder. It also handles localization (i.e. translation) of the filenames.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xdg-user-dirs

Installation of Xdg-user-dirs

Install xdg-user-dirs by running the following commands:

./configure --prefix=/usr --sysconfdir=/etc &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Configuring Xdg-user-dirs

Config Files

~/.config/user-dirs.dirs, /etc/xdg/user-dirs.conf, and /etc/xdg/user-dirs.defaults. Those default locations can be overridden by XDG_CONFIG_HOME and XDG_CONFIG_DIRS

Contents

Installed Programs: xdg-user-dir and xdg-user-dirs-update
Installed Library: None
Installed Directory: None

Short Descriptions

xdg-user-dir

looks up the current path for one of the XDG user directories

xdg-user-dirs-update

creates localized versions of the user directories

Last updated on

Chapter 12. System Utilities

This chapter contains mainly hardware utilities. It also contains some applications used by other applications in the book for installation or configuration purposes.

AccountsService-22.07.5

Introduction to AccountsService

The AccountsService package provides a set of D-Bus interfaces for querying and manipulating user account information and an implementation of those interfaces based on the usermod(8), useradd(8) and userdel(8) commands.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

AccountsService Dependencies

Required

Polkit-0.120

Recommended
Optional

GTK-Doc-1.33.2 and xmlto-0.0.28

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/accountsservice

Installation of AccountsService

Install AccountsService by running the following commands:

mkdir build &&
cd build &&

meson --prefix=/usr             \
      --buildtype=release       \
      -Dadmin_group=adm         \
      -Delogind=true            \
      -Dsystemdsystemunitdir=no \
      .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dadmin_group=adm: This switch sets the group for administrator accounts.

-Ddocbook=true: This switch enables building the D-Bus interface API documentation.

Configuring AccountsService

To allow users in the adm group to be listed as Administrators, execute the following commands as the root user:

cat > /etc/polkit-1/rules.d/40-adm.rules << "EOF"
polkit.addAdminRule(function(action, subject) {
   return ["unix-group:adm"];
   });
EOF

Contents

Installed Programs: accounts-daemon (library executable)
Installed Libraries: libaccountsservice.so
Installed Directories: /usr/include/accountsservice-1.0, /usr/share/doc/accountsservice, /usr/share/gtk-doc/html/libaccountsservice, and /var/lib/AccountsService

Short Descriptions

accounts-daemon

is the AccountsService daemon

libaccountsservice.so

contains the AccountsService API functions

Last updated on

acpid-2.0.33

Introduction to acpid

The acpid (Advanced Configuration and Power Interface event daemon) is a completely flexible, totally extensible daemon for delivering ACPI events. It listens on netlink interface and when an event occurs, executes programs to handle the event. The programs it executes are configured through a set of configuration files, which can be dropped into place by packages or by the user.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/acpid

Installation of acpid

Install acpid by running the following commands:

./configure --prefix=/usr \
            --docdir=/usr/share/doc/acpid-2.0.33 &&
make

This package does not come with a test suite.

Now, as the root user:

make install                         &&
install -v -m755 -d /etc/acpi/events &&
cp -r samples /usr/share/doc/acpid-2.0.33

Configuring acpid

acpid is configured by user defined events. Place event files under /etc/acpi/events directory. If an event occurs, acpid recurses through the event files in order to see if the regex defined after "event" matches. If they do, action is executed.

The following brief example will suspend the system when the laptop lid is closed (it requires pm-utils-1.4.1):

cat > /etc/acpi/events/lid << "EOF"
event=button/lid
action=/etc/acpi/lid.sh
EOF

cat > /etc/acpi/lid.sh << "EOF"
#!/bin/sh
/bin/grep -q open /proc/acpi/button/lid/LID/state && exit 0
/usr/sbin/pm-suspend
EOF
chmod +x /etc/acpi/lid.sh

Unfortunately, not every computer labels ACPI events in the same way. To determine how your buttons are recognized, use the acpi_listen tool. Also, look in the samples directory under /usr/share/doc/acpid-2.0.33 for more examples.

Boot Script

To automatically start acpid when the system is rebooted, install the /etc/rc.d/init.d/acpid boot script from the blfs-bootscripts-20210826 package.

make install-acpid

Contents

Installed Programs: acpid, acpi_listen, and kacpimon
Installed Libraries: None
Installed Directories: /etc/acpi and /usr/share/doc/acpid-2.0.33

Short Descriptions

acpid

is a program that listens for ACPI events and executes the rules that match the received event

acpi_listen

is a simple tool which connects to acpid and listens for events

kacpimon

is a monitor program that connects to three sources of ACPI events (events file, netlink and input layer) and then reports on what it sees while it is connected

Last updated on

at-3.2.4

Introduction to at

The at package provide delayed job execution and batch processing. It is required for Linux Standards Base (LSB) conformance.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

at Dependencies

Required

An MTA

Optional

Linux-PAM-1.5.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/at

Installation of at

Before building at, as the root user you should create the group and user atd which will run the atd daemon:

groupadd -g 17 atd                                                  &&
useradd -d /dev/null -c "atd daemon" -g atd -s /bin/false -u 17 atd

Install at with the following commands:

./configure --with-daemon_username=atd        \
            --with-daemon_groupname=atd       \
            --with-jobdir=/var/spool/atjobs   \
            --with-atspool=/var/spool/atspool \
            SENDMAIL=/usr/sbin/sendmail       &&
make -j1

To test the results, issue: make test.

Now, as the root user:

make install docdir=/usr/share/doc/at-3.2.4 \
             atdocdir=/usr/share/doc/at-3.2.4

Configuring at

Config Files

/etc/at.allow and /etc/at.deny determines who can submit jobs via at or batch.

Linux PAM Configuration

If At has been built with Linux PAM support, you need to create a PAM configuration file, to get it working correctly with BLFS.

Issue the following commands as the root user to create the configuration file for Linux PAM:

cat > /etc/pam.d/atd << "EOF"
# Begin /etc/pam.d/atd

auth required pam_unix.so
account required pam_unix.so
password required pam_unix.so
session required pam_unix.so

# End /etc/pam.d/atd
EOF

Boot Script

Install the /etc/init.d/atd init script from the blfs-bootscripts-20210826 package.

make install-atd

Contents

Installed Programs: at, atd, atq (symlink), atrm (symlink), atrun, and batch
Installed Libraries: None
Installed Directories: /usr/share/doc/at-3.2.4

Short Descriptions

at

queues, examines or deletes jobs for later execution

atd

is the daemon that runs jobs queued for later execution

atq

lists the user's pending jobs, or all jobs, if superuser

atrm

deletes jobs, identified by their job number

atrun

runs jobs queued for later execution

batch

is a script that executes commands when system load levels permit

Last updated on

autofs-5.1.8

Introduction to Autofs

Autofs controls the operation of the automount daemons. The automount daemons automatically mount filesystems when they are accessed and unmount them after a period of inactivity. This is done based on a set of pre-configured maps.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Autofs Dependencies

Required

libtirpc-1.3.2 and rpcsvc-proto-1.4.3

Optional

nfs-utils-2.6.1, libnsl-2.0.0, libxml2-2.9.13, MIT Kerberos V5-1.19.2, OpenLDAP-2.6.1 (client only), and Cyrus SASL-2.1.27

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/autofs

Kernel Configuration

Verify that automounter kernel support has been enabled:

File systems --->
  <*/M> Kernel automounter support (supports v3, v4, and v5) [CONFIG_AUTOFS_FS]

Optionally, enable the following options in the kernel configuration:

File systems  --->
  [*] Network File Systems  --->                                      [CONFIG_NETWORK_FILESYSTEMS]
    <*/M> NFS client support                                          [CONFIG_NFS_FS]
    <*/M> SMB3 and CIFS support (advanced network filesystem)         [CONFIG_CIFS]

Recompile and install the new kernel, if necessary.

Installation of Autofs

Install Autofs by running the following commands:

./configure --prefix=/usr             \
            --with-mapdir=/etc/autofs \
            --with-libtirpc           \
            --without-openldap        \
            --mandir=/usr/share/man &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Caution

If autofs is already installed on your system, be sure to backup your configuration files. They'll be overwritten by the following command.

Install the default configuration files, still as the root user:

make install_samples

Command Explanations

--with-libtirpc: This switch forces the package to use libtirpc for RPC functionality instead of relying on implementation from Glibc, which was removed in LFS 8.1.

--without-openldap: This switch disables openldap if found. If openldap is desired, omit this switch. Note that openldap support in autofs requires MIT Kerberos V5-1.19.2.

Configuring Autofs

Config Files

/etc/sysconfig/autofs.conf, /etc/autofs/auto.master, /etc/autofs/auto.misc, and /etc/autofs/auto.net

Configuration Information

The installation process creates auto.master, auto.misc, auto.smb, and auto.net. Replace the auto.master file with the following commands as the root user:

mv /etc/autofs/auto.master /etc/autofs/auto.master.bak &&
cat > /etc/autofs/auto.master << "EOF"
# Begin /etc/autofs/auto.master

/media/auto  /etc/autofs/auto.misc  --ghost
#/home        /etc/autofs/auto.home

# End /etc/autofs/auto.master
EOF

This file creates a new media directory, /media/auto that will overlay any existing directory of the same name. In this example, the file, /etc/autofs/auto.misc, has a line:

                cd   -fstype=iso9660,ro,nosuid,nodev :/dev/cdrom

that will mount a cdrom as /media/auto/cd if that directory is accessed. The --ghost option tells the automounter to create ghost versions (i.e. empty directories) of all the mount points listed in the configuration file regardless whether any of the file systems are actually mounted or not. This is very convenient and highly recommended, because it will show you the available auto-mountable file systems as existing directories, even when their file systems aren't currently mounted. Without the --ghost option, you'll have to remember the names of the directories. As soon as you try to access one of them, the directory will be created and the file system will be mounted. When the file system gets unmounted again, the directory is destroyed too, unless the --ghost option was given.

Note

An alternative method would be to specify another automount location such as /var/lib/auto/cdrom and create a symbolic link from /media/cdrom to the automount location.

The auto.misc file must be configured to your working hardware. The loaded configuration file should load your cdrom if /dev/cdrom is active or it can be edited to match your device setup. Examples for floppies are available in the file and easily activated. Documentation for this file is available using the man 5 autofs command.

In the second line, if enabled, a user's home directory would be mounted via NFS upon login. The /etc/home.auto would need to exist and have an entry similar to:

joe  example.org:/export/home/joe

where the directory /export/home/joe is exported via NFS from the system example.org. NFS shares are covered on the next page.

This package could also be used to mount SMB shares, however that feature is not configured in these instructions. For additional configuration information, see the man pages for auto.master(5). There are also web resources such as this AUTOFS HOWTO available.

Boot Script

autofs installs its own boot script, but it has no capability for logging or visual conformance with other BLFS scripts. It will be replaced by an enhanced version.

Install the /etc/init.d/autofs mount script included with the blfs-bootscripts-20210826 package.

make install-autofs

The time-out variable is set in /etc/sysconfig/autofs.conf. The installed file sets a default of 60 seconds of inactivity before unmounting the device. A much shorter time may be necessary to protect buffer writing to a floppy if users tend to remove the media prior to the timeout setting.

Contents

Installed Program: automount
Installed Libraries: lookup_dir.so, lookup_file.so, lookup_files.so, lookup_hosts.so, lookup_ldap.so (optional), lookup_multi.so, lookup_nis.so, lookup_program.so, lookup_userhome.so, lookup_yp.so, mount_afs.so, mount_autofs.so, mount_bind.so, mount_changer.so, mount_ext2.so, mount_ext3.so, mount_ext4.so, mount_generic.so, mount_nfs.so, mount_nfs4.so, parse_amd.so, and parse_sun.so
Installed Directories: /usr/lib/autofs and /etc/autofs

Short Descriptions

automount

is the daemon that performs the mounting when a request is made for the device

Last updated on

BlueZ-5.63

Introduction to BlueZ

The BlueZ package contains the Bluetooth protocol stack for Linux.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

BlueZ Dependencies

Required

dbus-1.12.20, GLib-2.70.4, and libical-3.0.14

Optional

docutils-0.18.1 (to generate man pages)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/bluez

Kernel Configuration

If you are building this package to use bluetooth devices (rather than as a build dependency), enable the following options in the kernel configuration, also the options below the next paragraph if you intend to run the tests, and recompile the kernel if necessary:

General Setup --->
  [*] Configure standard kernel features (expert users)               [CONFIG_EXPERT]
    [*] Enable timerfd() system call               [CONFIG_TIMERFD]
    [*] Enable eventfd() system call               [CONFIG_EVENTFD]

[*] Networking support --->                [CONFIG_NET]
  <*/M> Bluetooth subsystem support --->    [CONFIG_BT]
    <*/M> RFCOMM protocol support          [CONFIG_BT_RFCOMM]
    [*]   RFCOMM TTY support               [CONFIG_BT_RFCOMM_TTY]
    <*/M> BNEP protocol support            [CONFIG_BT_BNEP]
    [*]   Multicast filter support         [CONFIG_BT_BNEP_MC_FILTER]
    [*]   Protocol filter support          [CONFIG_BT_BNEP_PROTO_FILTER]
    <*/M> HIDP protocol support            [CONFIG_BT_HIDP]
        Bluetooth device drivers --->
          (Select the appropriate drivers for your Bluetooth hardware)

   <*/M> RF switch subsystem support ----   [CONFIG_RFKILL]

-*- Cryptographic API --->
   <*/M*> User-space cryptographic algorithm configuration         [CONFIG_CRYPTO_USER]
   <*/M*> User-space interface for hash algorithms                 [CONFIG_CRYPTO_USER_API_HASH]
   <*/M*> User-space interface for symmetric key cipher algorithms [CONFIG_CRYPTO_USER_API_SKCIPHER]
   <*/M*> MD5 digest algorithm                                     [CONFIG_CRYPTO_MD5]
   <*/M*> SHA1 digest algorithm                                    [CONFIG_CRYPTO_SHA1]

Security Options --->
  <*/M*> Diffie-Hellman operations on retained keys [CONFIG_KEY_DH_OPERATIONS]

Installation of BlueZ

Now, make some changes needed for SystemV systems:

patch -Np1 -i ../bluez-5.63-obexd_without_systemd-1.patch

Install BlueZ by running the following commands:

./configure --prefix=/usr         \
            --sysconfdir=/etc     \
            --localstatedir=/var  \
            --enable-library      \
            --disable-manpages    \
            --disable-systemd     &&
make

To test the results, issue: make check.

Now, as the root user:

make install &&
ln -svf ../libexec/bluetooth/bluetoothd /usr/sbin

Install the main configuration file as the root user:

install -v -dm755 /etc/bluetooth &&
install -v -m644 src/main.conf /etc/bluetooth/main.conf

If desired, install the API documentation as the root user:

install -v -dm755 /usr/share/doc/bluez-5.63 &&
install -v -m644 doc/*.txt /usr/share/doc/bluez-5.63

Command Explanations

--disable-manpages: This switch disables generating the manual pages because of the reliance on 'rst2man' in docutils. Remove this switch if you have docutils-0.18.1 installed and wish to generate the manual pages.

--enable-library: This switch enables building the BlueZ 4 compatibility library which is required by some applications.

--disable-systemd: This switch is needed because systemd is not part of LFS/BLFS. If you are using systemd, remove this switch.

ln -svf ../libexec/bluetooth/bluetoothd /usr/sbin: This command makes access to the bluetooth daemon more convenient.

Configuring BlueZ

Configuration Files

/etc/bluetooth/main.conf is installed automatically during the install. Additionally, there are three supplementary configuration files. /etc/sysconfig/bluetooth is installed as a part of the boot script below. In addition, you optionally can install the following, as the root user:

cat > /etc/bluetooth/rfcomm.conf << "EOF"
# Start rfcomm.conf
# Set up the RFCOMM configuration of the Bluetooth subsystem in the Linux kernel.
# Use one line per command
# See the rfcomm man page for options


# End of rfcomm.conf
EOF
cat > /etc/bluetooth/uart.conf << "EOF"
# Start uart.conf
# Attach serial devices via UART HCI to BlueZ stack
# Use one line per device
# See the hciattach man page for options

# End of uart.conf
EOF

Boot Script

To automatically start the bluetoothd daemon when the system is rebooted, install the /etc/rc.d/init.d/bluetooth bootscript from the blfs-bootscripts-20210826 package.

make install-bluetooth

Contents

Installed Programs: bluemoon, bluetoothctl, bluetoothd (symlink), btattach, btmon, hex2hcd, l2ping, l2test, mpris-proxy, and rctest
Installed Library: libbluetooth.so
Installed Directories: /etc/bluetooth, /usr/{include,libexec}/bluetooth, and /usr/share/doc/bluez-5.63

Short Descriptions

bluemoon

is a Bluemoon configuration utility

bluetoothctl

is the interactive Bluetooth control program

bluetoothd

is the Bluetooth daemon

btmon

provides access to the Bluetooth subsystem monitor infrastructure for reading HCI traces

hex2hcd

is used to convert a file needed by Broadcom devices to hcd (Broadcom bluetooth firmware) format

l2ping

is used to send a L2CAP echo request to the Bluetooth MAC address given in dotted hex notation

l2test

is a L2CAP testing program

rctest

is used to test RFCOMM communications on the Bluetooth stack

libbluetooth.so

contains the BlueZ 4 API functions

Last updated on

Bubblewrap-0.5.0

Introduction to Bubblewrap

Bubblewrap is a setuid implementation of user namespaces, or sandboxing, that provides access to a subset of kernel user namespace features. Bubblewrap allows user owned processes to run in an isolated environment with limited access to the underlying filesystem.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Bubblewrap Dependencies

Optional (to generate manual pages)

libxslt-1.1.35

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/bubblewrap

Installation of Bubblewrap

Install Bubblewrap by running the following commands:

./configure --prefix=/usr &&
make

Next, if you desire to run the test suite, fix an issue caused by the merged-/usr configuration in LFS:

sed 's@symlink usr/lib64@ro-bind-try /lib64@' -i tests/libtest.sh

To test the results, issue: make check

Now, as the root user:

make install

Contents

Installed Program: bwrap
Installed Libraries: None
Installed Directories: None

Short Descriptions

bwrap

generates a sandbox for a program to run in

Last updated on

Colord-1.4.6

Introduction to Colord

Colord is a system service that makes it easy to manage, install, and generate color profiles. It is used mainly by GNOME Color Manager for system integration and use when no users are logged in.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Colord Dependencies

Required

dbus-1.12.20, GLib-2.70.4, Little CMS-2.13.1, Polkit-0.120, and SQLite-3.37.2

Recommended
Optional

gnome-desktop-41.3 and colord-gtk-0.3.0 (to build the example tools), DocBook-utils-0.6.14, GTK-Doc-1.33.2, libxslt-1.1.35, SANE-1.0.32, ArgyllCMS, and Bash Completion

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/colord

Installation of Colord

There should be a dedicated user and group to take control of the colord daemon after it has started. Issue the following commands as the root user:

groupadd -g 71 colord &&
useradd -c "Color Daemon Owner" -d /var/lib/colord -u 71 \
        -g colord -s /bin/false colord

First, clean up about 100 warnings:

mv po/fur.po po/ur.po &&
sed -i 's/fur/ur/' po/LINGUAS

Install Colord by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr            \
      --buildtype=release      \
      -Ddaemon_user=colord     \
      -Dvapi=true              \
      -Dsystemd=false          \
      -Dlibcolordcompat=true   \
      -Dargyllcms_sensor=false \
      -Dbash_completion=false  \
      -Ddocs=false             \
      -Dman=false ..           &&
ninja

Now, as the root user:

ninja install

To test the results, issue: ninja -k 2 test. One test, colord-self-test-daemon, will fail. The test suite must be run after the package is installed, and the system-wide D-Bus Daemon must be running.

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Ddaemon_user=colord: This switch is used so the colord daemon will run as an unprivileged user instead of the root user.

-Dvapi=true: This switch enables building the Vala bindings. Remove if you don't have Vala-0.54.7 installed.

-Dsystemd=false: This switch disables support for systemd login in Colord applications.

-Dlibcolordcompat=true: This switch enables building a compatibility library for older packages that use Colord.

-Dargyllcms_sensor=false: This switch disables the ArgLLCMS sensor driver. Omit if you have ArgyllCMS installed and wish to use it.

-Dbash_completion=false: This switch disables Bash Completion support for Colord applications.

-Ddocs=false: This switch disables building of documentation. Omit if you have GTK-Doc-1.33.2 available.

-Dman=false: This switch disables building of man pages. Omit if you have DocBook-utils-0.6.14 available. Namespaced versions of the docbook-xsl stylesheets are also required.

Contents

Installed Programs: cd-create-profile, cd-fix-profile, cd-iccdump, cd-it8, and colormgr
Installed Libraries: libcolord.so, libcolordcompat.so, libcolordprivate.so, and libcolorhug.so
Installed Directories: /usr/include/colord-1, /usr/lib/colord-{plugins,sensors}, /usr/share/color{d}, /usr/share/gtk-doc/html/colord, and /var/lib/colord

Short Descriptions

cd-create-profile

is the Color Manager Profile Creation Tool

cd-fix-profile

is a tool used to fix metadata in ICC profiles

cd-iccdump

dumps the contents of an ICC profile as human readable text

cd-it8

is the Color Manager Testing Tool

colormgr

is a text-mode program that allows you to interact with colord on the command line

libcolord.so

contains the Colord API functions

libcolordcompat.so

contains legacy API functions for compatibility with older applications

libcolordprivate.so

contains internal API functions for the programs included with Colord

libcolorhug.so

contains a simple display hardware colorimiter

Last updated on

cpio-2.13

Introduction to cpio

The cpio package contains tools for archiving.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

CPIO Dependencies

Optional

texlive-20210325 (or install-tl-unx)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/cpio

Installation of cpio

First, fix a build issue when using GCC-10 and higher:

sed -i '/The name/,+2 d' src/global.c

Install cpio by running the following commands:

./configure --prefix=/usr \
            --enable-mt   \
            --with-rmt=/usr/libexec/rmt &&
make &&
makeinfo --html            -o doc/html      doc/cpio.texi &&
makeinfo --html --no-split -o doc/cpio.html doc/cpio.texi &&
makeinfo --plaintext       -o doc/cpio.txt  doc/cpio.texi

If you have texlive-20210325 installed and wish to create PDF or Postscript documentation, issue one or both of the following commands:

make -C doc pdf &&
make -C doc ps

To test the results, issue: make check.

Now, as the root user:

make install &&
install -v -m755 -d /usr/share/doc/cpio-2.13/html &&
install -v -m644    doc/html/* \
                    /usr/share/doc/cpio-2.13/html &&
install -v -m644    doc/cpio.{html,txt} \
                    /usr/share/doc/cpio-2.13

If you built PDF or Postscript documentation, install it by issuing the following commands as the root user:

install -v -m644 doc/cpio.{pdf,ps,dvi} \
                 /usr/share/doc/cpio-2.13

Command Explanations

--enable-mt: This parameter forces the building and installation of the mt program.

--with-rmt=/usr/libexec/rmt: This parameter inhibits building the rmt program as it is already installed by the Tar package in LFS.

Contents

Installed Programs: cpio and mt
Installed Libraries: None
Installed Directories: /usr/share/doc/cpio-2.13

Short Descriptions

cpio

copies files to and from archives

mt

controls magnetic tape drive operations

Last updated on

cups-pk-helper-0.2.6

Introduction to cups-pk-helper

The cups-pk-helper package contains a PolicyKit helper used to configure Cups with fine-grained privileges.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

cups-pk-helper Dependencies

Required

Cups-2.4.1 and Polkit-0.120

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/cups-pk-helper

Installation of cups-pk-helper

First, fix some deprecated syntax that will prevent cups-pk-helper from building on future versions of CUPS:

patch -Np1 -i ../cups-pk-helper-0.2.6-consolidated_fixes-1.patch

Install cups-pk-helper by running the following commands:

./configure --prefix=/usr --sysconfdir=/etc &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: cups-pk-helper-mechanism (library executable)
Installed Libraries: None
Installed Directories: None

Last updated on

dbus-1.12.20

Introduction to D-Bus

D-Bus is a message bus system, a simple way for applications to talk to one another. D-Bus supplies both a system daemon (for events such as new hardware device added or printer queue changed) and a per-user-login-session daemon (for general IPC needs among user applications). Also, the message bus is built on top of a general one-to-one message passing framework, which can be used by any two applications to communicate directly (without going through the message bus daemon).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

D-Bus Dependencies

Recommended
Optional

For the tests: dbus-glib-0.112, D-Bus Python-1.2.18, PyGObject-3.42.0, and Valgrind-3.18.1; for documentation: Doxygen-1.9.3, xmlto-0.0.28, Ducktype, and Yelp Tools

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/dbus

Installation of D-Bus

Install D-Bus by running the following commands (you may wish to review the output from ./configure --help first and add any desired parameters to the configure command shown below):

./configure --prefix=/usr                        \
            --sysconfdir=/etc                    \
            --localstatedir=/var                 \
            --enable-user-session                \
            --disable-doxygen-docs               \
            --disable-xml-docs                   \
            --disable-static                     \
            --with-systemduserunitdir=no         \
            --with-systemdsystemunitdir=no       \
            --docdir=/usr/share/doc/dbus-1.12.20 \
            --with-console-auth-dir=/run/console \
            --with-system-pid-file=/run/dbus/pid \
            --with-system-socket=/run/dbus/system_bus_socket &&
make

See below for test instructions.

Now, as the root user:

make install

If you are using a DESTDIR install, dbus-daemon-launch-helper needs to be fixed afterwards. Issue, as root user:

chown -v root:messagebus /usr/libexec/dbus-daemon-launch-helper &&
chmod -v      4750       /usr/libexec/dbus-daemon-launch-helper

If you are still building your system in chroot or you did not start the daemon yet, but you want to compile some packages that require D-Bus, generate the D-Bus UUID to avoid warnings when compiling some packages with the following command as the root user:

dbus-uuidgen --ensure

If using elogind-246.10, create a symlink to the /var/lib/dbus/machine-id file:

ln -sv /var/lib/dbus/machine-id /etc

The dbus tests cannot be run until after dbus-glib-0.112 has been installed. They must be run as an unprivileged user from a local session with bus address. To run the standard tests issue make check.

If you want to run the unit regression tests, configure requires additional parameters which expose additional functionality in the binaries that are not intended to be used in a production build of D-Bus. If you would like to run the tests, issue the following commands (for the tests, you don't need to build the docs):

make distclean                                    &&
PYTHON=python3 ./configure --enable-tests         \
                           --enable-asserts       \
                           --disable-doxygen-docs \
                           --disable-xml-docs     &&
make                                              &&
make check

There have been reports that the tests may fail if running inside a Midnight Commander shell. You may get out-of-memory error messages when running the tests. These are normal and can be safely ignored.

Command Explanations

--disable-doxygen-docs: This switch disables doxygen documentation build and install, if you have doxygen installed. If doxygen is installed, and you wish to build them, remove this parameter.

--disable-xml-docs: This switch disables html documentation build and install, if you have xmlto installed. If xmlto is installed, and you wish to build them, remove this parameter.

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-user-session: This parameter enables per-user DBus sessions with elogind.

--with-systemd{user,system}unitdir=no: These switches disable installation of systemd units on elogind based systems.

--with-console-auth-dir=/run/console: This parameter specifies the directory to check for console ownership.

--with-system-pid-file=/run/dbus/pid: This parameter specifies the location of the PID file.

--with-system-socket=/run/dbus/system_bus_socket: This parameter specifies the location of the system bus socket.

--enable-tests: Builds extra parts of the code to support all tests. Do not use on a production build.

--enable-embedded-tests: Builds extra parts of the code to support only unit tests. Do not use on a production build.

--enable-asserts: Enables debugging code to run assertions for statements normally assumed to be true. This prevents a warning that '--enable-tests' on its own is only useful for profiling and might not give true results for all tests, but adds its own NOTE that this should not be used in a production build.

Configuring D-Bus

Config Files

/etc/dbus-1/session.conf, /etc/dbus-1/system.conf and /etc/dbus-1/system.d/*

Configuration Information

The configuration files listed above should probably not be modified. If changes are required, you should create /etc/dbus-1/session-local.conf and/or /etc/dbus-1/system-local.conf and make any desired changes to these files.

If any packages install a D-Bus .service file outside of the standard /usr/share/dbus-1/services directory, that directory should be added to the local session configuration. For instance, /usr/local/share/dbus-1/services can be added by performing the following commands as the root user:

cat > /etc/dbus-1/session-local.conf << "EOF"
<!DOCTYPE busconfig PUBLIC
 "-//freedesktop//DTD D-BUS Bus Configuration 1.0//EN"
 "http://www.freedesktop.org/standards/dbus/1.0/busconfig.dtd">
<busconfig>

  <!-- Search for .service files in /usr/local -->
  <servicedir>/usr/local/share/dbus-1/services</servicedir>

</busconfig>
EOF

D-Bus Session Daemon

To automatically start dbus-daemon when the system is rebooted, install the /etc/rc.d/init.d/dbus bootscript from the blfs-bootscripts-20210826 package.

make install-dbus

Note that this boot script only starts the system-wide D-Bus daemon. Each user requiring access to D-Bus services will also need to run a session daemon as well. There are many methods you can use to start a session daemon using the dbus-launch command. Review the dbus-launch man page for details about the available parameters and options. Here are some suggestions and examples:

  • Add dbus-launch to the line in the ~/.xinitrc file that starts your graphical desktop environment.

  • If you use gdm or some other display manager that calls the ~/.xsession file, you can add dbus-launch to the line in your ~/.xsession file that starts your graphical desktop environment. The syntax would be similar to the example in the ~/.xinitrc file.

  • The examples shown previously use dbus-launch to specify a program to be run. This has the benefit (when also using the --exit-with-session parameter) of stopping the session daemon when the specified program is stopped. You can also start the session daemon in your system or personal startup scripts by adding the following lines:

    # Start the D-Bus session daemon
    eval `dbus-launch`
    export DBUS_SESSION_BUS_ADDRESS

    This method will not stop the session daemon when you exit your shell, therefore you should add the following line to your ~/.bash_logout file:

    # Kill the D-Bus session daemon
    kill $DBUS_SESSION_BUS_PID

Contents

Installed Programs: dbus-cleanup-sockets, dbus-daemon, dbus-launch, dbus-monitor, dbus-run-session, dbus-send, dbus-test-tool, dbus-update-activation-environment, and dbus-uuidgen
Installed Library: libdbus-1.so
Installed Directories: /etc/dbus-1, /usr/{include,lib}/dbus-1.0, /usr/lib/cmake/DBus1, /usr/share/dbus-1, /usr/share/xml/dbus-1, /usr/share/doc/dbus-1.12.20, and /var/{lib,run}/dbus

Short Descriptions

dbus-cleanup-sockets

is used to clean up leftover sockets in a directory

dbus-daemon

is the D-Bus message bus daemon

dbus-launch

is used to start dbus-daemon from a shell script. It would normally be called from a user's login scripts

dbus-monitor

is used to monitor messages going through a D-Bus message bus

dbus-run-session

starts a process as a new D-Bus session

dbus-send

is used to send a message to a D-Bus message bus

dbus-test-tool

is a D-Bus traffic generator and test tool; it is a multi-purpose tool for debugging and profiling D-Bus

dbus-update-activation-environment

is used to update the environment used for D-Bus session services; it updates the list of environment variables used by dbus-daemon --session when it activates session services without using systemd

dbus-uuidgen

is used to generate a universally unique ID

libdbus-1.so

contains the API functions used by the D-Bus message daemon. D-Bus is first a library that provides one-to-one communication between any two applications; dbus-daemon is an application that uses this library to implement a message bus daemon

Last updated on

elogind-246.10

Introduction to elogind

elogind is the systemd project's "logind", extracted out to be a standalone daemon. It integrates with Linux-PAM-1.5.2 to know the set of users that are logged in to a system and whether they are logged in graphically, on the console, or remotely. Elogind exposes this information via the standard org.freedesktop.login1 D-Bus interface, as well as through the file system using systemd's standard /run/systemd layout.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

elogind Dependencies

Required

dbus-1.12.20

Recommended
Optional

For the tests: lxml-4.7.1, gobject-introspection-1.70.0, zsh-5.8.1, Valgrind-3.18.1, audit-userspace, bash-completion, kexec, and SELinux

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/elogind

Kernel Configuration

Enable the following options in the kernel configuration and recompile the kernel if necessary:

General setup --->
    [*]     Control Group support                        [CONFIG_CGROUPS]
File systems --->
    [*]     Inotify support for userspace                [CONFIG_INOTIFY_USER]
            Pseudo filesystems --->
                [*]    Tmpfs POSIX Access Control Lists  [CONFIG_TMPFS_POSIX_ACL]

In addition, some tests need the userspace cryptographic kernel API, which is enabled with:

-*- Cryptographic API --->                               [CONFIG_CRYPTO]
   <M/*> Userspace cryptographic algorithm configuration [CONFIG_CRYPTO_USER]
   <M/*> User-space interface for hash algorithms        [CONFIG_CRYPTO_USER_API_HASH]

Installation of elogind

Install elogind by running the following commands:

sed -i '/Disable polkit/,+8 d' meson.build &&

mkdir build &&
cd    build &&

meson --prefix=/usr                        \
      --buildtype=release                  \
      -Dcgroup-controller=elogind          \
      -Ddbuspolicydir=/etc/dbus-1/system.d \
      -Dman=auto                           \
      ..  &&
ninja

To test the results, issue: ninja test. A few tests are skipped if not run with root privileges.

Now, as the root user:

ninja install                                           &&
ln -sfv  libelogind.pc /usr/lib/pkgconfig/libsystemd.pc &&
ln -sfvn elogind /usr/include/systemd

Command Explanations

sed ... meson.build: This change allows the package to be built without polkit being installed (it is still a runtime dependency) but able to use polkit after that package is installed.

-Dcgroup-controller=elogind: This switch ensures that elogind is selected as the cgroup controller, even if booted with another running cgroup controller.

-Ddbuspolicydir=/etc/dbus-1/system.d: This switch sets the location of the D-Bus policy directory.

-Dman=auto: The default value of this switch is false. Setting it to auto allows building and installing the man pages if the recommended dependencies are installed.

-Ddefault-kill-user-processes=false: Configure whether the processes of a user should be killed when the user logs out. The default is true, but this defeats the traditional use of screen or tmux. This can also be changed in the configuration file (see below).

ln -s ...: These commands install symlinks so that software packages find systemd compatible library and headers.

Configuring elogind

Config File

/etc/elogind/logind.conf

Configuration Information

The installed file /etc/elogind/logind.conf contains all the possible options with their defaults, commented out. You may wish to disable killing user processes when the user logs out, by running, as the root user:

sed -e '/\[Login\]/a KillUserProcesses=no' \
    -i /etc/elogind/logind.conf

Each user will need to register a user session using Linux-PAM at login. The /etc/pam.d/system-session file needs to be modified and a new file needs to be created in order for elogind to work correctly. Run the following commands as the root user:

cat >> /etc/pam.d/system-session << "EOF" &&
# Begin elogind addition

session  required    pam_loginuid.so
session  optional    pam_elogind.so

# End elogind addition
EOF
cat > /etc/pam.d/elogind-user << "EOF"
# Begin /etc/pam.d/elogind-user

account  required    pam_access.so
account  include     system-account

session  required    pam_env.so
session  required    pam_limits.so
session  required    pam_unix.so
session  required    pam_loginuid.so
session  optional    pam_keyinit.so force revoke
session  optional    pam_elogind.so

auth     required    pam_deny.so
password required    pam_deny.so

# End /etc/pam.d/elogind-user
EOF

Contents

Installed Programs: busctl, elogind-inhibit, and loginctl
Installed Library: libelogind.so
Installed Directories: /lib/elogind, /etc/elogind, /usr/include/elogind, and /usr/share/doc/elogind-246.10

Short Descriptions

busctl

is used to introspect and monitor the D-Bus bus

elogind-inhibit

is used to execute a program with a shutdown, sleep or idle inhibitor lock taken

loginctl

is used to introspect and control the state of the elogind Login Manager

libelogind.so

is the main elogind utility library

Last updated on

blocaled-0.4

Introduction to blocaled

blocaled is an implementation of the org.freedesktop.locale1 D-Bus protocol, which normally comes with systemd. It is needed by the GNOME desktop.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

blocaled Dependencies

Required

Polkit-0.120 and libdaemon-0.14

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/blocaled

Installation of blocaled

Install blocaled by running the following commands:

./configure --prefix=/usr --sysconfdir=/etc &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Configuring blocaled

Config Files

/etc/blocaled.conf

Configuration Information

/etc/blocaled.conf contains the location of the settings files used by blocaled. The defaults are suitable for BLFS. Information about the entries is available as comments in the file.

The org.freedesktop.locale1 protocol is unable to export locale variables. Locale settings are stored by default in /etc/locale.conf. We need to retrieve them in the bash profile. As the root user, issue:

cat > /etc/profile.d/i18n.sh << "EOF"
# Begin /etc/profile.d/i18n.sh

if [ -r /etc/locale.conf ]; then source /etc/locale.conf; fi

if [ -n "$LANG" ];              then export LANG; fi
if [ -n "$LC_TYPE" ];           then export LC_TYPE; fi
if [ -n "$LC_NUMERIC" ];        then export LC_NUMERIC; fi
if [ -n "$LC_TIME" ];           then export LC_TIME; fi
if [ -n "$LC_COLLATE" ];        then export LC_COLLATE; fi
if [ -n "$LC_MONETARY" ];       then export LC_MONETARY; fi
if [ -n "$LC_MESSAGES" ];       then export LC_MESSAGES; fi
if [ -n "$LC_PAPER" ];          then export LC_PAPER; fi
if [ -n "$LC_NAME" ];           then export LC_NAME; fi
if [ -n "$LC_ADDRESS" ];        then export LC_ADDRESS; fi
if [ -n "$LC_TELEPHONE" ];      then export LC_TELEPHONE; fi
if [ -n "$LC_MEASUREMENT" ];    then export LC_MEASUREMENT; fi
if [ -n "$LC_IDENTIFICATION" ]; then export LC_IDENTIFICATION; fi

# End /etc/profile.d/i18n.sh
EOF

Then the /etc/locale file should be generated, as the root user:

cat > /etc/locale.conf << EOF
# Begin /etc/locale.conf

LANG=$LANG

# End /etc/locale.conf
EOF

If you plan to run an X (or Wayland) Window system, you may want to set up your X keyboard. The best way to do it is to retrieve the settings from /etc/sysconfig/console, and feed them to the blocaled daemon. As the root user:

source /etc/sysconfig/console &&
KEYMAP=${KEYMAP:-us}          &&

gdbus call --system                                             \
           --dest org.freedesktop.locale1                       \
           --object-path /org/freedesktop/locale1               \
           --method org.freedesktop.locale1.SetVConsoleKeyboard \
           "$KEYMAP" "$KEYMAP_CORRECTIONS" true true

This should create or modify the Xorg configuration file (default is /etc/X11/xorg.conf.d/30-keyboard.conf) to match the keyboard settings set in KEYMAP.

Contents

Installed Program: blocaled (in /usr/libexec)
Installed Library: None
Installed Directory: /usr/share/blocaled

Short Descriptions

blocaled

is the daemon implementing the org.freedesktop.locale1 D-Bus protocol

Last updated on

Fcron-3.2.1

Introduction to Fcron

The Fcron package contains a periodical command scheduler which aims at replacing Vixie Cron.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Fcron Dependencies

Optional

An MTA, text editor (default is vi from the Vim-8.2.4383 package), Linux-PAM-1.5.2, and DocBook-utils-0.6.14

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/fcron

Installation of Fcron

Fcron uses the cron facility of syslog to log all messages. Since LFS does not set up this facility in /etc/syslog.conf, it needs to be done prior to installing Fcron. This command will append the necessary line to the current /etc/syslog.conf (perform as the root user):

cat >> /etc/syslog.conf << "EOF"
# Begin fcron addition to /etc/syslog.conf

cron.* -/var/log/cron.log

# End fcron addition
EOF

The configuration file has been modified, so reloading the sysklogd daemon will activate the changes (again as the root user).

/etc/rc.d/init.d/sysklogd reload

For security reasons, an unprivileged user and group for Fcron should be created (perform as the root user):

groupadd -g 22 fcron &&
useradd -d /dev/null -c "Fcron User" -g fcron -s /bin/false -u 22 fcron

Install Fcron by running the following commands:

./configure --prefix=/usr          \
            --sysconfdir=/etc      \
            --localstatedir=/var   \
            --without-sendmail     \
            --with-boot-install=no \
            --with-systemdsystemunitdir=no &&
make

This package does not come with a test suite.

Now, as the root user:

make install

DESTDIR install must be done as root user. Furthermore, if PAM configuration files should be installed in /etc/pam.d, you have to create this directory in the DESTDIR before doing the install.

Command Explanations

--without-sendmail: By default, Fcron will attempt to use the sendmail command from an MTA package to email you the results of the fcron script. This switch is used to disable default email notification. Omit the switch to enable the default. Alternatively, you can use the --with-sendmail=</path/to/MTA command> to use a different mailer command.

--with-boot-install=no: This prevents installation of the bootscript included with the package.

--with-systemdsystemunitdir=no: This prevents building the systemd units, which are not needed for a SYS V system.

--with-editor=</path/to/editor>: This switch allows you to set the default text editor.

--with-dsssl-dir=</path/to/dsssl-stylesheets>: May be used if you have DocBook-utils-0.6.14 installed. Currently, the dsssl stylesheets are located at /usr/share/sgml/docbook/dsssl-stylesheets-1.79.

Configuring Fcron

Config Files

/etc/fcron.conf, /etc/fcron.allow, and /etc/fcron.deny

Configuration Information

There are no required changes in any of the config files. Configuration information can be found in the man page for fcron.conf.

fcron scripts are written using fcrontab. Refer to the fcrontab man page for proper parameters to address your situation.

If Linux-PAM is installed, two PAM configuration files are installed in etc/pam.d. Alternatively if etc/pam.d is not used, the installation will append two configuration sections to the existing /etc/pam.conf file. You should ensure the files match your preferences. Modify them as required to suit your needs.

Periodic Jobs

If you would like to setup a periodic hierarchy for the root user, first issue the following commands (as the root user to create the /usr/bin/run-parts script:

cat > /usr/bin/run-parts << "EOF" &&
#!/bin/sh
# run-parts:  Runs all the scripts found in a directory.
# from Slackware, by Patrick J. Volkerding with ideas borrowed
# from the Red Hat and Debian versions of this utility.

# keep going when something fails
set +e

if [ $# -lt 1 ]; then
  echo "Usage: run-parts <directory>"
  exit 1
fi

if [ ! -d $1 ]; then
  echo "Not a directory: $1"
  echo "Usage: run-parts <directory>"
  exit 1
fi

# There are several types of files that we would like to
# ignore automatically, as they are likely to be backups
# of other scripts:
IGNORE_SUFFIXES="~ ^ , .bak .new .rpmsave .rpmorig .rpmnew .swp"

# Main loop:
for SCRIPT in $1/* ; do
  # If this is not a regular file, skip it:
  if [ ! -f $SCRIPT ]; then
    continue
  fi
  # Determine if this file should be skipped by suffix:
  SKIP=false
  for SUFFIX in $IGNORE_SUFFIXES ; do
    if [ ! "$(basename $SCRIPT $SUFFIX)" = "$(basename $SCRIPT)" ]; then
      SKIP=true
      break
    fi
  done
  if [ "$SKIP" = "true" ]; then
    continue
  fi
  # If we've made it this far, then run the script if it's executable:
  if [ -x $SCRIPT ]; then
    $SCRIPT || echo "$SCRIPT failed."
  fi
done

exit 0
EOF
chmod -v 755 /usr/bin/run-parts

Next, create the directory layout for the periodic jobs (again as the root user):

install -vdm754 /etc/cron.{hourly,daily,weekly,monthly}

Finally, add the run-parts to the system fcrontab (while still the root user):

cat > /var/spool/fcron/systab.orig << "EOF"
&bootrun 01 * * * * root run-parts /etc/cron.hourly
&bootrun 02 4 * * * root run-parts /etc/cron.daily
&bootrun 22 4 * * 0 root run-parts /etc/cron.weekly
&bootrun 42 4 1 * * root run-parts /etc/cron.monthly
EOF

Boot Script

Install the /etc/rc.d/init.d/fcron init script from the blfs-bootscripts-20210826 package.

make install-fcron

Finally, again as the root user, start fcron and generate the /var/spool/fcron/systab file:

/etc/rc.d/init.d/fcron start &&
fcrontab -z -u systab

Contents

Installed Programs: fcron, fcrondyn, fcronsighup, and fcrontab
Installed Libraries: None
Installed Directories: /usr/share/doc/fcron-3.2.1 and /var/spool/fcron

Short Descriptions

fcron

is the scheduling daemon

fcrondyn

is a user tool intended to interact with a running fcron daemon

fcronsighup

instructs fcron to reread the Fcron tables

fcrontab

is a program used to install, edit, list and remove the tables used by fcron

Last updated on

GPM-1.20.7

Introduction to GPM

The GPM (General Purpose Mouse daemon) package contains a mouse server for the console and xterm. It not only provides cut and paste support generally, but its library component is used by various software such as Links to provide mouse support to the application. It is useful on desktops, especially if following (Beyond) Linux From Scratch instructions; it's often much easier (and less error prone) to cut and paste between two console windows than to type everything by hand!

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/GPM

Kernel Configuration

Enable the following option in the kernel configuration and recompile the kernel if necessary:

Device Drivers  --->
  Input device support ---> [CONFIG_INPUT]
    <*/M> Mouse interface   [CONFIG_INPUT_MOUSEDEV]

Installation of GPM

Install GPM by running the following commands:

patch -Np1 -i ../gpm-1.20.7-consolidated-1.patch &&
./autogen.sh                                     &&
./configure --prefix=/usr --sysconfdir=/etc      &&
make

This package does not come with a test suite.

Now, as the root user:

make install                                          &&

install-info --dir-file=/usr/share/info/dir           \
             /usr/share/info/gpm.info                 &&

rm -fv /usr/lib/libgpm.a                              &&
ln -sfv libgpm.so.2.1.0 /usr/lib/libgpm.so            &&
install -v -m644 conf/gpm-root.conf /etc              &&

install -v -m755 -d /usr/share/doc/gpm-1.20.7/support &&
install -v -m644    doc/support/*                     \
                    /usr/share/doc/gpm-1.20.7/support &&
install -v -m644    doc/{FAQ,HACK_GPM,README*}        \
                    /usr/share/doc/gpm-1.20.7

Command Explanations

./autogen.sh: This command creates the missing configure script.

install-info ...: This package installs a .info file, but does not update the system dir file. This command makes the update.

ln -v -sfn libgpm.so.2.1.0 /usr/lib/libgpm.so: This command is used to create (or update) the .so symlink to the library.

Configuring GPM

Boot Script

Install the /etc/rc.d/init.d/gpm init script included in the blfs-bootscripts-20210826 package.

make install-gpm

Config Files

/etc/gpm-root.conf and ~/.gpm-root: The default and individual user gpm-root configuration files.

/etc/sysconfig/mouse: This file contains the name of your mouse device and the protocol it uses. To create this file, run the following as the root user:

cat > /etc/sysconfig/mouse << "EOF"
# Begin /etc/sysconfig/mouse

MDEVICE="<yourdevice>"
PROTOCOL="<yourprotocol>"
GPMOPTS="<additional options>"

# End /etc/sysconfig/mouse
EOF

Configuration Information

Examples of values to set MDEVICE, PROTOCOL, and GPMOPTS to are:

MDEVICE="/dev/input/mice"
PROTOCOL="imps2"
GPMOPTS=""

A list of which protocol values are known can be found by running gpm -m [device] -t -help. The MDEVICE setting depends on which type of mouse you have. For example, /dev/ttyS0 for a serial mouse (on Windows this is COM1), /dev/input/mice is often used for USB mice and /dev/psaux for PS2 mice. GPMOPTS is the 'catch all' for any additional options that are needed for your hardware.

Contents

Installed Programs: disable-paste, display-buttons, display-coords, get-versions, gpm, gpm-root, hltest, mev, and mouse-test
Installed Library: libgpm.so
Installed Directory: /usr/share/doc/gpm-1.20.7

Short Descriptions

disable-paste

is a security mechanism used to disable the paste buffer

display-buttons

is a simple program that reports the mouse buttons being pressed and released

display-coords

is a simple program that reports the mouse coordinates

get-versions

is used to report the GPM library and server versions

gpm

is a cut and paste utility and mouse server for virtual consoles

gpm-root

is a default handler for gpm. It is used to draw menus on the root window

hltest

is a simple sample application using the high-level library, meant to be read by programmers trying to use the high-level library

mev

is a program to report mouse events

mouse-test

is a tool for determining the mouse type and device it's attached to

libgpm.so

contains the API functions to access the GPM daemon

Last updated on

Hdparm-9.63

Introduction to Hdparm

The Hdparm package contains a utility that is useful for obtaining information about, and controlling ATA/IDE controllers and hard drives. It allows to increase performance and sometimes to increase stability.

This package is known to build and work properly using an LFS-11.1 platform.

Warning

As well as being useful, incorrect usage of Hdparm can destroy your information and in rare cases, drives. Use with caution and make sure you know what you are doing. If in doubt, it is recommended that you leave the default kernel parameters alone.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/hdparm

Installation of Hdparm

Build Hdparm by running the following command:

make

This package does not come with a test suite.

Now, as the root user:

make binprefix=/usr install

Contents

Installed Program: hdparm
Installed Libraries: None
Installed Directories: None

Short Descriptions

hdparm

provides a command-line interface to various hard disk ioctls supported by the stock Linux ATA/IDE device driver subsystem

Last updated on

LSB-Tools-0.9

Introduction to LSB-Tools

The LSB-Tools package includes tools for Linux Standards Base (LSB) conformance.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/LSB-Tools

Installation of LSB-Tools

Install LSB-Tools by running the following commands:

python3 setup.py build

Now, as the root user:

python3 setup.py install --optimize=1

Configuration Information

The configuration for this package was done in LFS. The file /etc/lsb-release should already exist. Be sure that the DISTRIB_CODENAME entry has been set properly.

Contents

Installed Programs: lsb_release, install_initd, and remove_initd
Installed Library: LSB_Tools-0.9-py3.10.egg-info
Installed Directories: /usr/lib/lsb and /usr/lib/python3.10/site-packages/lsbtools

Short Descriptions

lsb_release

is a script to give LSB data

install_initd

is a script to activate SysV startup scripts

remove_initd

is a script to deactivate SysV startup scripts

Last updated on

lm-sensors-3-6-0

Introduction to lm_sensors

The lm_sensors package provides user-space support for the hardware monitoring drivers in the Linux kernel. This is useful for monitoring the temperature of the CPU and adjusting the performance of some hardware (such as cooling fans).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

lm_sensors Dependencies

Required

Which-2.21

Optional

RRDtool (required to build the sensord program)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lm_sensors

Kernel Configuration

Getting your kernel config right is an iterative process that may require that you recompile your kernel a couple of times. The simplest way to go about it is to start by enabling modules and then compile everything that may be needed by Lm Sensors as a module:

Bus options (PCI etc.)  --->
  [*] PCI support                         [CONFIG_PCI]

[*] Enable loadable module support  --->  [CONFIG_MODULES]

Device Drivers  --->
  I2C support --->
    <*/M> I2C device interface            [CONFIG_I2C_CHARDEV]
    I2C Hardware Bus support  --->
      <M> (configure all of them as modules)
  <*/M> Hardware Monitoring support  ---> [CONFIG_HWMON]
    <M> (configure all of them as modules)

Recompile your kernel and reboot into the new kernel. Don't forget to make modules_install We will come back to the kernel in the Configuring section below.

Installation of lm_sensors

Install lm_sensors by running the following commands:

make PREFIX=/usr        \
     BUILD_STATIC_LIB=0 \
     MANDIR=/usr/share/man

This package does not come with a test suite.

Now, as the root user:

make PREFIX=/usr        \
     BUILD_STATIC_LIB=0 \
     MANDIR=/usr/share/man install &&

install -v -m755 -d /usr/share/doc/lm_sensors-3-6-0 &&
cp -rv              README INSTALL doc/* \
                    /usr/share/doc/lm_sensors-3-6-0

Command Explanations

BUILD_STATIC_LIB=0: This parameter disables compiling and installing the static version of libsensors.

PROG_EXTRA=sensord: This parameter enables compiling sensord, a daemon that can monitor your system at regular intervals. Compiling sensord requires RRDtool. Compiling RRDtool 1.4.6 requires a sed: sed -i '/ sv_undef/d' bindings/perl-shared/RRDs.xs.

Configuring lm_sensors

Config File

/etc/sensors3.conf

Configuration Information

To find out what hardware sensors your system has, issue the following command as the root user:

sensors-detect

The appropriate modules should have been loaded and a summary is displayed at the end. Now you know what is needed and you can recompile your kernel to enable just the options you need (i.e., don't enable the modules you cannot use).

Contents

Installed Programs: fancontrol, isadump, isaset, pwmconfig, sensors, sensors-conf-convert, sensors-detect, and optionally, sensord
Installed Library: libsensors.so
Installed Directories: /etc/sensors.d, /usr/include/sensors and /usr/share/doc/lm_sensors-3-6-0

Short Descriptions

fancontrol

is a shell script for use with lm_sensors. It reads its configuration from a file, then calculates fan speeds from temperatures and sets the corresponding PWM outputs to the computed values

isadump

is a small helper program to examine registers visible through the ISA bus. It is intended to probe any chip that lives on the ISA bus working with an address register and a data register (I2C-like access) or a flat range (of up to 256 bytes)

isaset

is a small helper program to set registers visible through the ISA bus

pwmconfig

tests the pulse width modulation (PWM) outputs of sensors and configures fancontrol

sensors

prints the current readings of all sensor chips

sensors-conf-convert

is a Perl script to convert lm-sensors version 2 configuration files to work with version 3

sensors-detect

is a Perl script that will walk you through the process of scanning your system for various hardware monitoring chips (sensors) supported by libsensors, or more generally by the lm_sensors tool suite

sensord

(optional) is a daemon that can be used to periodically log sensor readings

libsensors.so

contains the lm_sensors API functions

Last updated on

Logrotate-3.19.0

Introduction to Logrotate

The logrotate package allows automatic rotation, compression, removal, and mailing of log files.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Logrotate Dependencies

Required

popt-1.18

Recommended
Optional

An MTA (runtime)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/logrotate

Installation of Logrotate

Install logrotate by running the following command:

./configure --prefix=/usr &&
make

To test the results, issue: make test. One test fails because the very old compress is not present and two tests fail if an MTA is not installed.

Now, as the root user:

make install

Configuring Logrotate

Logrotate needs a configuration file, which must be passed as an argument to the command when executed. Create the file as the root user:

cat > /etc/logrotate.conf << EOF
# Begin /etc/logrotate.conf

# Rotate log files weekly
weekly

# Don't mail logs to anybody
nomail

# If the log file is empty, it will not be rotated
notifempty

# Number of backups that will be kept
# This will keep the 2 newest backups only
rotate 2

# Create new empty files after rotating old ones
# This will create empty log files, with owner
# set to root, group set to sys, and permissions 664
create 0664 root sys

# Compress the backups with gzip
compress

# No packages own lastlog or wtmp -- rotate them here
/var/log/wtmp {
    monthly
    create 0664 root utmp
    rotate 1
}

/var/log/lastlog {
    monthly
    rotate 1
}

# Some packages drop log rotation info in this directory
# so we include any file in it.
include /etc/logrotate.d

# End /etc/logrotate.conf
EOF

chmod -v 0644 /etc/logrotate.conf

Now create the /etc/logrotate.d directory as the root user:

mkdir -p /etc/logrotate.d

At this point additional log rotation commands can be entered, typically in the /etc/logrotate.d directory. For example:

cat > /etc/logrotate.d/sys.log << EOF
/var/log/sys.log {
   # If the log file is larger than 100kb, rotate it
   size   100k
   rotate 5
   weekly
   postrotate
      /bin/killall -HUP syslogd
   endscript
}
EOF

chmod -v 0644 /etc/logrotate.d/sys.log

You can designate multiple files in one entry:

cat > /etc/logrotate.d/example.log << EOF
file1
file2
file3 {
   ...
   postrotate
    ...
   endscript
}
EOF

chmod -v 0644 /etc/logrotate.d/example.log

You can use in the same line the list of files: file1 file2 file3. See the logrotate man page or http://www.techrepublic.com/article/manage-linux-log-files-with-logrotate/ for more examples.

The command logrotate /etc/logrotate.conf can be run manually, however, the command should be run daily. Other useful commands are logrotate -d /etc/logrotate.conf for debugging purposes and logrotate -f /etc/logrotate.conf forcing the logrotate commands to be run immediately. Combining the previous options -df, you can debug the effect of the force command. When debugging, the commands are only simulated and are not actually run. As a result, errors about files not existing will eventually appear because the files are not actually created.

To run the logrotate command daily, if you've installed Fcron-3.2.1 and completed the section on periodic jobs, execute the following commands, as the root user, to create a daily cron job:

cat > /etc/cron.daily/logrotate.sh << "EOF" &&
#!/bin/bash
/usr/sbin/logrotate /etc/logrotate.conf
EOF
chmod 754 /etc/cron.daily/logrotate.sh

Contents

Installed Programs: logrotate
Installed Library: None
Installed Directories: None

Short Descriptions

logrotate

performs the log maintenance functions defined in the configuration files

Last updated on

MC-4.8.27

Introduction to MC

MC (Midnight Commander) is a text-mode full-screen file manager and visual shell. It provides a clear, user-friendly, and somewhat protected interface to a Unix system while making many frequent file operations more efficient and preserving the full power of the command prompt.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

MC Dependencies

Required

GLib-2.70.4 and PCRE-8.45

Recommended
Optional

Doxygen-1.9.3, GPM-1.20.7, libssh2-1.10.0, Ruby-3.1.0, Samba-4.15.5, UnZip-6.0, a graphical environment, and Zip-3.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/MC

Installation of MC

Install MC by running the following commands:

./configure --prefix=/usr \
            --sysconfdir=/etc \
            --enable-charset &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--sysconfdir=/etc: This switch places the global configureation directory in /etc.

--enable-charset: This switch adds support to mcedit for editing files in encodings different from the one implied by the current locale.

Configuring MC

Config Files

~/.config/mc/*

Configuration Information

The ~/.config/mc directory and its contents are created when you start mc for the first time. Then you can edit the main ~/.config/mc/ini configuration file manually or through the MC shell. Consult the mc(1) man page for details.

Contents

Installed Programs: mc and the symlinks mcdiff, mcedit and mcview
Installed Libraries: None
Installed Directories: /etc/mc and /usr/{libexec,share}/mc

Short Descriptions

cons.saver

is used internally by mc for saving and restoring the text behind the panels on Linux text console

mc

is a visual shell

mcdiff

is an internal visual diff tool

mcedit

is an internal file editor

mcview

is an internal file viewer

Last updated on

ModemManager-1.18.6

Introduction to ModemManager

ModemManager provides a unified high level API for communicating with mobile broadband modems, regardless of the protocol used to communicate with the actual device.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

ModemManager Dependencies

Required

libgudev-237

Recommended
Optional

GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/ModemManager

Installation of ModemManager

Install ModemManager by running the following commands:

./configure --prefix=/usr                 \
            --sysconfdir=/etc             \
            --localstatedir=/var          \
            --disable-static              \
            --disable-maintainer-mode     \
            --with-systemd-journal=no     \
            --with-systemd-suspend-resume &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--with-systemd-suspend-resume: This switch forces ModemManager to use the elogind power management facilities.

--with-systemd-journal=no : This switch forces ModemManager not to use the systemd journal for logging.

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: mmcli and ModemManager
Installed Libraries: libmm-glib.so
Installed Directories: /usr/include/libmm-glib, /usr/include/ModemManager, /usr/lib/ModemManager, /usr/share/ModemManager, /usr/share/gtk-doc/html/libmm-glib, and /usr/share/gtk-doc/html/ModemManager

Short Descriptions

mmcli

is an utility used to control and monitor the ModemManager

ModemManager

is a D-Bus service used to communicate with modems

libmm-glib.so

contains API functions for communicating with mobile broadband modems, regardless of the protocol used to communicate with the actual device

Last updated on

notification-daemon-3.20.0

Introduction to Notification Daemon

The Notification Daemon package contains a daemon that displays passive pop-up notifications.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Notification Daemon Dependencies

Required

GTK+-3.24.31 and libcanberra-0.30 (Built with GTK+-3.24.31 support).

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/notification-daemon

Installation of Notification Daemon

Install Notification Daemon by running the following commands:

./configure --prefix=/usr     \
            --sysconfdir=/etc \
            --disable-static  &&
make

This package does not come with a testsuite.

Now, as the root user:

make install

You can test the notification daemon with the command notify-send:

pgrep -l notification-da &&
notify-send -i info Information "Hi ${USER}, This is a Test"

The command pgrep -l notification-da is added to assure that it is the daemon of this package that is running, not another one, e.g. the daemon from xfce4-notifyd-0.6.3.

Contents

Installed Program: none
Installed Libraries: none
Installed Directory: none

Last updated on

p7zip-17.04

Introduction to p7zip

p7zip is the Unix command-line port of 7-Zip, a file archiver that archives with high compression ratios. It handles 7z, ZIP, GZIP, Brotli, BZIP2, XZ, TAR, APM, ARJ, CAB, CHM, CPIO, CramFS, DEB, DMG, FAT, HFS, ISO, Lizard, LZ5, LZFSE, LZH, LZMA, LZMA2, MBR, MSI, MSLZ, NSIS, NTFS, RAR, RPM, SquashFS, UDF, VHD, WIM, XAR, Z, and Zstd formats.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

p7zip Dependencies

Optional

wxWidgets

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/p7zip

Installation of p7zip

First, prevent p7zip from installing compressed manual pages:

sed '/^gzip/d' -i install.sh

Next, fix a security vulnerability:

sed -i '160a if(_buffer == nullptr || _size == _pos) return E_FAIL;' CPP/7zip/Common/StreamObjects.cpp

Install p7zip by running the following commands:

make all3

To test the results, issue: make test.

Now, as the root user:

make DEST_HOME=/usr \
     DEST_MAN=/usr/share/man \
     DEST_SHARE_DOC=/usr/share/doc/p7zip-17.04 install

Note

If using DESTDIR techniques, use DEST_DIR instead.

Contents

Installed Programs: 7z, 7za, and 7zr
Installed Libraries: None
Installed Directory: /usr/lib/p7zip and /usr/share/doc/p7zip-17.04

Short Descriptions

7z

is a file archiver utility

7za

is a stand-alone executable handling less archive formats than 7z

7zr

is a minimal version of 7za that handles only 7z archives

Last updated on

Pax-20201030

Introduction to Pax

pax is an archiving utility created by POSIX and defined by the POSIX.1-2001 standard. Rather than sort out the incompatible options that have crept up between tar and cpio, along with their implementations across various versions of UNIX, the IEEE designed a new archive utility. The name pax is an acronym for portable archive exchange. Furthermore, pax means peace in Latin, so its name implies that it shall create peace between the tar and cpio format supporters. The command invocation and command structure is somewhat a unification of both tar and cpio.

pax has been required to be present in LSB conformant systems since LSB version 3.0.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pax

Installation of Pax

Install pax by running the following commands:.

Note

This package expands to the directory pax.

bash Build.sh

This package does not come with a test suite.

Now, as the root user:

Note

This package also creates hard links from pax to the programs cpio and tar in the build directory. The LFS editors do not recommend that they be installed as they will overwrite the GNU versions of these programs.

install -v pax /usr/bin &&
install -v -m644 pax.1 /usr/share/man/man1

Contents

Installed Program: pax

Short Descriptions

pax

copies files to and from archives in several formats

Last updated on

pciutils-3.7.0

Introduction to PCI Utils

The PCI Utils package contains a set of programs for listing PCI devices, inspecting their status and setting their configuration registers.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

pciutils Dependencies

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pciutils

Installation of PCI Utils

Install PCI Utils by running the following commands:

make PREFIX=/usr                \
     SHAREDIR=/usr/share/hwdata \
     SHARED=yes

This package does not come with a test suite.

Now, as the root user:

make PREFIX=/usr                \
     SHAREDIR=/usr/share/hwdata \
     SHARED=yes                 \
     install install-lib        &&

chmod -v 755 /usr/lib/libpci.so

Command Explanations

SHARED=yes: This parameter enables building of the shared library instead of the static one.

ZLIB=no: This option prevents compression of the pci.ids file.

Configuring PCI Utils

The pci.ids data file is constantly being updated. To get a current version of this file, run update-pciids as the root user. This program requires the Which-2.21 script or program to find cURL-7.81.0, Lynx-2.8.9rel.1 or Wget-1.21.2 which are used to download the most current file, and then replace the existing file in /usr/share/hwdata.

You should update the /usr/share/hwdata/pci.ids file periodically. If you've installed Fcron-3.2.1 and completed the section on periodic jobs, execute the following commands, as the root user, to create a weekly cron job:

cat > /etc/cron.weekly/update-pciids.sh << "EOF" &&
#!/bin/bash
/usr/sbin/update-pciids
EOF
chmod 754 /etc/cron.weekly/update-pciids.sh

Contents

Installed Programs: lspci, setpci, and update-pciids
Installed Library: libpci.so
Installed Directory: /usr/include/pci and /usr/share/hwdata

Short Descriptions

lspci

is a utility for displaying information about all PCI buses in the system and all devices connected to them

setpci

is a utility for querying and configuring PCI devices

update-pciids

fetches the current version of the PCI ID list.

libpci.so

is library that allows applications to access the PCI subsystem

Last updated on

pm-utils-1.4.1

Introduction to Power Management Utilities

The Power Management Utilities provide simple shell command line tools to suspend and hibernate the computer. They can be used to run user supplied scripts on suspend and resume.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Power Management Utilities Dependencies

Optional

xmlto-0.0.28 (to generate man pages)

Optional (runtime)

Hdparm-9.63, Wireless Tools-29, ethtool, and vbetool

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pm-utils

Kernel Configuration

If needed, enable the following options in the kernel configuration and recompile the kernel:

Power management and ACPI options --->
    <*> Suspend to RAM and standby            [CONFIG_SUSPEND]
    <*> Hibernation (aka 'suspend to disk')   [CONFIG_HIBERNATION]

Suspend to RAM allows the system to enter sleep states in which main memory is powered and thus its contents are preserved. The method cuts power to most parts of the machine aside from the RAM. Because of the large power savings, it is advisable for laptops to automatically enter this mode when the computer is running on batteries and the lid is closed (or the user is inactive for some time).

Suspend to disk (Hibernation) saves the machine's state into swap space and completely powers off the machine. When the machine is powered on, the state is restored. Until then, there is zero power consumption. Suspend to RAM and hibernation are normally appropriate for portable devices such as laptops, but can be used on workstations. The capability is not really appropriate for servers.

To use hibernation, the kernel parameter resume=/dev/<swap_partition> has to be used on the kernel command line (in grub.cfg). The swap partition should be at least the size of the physical RAM on the system.

Installation of Power Management Utilities

Install Power Management Utilities by running the following commands:

./configure --prefix=/usr     \
            --sysconfdir=/etc \
            --docdir=/usr/share/doc/pm-utils-1.4.1 &&
make

This package does not come with a test suite.

Now, as the root user:

make install

If you don't have xmlto-0.0.28 installed, copy pregenerated man pages, as the root user:

install -v -m644 man/*.1 /usr/share/man/man1 &&
install -v -m644 man/*.8 /usr/share/man/man8 &&
ln -sv pm-action.8 /usr/share/man/man8/pm-suspend.8 &&
ln -sv pm-action.8 /usr/share/man/man8/pm-hibernate.8 &&
ln -sv pm-action.8 /usr/share/man/man8/pm-suspend-hybrid.8

Configuring Power Management Utilities

Suspend or resume functionality can be easily modified by installing files into the /etc/pm/sleep.d directory. These files, known as hooks, are run when the system is put into a sleep state or resumed. Default hooks are located in /usr/lib/pm-utils/sleep.d, and user hooks should be put in /etc/pm/sleep.d. See the pm-action(8) man page for more information.

In order to use hibernation with GRUB and a swap partition, you need to add kernel parameter resume=swap_partition (e.g. resume=/dev/sda1) to the kernel line in the /boot/grub/grub.cfg configuration file.

Contents

Installed Programs: on_ac_power, pm-hibernate, pm-is-supported, pm-powersave, pm-suspend and pm-suspend-hybrid
Installed Libraries: None
Installed Directories: /etc/pm, /usr/lib/pm-utils and /usr/share/doc/pm-utils-1.4.1

Short Descriptions

on_ac_power

is a script that determines whether the system is running on AC power (rather than a battery)

pm-hibernate

is a symlink to pm-action script that puts the computer into hibernate mode (the system is fully powered off and system state is saved to disk)

pm-is-supported

is a script that checks whether power management features such as suspend and hibernate are supported

pm-powersave

is a script that puts the computer into powersaving (low power) mode

pm-suspend

is a symlink to pm-action script that puts the computer into suspend mode (most devices are shut down and system state is saved in RAM)

pm-suspend-hybrid

is a symlink to pm-action script that puts the computer into hybrid-suspend mode (the system does everything it needs to hibernate, but suspends instead of shutting down)

Last updated on

Raptor-2.0.15

Introduction to Raptor

Raptor is a C library that provides a set of parsers and serializers that generate Resource Description Framework (RDF) triples.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Raptor Dependencies

Required

cURL-7.81.0 and libxslt-1.1.35

Optional

GTK-Doc-1.33.2, ICU-70.1 and libyajl

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/raptor

Installation of Raptor

First, apply a patch that fixes a couple of security issues:

patch -Np1 -i ../raptor-2.0.15-security_fixes-1.patch

Install Raptor by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check. Several of the XML tests may fail.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--with-icu-config=/usr/bin/icu-config: Use this switch if you have installed ICU-70.1 and wish to build Raptor with its support.

Contents

Installed Programs: rapper
Installed Libraries: libraptor2.so
Installed Directories: /usr/include/raptor2 and /usr/share/gtk-doc/html/raptor2

Short Descriptions

rapper

is a RDF parsing and serializing utility

libraptor2.so

contains the Raptor API functions

Last updated on

Rasqal-0.9.33

Introduction to Rasqal

Rasqal is a C library that handles Resource Description Framework (RDF) query language syntaxes, query construction, and execution of queries returning results as bindings, boolean, RDF graphs/triples or syntaxes.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://download.librdf.org/source/rasqal-0.9.33.tar.gz

  • Download MD5 sum: 1f5def51ca0026cd192958ef07228b52

  • Download size: 1.6 MB

  • Estimated disk space required: 22 MB (additional 4 MB for the tests)

  • Estimated build time: 0.3 SBU (additional 0.7 SBU for the tests)

Rasqal Dependencies

Required

Raptor-2.0.15

Optional

PCRE-8.45 and libgcrypt-1.10.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/rasqal

Installation of Rasqal

Install Rasqal by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: rasqal-config and roqet
Installed Library: librasqal.so
Installed Directories: /usr/include/rasqal and /usr/share/gtk-doc/html/rasqal

Short Descriptions

rasqal-config

is an utility for retrieving the installation options of Rasqal

roqet

is an RDF query utility

Last updated on

Redland-1.0.17

Introduction to Redland

Redland is a set of free software C libraries that provide support for the Resource Description Framework (RDF).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Redland Dependencies

Required

Rasqal-0.9.33

Optional

Berkeley DB-5.3.28, libiodbc-3.52.15, SQLite-3.37.2, MariaDB-10.6.7 or MySQL, PostgreSQL-14.2, virtuoso, and 3store

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/redland

Installation of Redland

Install Redland by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: rdfproc, redland-config and redland-db-upgrade
Installed Libraries: librdf.so and /usr/lib/redland/librdf_storage_*.so
Installed Directories: /usr/lib/redland, /usr/share/gtk-doc/html/redland and /usr/share/redland

Short Descriptions

rdfproc

is the Redland RDF processor utility

redland-config

is a script to get information about the installed version of Redland

redland-db-upgrade

upgrades older Redland databases to 0.9.12 format

Last updated on

sg3_utils-1.47

Introduction to sg3_utils

The sg3_utils package contains low level utilities for devices that use a SCSI command set. Apart from SCSI parallel interface (SPI) devices, the SCSI command set is used by ATAPI devices (CD/DVDs and tapes), USB mass storage devices, Fibre Channel disks, IEEE 1394 storage devices (that use the "SBP" protocol), SAS, iSCSI and FCoE devices (amongst others).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/sg3_utils

Installation of sg3_utils

Install sg3_utils by running the following commands:

./configure --prefix=/usr --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: rescan-scsi-bus.sh, scsi_logging_level, scsi_mandat, scsi_readcap, scsi_ready, scsi_satl, scsi_start, scsi_stop, scsi_temperature, sg_bg_ctl, sg_compare_and_write, sg_copy_results, sg_dd, sg_decode_sense, sg_emc_trespass, sg_format, sg_get_config, sg_get_lba_status, sg_ident, sg_inq, sg_logs, sg_luns, sg_map, sg_map26, sg_modes, sg_opcodes, sg_persist, sg_prevent, sg_raw, sg_rbuf, sg_rdac, sg_read, sg_read_attr, sg_read_block_limits, sg_read_buffer, sg_read_long, sg_readcap, sg_reassign, sg_referrals, sg_rep_pip, sg_rep_zones, sg_requests, sg_reset, sg_reset_wp, sg_rmsn, sg_rtpg, sg_safte, sg_sanitize, sg_sat_identify, sg_sat_phy_event, sg_sat_read_gplog, sg_sat_set_features, sg_scan, sg_seek, sg_senddiag, sg_ses, sg_ses_microcode, sg_start, sg_stpg, sg_stream_ctl, sg_sync, sg_test_rwbuf, sg_timestamp, sg_turs, sg_unmap, sg_verify, sg_vpd, sg_wr_mode, sg_write_buffer, sg_write_long, sg_write_same, sg_write_verify, sg_write_x, sg_xcopy, sg_zone, sginfo, sgm_dd, and sgp_dd
Installed Library: libsgutils2.so
Installed Directories: None

Short Descriptions

rescan-scsi-bus.sh

adds or removes SCSI devices without having to reboot

scsi_logging_level

accesses Linux SCSI logging level information

scsi_mandat

checks SCSI device support for mandatory commands

scsi_readcap

does the SCSI READ CAPACITY command on disks

scsi_ready

does the SCSI TEST UNIT READY on devices

scsi_satl

checks for SCSI to ATA Translation (SAT) device support

scsi_start

starts one or more SCSI disks

scsi_stop

stops one or more SCSI disks

scsi_temperature

fetches the temperature of a SCSI device

sg_bg_ctl

performs a SCSI BACKGROUND CONTROL command on a device to perform "advanced background operations"

sg_compare_and_write

sends the SCSI COMPARE AND WRITE command to device

sg_copy_results

sends the SCSI RECEIVE COPY RESULTS command (XCOPY related)

sg_dd

copies data to and from files and devices. Specialised for devices that understand the SCSI command set

sg_decode_sense

takes SCSI sense data in binary or as a sequence of ASCII hexadecimal bytes and decodes it

sg_emc_trespass

changes ownership of a LUN from another Service-Processor to this one

sg_format

formats or resizes a SCSI disk (perhaps changes its block size)

sg_get_config

sends a SCSI GET CONFIGURATION command (MMC-4 +)

sg_get_elem_status

sends a SCSI GET PHYSICAL ELEMENT STATUS command to a device

sg_get_lba_status

sends the SCSI GET LBA STATUS command

sg_ident

sends a SCSI REPORT or SET IDENTIFYING INFORMATION command

sginfo

access mode page information for a SCSI (or ATAPI) device

sg_inq

sends a SCSI INQUIRY or ATA IDENTIFY (PACKET) DEVICE command and outputs the response

sg_logs

access log pages with SCSI LOG SENSE command

sg_luns

sends the SCSI REPORT LUNS command

sg_map

displays mapping between linux sg and other SCSI devices

sg_map26

maps a special file to a SCSI generic (sg) device (or vice versa)

sgm_dd

copies data to and from files and devices. Specialized for devices that understand the SCSI command set and does memory mapped transfers from sg devices

sg_modes

reads mode pages with the SCSI MODE SENSE command

sg_opcodes

reports information on supported SCSI commands or task management functions

sgp_dd

copies data to and from files and devices. Specialized for devices that understand the SCSI command set

sg_persist

sends a SCSI PERSISTENT RESERVE (IN or OUT) command to manipulate registrations and reservations

sg_prevent

sends a SCSI PREVENT ALLOW MEDIUM REMOVAL command

sg_raw

sends an arbitrary SCSI command to a device

sg_rbuf

reads data using the SCSI READ BUFFER command

sg_rdac

displays or modifies the RDAC Redundant Controller Page

sg_read

reads blocks of data continually from the same offset

sg_read_attr

performs a SCSI READ ATTRIBUTE command on a device

sg_read_block_limits

sends a SCSI READ BLOCK LIMITS command

sg_read_buffer

sends a SCSI READ BUFFER command

sg_readcap

sends a SCSI READ CAPACITY command

sg_read_long

sends a SCSI READ LONG command

sg_reassign

sends a SCSI REASSIGN BLOCKS command

sg_referrals

sends a SCSI REPORT REFERRALS command

sg_rep_pip

sends a SCSI REPORT PROVISIONING INITIALIZATION PATTERN command

sg_rep_zones

sends a SCSI REPORT ZONES command

sg_requests

sends one or more SCSI REQUEST SENSE commands

sg_reset

sends a SCSI device, target, bus or host reset; or checks reset state

sg_reset_wp

sends a SCSI RESET WRITE POINTER command

sg_rmsn

sends a SCSI READ MEDIA SERIAL NUMBER command

sg_rtpg

sends a SCSI REPORT TARGET PORT GROUPS command

sg_safte

fetches status information from a SCSI Accessed Fault-Tolerant Enclosure (SAF-TE) device

sg_sanitize

sends a SCSI SANITIZE command

sg_sat_identify

sends an ATA IDENTIFY (PACKET) DEVICE command via a SCSI to ATA Translation (SAT) layer

sg_sat_phy_event

sends an ATA READ LOG EXT command via a SAT pass through to fetch log page 11h which contains SATA phy event counters

sg_sat_read_gplog

sends an ATA READ LOG EXT command via a SCSI to ATA Translation (SAT) layer

sg_sat_set_features

sends an ATA SET FEATURES command via a SCSI to ATA Translation (SAT) layer

sg_scan

does a scan of sg devices (or given SCSI/ATAPI/ATA devices) and prints the results

sg_seek

performs a SCSI SEEK or PRE-FETCH command on a device and it's cache

sg_senddiag

performs a SCSI SEND DIAGNOSTIC command

sg_ses

sends controls and fetches the current status from a SCSI Enclosure Services (SES) device

sg_ses_microcode

sends microcode to a SCSI enclosure

sg_start

sends a SCSI START STOP UNIT command to start, stop, load or eject medium

sg_stpg

sends a SCSI SET TARGET PORT GROUPS command

sg_stream_ctl

performs a SCSI STREAM CONTROL or GET STREAM STATUS command on a device to open or close an I/O stream

sg_sync

sends a SCSI command to synchronize the cache

sg_test_rwbuf

tests the SCSI host adapter by issuing write and read operations on a device's buffer and calculating checksums

sg_timestamp

reports or sets the timestamp on a SCSI device

sg_turs

sends one or more SCSI TEST UNIT READY commands

sg_unmap

sends a SCSI UNMAP command

sg_verify

invokes SCSI VERIFY command(s) on a block device

sg_vpd

fetches Vital Product Data (VPD) pages using a SCSI INQUIRY command

sg_write_buffer

sends a SCSI WRITE BUFFER command

sg_write_long

sends a SCSI WRITE LONG command

sg_write_same

sends a SCSI WRITE SAME command

sg_write_verify

sends a SCSI WRITE AND VERIFY command

sg_write_x

performs SCSI WRITE commands on a device

sg_wr_mode

writes mode pages

sg_xcopy

copies data to and from files and devices using SCSI EXTENDED COPY (XCOPY)

sg_zone

performs SCSI ZONE commands on a device, such as OPEN, CLOSE, FINISH or SEQUENTIALIZE

libsgutils2.so

contains the sg3_utils API functions

Last updated on

Sysstat-12.5.5

Introduction to Sysstat

The Sysstat package contains utilities to monitor system performance and usage activity. Sysstat contains the sar utility, common to many commercial Unixes, and tools you can schedule via cron to collect and historize performance and activity data.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Sysstat Dependencies

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/sysstat

Installation of Sysstat

Install Sysstat by running the following commands:

sa_lib_dir=/usr/lib/sa    \
sa_dir=/var/log/sa        \
conf_dir=/etc/sysconfig   \
./configure --prefix=/usr \
            --disable-file-attr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

sa_lib_dir: This environment variable specifies the location of the package-specific library directory.

sa_dir: This environment variable specifies the location of the directory containing the data files.

conf_dir: This environment variable specifies the location of the system configuration directory.

--disable-file-attr: Do not set attributes on files being installed. This parameter causes the installation to ignore the man group variable resulting in the man files having root: root ownership.

Note

Run ./configure --help to see other influential environment variables you can pass to configure. You may want to use the history and compressafter variables to customize the amount of data files kept on the system.

Configuring Sysstat

Config Files

/etc/sysconfig/sysstat and /etc/sysconfig/sysstat.ioconf

Cron Information

To begin gathering Sysstat history information, you must add to, or create a privileged user's crontab. The history data location is /var/log/sa. The user running Sysstat utilities via cron must have write access to this location.

Below is an example of what to install in the crontab. Adjust the parameters to suit your needs. Use man sa1 and man sa2 for information about the commands.

# 8am-7pm activity reports every 10 minutes during weekdays
0 8-18 * * 1-5 /usr/lib/sa/sa1 600 6 &

# 7pm-8am activity reports every hour during weekdays
0 19-7 * * 1-5 /usr/lib/sa/sa1 &

# Activity reports every hour on Saturday and Sunday
0 * * * 0,6 /usr/lib/sa/sa1 &

# Daily summary prepared at 19:05
5 19 * * * /usr/lib/sa/sa2 -A &

Ensure you submit the revised crontab to the cron daemon.

System Startup Information

At system startup, a LINUX RESTART message must be inserted in the daily data file to reinitialize the kernel counters. This can be automated by installing the /etc/rc.d/init.d/sysstat init script included in the blfs-bootscripts-20210826 package using the following command as the root user:

make install-sysstat

Contents

Installed Programs: cifsiostat, iostat, mpstat, pidstat, sadf, sar, and tapestat
Installed Libraries: None
Installed Directories: /usr/lib/sa, /usr/share/doc/sysstat-12.5.5 and /var/log/sa

Short Descriptions

cifsiostat

displays statistics about read and write operations on CIFS filesystems

iostat

reports CPU statistics and input/output statistics for devices and partitions

mpstat

writes activities for each available processor

pidstat

is used for monitoring individual tasks currently being managed by the Linux kernel

sadf

is used for displaying the contents of data files created by the sar command. But unlike sar, sadf can write its data in many different formats

sar

is used for displaying the contents of elected cumulative activity counters in the operating system

tapestat

is used for monitoring the activity of tape drives connected to a system

Last updated on

UDisks-2.9.4

Introduction to UDisks

The UDisks package provides a daemon, tools and libraries to access and manipulate disks and storage devices.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

UDisks Dependencies

Required

libatasmart-0.19, libblockdev-2.26, libgudev-237, libxslt-1.1.35, and Polkit-0.120

Required at runtime

btrfs-progs-5.16.2, dbus-1.12.20, dosfstools-4.2, gptfdisk-1.0.8, mdadm-4.2, and xfsprogs-5.14.2

Recommended
Optional (Required if building GNOME)

gobject-introspection-1.70.0

Optional

D-Bus Python-1.2.18 (for the integration tests), GTK-Doc-1.33.2, LVM2-2.03.15, ntfs-3g-2021.8.22, PyGObject-3.42.0 (for the integration tests), exFAT, and libiscsi

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/udisks2

Installation of UDisks

Install UDisks by running the following commands:

./configure --prefix=/usr        \
            --sysconfdir=/etc    \
            --localstatedir=/var \
            --disable-static     &&
make

To test the results, issue: make check. A more thorough test can be run with make ci. You must first create the directories /var/run/udisks2 and /var/lib/udisks2, and the optional python modules should be present.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Configuring UDisks2

Config Files

/etc/udisks2/mount_options.conf and /etc/udisks2/udisks2.conf

Configuration Information

The default configuration of UDisks2 assumes ntfs-3g is used to mount NTFS filesystems. If the wrapper script for in-kernel NTFS3 driver (recommended in the ntfs-3g-2021.8.22 page) is used instead, create a configuration file for UDisks2 compatible with NTFS3 to allow mounting NTFS filesystems:

cat > /etc/udisks2/mount_options.conf << "EOF"
[defaults]
ntfs_defaults=uid=$UID,gid=$GID
EOF

Contents

Installed Programs: udisksctl and umount.udisks2
Installed Library: libudisks2.so
Installed Directories: /etc/udisks2, /usr/include/udisks2, /usr/libexec/udisks2, /usr/share/gtk-doc/html/udisks2, and /var/lib/udisks2

Short Descriptions

udisksctl

is a command-line program used to interact with the udisksd daemon

umount.udisks2

is a command-line program used to unmount file systems that have been mounted by the UDisks daemon

libudisks2.so

contains the UDisks API functions

Last updated on

UnRar-6.1.4

Introduction to UnRar

The UnRar package contains a RAR extraction utility used for extracting files from RAR archives. RAR archives are usually created with WinRAR, primarily in a Windows environment.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/unrar

Installation of UnRar

Note

This package extracts the tarball to the unversioned directory unrar and not the expected directory unrar-6.1.4.

Install UnRar by running the following commands:

make -f makefile

This package does not come with a test suite.

Now, as the root user:

install -v -m755 unrar /usr/bin

Contents

Installed Program: unrar
Installed Libraries: None
Installed Directories: None

Short Descriptions

unrar

uncompresses a RAR archive

Last updated on

UnZip-6.0

Introduction to UnZip

The UnZip package contains ZIP extraction utilities. These are useful for extracting files from ZIP archives. ZIP archives are created with PKZIP or Info-ZIP utilities, primarily in a DOS environment.

This package is known to build and work properly using an LFS-11.1 platform.

Caution

The previous version of the UnZip package had some locale related issues. Currently there are no BLFS editors capable of testing these locale issues. Therefore, the locale related information is left on this page, but has not been tested. A more general discussion of these problems can be found in the Program Assumes Encoding section of the Locale Related Issues page.

Package Information

Additional Downloads

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/unzip

UnZip Locale Issues

Note

Use of UnZip in the JDK, Mozilla, DocBook or any other BLFS package installation is not a problem, as BLFS instructions never use UnZip to extract a file with non-ASCII characters in the file's name.

These issues are thought to be fixed in the patch. But since none of the editors have data to test this, the following workarounds are retained in case they might still be needed.

The UnZip package assumes that filenames stored in the ZIP archives created on non-Unix systems are encoded in CP850, and that they should be converted to ISO-8859-1 when writing files onto the filesystem. Such assumptions are not always valid. In fact, inside the ZIP archive, filenames are encoded in the DOS codepage that is in use in the relevant country, and the filenames on disk should be in the locale encoding. In MS Windows, the OemToChar() C function (from User32.DLL) does the correct conversion (which is indeed the conversion from CP850 to a superset of ISO-8859-1 if MS Windows is set up to use the US English language), but there is no equivalent in Linux.

When using unzip to unpack a ZIP archive containing non-ASCII filenames, the filenames are damaged because unzip uses improper conversion when any of its encoding assumptions are incorrect. For example, in the ru_RU.KOI8-R locale, conversion of filenames from CP866 to KOI8-R is required, but conversion from CP850 to ISO-8859-1 is done, which produces filenames consisting of undecipherable characters instead of words (the closest equivalent understandable example for English-only users is rot13). There are several ways around this limitation:

1) For unpacking ZIP archives with filenames containing non-ASCII characters, use WinZip while running the Wine Windows emulator.

2) Use bsdtar -xf from libarchive-3.6.0 to unpack the ZIP archive. Then fix the damage made to the filenames using the convmv tool (http://j3e.de/linux/convmv/). The following is an example for the zh_CN.UTF-8 locale:

convmv -f cp936 -t utf-8 -r --nosmart --notest \
    </path/to/unzipped/files>

Installation of UnZip

First apply the patch:

patch -Np1 -i ../unzip-6.0-consolidated_fixes-1.patch

Now compile the package:

make -f unix/Makefile generic

The test suite does not work for target generic.

Now, as the root user:

make prefix=/usr MANDIR=/usr/share/man/man1 \
 -f unix/Makefile install

Command Explanations

make -f unix/Makefile generic: This target begins by running a configure script (unlike the older targets such as linux and linux_noasm) which creates a flags file that is then used in the build. This ensures that the 32-bit x86 build receives the right flags to unzip files which which are larger than 2GB when extracted.

Contents

Installed Programs: funzip, unzip, unzipfsx, zipgrep, and zipinfo
Installed Libraries: None
Installed Directories: None

Short Descriptions

funzip

allows the output of unzip commands to be redirected

unzip

lists, tests or extracts files from a ZIP archive

unzipfsx

is a self-extracting stub that can be prepended to a ZIP archive. Files in this format allow the recipient to decompress the archive without installing UnZip

zipgrep

searches files in a ZIP archive for lines matching a pattern

zipinfo

produces technical information about the files in a ZIP archive, including file access permissions, encryption status, type of compression, etc

Last updated on

UPower-0.99.13

Introduction to UPower

The UPower package provides an interface for enumerating power devices, listening to device events and querying history and statistics. Any application or service on the system can access the org.freedesktop.UPower service via the system message bus.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

UPower Dependencies

Required

libgudev-237, libusb-1.0.25, and Polkit-0.120

Optional (Required if building GNOME)

gobject-introspection-1.70.0

Optional

GTK-Doc-1.33.2, PyGObject-3.42.0, dbusmock-0.25.0, umockdev-0.17.6 (for part of the test suite), and libimobiledevice

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/upower

Installation of UPower

Install UPower by running the following commands:

./configure --prefix=/usr         \
             --sysconfdir=/etc    \
             --localstatedir=/var \
             --enable-deprecated  \
             --disable-static     &&
make

To test the results, issue: make check. Some checks may not pass due to missing files. Test suite should be run from a local GUI session started with dbus-launch.

Now, as the root user:

make install

Command Explanations

--enable-deprecated: This switch enables deprecated functionality which is still needed by some applications.

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Program: upower
Installed Libraries: libupower-glib.so
Installed Directories: /etc/UPower, /usr/include/libupower-glib, and /var/lib/upower

Short Descriptions

upower

is the UPower command line tool

libupower-glib.so

contains the UPower API functions

Last updated on

usbutils-014

Introduction to USB Utils

The USB Utils package contains utilities used to display information about USB buses in the system and the devices connected to them.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

USB Utils Dependencies

Required

libusb-1.0.25 and Wget-1.21.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/usbutils

Installation of USB Utils

Install USB Utils by running the following commands:

./configure --prefix=/usr --datadir=/usr/share/hwdata &&
make

This package does not come with a test suite.

Now, as the root user:

make install

To install the usb.ids data file, using Wget-1.21.2, run, as the root user:

install -dm755 /usr/share/hwdata/ &&
wget http://www.linux-usb.org/usb.ids -O /usr/share/hwdata/usb.ids

The script lsusb.py displays information in a more easily readable form than lsusb. To find the options, use lsusb.py -h. One form of use recommended by the developer is lsusb.py -ciu.

Configuring USB Utils

The usb.ids data file is constantly being updated. To get a current version of this file, using Wget-1.21.2, periodically run again, as the root user:

wget http://www.linux-usb.org/usb.ids -O /usr/share/hwdata/usb.ids

You should update the /usr/share/hwdata/usb.ids file periodically. If you've installed Fcron-3.2.1 and completed the section on periodic jobs, execute the following commands, as the root user, to create a weekly cron job:

cat > /etc/cron.weekly/update-usbids.sh << "EOF" &&
#!/bin/bash
/usr/bin/wget http://www.linux-usb.org/usb.ids -O /usr/share/hwdata/usb.ids
EOF
chmod 754 /etc/cron.weekly/update-usbids.sh

Contents

Installed Programs: lsusb, lsusb.py, usb-devices, and usbhid-dump
Installed Libraries: None
Installed Directories: None

Short Descriptions

lsusb

is a utility for displaying information about all USB buses in the system and all devices connected to them, but not in human friendly form

lsusb.py

displays information about all USB buses in the system and all devices connected to them in reasonable human friendly form

usb-devices

is a shell script that displays details of USB buses and devices connected to them. It is designed to be used if /proc/bus/usb/devices is not available on your system

usbhid-dump

is used to dump report descriptors and streams from HID (human interface device) interfaces of USB devices

Last updated on

Which-2.21 and Alternatives

The presence or absence of the which program in the main LFS book is probably one of the most contentious issues on the mailing lists. It has resulted in at least one flame war in the past. To hopefully put an end to this once and for all, presented here are two options for equipping your system with which. The question of which which is for you to decide.

Introduction to GNU Which

The first option is to install the actual GNU which package.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/which

Installation of Which

Install which by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Program: which
Installed Libraries: None
Installed Directories: None

Short Descriptions

which

shows the full path of (shell) commands installed in your PATH

The 'which' Script

The second option (for those who don't want to install the package) is to create a simple script (execute as the root user):

cat > /usr/bin/which << "EOF"
#!/bin/bash
type -pa "$@" | head -n 1 ; exit ${PIPESTATUS[0]}
EOF
chmod -v 755 /usr/bin/which
chown -v root:root /usr/bin/which

This should work OK and is probably the easiest solution for most cases, but is not the most comprehensive implementation.

Last updated on

Zip-3.0

Introduction to Zip

The Zip package contains Zip utilities. These are useful for compressing files into ZIP archives.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/zip

Installation of Zip

Install Zip by running the following commands:

make -f unix/Makefile generic_gcc

This package does not come with a test suite.

Now, as the root user:

make prefix=/usr MANDIR=/usr/share/man/man1 -f unix/Makefile install

Command Explanations

make prefix=/usr -f unix/Makefile install: This command overrides the prefix variable that is set to /usr/local in the unix/Makefile. Alternatives to generic_gcc can be seen with a make -f unix/Makefile list command.

Contents

Installed Programs: zip, zipcloak, zipnote, and zipsplit
Installed Libraries: None
Installed Directories: None

Short Descriptions

zip

compresses files into a ZIP archive

zipcloak

is a utility to encrypt and decrypt a ZIP archive

zipnote

reads or writes comments stored in a ZIP file

zipsplit

is a utility to split ZIP files into smaller files

Last updated on

Chapter 13. Programming

A base LFS system can be used as a development platform, however the base system only includes language support for C, C++ and Perl. This chapter provides instructions to build many popular programming environments to greatly expand your system's development capabilities.

Autoconf2.13

Introduction to Autoconf2.13

Autoconf2.13 is an old version of Autoconf . This old version accepts switches which are not valid in more recent versions. Now that firefox has started to use python2 for configuring, this old version is required even if configure files have not been changed.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/autoconf213

Installation of Autoconf2.13

Install Autoconf by running the following commands:

patch -Np1 -i ../autoconf-2.13-consolidated_fixes-1.patch &&
mv -v autoconf.texi autoconf213.texi                      &&
rm -v autoconf.info                                       &&
./configure --prefix=/usr --program-suffix=2.13           &&
make

To test the installation issue make check (all 253 tests should pass).

Now, as the root user:

make install                                      &&
install -v -m644 autoconf213.info /usr/share/info &&
install-info --info-dir=/usr/share/info autoconf213.info

Command Explanations

mv -v autoconf.texi autoconf213.texi: ensure that the info file added by this package will not overwrite the more recent version.

rm -v autoconf.info: ensure that the info file will be created by the current version of texinfo.

--program-suffix=2.13: ensure that the installed programs have the version added to their names, so that only a script which specifically looks for these old versions will find them.

install -v -m644 ...: the patch removes install-info from the Makefile because that would install (and if necessary recreate) standards.info which is an old version, so now autoconf213.info has to be manually installed.

Contents

Installed Programs: autoconf2.13, autoheader2.13, autoreconf2.13, autoscan2.13, autoupdate2.13, and ifnames2.13
Installed Library: None
Installed Directory: /usr/share/autoconf-2.13

Short Descriptions

autoconf2.13

Produces shell scripts that automatically configure software source code packages to adapt to many kinds of Unix-like systems

autoheader2.13

is a tool for creating template files of C #define statements for configure to use

autoreconf2.13

This automatically runs autoconf2.13, autoheader2.13, aclocal, automake, gettextize and libtoolize in the right order when changes have been made to autoconf or automake template files

autoscan2.13

Can be used as a preliminary step in creating a configure.in file

autoupdate2.13

Modifies a configure.in file that still calls autoconf macros by their old names to use the current macro names

ifnames2.13

Prints the identifiers that the package uses in C preprocessor conditionals [If a package has already been set up to have some portability, this program can help determine what configure needs to check for. It can also fill in gaps in a configure.in file generated by autoscan]

Last updated on

Cbindgen-0.20.0

Introduction to Cbindgen

Cbindgen can be used to generate C bindings for Rust code.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

cbindgen Dependencies

Required

rustc-1.58.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/cbindgen

Installation of cbindgen

Note

As with most Rust packages, this needs a network connection to check the current versions of the required cargo crates, and to download them if they are not already present.

Install cbindgen by running the following commands:

cargo build --release

To test the results, issue: cargo test. Three tests in the final suite are known to fail.

Now, as the root user:

install -Dm755 target/release/cbindgen /usr/bin/

Contents

Installed Program: cbindgen
Installed Library: none
Installed Directory: none

Short Descriptions

cbindgen

generates C bindings for Rust code

Last updated on

Clisp-2.49

Introduction to Clisp

GNU Clisp is a Common Lisp implementation which includes an interpreter, compiler, debugger, and many extensions.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Clisp Dependencies

Recommended
Optional

libnsl-2.0.0 and libffcall

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/clisp

Installation of Clisp

Note

This package does not support parallel build.

If you are building on a 32-bit system, work around a bug in GCC caused by the latest version of binutils:

case $(uname -m) in
    i?86) export CFLAGS="${CFLAGS:--O2 -g} -falign-functions=4" ;;
esac

Remove two tests, which fail for unknown reasons:

sed -i -e '/socket/d' -e '/"streams"/d' tests/tests.lisp

Install Clisp by running the following commands:

If you are building clisp against libffcall, apply the patch to fix a build failure with current readline:

patch -Np1 -i ../clisp-2.49-readline7_fixes-1.patch

Install Clisp by running the following commands:

mkdir build &&
cd    build &&

../configure --srcdir=../                       \
             --prefix=/usr                      \
             --docdir=/usr/share/doc/clisp-2.49 \
             --with-libsigsegv-prefix=/usr &&

ulimit -s 16384 &&
make -j1

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

ulimit -s 16384: this increases the maximum stack size, as recommended by the configure.

--docdir=/usr/share/doc/clisp-2.49: this ensures the html documentation will go into a versioned directory instead of straight into /usr/share/html/.

--with-libsigsegv-prefix=/usr: use this to tell configure that you have installed libsigsegv in /usr, otherwise it will not be found.

--with-libffcall-prefix=/usr: use this to tell configure that you have installed the optional libffcall in /usr, otherwise like libsigsegv it will not be found.

Contents

Installed Programs: clisp, clisp-link
Installed Libraries: various static libraries in /usr/lib/clisp-2.49/base/
Installed Directories: /usr/lib/clisp-2.49 /usr/share/doc/clisp-2.49 /usr/share/emacs/site-lisp;

Short Descriptions

clisp

is an ANSI Common Lisp compiler, interpreter, and debugger

clisp-link

is used to link an external module to clisp

Last updated on

CMake-3.22.2

Introduction to CMake

The CMake package contains a modern toolset used for generating Makefiles. It is a successor of the auto-generated configure script and aims to be platform- and compiler-independent. A significant user of CMake is KDE since version 4.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://cmake.org/files/v3.22/cmake-3.22.2.tar.gz

  • Download MD5 sum: f96b91224aa14b09565325b51d60af43

  • Download size: 9.3 MB

  • Estimated disk space required: 334 MB (add 982 MB for tests)

  • Estimated build time: 2.1 SBU (add 3.7 SBU for tests, both using parallelism=4)

CMake Dependencies

Required

libuv-1.43.0

Recommended
Optional

GCC-11.2.0 (for gfortran), git-2.35.1 (for use during tests), Mercurial-6.0.2 (for use during tests), Qt-5.15.2 (for the Qt-based GUI), Subversion-1.14.1 (for testing), rhash, and Sphinx (for building documents)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/cmake

Installation of CMake

Install CMake by running the following commands:

sed -i '/"lib64"/s/64//' Modules/GNUInstallDirs.cmake &&

./bootstrap --prefix=/usr        \
            --system-libs        \
            --mandir=/share/man  \
            --no-system-jsoncpp  \
            --no-system-librhash \
            --docdir=/share/doc/cmake-3.22.2 &&
make

To test the results, issue: LC_ALL=en_US.UTF-8 bin/ctest -j<N> -O cmake-3.22.2-test.log, where <N> is an integer between 1 and the number of system cores. Setting LC_ALL is needed to prevent some test failures when some of the locale variables are set to non English locales. Oner test, RunCMake.CMP0125, is known to fail.

If you want to investigate a problem with a given "problem1-test", use bin/ctest -R "problem1-test" and, to omit it, use bin/ctest -E "problem1-test". These options can be used together: bin/ctest -R "problem1-test" -E "problem2-test". Option -N can be used to display all available tests, and you can run bin/ctest for a sub-set of tests by using separated by spaces names or numbers as options. Option --help can be used to show all options.

Now, as the root user:

make install

Command Explanations

sed ... Modules/GNUInstallDirs.cmake: This command disables applications using cmake from attempting to install files in /usr/lib64/.

--system-libs: This switch forces the build system to link against Zlib, Bzip2, cURL, nghttp2, Expat and libarchive installed on the system.

--no-system-jsoncpp: This switch removes the JSON-C++ library from the list of system libraries. A bundled version of that library is used instead.

--no-system-librhash: This switch removes the librhash library from the list of system libraries used. A bundled version of that library is used instead.

--qt-gui: This switch enables building the Qt-based GUI for CMake.

--parallel=: This switch enables performing the CMake bootstrap with multiple jobs at one time.

Contents

Installed Programs: ccmake, cmake, cmake-gui (optional), cpack, and ctest
Installed Libraries: None
Installed Directories: /usr/share/cmake-3.22 and /usr/share/doc/cmake-3.22.2

Short Descriptions

ccmake

is a curses based interactive frontend to cmake

cmake

is the makefile generator

cmake-gui

(optional) is the Qt-based frontend to cmake

cpack

is the CMake packaging program

ctest

is a testing utility for cmake-generated build trees

Last updated on

Doxygen-1.9.3

Introduction to Doxygen

The Doxygen package contains a documentation system for C++, C, Java, Objective-C, Corba IDL and to some extent PHP, C# and D. It is useful for generating HTML documentation and/or an off-line reference manual from a set of documented source files. There is also support for generating output in RTF, PostScript, hyperlinked PDF, compressed HTML, and Unix man pages. The documentation is extracted directly from the sources, which makes it much easier to keep the documentation consistent with the source code.

You can also configure Doxygen to extract the code structure from undocumented source files. This is very useful to quickly find your way in large source distributions. Used along with Graphviz, you can also visualize the relations between the various elements by means of include dependency graphs, inheritance diagrams, and collaboration diagrams, which are all generated automatically.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://doxygen.nl/files/doxygen-1.9.3.src.tar.gz

  • Download MD5 sum: 065cef54eb09cdb54614e1ed353ddbd1

  • Download size: 4.9 MB

  • Estimated disk space required: 170 MB (with tests)

  • Estimated build time: 1.3 SBU (using parallelism=4; with tests)

Doxygen Dependencies

Required

CMake-3.22.2 and git-2.35.1

Optional

Graphviz-2.50.0, ghostscript-9.55.0, libxml2-2.9.13 (required for the tests), LLVM-13.0.1 (with clang), Python-2.7.18, Qt-5.15.2 (for doxywizard), texlive-20210325 (or install-tl-unx), xapian-1.4.19 (for doxyindexer), and javacc

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/doxygen

Installation of Doxygen

Install Doxygen by running the following commands:

mkdir -v build &&
cd       build &&

cmake -G "Unix Makefiles"         \
      -DCMAKE_BUILD_TYPE=Release  \
      -DCMAKE_INSTALL_PREFIX=/usr \
      -Wno-dev .. &&

make

To test the results, issue: make tests. One test, 012_cite.dox, is known to fail.

If you wish to generate the package documentation, you must have Python, TeX Live (for HTML docs) and Ghostscript (for PDF docs) installed, then issue the following command:

cmake -DDOC_INSTALL_DIR=share/doc/doxygen-1.9.3 -Dbuild_doc=ON .. &&

make docs

Now, as the root user:

make install &&
install -vm644 ../doc/*.1 /usr/share/man/man1

If you have generated the package documentation, then the man pages are automatically installed, and you do not need to run the last install ... command.

Command Explanations

-Dbuild_wizard=ON: Use this switch if Qt5 is installed and you wish to build the GUI front-end.

-Dbuild_search=ON: Use this switch if xapian is installed and you wish to build external search tools (doxysearch.cgi and doxyindexer).

-Duse_libclang=ON: Use this switch if llvm with clang are installed, to add support for libclang parsing.

Configuring Doxygen

There is no real configuration necessary for the Doxygen package although three additional packages are required if you wish to use extended capabilities. If you need to use the language translation features, you must have Python-2.7.18 installed. If you require formulas to create PDF documentation, then you must have texlive-20210325 installed. If you require formulas to convert PostScript files to bitmaps, then you must have ghostscript-9.55.0 installed.

Contents

Installed Programs: doxygen and optionally, doxywizard, doxyindexer and doxysearch.cgi
Installed Libraries: None
Installed Directory: /usr/share/doc/doxygen-1.9.3

Short Descriptions

doxygen

is a command-line based utility used to generate template configuration files and then generate documentation from these templates. Use doxygen --help for an explanation of the command-line parameters

doxywizard

is a GUI front-end for configuring and running doxygen

doxyindexer

generates a search index called doxysearch.db from one or more search data files produced by doxygen. See, e.g. https://javacc.github.io/javacc/

doxysearch.cgi

is a CGI program to search the data indexed by doxyindexer

Last updated on

GCC-11.2.0

Introduction to GCC

The GCC package contains the GNU Compiler Collection. This page describes the installation of compilers for the following languages: C, C++, D, Fortran, Objective C, Objective C++, and Go.

This package is known to build and work properly using an LFS-11.1 platform.

Caution

If you are upgrading GCC from any other version prior to 11.2.0, then you must be careful compiling 3rd party kernel modules. You should ensure that the kernel and all its native modules are also compiled using the same version of GCC that you use to build the 3rd party module. This issue does not affect native kernel (and kernel modules) updates, as the instructions below are a complete reinstallation of GCC. If you have existing 3rd party modules installed, ensure they are recompiled using the updated version of GCC. As always, never update the kernel headers from the ones used when Glibc was compiled during LFS.

Some system headers need to be fixed to be used with GCC. This is done during the installation of GCC, and the fixed headers are installed in /usr/lib/gcc/<machine triplet>/<GCC version>/include-fixed . This is harmless if GCC is built during the LFS stage. But if you reinstall GCC in BLFS, some of the BLFS packages may be fixed. If one of those packages is reinstalled afterwards, the fixed headers are not updated, which may lead to version mismatches. In case that happens, the fixed headers must be updated by running (as root): /usr/libexec/gcc/x86_64-pc-linux-gnu/11.2.0/install-tools/mkheaders . The machine triplet may be different on a 32bit system.

Package Information

GCC Dependencies

Optional

GDB-11.2, Valgrind-3.18.1 (for tests), and ISL (to enable graphite optimization)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gcc

Installation of GCC

Important

Even if you specify only languages other than C and C++ to the ./configure command below, the installation process will overwrite your existing GCC C and C++ compilers and libraries. Running the full suite of tests is recommended.

Do not continue with the make install command until you are confident the build was successful. You can compare your test results with those found at https://gcc.gnu.org/ml/gcc-testresults/. You may also want to refer to the information found in the GCC section of Chapter 8 in the LFS book (../../../../lfs/view/11.1/chapter08/gcc.html).

The instructions below are intentionally performing a bootstrap process. Bootstrapping is needed for robustness and is highly recommended when upgrading the compilers version. To disable bootstrap anyways, add --disable-bootstrap to the ./configure options below.

As in LFS fix an issue breaking libasan.a identified upstream:

sed -e '/static.*SIGSTKSZ/d' \
    -e 's/return kAltStackSize/return SIGSTKSZ * 4/' \
    -i libsanitizer/sanitizer_common/sanitizer_posix_libcdep.cpp

Install GCC by running the following commands:

case $(uname -m) in
  x86_64)
    sed -i.orig '/m64=/s/lib64/lib/' gcc/config/i386/t-linux64
  ;;
esac

mkdir build                                            &&
cd    build                                            &&

../configure                                           \
    --prefix=/usr                                      \
    --disable-multilib                                 \
    --with-system-zlib                                 \
    --enable-languages=c,c++,d,fortran,go,objc,obj-c++ &&
make

If you have installed additional packages such as Valgrind and GDB, the GCC part of the testsuite will run more tests than in LFS. Some of those will report FAIL and others XPASS (pass when expected to FAIL). As of gcc-11.1.0, about 90 FAIL occur in the guality suite, as well as miscellaneous failures throughout the rest of the test suite. If all the compilers above are built, there will be around 102 unexpected failures out of over 481,000 tests. To run the tests, issue:

ulimit -s 32768 &&
make -k check

The tests are very long, and the results may be hard to find in the logs, specially if you use parallel jobs with make. You can get a summary of the tests with:

../contrib/test_summary

A few tests, less than 20 out of about 450,000, will fail, but unless the failures are excessive, they can be ignored.

Now, as the root user:

make install &&

mkdir -pv /usr/share/gdb/auto-load/usr/lib              &&
mv -v /usr/lib/*gdb.py /usr/share/gdb/auto-load/usr/lib &&

chown -v -R root:root \
    /usr/lib/gcc/*linux-gnu/11.2.0/include{,-fixed}

rm -rf /usr/lib/gcc/$(gcc -dumpmachine)/11.2.0/include-fixed/bits/

Some packages expect to find the C preprocessor in /lib or may refer to the C compiler under the name cc. The following symbolic links are not needed if you have followed the LFS instructions, since they have been already created. If you do not have them on your system, issue as the root user:

ln -v -sf ../usr/bin/cpp /lib          &&
ln -v -sf gcc /usr/bin/cc              &&
install -v -dm755 /usr/lib/bfd-plugins &&
ln -sfv ../../libexec/gcc/$(gcc -dumpmachine)/11.2.0/liblto_plugin.so /usr/lib/bfd-plugins/

Command Explanations

mkdir build; cd build: The GCC documentation recommends building the package in a dedicated build directory.

--disable-multilib: This parameter ensures that files are created for the specific architecture of your computer.

--with-system-zlib: Uses the system zlib instead of the bundled one. zlib is used for compressing and uncompressing GCC's intermediate language in LTO (Link Time Optimization) object files.

--enable-languages=c,c++,d,fortran,go,objc,obj-c++: This command identifies which languages to build. You may modify this command to remove undesired languages. Three other languages can be added, including ADA, BRIG (add brig to the list of enabled languages), a binary format for HSAIL (Heterogeneous System Architecture Intermediate Language), and JIT (add jit to the list of enabled languages), a library which can be linked into interpreters that want to generate machine code on the fly at run-time. They have not been tested by the BLFS developers.

ulimit -s 32768: This command prevents several tests from running out of stack space.

make -k check: This command runs the test suite without stopping if any errors are encountered.

../contrib/test_summary: This command will produce a summary of the test suite results. You can append | grep -A7 Summ to the command to produce an even more condensed version of the summary. You may also wish to redirect the output to a file for review and comparison later on.

mv -v /usr/lib/*gdb.py ...: The installation stage puts some files used by gdb under the /usr/lib directory. This generates spurious error messages when performing ldconfig. This command moves the files to another location.

chown -v -R root:root /usr/lib/gcc/*linux-gnu/...: If the package is built by a user other than root, the ownership of the installed include directory (and its content) will be incorrect. This command changes the ownership to the root user and group.

rm -rf .../include-fixed/bits/: Remove an erroneous file in gcc added by the fixincludes process.

Contents

Some program and library names and descriptions are not listed here, but can be found at LFS section for GCC as they were initially installed during the building of LFS.

Installed Programs: gccgo, gdc, gfortran, go, and gofmt, hard-linked to architecture specific names
Installed Libraries: libgfortran.{so,a}, libgdruntime.{so,a}, libgphobos.{so,a} libgo.{so,a}, libgobegin.a, libgolibbegin.a, libobjc.{so,a}, and numerous other run-time libraries and executables
Installed Directories: /usr/lib/go

Short Descriptions

gccgo

is a GCC-based compiler for the Go language

go

is a tool for managing Go source code

gofmt

is a tool for formatting Go source code

gdc

is a GCC-based compiler for the D language

gfortran

is a GCC-based compiler for the Fortran language

Last updated on

GC-8.0.6

Introduction to GC

The GC package contains the Boehm-Demers-Weiser conservative garbage collector, which can be used as a garbage collecting replacement for the C malloc function or C++ new operator. It allows you to allocate memory basically as you normally would, without explicitly deallocating memory that is no longer useful. The collector automatically recycles memory when it determines that it can no longer be otherwise accessed. The collector is also used by a number of programming language implementations that either use C as intermediate code, want to facilitate easier interoperation with C libraries, or just prefer the simple collector interface. Alternatively, the garbage collector may be used as a leak detector for C or C++ programs, though that is not its primary goal.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Optional

libatomic_ops-7.6.12

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gc

Installation of GC

Install GC by running the following commands:

./configure --prefix=/usr      \
            --enable-cplusplus \
            --disable-static   \
            --docdir=/usr/share/doc/gc-8.0.6 &&
make

To test the results, issue: make check.

Now, as the root user:

make install &&
install -v -m644 doc/gc.man /usr/share/man/man3/gc_malloc.3

Command Explanations

--docdir=/usr/share/doc/gc-8.0.6: This option is used so the package will install the documentation in a versioned directory.

--enable-cplusplus: This parameter enables the building and installing of the C++ library along with the standard C library.

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Libraries: libcord.so, libgc.so, and libgccpp.so
Installed Directories: /usr/include/gc and /usr/share/doc/gc-8.0.6

Short Descriptions

libcord.so

contains a tree-based string library

libgc.so

contains a C interface to the conservative garbage collector, primarily designed to replace the C malloc function

libgccpp.so

contains a C++ interface to the conservative garbage collector

Last updated on

GDB-11.2

Introduction to GDB

GDB, the GNU Project debugger, allows you to see what is going on inside another program while it executes -- or what another program was doing at the moment it crashed. Note that GDB is most effective when tracing programs and libraries that were built with debugging symbols and not stripped.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

GDB Dependencies

Recommended Runtime Dependency
Optional

Doxygen-1.9.3, GCC-11.2.0 (ada, gfortran, and go are used for tests), Guile-3.0.8, Python-2.7.18, rustc-1.58.1 (used for some tests), Valgrind-3.18.1, and SystemTap (run-time, used for tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gdb

Installation of GDB

First, apply some changes from upstream to fix issues with glibc-2.35:

patch -Np1 -i ../gdb-11.2-upstream_fixes-1.patch

Install GDB by running the following commands:

mkdir build &&
cd    build &&

../configure --prefix=/usr          \
             --with-system-readline \
             --with-python=/usr/bin/python3 &&
make

Optionally, to build the API documentation using Doxygen-1.9.3, run:

make -C gdb/doc doxy

To test the results, issue:

pushd gdb/testsuite &&
make  site.exp      &&
echo  "set gdb_test_timeout 120" >> site.exp &&
runtest
popd

See gdb/testsuite/README and TestingGDB. There are many problems with the test suite:

  • Clean directories are needed if re-running the tests. For that reason, make a copy of the compiled source code directory before the tests in case you need to run the tests again.

  • Results depend on installed compilers.

  • A few tests assume that the header file <sys/sdt.h>, part of SystemTap, is present.

  • A test run of the test suite had about 1700 unexpected failures (out of over 80000 tests). Over 1370 of the failures were related to FORTRAN tests.

  • On some systems, the gdb.tui test suite will fail if running over SSH.

  • On some AMD-based systems, over 200 additional tests may fail due to a difference in the threading implementation on those CPUs.

Now, as the root user:

make -C gdb install

If you have built the API documentation, it is now in gdb/doc/doxy. You can install it (as the root user):

install -d /usr/share/doc/gdb-11.2 &&
rm -rf gdb/doc/doxy/xml &&
cp -Rv gdb/doc/doxy /usr/share/doc/gdb-11.2

Command Explanations

--with-system-readline: This switch forces GDB to use the copy of Readline installed in LFS.

--with-python=/usr/bin/python3: This switch forces GDB to use Python 3. Remove this switch if you have installed Python-2.7.18 and want to use it instead of Python 3.

Contents

Installed Programs: gcore, gdb and gdbserver
Installed Library: None
Installed Directories: /usr/{include,share}/gdb and /usr/share/doc/gdb-11.2

Short Descriptions

gcore

generates a core dump of a running program

gdb

is the GNU Debugger

gdbserver

is a remote server for the GNU debugger (it allows programs to be debugged from a different machine)

Last updated on

Git-2.35.1

Introduction to Git

Git is a free and open source, distributed version control system designed to handle everything from small to very large projects with speed and efficiency. Every Git clone is a full-fledged repository with complete history and full revision tracking capabilities, not dependent on network access or a central server. Branching and merging are fast and easy to do. Git is used for version control of files, much like tools such as Mercurial-6.0.2, Bazaar, Subversion-1.14.1, CVS, Perforce, and Team Foundation Server.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://www.kernel.org/pub/software/scm/git/git-2.35.1.tar.xz

  • Download MD5 sum: 3aae077280b6be861e3c1c637491853a

  • Download size: 6.6 MB

  • Estimated disk space required: 224 MB (with downloaded documentation, add 16 MB to build documentation)

  • Estimated build time: 0.3 SBU (with parallelism=4; add 0.6 SBU for building documentation and 1.6 SBU for tests, both with parallelism=4)

Additional Downloads

Git Dependencies

Recommended
Optional

GnuPG-2.2.34 (runtime, may be used to sign Git commits or tags, or verify the signatures of them), OpenSSH-8.8p1 (runtime, needed to use Git over ssh), pcre2-10.39 (or the deprecated PCRE-8.45), in either case configured with --enable-jit, Subversion-1.14.1 with Perl bindings (runtime, for git svn), Tk-8.6.12 (gitk, a simple Git repository viewer, uses Tk at runtime), Valgrind-3.18.1, Authen::SASL and MIME::Base64 (both runtime, for git send-email)

Optional (to create the man pages, html docs and other docs)

xmlto-0.0.28 and asciidoc-10.1.1 , and also dblatex (for the PDF version of the user manual), and docbook2x to create info pages

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/git

Installation of Git

Install Git by running the following commands:

./configure --prefix=/usr \
            --with-gitconfig=/etc/gitconfig \
            --with-python=python3 &&
make

You can build the man pages and/or html docs, or use downloaded ones. If you choose to build them, use the next two instructions.

If you have installed asciidoc-10.1.1 you can create the html version of the man pages and other docs:

make html

If you have installed asciidoc-10.1.1 and xmlto-0.0.28 you can create the man pages:

make man

The test suite can be run in parallel mode. To run the test suite, issue: make test. If run as a normal user, 0 tests should be reported as failed in the final summary.

Now, as the root user:

make perllibdir=/usr/lib/perl5/5.34/site_perl install

If you created the man pages and/or html docs

Install the man pages as the root user:

make install-man

Install the html docs as the root user:

make htmldir=/usr/share/doc/git-2.35.1 install-html

If you downloaded the man pages and/or html docs

If you downloaded the man pages untar them as the root user:

tar -xf ../git-manpages-2.35.1.tar.xz \
    -C /usr/share/man --no-same-owner --no-overwrite-dir

If you downloaded the html docs untar them as the root user:

mkdir -vp   /usr/share/doc/git-2.35.1 &&
tar   -xf   ../git-htmldocs-2.35.1.tar.xz \
      -C    /usr/share/doc/git-2.35.1 --no-same-owner --no-overwrite-dir &&

find        /usr/share/doc/git-2.35.1 -type d -exec chmod 755 {} \; &&
find        /usr/share/doc/git-2.35.1 -type f -exec chmod 644 {} \;

Reorganize text and html in the html-docs (both methods)

For both methods, the html-docs include a lot of plain text files. Reorganize the files as the root user:

mkdir -vp /usr/share/doc/git-2.35.1/man-pages/{html,text}         &&
mv        /usr/share/doc/git-2.35.1/{git*.txt,man-pages/text}     &&
mv        /usr/share/doc/git-2.35.1/{git*.,index.,man-pages/}html &&

mkdir -vp /usr/share/doc/git-2.35.1/technical/{html,text}         &&
mv        /usr/share/doc/git-2.35.1/technical/{*.txt,text}        &&
mv        /usr/share/doc/git-2.35.1/technical/{*.,}html           &&

mkdir -vp /usr/share/doc/git-2.35.1/howto/{html,text}             &&
mv        /usr/share/doc/git-2.35.1/howto/{*.txt,text}            &&
mv        /usr/share/doc/git-2.35.1/howto/{*.,}html               &&

sed -i '/^<a href=/s|howto/|&html/|' /usr/share/doc/git-2.35.1/howto-index.html &&
sed -i '/^\* link:/s|howto/|&html/|' /usr/share/doc/git-2.35.1/howto-index.txt

Command Explanations

--with-gitconfig=/etc/gitconfig: This sets /etc/gitconfig as the file that stores the default, system wide, Git settings.

--with-python=python3: Use this switch to use Python 3, instead of the EOL'ed Python 2. Python is used for the git p4 interface to Perforce repositories, and also used in some tests.

--with-libpcre2: Use this switch if PCRE2 is installed and has been built with the non-default JIT enabled.

--with-libpcre: As an alternative to PCRE2, use this switch if the deprecated PCRE is installed and has been built with the non-default JIT enabled.

tar -xf ../git-manpages-2.35.1.tar.gz -C /usr/share/man --no-same-owner: This untars git-manpages-2.35.1.tar.gz. The -C option makes tar change directory to /usr/share/man before it starts to decompress the docs. The --no-same-owner option stops tar from preserving the user and group details of the files. This is useful as that user or group may not exist on your system; this could (potentially) be a security risk.

mv /usr/share/doc/git-2.35.1 ...: These commands move some of the files into subfolders to make it easier to sort through the docs and find what you're looking for.

find ... chmod ...: These commands correct the permissions in the shipped documentation tar file.

Configuring Git

Config Files

~/.gitconfig and /etc/gitconfig

Contents

Installed Programs: git, git-receive-pack, git-upload-archive, and git-upload-pack (hardlinked to each other), git-cvsserver, git-shell, and gitk
Installed Libraries: None
Installed Directories: /usr/libexec/git-core, and /usr/share/{doc/git-2.35.1,git-core,git-gui,gitk,gitweb}

Short Descriptions

git

is the stupid content tracker

git-cvsserver

is a CVS server emulator for Git

gitk

is a graphical Git repository browser (needs Tk-8.6.12)

git-receive-pack

is invoked by git send-pack and updates the repository with the information fed from the remote end

git-shell

is a login shell for SSH accounts to provide restricted Git access

git-upload-archive

is invoked by git archive --remote and sends a generated archive to the other end over the git protocol

git-upload-pack

is invoked by git fetch-pack, it discovers what objects the other side is missing, and sends them after packing

Last updated on

Running a Git Server

Introduction

This section will describe how to set up, administer and secure a git server. Git has many options available. For more detailed documentation see https://git-scm.com/book/en/v2.

Server Dependencies

Required

git-2.35.1 and OpenSSH-8.8p1

Setting up a Git Server

The following instructions will install a git server. It will be set up to use OpenSSH as the secure remote access method.

Configuration of the server consists of the following steps:

1. Setup Users, Groups, and Permissions

You will need to be user root for the initial portion of configuration. Create the git user and group and set and unusable password hash with the following commands:

groupadd -g 58 git &&
useradd -c "git Owner" -d /home/git -m -g git -s /usr/bin/git-shell -u 58 git &&
sed -i '/^git:/s/^git:[^:]:/git:NP:/' /etc/shadow

Putting in an unuable password hash (replacing the ! by NP) unlocks the account but it cannot be used to login via password authentication. That is required by sshd to work properly. Next, create some files and directories in the home directory of the git user allowing access to the git repository using ssh keys.

install -o git -g git -dm0700 /home/git/.ssh &&
install -o git -g git -m0600 /dev/null /home/git/.ssh/authorized_keys

For any developer who should have access to the repository add his/her public ssh key to /home/git/.ssh/authorized_keys. First, prepend some options to prevent users from using the connection to git for port forwarding to other machines the git server might reach.

echo -n "no-port-forwarding,no-X11-forwarding,no-agent-forwarding,no-pty " >> /home/git/.ssh/authorized_keys &&
cat <user-ssh-key> >> /home/git/.ssh/authorized_keys

It is also useful to set the default name of the initial branch of new repositories by modifying the git configuration. As the root user, run:

git config --system init.defaultBranch trunk

Finally add the /usr/bin/git-shell entry to the /etc/shells configuration file. This shell has been set in the git user profile and is to make sure that only git related actions can be executed:

echo "/usr/bin/git-shell" >> /etc/shells

2. Create a git repository

The repository can be anywhere on the filesystem. It is important that the git user has read/write access to that location. We use /srv/git as base directory. Create a new git repository with the following commands (as the root user):

Note

In all the instructions below, we use project1 as an example repository name. You should name your repository as a short descriptive name for your specific project.

install -o git -g git -m755 -d /srv/git/project1.git &&
cd /srv/git/project1.git                             &&
git init --bare                                      &&
chown -R git:git .

3. Populate the repository from a client system

Note

All the instructions in this section and the next should be done on a user system, not the server system.

Now that the repository is created, it can be used by the developers to put some files into it. Once the ssh key of the user is imported to git's authorized_keys file, the user can interact with the repository.

A minimal configuration should be available on the developer's system specifying its user name and the email address. Create this minimal config file on client side:

cat > ~/.gitconfig <<EOF
[user]
        name = <users-name>
        email = <users-email-address>
EOF

On the developer's machine, setup some files to be pushed to the repository as the initial content:

Note

The gitserver term used below should be the host name (or ip address) of the git server.

mkdir myproject
cd myproject
git init --initial-branch=trunk
git remote add origin git@gitserver:/srv/git/project1.git
cat >README <<EOF
This is the README file
EOF
git add README
git commit -m 'Initial creation of README'
git push --set-upstream origin trunk

The initial content is now pushed to the server and is available for other users. On the current machine, the argument --set-upstream origin trunk is now no longer required as the local repository is now connected to the remote repository. Subsequent pushes can be performed as

git push

Other developers can now clone the repository and do modifications to the content (as long as their ssh keys has been installed):

git clone git@gitserver:/srv/git/project1.git
cd project1
vi README
git commit -am 'Fix for README file'
git push

Note

This is a very basic server setup based on OpenSSH access. All developers are using the git user to perform actions on the repository and the changes users are committing can be distiguished as the local user name (see ~/.gitconfig) is recorded in the changesets.

Access is restricted by the public keys added to git's authorized_keys file and there is no option for the public to export/clone the repository. To enable this, continue with step 4 to set up the git server for public read-only access.

In the URL used to clone the project, the absolute path (here /srv/git/project1.git) has to be specified as the repository is not in git's home directory but in /srv/git. To get rid of the need to expose the structure of the server installation, a symlink can be added in git's home directory for each project like this:

ln -svf /srv/git/project1.git /home/git/

Now, the repository can be cloned using

git clone git@gitserver:project1.git

4. Configure the Server

The setup described above makes a repository available for authenticated users (via providing the ssh public key file). There is also a simple way to publish the repository to unauthenticated users — of course without write access.

The combination of access via ssh (for authenticated users) and the export of repositories to unauthenticated users via the daemon is in most cases enough for a development site.

Note

The daemon will be reachable at port 9418 by default. Make sure that your firewall setup allows access to that port.

To start the server at boot time, install the git-daemon bootscript included in the blfs-bootscripts-20210826 package:

make install-git-daemon

In order to allow git to export a repository, a file named git-daemon-export-ok is required in each repository directory on the server. The file needs no content, just its existence enables, its absence disables the export of that repository.

touch /srv/git/project1.git/git-daemon-export-ok

The script to start the git daemon uses some default values internally. Most important is the path to the repository directory which is set to /srv/git. In case you have for whatever reason created the repository in a different location, you'll need to tell the boot script where the repository is to be found. This can be achieved by creating a configuration file named /etc/sysconfig/git-daemon. This configuration file will be imported if it exists, meaning it is optional. The file can look like:

# Begin /etc/sysconfig/git-daemon

# Specify the location of the git repository
GIT_BASE_DIR="/srv/git/"

# Directories added to whitelist
DFT_REPO_DIR="$GIT_BASE_DIR"

# Add extra options which will appended to the 'git daemon'
# command executed in the boot script
GIT_DAEMON_OPTS=""

# End /etc/sysconfig/git-daemon

There are only three options to set in the configuration file:

  • GIT_BASE_DIR=<dirname>

    Specify the location of the git repositories. Relative paths used when accessing the daemon will translated relative to this directory.

  • DFT_REPO_DIR=<dirname>

    This directory is added to the white list of allowed directories. This variable can hold multiple directory names but is usually set equal to GIT_BASE_DIR.

  • GIT_DAEMON_OPTS=<options>

    In case special options to the git daemon command are needed, they have to be specified in this setting. One example might be to adjust the port number where daemon is listening. In this case, add --port=<port number> to this variable. For more information about which options can be set, take a look at the output of git daemon --help.

After starting the daemon, unauthenticated users can clone exported repositories by using

git clone git://gitserver/project1.git

As the base directory is /srv/git by default (or set to a custom value in the configuration), git interprets the incoming path (/project1.git) relative to that base directory so that the repository in /srv/git/project1.git is served.

Last updated on

Guile-3.0.8

Introduction to Guile

The Guile package contains the GNU Project's extension language library. Guile also contains a stand alone Scheme interpreter.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Guile Dependencies

Required

GC-8.0.6 and libunistring-1.0

Optional

Emacs-27.2 and GDB-11.2 (run-time only dependencies).

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/guile

Installation of Guile

Install Guile by running the following commands:

./configure --prefix=/usr    \
            --disable-static \
            --docdir=/usr/share/doc/guile-3.0.8 &&
make      &&
make html &&

makeinfo --plaintext -o doc/r5rs/r5rs.txt doc/r5rs/r5rs.texi &&
makeinfo --plaintext -o doc/ref/guile.txt doc/ref/guile.texi

To test the results, issue: ./check-guile. On an i686 system, as many as 10 tests will fail in the numbers.test test suite due to minor floating-point rounding errors.

Now, as the root user:

make install      &&
make install-html &&

mkdir -p                       /usr/share/gdb/auto-load/usr/lib &&
mv /usr/lib/libguile-*-gdb.scm /usr/share/gdb/auto-load/usr/lib &&
mv /usr/share/doc/guile-3.0.8/{guile.html,ref} &&
mv /usr/share/doc/guile-3.0.8/r5rs{.html,}     &&

find examples -name "Makefile*" -delete         &&
cp -vR examples   /usr/share/doc/guile-3.0.8   &&

for DIRNAME in r5rs ref; do
  install -v -m644  doc/${DIRNAME}/*.txt \
                    /usr/share/doc/guile-3.0.8/${DIRNAME}
done &&
unset DIRNAME

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: guild, guile, guile-config, guile-snarf and guile-tools
Installed Libraries: libguile-3.0.so and guile-readline.so
Installed Directories: /usr/include/guile, /usr/lib/guile, /usr/share/doc/guile-3.0.8 and /usr/share/guile

Short Descriptions

guile

is a stand-alone Scheme interpreter for Guile

guile-config

is a Guile script which provides the information necessary to link your programs against the Guile library, in much the same way PkgConfig does

guile-snarf

is a script to parse declarations in your C code for Scheme visible C functions

guild

is a wrapper program installed along with guile, which knows where a particular module is installed and calls it, passing its arguments to the program

guile-tools

is a symlink to guild

Last updated on

Librep-0.92.7

Introduction to Librep

The librep package contains a Lisp system. This is useful for scripting or for applications that may use the Lisp interpreter as an extension language.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/librep

Installation of Librep

Install librep by running the following commands:

./configure --prefix=/usr --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

sed -i '5043,5044 d' libtool &&
make install

Contents

Installed Programs: rep, rep-remote, rep-xgettext, and repdoc
Installed Libraries: librep.so and numerous modules installed in the /usr/lib/rep hierarchy
Installed Directories: /usr/lib/rep, /usr/share/emacs/site-lisp, and /usr/share/rep

Short Descriptions

rep

is the Lisp interpreter

librep.so

contains the functions necessary for the Lisp interpreter

Last updated on

LLVM-13.0.1

Introduction to LLVM

The LLVM package contains a collection of modular and reusable compiler and toolchain technologies. The Low Level Virtual Machine (LLVM) Core libraries provide a modern source and target-independent optimizer, along with code generation support for many popular CPUs (as well as some less common ones!). These libraries are built around a well specified code representation known as the LLVM intermediate representation ("LLVM IR").

Clang provides new C, C++, Objective C and Objective C++ front-ends for LLVM and is required by some desktop packages such as firefox and for rust if that is built using the system LLVM.

The Compiler RT package provides runtime sanitizer and profiling libraries for developers who use Clang and LLVM.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Recommended Download

Clang

Optional Download

Compiler RT

LLVM Dependencies

Required

CMake-3.22.2

Optional

Doxygen-1.9.3, git-2.35.1, Graphviz-2.50.0, libxml2-2.9.13, Pygments-2.11.2, rsync-3.2.3 (for tests), texlive-20210325 (or install-tl-unx), Valgrind-3.18.1, PyYAML-5.3.1, Zip-3.0, OCaml, psutil, recommonmark, Sphinx, and Z3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/llvm

Installation of LLVM

Install clang into the source tree by running the following commands:

tar -xf ../clang-13.0.1.src.tar.xz -C tools &&
mv tools/clang-13.0.1.src tools/clang

If you have downloaded compiler-rt, install it into the source tree by running the following commands:

tar -xf ../compiler-rt-13.0.1.src.tar.xz -C projects &&
mv projects/compiler-rt-13.0.1.src projects/compiler-rt

There are many Python scripts in this package which use /usr/bin/env python to access the system Python which on LFS is Python-3.10.2. Use the following comand to fix these scripts:

grep -rl '#!.*python' | xargs sed -i '1s/python$/python3/'

Install LLVM by running the following commands:

mkdir -v build &&
cd       build &&

CC=gcc CXX=g++                                  \
cmake -DCMAKE_INSTALL_PREFIX=/usr               \
      -DLLVM_ENABLE_FFI=ON                      \
      -DCMAKE_BUILD_TYPE=Release                \
      -DLLVM_BUILD_LLVM_DYLIB=ON                \
      -DLLVM_LINK_LLVM_DYLIB=ON                 \
      -DLLVM_ENABLE_RTTI=ON                     \
      -DLLVM_TARGETS_TO_BUILD="host;AMDGPU;BPF" \
      -DLLVM_BINUTILS_INCDIR=/usr/include       \
      -Wno-dev -G Ninja ..                      &&
ninja

If you have installed Sphinx and recommonmark and wish to generate the html documentation and manual pages, issue the following commands:

cmake -DLLVM_BUILD_DOCS=ON            \
      -DLLVM_ENABLE_SPHINX=ON         \
      -DSPHINX_WARNINGS_AS_ERRORS=OFF \
      -Wno-dev -G Ninja ..            &&
ninja docs-llvm-html  docs-llvm-man

The clang documentation can be built too:

ninja docs-clang-html docs-clang-man

To test the results, issue: ninja check-all. Tests are built with all available cores, but run using the number of online processors. (The difference is that available cores can be limited using taskset, but taking them offline requires echoing 0 to /sys/devices/system/cpu/cpu<N>/online by the root user and makes them temporarily unusable by all jobs on the machine.) Note that a few of the compiler-rt Sanitizer based tests (13 of more than 59000 tests run) are known to fail. Some of the LLVM-Unit IR tests are known to fail as well.

Now, as the root user:

ninja install

If you have built the llvm documentation, it has been installed by the above command, but it needs to be moved. As the root user:

install -v -d -m755 /usr/share/doc/llvm-13.0.1                        &&
mv -v /usr/share/doc/llvm/html /usr/share/doc/llvm-13.0.1/llvm-html   &&
rmdir -v /usr/share/doc/llvm

If you have built the clang documentation, it has been installed, but needs to be moved too. Again as the root user:

install -v -d -m755 /usr/share/doc/llvm-13.0.1                        &&
mv -v /usr/share/doc/clang/html /usr/share/doc/llvm-13.0.1/clang-html &&
rmdir -v /usr/share/doc/clang

Command Explanations

-DLLVM_ENABLE_FFI=ON: This switch allows LLVM to use libffi.

-DLLVM_BUILD_LLVM_DYLIB=ON: This switch builds the libraries as static and links all of them into an unique shared one. This is the recommended way of building a shared library.

-DCMAKE_BUILD_TYPE=Release: This switch enables compiler optimizations in order to speed up the code and reduce its size. It also disables some compile checks which are not necessary on a production system.

-DLLVM_TARGETS_TO_BUILD="host;AMDGPU;BPF": This switch enables building for the same target as the host, and also for the r600 AMD GPU used by the Mesa r600 and radeonsi drivers. The BPF target is required to build v4l-utils-1.22.1. The Default is all of the targets. You can use a semicolon separated list. Valid targets are: host, X86, Sparc, PowerPC, ARM, AArch64, Mips, Hexagon, Xcore, M68K, MSP430, NVPTX, SystemZ, AMDGPU, BPF, CppBackend, or all.

-DLLVM_LINK_LLVM_DYLIB=ON: Used in conjunction with -DLLVM_BUILD_LLVM_DYLIB=ON, this switch enables linking the tools against the shared library instead of the static ones. It also slightly reduces their size and also ensures that llvm-config will correctly use libLLVM-13.0.so.

-DLLVM_ENABLE_RTTI=ON: This switch is used to build LLVM with run-time type information. This is required for building Mesa-21.3.6.

-DLLVM_BINUTILS_INCDIR=/usr/include: This switch is used to tell the build system the location of binutils headers, which were installed in LFS. This allows the building of LLVMgold.so, which is needed for building programs with clang and Link Time Optimization (LTO).

-DBUILD_SHARED_LIBS=ON: if used instead of -DLLVM_BUILD_LLVM_DYLIB=ON and -DLLVM_LINK_LLVM_DYLIB=ON, builds all the LLVM libraries (about 60) as shared libraries instead of static.

-DLLVM_ENABLE_DOXYGEN: Enables the generation of browsable HTML documentation if you have installed Doxygen-1.9.3. You should run make doxygen-html afterwards, and install the generated documentation manually.

Contents

Installed Programs: bugpoint, c-index-test, clang, clang++ (symlinks to clang-<version>), clang-<version>, clang-check, clang-cl, clang-cpp (last two symlinks to clang), clang-extdef-mapping, clang-format, clang-offload-bundler, clang-offload-wrapper, clang-refactor, clang-rename, clang-repl, clang-scan-deps, diagtool, dsymutil, git-clang-format, hmaptool, llc, lli, llvm-addr2line (symlink to llvm-symbolizer), llvm-ar, llvm-as, llvm-bcanalyzer, llvm-bitcode-strip (symlink to llvm-objcopy), llvm-cat, llvm-cfi-verify, llvm-config, llvm-cov, llvm-c-test, llvm-cvtres, llvm-cxxdump, llvm-cxxfilt, llvm-cxxmap, llvm-diff, llvm-dis, llvm-dlltool (symlink to llvm-ar), llvm-dwarfdump, llvm-dwp, llvm-exegenesis, llvm-extract, llvm-gsymutil, llvm-ifs, llvm-install-name-tool (symlink to llvm-objcopy), llvm-jitlink, llvm-lib (symlink to llvm-ar), llvm-libtool-darwin, llvm-link, llvm-lipo, llvm-lto, llvm-lto2, llvm-mc, llvm-mca, llvm-ml, llvm-modextract, llvm-mt, llvm-nm, llvm-objcopy, llvm-objdump, llvm-opt-report, llvm-otool (symlink to llv-objdump), llvm-pdbutil, llvm-profdata, llvm-profgen, llvm-ranlib (symlink to llvm-ar), llvm-rc, llvm-readelf (symlink to llvm-readobj), llvm-readobj, llvm-reduce, llvm-rtdyld, llvm-sim, llvm-size, llvm-split, llvm-stress, llvm-strings, llvm-strip (symlink to llvm-objcopy), llvm-symbolizer, llvm-tapi-diff, llvm-tblgen, llvm-undname, llvm-windres (symlink to llvm-rc, llvm-xray, opt, sancov, sanstats, scan-build, scan-view, split-file, and verify-uselistorder
Installed Libraries: libLLVM.so, libLLVM*.a (89 libraries), libLTO.so, libRemarks.so, libclang.so, libclang-cpp.so, libclang*.a (38 libraries), and LLVMgold.so
Installed Directories: /usr/include/{clang,clang-c,llvm,llvm-c}, /usr/lib/{clang,cmake/{clang,llvm},libear,libscanbuild}, /usr/share/{clang,opt-viewer,scan-build,scan-view}, and /usr/share/doc/llvm-13.0.1

Short Descriptions

bugpoint

is the automatic test case reduction tool

c-index-test

is used to test the libclang API and demonstrate its usage

clang

is the Clang C, C++, and Objective-C compiler

clang-check

is a tool to perform static code analysis and display Abstract Syntax Trees (AST)

clang-extdef-mapping

is a tool to collect the USR name and location of external definitions in a source file

clang-format

is a tool to format C/C++/Java/JavaScript/Objective-C/Protobuf code

clang-offload-bundler

is a tool to bundle/unbundle OpenMP offloaded files associated with a common source file

clang-offload-wrapper

is a tool to create wrapper bitcode for offload target binaries

clang-refactor

is a Clang-based refactoring tool for C, C++ and Objective-C

clang-rename

is a tool to rename symbols in C/C++ programs

clang-scan-deps

is a tool to scan for dependencies in a source file

diagtool

is a combination of tools for dealing with diagnostics in clang

dsymutil

is a tool used to manipulate archived DWARF debug symbol files, compatible with the Darwin command dsymutil

git-clang-format

runs clang-format on git generated patches (requires git-2.35.1)

hmaptool

is a Python tool to dump and construct header maps

llc

is the LLVM static compiler

lli

is used to directly execute programs from LLVM bitcode

llvm-addr2line

is a tool used to convert addresses into file names and line numbers

llvm-ar

is the LLVM archiver

llvm-as

is the LLVM assembler

llvm-bcanalyzer

is the LLVM bitcode analyzer

llvm-bitcode-strip

strips LLVM bitcode from an object

llvm-cat

is a tool to concatenate llvm modules

llvm-cfi-verify

identifies whether Control Flow Integrity protects all indirect control flow instructions in the provided object file, DSO, or binary

llvm-config

Prints LLVM compilation options

llvm-cov

is used to emit coverage information

llvm-c-test

is a bytecode disassembler

llvm-cvtres

is a tool to convert Microsoft resource files to COFF

llvm-cxxdump

is used as a C++ ABI Data Dumper

llvm-cxxfilt

is used to demangle C++ symbols in llvm code

llvm-cxxmap

is used to remap C++ mangled symbols

llvm-diff

is the LLVM structural 'diff'

llvm-dis

is the LLVM disassembler

llvm-dwarfdump

prints the content of DWARF sections in object files

llvm-dwp

merges split DWARF files

llvm-elfabi

is used to read information about an ELF binary's ABI

llvm-exegesis

is a benchmarking tool that uses information available in LLVM to measure host machine instruction characteristics like latency or port decomposition

llvm-extract

is used to extract a function from an LLVM module

llvm-gsymutil

is used to process GSYM Symbolication Format files which convert memory addresses to function name and source file line. These files are smaller than DWARF or Breakpad files

llvm-ifs

is used to merge interface stubs with object files

llvm-install-name-tool

is used to rewrite load commands into MachO binary format

llvm-jitlink

is used to parse relocatable object files to make their contents executable in a target process

llvm-libtool-darwin

provides basic libtool functionality on Darwin-based systems. This is mostly useful if you are generating binaries for macOS systems

llvm-link

is the LLVM linker

llvm-lipo

is used to create universal binaries from MachO files

llvm-lto

is the LLVM LTO (link time optimization) linker

llvm-lto2

is a test harness for the resolution based LTO interface

llvm-mc

is a standalone machine code assembler/disassembler

llvm-mca

is a performance analysis tool to statically measure the performance of machine code

llvm-ml

is a playground for machine code provided by LLVM

llvm-modextract

is a tool to extract one module from multimodule bitcode files

llvm-mt

is a tool to generate signed files and catalogs from a side-by-side assembly manifest (used for Microsoft SDK)

llvm-nm

is used to list LLVM bitcode and object file's symbol table

llvm-objcopy

is LLVM's version of an objcopy tool

llvm-objdump

is an LLVM object file dumper

llvm-opt-report

is a tool to generate an optimization report from YAML optimization record files

llvm-pdbutil

is a PDB (Program Database) dumper. PDB is a Microsoft format

llvm-profdata

is a small tool to manipulate and print profile data files

llvm-profgen

generates LLVM SPGO profiling information

llvm-ranlib

is used to generate an index for a LLVM archive

llvm-rc

is a platform-independent tool to compile resource scripts into binary resource files

llvm-readobj

displays low-level format-specific information about object files

llvm-reduce

is used to automatically reduce testcases when running a test suite

llvm-rtdyld

is the LLVM MC-JIT tool

llvm-size

is the LLVM object size dumper

llvm-split

is the LLVM module splitter

llvm-stress

is used to generate random .ll files

llvm-strings

print strings found in a binary (object file, executable, or archive library)

llvm-symbolizer

converts adresses into source code locations

llvm-tblgen

is the LLVM Target Description To C++ Code Generator

llvm-undname

is a tool to demangle names

llvm-xray

is an implementation of Google's XRay function call tracing system

opt

is the LLVM optimizer

sancov

is the sanitizer coverage processing tool

sanstats

is the sanitizer statistics processing tool

scan-build

is a Perl script that invokes the Clang static analyzer

scan-view

is a viewer for Clang static analyzer results

split-file

splits an input file into multiple parts separated by regex

verify-uselistorder

is the LLVM tool to verify use-list order

Last updated on

Lua-5.4.4

Introduction to Lua

Lua is a powerful light-weight programming language designed for extending applications. It is also frequently used as a general-purpose, stand-alone language. Lua is implemented as a small library of C functions, written in ANSI C, and compiles unmodified in all known platforms. The implementation goals are simplicity, efficiency, portability, and low embedding cost. The result is a fast language engine with small footprint, making it ideal in embedded systems too.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://www.lua.org/ftp/lua-5.4.4.tar.gz

  • Download MD5 sum: bd8ce7069ff99a400efd14cf339a727b

  • Download size: 356 KB

  • Estimated disk space required: 5.8 MB (with Basic tests)

  • Estimated build time: less than 0.1 SBU (with Basic tests)

Additional Downloads

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lua

Installation of Lua

Some packages check for the pkg-config file for Lua, which is created with:

cat > lua.pc << "EOF"
V=5.4
R=5.4.4

prefix=/usr
INSTALL_BIN=${prefix}/bin
INSTALL_INC=${prefix}/include
INSTALL_LIB=${prefix}/lib
INSTALL_MAN=${prefix}/share/man/man1
INSTALL_LMOD=${prefix}/share/lua/${V}
INSTALL_CMOD=${prefix}/lib/lua/${V}
exec_prefix=${prefix}
libdir=${exec_prefix}/lib
includedir=${prefix}/include

Name: Lua
Description: An Extensible Extension Language
Version: ${R}
Requires:
Libs: -L${libdir} -llua -lm -ldl
Cflags: -I${includedir}
EOF

Install Lua by running the following commands:

patch -Np1 -i ../lua-5.4.4-shared_library-1.patch &&
make linux

To test the results, issue: make test. This will run the interpreter and print its version. More comprehensive tests can be performed if you downloaded the "Test suite" tarball. Those tests need to be executed after the package is installed, thus we defer to the description below.

Now, as the root user:

make INSTALL_TOP=/usr                \
     INSTALL_DATA="cp -d"            \
     INSTALL_MAN=/usr/share/man/man1 \
     TO_LIB="liblua.so liblua.so.5.4 liblua.so.5.4.4" \
     install &&

mkdir -pv                      /usr/share/doc/lua-5.4.4 &&
cp -v doc/*.{html,css,gif,png} /usr/share/doc/lua-5.4.4 &&

install -v -m644 -D lua.pc /usr/lib/pkgconfig/lua.pc

Here we describe only the "Basic tests". Untar the tarball and change to the lua-5.4.4-tests directory, then issue lua -e "_U=true" all.lua. If the tests finish without error, you will see a message containing the string "final OK".

Contents

Installed Programs: lua and luac
Installed Library: liblua.so
Installed Directories: /usr/{lib,share}/lua and /usr/share/doc/lua-5.4.4

Short Descriptions

lua

is the standalone Lua interpreter

luac

is the Lua compiler

liblua.so

contains the Lua API functions

Last updated on

Lua-5.2.4

Introduction to Lua 5.2

Lua is a powerful light-weight programming language designed for extending applications. It is also frequently used as a general-purpose, stand-alone language. Lua is implemented as a small library of C functions, written in ANSI C, and compiles unmodified in all known platforms. The implementation goals are simplicity, efficiency, portability, and low embedding cost. The result is a fast language engine with small footprint, making it ideal in embedded systems too.

This is an older verion of Lua needed only for compatibility with other programs such as Wireshark-3.6.2.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://www.lua.org/ftp/lua-5.2.4.tar.gz

  • Download MD5 sum: 913fdb32207046b273fdb17aad70be13

  • Download size: 248 KB

  • Estimated disk space required: 3.6 MB

  • Estimated build time: less than 0.1 SBU

Additional Downloads

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lua

Installation of Lua 5.2

Some packages check for the pkg-config file for Lua, which is created with:

cat > lua.pc << "EOF"
V=5.2
R=5.2.4

prefix=/usr
INSTALL_BIN=${prefix}/bin
INSTALL_INC=${prefix}/include/lua5.2
INSTALL_LIB=${prefix}/lib
INSTALL_MAN=${prefix}/share/man/man1
INSTALL_LMOD=${prefix}/share/lua/${V}
INSTALL_CMOD=${prefix}/lib/lua/${V}
exec_prefix=${prefix}
libdir=${exec_prefix}/lib
includedir=${prefix}/include/lua5.2

Name: Lua
Description: An Extensible Extension Language
Version: ${R}
Requires:
Libs: -L${libdir} -llua5.2 -lm -ldl
Cflags: -I${includedir}
EOF

Install Lua by running the following commands:

patch -Np1 -i ../lua-5.2.4-shared_library-1.patch &&

sed -i '/#define LUA_ROOT/s:/usr/local/:/usr/:' src/luaconf.h &&

sed -r -e '/^LUA_(SO|A|T)=/ s/lua/lua5.2/' \
       -e '/^LUAC_T=/ s/luac/luac5.2/'     \
       -i src/Makefile &&

make MYCFLAGS="-fPIC" linux

The installation of this package is complex, so we will use the DESTDIR method of installation:

make TO_BIN='lua5.2 luac5.2'                     \
     TO_LIB="liblua5.2.so liblua5.2.so.5.2 liblua5.2.so.5.2.4" \
     INSTALL_DATA="cp -d"                        \
     INSTALL_TOP=$PWD/install/usr                \
     INSTALL_INC=$PWD/install/usr/include/lua5.2 \
     INSTALL_MAN=$PWD/install/usr/share/man/man1 \
     install &&

install -Dm644 lua.pc install/usr/lib/pkgconfig/lua52.pc &&

mkdir -pv install/usr/share/doc/lua-5.2.4 &&
cp -v doc/*.{html,css,gif,png} install/usr/share/doc/lua-5.2.4 &&

ln -s liblua5.2.so install/usr/lib/liblua.so.5.2   &&
ln -s liblua5.2.so install/usr/lib/liblua.so.5.2.4 &&

mv install/usr/share/man/man1/{lua.1,lua5.2.1} &&
mv install/usr/share/man/man1/{luac.1,luac5.2.1}

Now, as the root user:

chown -R root:root install  &&
cp -a install/* /

Command Explanations

sed -i ... src/luaconf.h: This command changes the Lua search path to match the install path.

sed -i ... src/Makefile: This command deconflicts this installation with the latest version of lua.

Contents

Installed Programs: lua5.2 and luac5.2
Installed Library: liblua5.2.so
Installed Directories: /usr/include/lua5.2, /usr/lib/lua/5.2, /usr/share/doc/lua-5.2.4, and /usr/share/lua/5.2

Short Descriptions

lua5.2

is the standalone Lua version 5.2 interpreter

luac5.2

is the Lua version 5.2 compiler

liblua5.2.so

contains the Lua version 5.2 API functions

Last updated on

Mercurial-6.0.2

Introduction to Mercurial

Mercurial is a distributed source control management tool similar to Git and Bazaar. Mercurial is written in Python and is used by projects such as Mozilla for Firefox and Thunderbird.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Mercurial Dependencies

Optional

docutils-0.18.1 (required to build the documentation), git-2.35.1, GPGME-1.17.0 (with Python bindings), OpenSSH-8.8p1 (runtime, to access ssh://... repositories), Pygments-2.11.2, rustc-1.58.1 (see rust/README.rst and rust/rhg/README.md), Subversion-1.14.1 (with Python bindings), Bazaar, CVS, pyflakes, pyOpenSSL, and re2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/mercurial

Installation of Mercurial

Build Mercurial by issuing the following command:

make build

To build the documentation (requires docutils-0.18.1), issue:

make doc

To run the test suite, issue (15 tests are known to fail):

TESTFLAGS="-j<N> --tmpdir tmp --blacklist blacklists/fsmonitor --blacklist blacklists/linux-vfat" make check

where <N> is an integer between one and the number of ( processor X threads ), inclusive. In order to investigate any apparently failing tests, you may use the run-tests.py script. To see the almost forty switches, some of them very useful, issue tests/run-tests.py --help. Running the following commands, you will execute only the tests that failed before:

pushd tests  &&
  rm -rf tmp &&
  ./run-tests.py --tmpdir tmp test-gpg.t
popd

Normally, the previous failures will be confirmed. However, if you add the switch --debug before --tmpdir, and run again, some failures are gone, which seems to be a problem with the test suite. If this happens, normally, from now on, there will be no more such failures whether you use the debug switch or not. There are 13 of 876 tests that are known to fail.

An interesting switch is --time, which will generate at the end of the test suite execution, a table with all executed tests and respective start, end, user, system and real times. Note that the switches may be used with make check by including them in the TESTFLAGS environment variable.

Install Mercurial by running the following command (as root):

make PREFIX=/usr install-bin

If you built the documentation, install it by running the following command (as root):

make PREFIX=/usr install-doc

After installation, two very quick and simple tests should run correctly. The first one needs some configuration:

cat >> ~/.hgrc << "EOF"
[ui]
username = <user_name> <user@mail>
EOF

where you must replace <user_name> and <your@mail> (mail is optional and can be omitted). With the user identity defined, run hg debuginstall and several lines will be displayed, the last one reading "no problems detected". Another quick and simple test is just hg, which should output basic commands that can be used with hg.

Configuring Mercurial

Config Files

/etc/mercurial/hgrc and ~/.hgrc

The great majority of extensions are disabled by default. Run hg help extensions if you need to enable any, e.g. when investigating test failures. You will obtain the lists of enabled and disabled extensions, and more information, such as how to enable or disable them using configuration files.

If you have installed make-ca-1.10 and want Mercurial to use the certificates, as the root user, issue:

install -v -d -m755 /etc/mercurial &&
cat > /etc/mercurial/hgrc << "EOF"
[web]
cacerts = /etc/pki/tls/certs/ca-bundle.crt
EOF

Contents

Installed Programs: hg
Installed Libraries: several internal modules under /usr/lib/python3.10/site-packages/mercurial
Installed Directories: /etc/mercurial and /usr/lib/python3.10/site-packages/{hgdemandimport,hgext,hgext3rd,mercurial}

Short Descriptions

hg

is the mercurial version control system

Last updated on

NASM-2.15.05

Introduction to NASM

NASM (Netwide Assembler) is an 80x86 assembler designed for portability and modularity. It includes a disassembler as well.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

NASM Dependencies

Optional (for generating documentation):

asciidoc-10.1.1 and xmlto-0.0.28

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/nasm

Installation of NASM

If you downloaded the optional documentation, put it into the source tree:

tar -xf ../nasm-2.15.05-xdoc.tar.xz --strip-components=1

Install NASM by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

If you downloaded the optional documentation, install it with the following instructions as the root user:

install -m755 -d         /usr/share/doc/nasm-2.15.05/html  &&
cp -v doc/html/*.html    /usr/share/doc/nasm-2.15.05/html  &&
cp -v doc/*.{txt,ps,pdf} /usr/share/doc/nasm-2.15.05

Contents

Installed Programs: nasm and ndisasm
Installed Libraries: None
Installed Directory: /usr/share/doc/nasm-2.15.05

Short Descriptions

nasm

is a portable 80x86 assembler

ndisasm

is an 80x86 binary file disassembler

Last updated on

Perl Modules

Introduction to Perl Modules

The Perl module packages (also referred to as Distributions, because each can contain multiple modules) add useful objects to the Perl language. The packages listed on this page are required or recommended for other packages in the book. If they have dependent modules, those are either on this page or else on the next page (Perl Module Dependencies).

In many cases, only the required or recommended dependencies are listed - there might be other modules which allow more tests to be run, but omitting them will still allow the tests to PASS.

For a few modules, the BLFS editors have determined that other modules still listed as prerequisites are not required, and omitted them.

Where an alphabetically-earlier dependency of the same module pulls in a dependency, it is not mentioned for the later dependencies of the same module. You should build the listed dependencies in order.

It is generally worth running the tests for perl modules, they often can show problems such as missing dependencies which are required to use the module. Here, the editors have attempted to separate those dependencies which are only required for running testsuites, but they will not be mentioned for a module where one of its dependencies uses that module for its own testsuite. That is to say, if you intend to run the testsuites, please run them for each dependency of the module.

It is possible to automatically install the current versions of a module and all missing or too-old dependencies recommended by upstream using CPAN. See CPAN automated install of perl modules at the end of this page.

Most of these modules only install files below /usr/lib/perl5/site_perl/5.xx.y and those will not be documented. One or two install programs (mostly, perl scripts), or a library, into /usr/bin/ or /usr/lib/ and these are documented.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/perl-modules

Archive::Zip-1.68

Introduction to Archive::Zip

The Archive::Zip module allows a Perl program to create, manipulate, read, and write Zip archive files.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Archive::Zip Dependencies
Recommended (for the testsuite)

UnZip-6.0 (with its patch)

Optional

Test-MockModule-v0.176.0

Installation of Archive::Zip

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Contents

Installed Programs: crc32

Short Descriptions

crc32

computes and prints to stdout the CRC-32 values of the given files

autovivification-0.18

Introduction to the autovivification module

This module allows you disable autovivification (the automatic creation and population of new arrays and hashes whenever undefined variables are dereferenced), and optionally throw a warning or an error when it would have occurred.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of autovivification

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Business::ISBN-3.007

Introduction to Business::ISBN

The Business::ISBN module is for work with International Standard Book Numbers.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Business::ISBN Dependencies
Required

Business-ISBN-Data-20210112.006

Installation of Business::ISBN

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Business::ISMN-1.202

Introduction to Business::ISMN

The Business::ISMN module is for work with International Standard Music Numbers.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Business::ISMN Dependencies
Required

Tie-Cycle-1.227

Installation of Business::ISMN

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Business::ISSN-1.004

Introduction to Business::ISSN

The Business::ISSN module is for work with International Standard Serial Numbers.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Business::ISSN

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Class::Accessor-0.51

Introduction to Class::Accessor

Class::Accessor generates accessors/mutators for your class.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Class::Accessor

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Data::Compare-1.27

Introduction to Data::Compare

The Data::Compare module compares two perl data structures.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Data::Compare Dependencies
Required

Clone-0.45, File-Find-Rule-0.34

Installation of Data::Compare

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Data::Dump-1.25

Introduction to Data::Dump

Data::Dump provides pretty printing of data structures.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Data::Dump

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Data::Uniqid-0.12

Introduction to Data::Uniqid

Data::Uniqid provides three simple routines for generating unique IDs.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Data::Uniqid

Although the final test fails and reports an Error, the testsuite returns a status of 0. The error can safely be ignored.

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

DateTime::Calendar::Julian-0.107

Introduction to DateTime::Calendar::Julian

DateTime::Calendar::Julian implements the Julian Calendar.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
DateTime::Calendar::Julian Dependencies
Required

DateTime-1.55

Installation of DateTime::Calendar::Julian

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

DateTime::Format::Builder-0.83

Introduction to DateTime::Format::Builder

DateTime::Format::Builder created DateTime parser classes and objects.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
DateTime::Format::Builder Dependencies
Required

DateTime-Format-Strptime-1.79 and Params-Validate-1.30

Installation of DateTime::Format::Builder

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Encode::EUCJPASCII-0.03

Introduction to Encode::EUCJPASCII

Encode::EUCJPASCII provides an eucJP-open (Extended Unix Code, Japanese) mapping.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Encode::EUCJPASCII

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Encode::HanExtra-0.23

Introduction to Encode::HanExtra

The Encode::HanExtra module provides extra sets of Chinese Encodings which are not included in the core Encode module because of size issues.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Encode::HanExtra

This module uses the 'unsafe' build and installation instructions (In perl-5.26.0 the use of the current directory in @INC was removed for security reasons and this module has not been updated) :

PERL_USE_UNSAFE_INC=1 perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Encode::JIS2K-0.03

Introduction to Encode::JIS2K

The Encode::JIS2K module provides JIS X 0212 (aka JIS 2000) Encodings.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Encode::JIS2K

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

File::Slurper-0.013

Introduction to File::Slurper

File::Slurper is a simple, sane and efficient module to slurp a file.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
File::Slurper Dependencies
Recommended (required for the testsuite)

Installation of File::Slurper

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

File::Which-1.27

Introduction to File::Which

File::Which provides a portable implementation of the 'which' utility.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of File::Which

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

HTML::Parser-3.76

Introduction to HTML::Parser

The HTML::Parser distribution is a collection of modules that parse and extract information from HTML documents.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
HTML::Parser Dependencies
Required

HTML-Tagset-3.20

Required (runtime)

HTTP-Message-6.36 (its module HTTP::Headers is a run-time requirement for HTML::HeadParser from this distribution).

Installation of HTML::Parser

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

HTTP::Daemon-6.13

Introduction to HTTP::Daemon

Instances of the HTTP::Daemon class are HTTP/1.1 servers that listen on a socket for incoming requests. The HTTP::Daemon is a subclass of IO::Socket::INET, so you can perform socket operations directly on it too.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
HTTP::Daemon Dependencies
Required

HTTP-Message-6.36

Installation of HTTP::Daemon

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

IO::Socket::SSL-2.074

Introduction to IO::Socket::SSL

IO::Socket::SSL makes using SSL/TLS much easier by wrapping the necessary functionality into the familiar IO::Socket interface and providing secure defaults whenever possible.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
IO::Socket::SSL Dependencies
Required

make-ca-1.10 and Net-SSLeay-1.92

Recommended

Installation of IO::Socket::SSL

This module uses a variant of the standard build and installation instructions:

yes | perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Command Explanations

yes: Perl will ask if you wish to run external tests, which will 'fail soft' if there are network problems. The default is 'y', this allows you to script the build.

IO::String-1.08

Introduction to IO::String

IO::String - Emulate file interface for in-core strings.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of IO::String

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

IPC::Run3-0.048

Introduction to IPC::Run3

IPC::Run3 is used to run a subprocess with input/output redirection.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of IPC::Run3

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Lingua::Translit-0.28

Introduction to Lingua::Translit

Lingua::Translit and its translit program transliterate text between writing systems.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Lingua::Translit

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Contents

Installed Programs: translit

Short Descriptions

translit

transliterates text between writing systems using various standards

List::AllUtils-0.19

Introduction to List::AllUtils

The List::Allutils module combines List::Util and List::MoreUtils in one bite-sized package.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
List::AllUtils Dependencies
Required

List-SomeUtils-0.58, List-UtilsBy-0.11, Scalar-List-Utils-1.60

Installation of List::AllUtils

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

List::MoreUtils-0.430

Introduction to List::MoreUtils

List::MoreUtils provides the stuff missing in List::Util.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
List::MoreUtils Dependencies
Required

Exporter-Tiny-1.002002 and List-MoreUtils-XS-0.430

Installation of List::MoreUtils

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Log::Log4perl-1.54

Introduction to Log::Log4perl

Log::Log4perl provides a Log4j implementation for perl.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Log::Log4perl

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Contents

Installed Programs: l4p-templ

Short Descriptions

l4p-templ

prints out the text of a template Log4perl configuration for starting a new Log4perl configuration file

LWP::Protocol::https-6.10

Introduction to LWP::Protocol::https

LWP::Protocol::https provides https support for LWP::UserAgent (i.e. libwww-perl-6.61). Once the module is installed LWP is able to access sites using HTTP over SSL/TLS.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Additional Download
LWP::Protocol::https Dependencies
Required

IO-Socket-SSL-2.074, libwww-perl-6.61 and make-ca-1.10 with /etc/pki/tls/certs/ca-bundle.crt.

Installation of LWP::Protocol::https

First, apply a patch to use the system certificates (using the CPAN automated install will instead use Mozilla::CA which is usually not up to date and does not use local certificates).

patch -Np1 -i ../LWP-Protocol-https-6.10-system_certs-2.patch

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Module::Build-0.4231

Introduction to Module::Build

Module::Build allows perl modules to be built without a make command being present.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Module::Build

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Note that this module can also be built using Build.PL

Contents

Installed Programs: config_data

Short Descriptions

config_data

is used to query or change the configuration of perl modules

Net::DNS-1.33

Introduction to Net::DNS

Net::DNS is a DNS resolver implemented in Perl. It can be used to perform nearly any type of DNS query from a Perl script.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Net::DNS

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Parse::RecDescent-1.967015

Introduction to Parse::RecDescent

Parse::RecDescent incrementally generates top-down recursive-descent text parsers from simple yacc-like grammar specifications.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Parse::RecDescent

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Parse::Yapp-1.21

Introduction to Parse::Yapp

Parse::Yapp is a Perl extension for generating and using LALR parsers.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Parse::Yapp

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Contents

Installed Programs: yapp

Short Descriptions

yapp

is a frontend to the Parse::Yapp module, which lets you create a Perl OO parser from an input grammar file

PerlIO::utf8_strict-0.009

Introduction to PerlIO::utf8_strict

PerlIO::utf8_strict provides a fast and correct UTF-8 PerlIO layer. Unlike perl's default :utf8 layer it checks the input for correctness.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
PerlIO::utf8_strict Dependencies
Recommended (required for the testsuite)

Installation of PerlIO::utf8_strict

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Regexp::Common-2017060201

Introduction to Regexp::Common

Regexp::Common provides commonly requested regular expressions.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Regexp::Common

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

SGMLSpm-1.1

Introduction to SGMLSpm

The SGMLSpm module is a Perl library used for parsing the output from James Clark's SGMLS and NSGMLS parsers.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of SGMLSpm

Before beginning the build, issue the following command to prevent an error:

chmod -v 644 MYMETA.yml

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

After the package has been installed, run the following command as the root user:

ln -sv sgmlspl.pl /usr/bin/sgmlspl

Contents

Installed Programs: sgmlspl.pl, sgmlspl

Short Descriptions

sgmlspl.pl

is an SGML processor

sgmlspl

is a symbolic link used during the install of DocBook-utils-0.6.14

Sort::Key-1.33

Introduction to Sort::Key

Sort::Key provides a set of functions to sort lists of values by some calculated key value.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Sort::Key

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Test::Command-0.11

Introduction to Test::Command

Test::Command tests the exit status, STDOUT, or STDERR, of an external command.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Test::Command

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Test::Differences-0.69

Introduction to Test::Differences

Test::Differences tests strings and data structures and shows the differences if they do not match.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Test::Differences Dependencies
Required

Text-Diff-1.45,

Recommended (required for the testsuite)

Installation of Test::Differences

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Text::BibTeX-0.88

Introduction to Text::BibTeX

Text::BibTeX provides an interface to read and parse BibTeX files.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Text::BibTeX Dependencies
Required

Config-AutoConf-0.320, ExtUtils-LibBuilder-0.08

Installation of Text::BibTeX

This module is built using Build.PL:

perl Build.PL &&
./Build       &&
./Build test

Now, as the root user:

./Build install

Contents

Installed Programs: biblex, libparse, dumpnames
Installed Libraries: libtparse.so

Short Descriptions

biblex

performs lexical analysis on a BibTeX file

bibparse

parses a series of BibTeX files with command line options to control the string post-processing behaviour

dumpnames

parses a BibTeX file, splitting 'author' and 'editor' fields into lists of names, and then dumps everything to stdout

libbtparse.so

is a library for parsing and processing BibTeX data files

Text::CSV-2.01

Introduction to Text::CSV

Text::CSV is a comma-separated values manipulator, using XS (eXternal Subroutine - for subroutines written in C or C++) or pure perl.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Text::CSV Dependencies
Recommended

Installation of Text::CSV

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Text::Roman-3.5

Introduction to Text::Roman

Text::Roman allows conversion between Roman and Arabic algorisms (number systems, e.g. MCMXLV and 1945).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Text::Roman

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Unicode::Collate-1.31

Introduction to Unicode::Collate

Unicode::Collate provides a Unicode collation algorithm.

Note

This is a core module. If you are using perl-5.28.0 or later, its version is good enough for biber-2.17 and you do not need to reinstall this module.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Unicode::Collate

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Unicode::LineBreak-2019.001

Introduction to Unicode::LineBreak

Unicode::LineBreak provides a UAX #14 Unicode Line Breaking Algorithm.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Unicode::LineBreak Dependencies
Required

MIME-Charset-1.012.2, also Wget-1.21.2 (to download two files from unicode.org in the testsuite)

Optional

Installation of Unicode::LineBreak

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

URI-5.10

Introduction to URI

This module implements the URI class. Objects of this class represent "Uniform Resource Identifier references" as specified in RFC 2396 (and updated by RFC 2732). A Uniform Resource Identifier is a compact string of characters that identifies an abstract or physical resource. A Uniform Resource Identifier can be further classified as either a Uniform Resource Locator (URL) or a Uniform Resource Name (URN). The distinction between URL and URN does not matter to the URI class interface. A "URI-reference" is a URI that may have additional information attached in the form of a fragment identifier.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
URI Dependencies
Recommended (required for the testsuite)
Optional

Business-ISBN-3.007

Installation of URI

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

XML::LibXML::Simple-1.01

Introduction to XML::LibXML::Simple

The XML::LibXML::Simple module is a rewrite of XML::Simple to use the XML::LibXML parser for XML structures,instead of the plain Perl or SAX parsers.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
XML::LibXML::Simple Dependencies
Required

XML-LibXML-2.0207

Installation of XML::LibXML::Simple

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

XML::LibXSLT-1.99

Introduction to XML::LibXSLT

XML-LibXSLT provides an interface to libxslt-1.1.35

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
XML::LibXSLT Dependencies
Required

libxslt-1.1.35, XML-LibXML-2.0207

Installation of XML::LibXSLT

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

XML::Simple-2.25

Introduction to XML::Simple

XML::Simple provides an easy API to read and write XML (especially config files). It is deprecated and its use is discouraged.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
XML::Simple Dependencies
Optional

XML-SAX-1.02 (for an alternative parser which will be used if available, otherwise XML::Parser which was installed in LFS will be used),

Installation of XML::Simple

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

XML::Writer-0.900

Introduction to XML::Writer

XML::Writer provides a Perl extension for writing XML documents.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of XML::Writer

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

CPAN automated install of perl modules

Automatic Installation of Perl Modules.

There is an alternate way of installing the modules using the cpan shell install command. The command automatically downloads the latest source from the CPAN archive for the module and any missing prerequisite modules listed by upstream. Then for each module it extracts it, runs the compilation, the tests and installs it.

You still need to install any non-perl dependencies before running the automated installation method. You may wish to clean out the build/ directory after installing, to free up the space. If any post-install actions such as creating a symlink are mentioned, you should also do those.

The first time you run cpan, you'll be prompted to enter some information regarding download locations and methods. This information is retained in files located in ~/.cpan.

In particular, you may wish to configure it so that Sudo-1.9.9 is used for the installs, allowing you to build and test as a regular user. The following examples have not used that approach.

Start the cpan shell by issuing 'cpan' as the root user. Any module may now be installed from the cpan>  prompt with the command:

install <Module::Name>

For additional commands and help, issue 'help' from the cpan>  prompt.

Alternatively, for scripted or non-interactive installations, use the following syntax as the root user to install one or more modules:

cpan -i <Module1::Name> <Module2::Name>

Review the cpan.1 man page for additional parameters you can pass to cpan on the command line.

Last updated on

Perl Module Dependencies

Perl Modules which are only required by other modules

The modules on the previous page are referenced from other pages in BLFS, but these modules are only in the book as dependencies of those modules. If you use the CPAN install method, you do not need to read this page.

The BLFS editors pay much less attention to these modules, and the versions will not be regularly reviewed. In all cases, only the required or recommended dependencies are listed - there might be other modules which allow more tests to be run, but omitting them will still allow the tests to PASS.

Note

The links on this page (to metacpan.org) should go to "known good" versions, for which their dependencies are correct. If you wish to use a later version, please check the Changes file at https://metacpan.org - sometimes added dependencies are listed, other times not. Some of these modules have very frequent updates, often bringing different dependencies. The linked metacpan.org versions below are known to build and work with the module versions in BLFS-10.0..

However, if you notice that the Changes file for a newer version than is in the current development book reports a fix for a security issue, please report this to either the blfs-dev or the blfs-support list.

Similarly, if you discover that an updated module on the previous page needs an extra dependency, please report this.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/perl-modules

Algorithm::Diff-1.201

Introduction to Algorithm::Diff

Algorithm::Diff computes 'intelligent' differences between two files or lists.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Algorithm::Diff

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Alien::Build-2.46

Introduction to Alien::Build

Alien::Build provides tools for building external (non-CPAN) dependencies for CPAN.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Alien::Build Dependencies
Required

Capture-Tiny-0.48, File-Which-1.27, FFI-CheckLib-0.28 and File-chdir-0.1010

Installation of Alien::Build

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Alien::Libxml2-0.17

Introduction to Alien::Libxml2

Alien::Libxml2 is designed to allow modules to install the C libxml2 library on your system. In BLFS, it uses pkg-config to find how to link to the installed libxml2-2.9.13.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Alien::Libxml2 Dependencies
Required

Alien-Build-2.46, libxml2-2.9.13, Path-Tiny-0.122

Recommended (required for the testsuite)

Installation of Alien::Libxml2

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

B::COW-0.004

Introduction to B::COW

B::COW provides additional helpers for the B core module to check Copy On Write.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of B::COW

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

B::Hooks::EndOfScope-0.25

Introduction to B::Hooks::EndOfScope

B::Hooks::EndOfScope allows you to execute code when perl finished compiling the surrounding scope.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
B::Hooks::EndOfScope Dependencies
Required

Module-Implementation-0.09, Sub-Exporter-Progressive-0.001013 and Variable-Magic-0.62

Recommended (required for the testsuite)

Installation of B::Hooks::EndOfScope

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Business::ISBN::Data-20210112.006

Introduction to Business-ISBN-Data

Business-ISBN-Data is a data pack for Business::ISBN.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Business-ISBN-Data

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Capture::Tiny-0.48

Introduction to Capture::Tiny

The Capture::Tiny module captures STDOUT and STDERR from Perl, XS (eXternal Subroutine, i.e. written in C or C++) or external programs.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Capture::Tiny

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Class::Data::Inheritable-0.09

Introduction to Class::Data::Inheritable

Class::Data::Inheritable is for creating accessor/mutators to class data. That is, if you want to store something about your class as a whole (instead of about a single object).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Class::Data::Inheritable

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Class::Inspector-1.36

Introduction to Class::Inspector

Class::Inspector allows you to get information about a loaded class.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Class::Inspector

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Class::Singleton-1.6

Introduction to Class::Singleton

A Singleton describes an object class that can have only one instance in any system, such as a print spooler. This module implements a Singelton class from which other classes can be derived.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Class::Singleton

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Class:Tiny-1.008

Introduction to Class:Tiny

Class:Tiny offers a minimalist class construction kit.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Class:Tiny

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Clone-0.45

Introduction to Clone

Clone recursively copies perl datatypes.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Clone Dependencies
Recommended (required for the testsuite)

Installation of Clone

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Config::AutoConf-0.320

Introduction to Config::AutoConf

The Config::AutoConf module implements some of the AutoConf macros (detecting a command, detecting a library, etc.) in pure perl.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Config::AutoConf Dependencies
Required

Capture-Tiny-0.48, File-Slurper-0.013

Installation of Config::AutoConf

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

CPAN::Meta::Check-0.014

Introduction to CPAN::Meta::Check

CPAN::Meta::Check verifies if requirements described in a CPAN::Meta object are present.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
CPAN::Meta::Check Dependencies
Recommended (Required for the testsuite)

Installation of CPAN::Meta::Check

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

DateTime-1.55

Introduction to DateTime

DateTime is a date and time object for perl.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
DateTime Dependencies
Required

DateTime-Locale-1.33, DateTime-TimeZone-2.51

Recommended (required for the testsuite)

Installation of DateTime

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

DateTime::Format::Strptime-1.79

Introduction to DateTime::Format::Strptime

DateTime::Format::Strptime implements most of strptime(3), i.e. it takes a string and a pattern and returns a DateTime object.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
DateTime::Format::Strptime Dependencies
Required

DateTime-1.55

Installation of DateTime::Format::Strptime

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

DateTime::Locale-1.33

Introduction to DateTime::Locale

DateTime::Locale provides localization support for DateTime-1.55.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
DateTime::Locale Dependencies
Required

Dist-CheckConflicts-0.11, File-ShareDir-1.118, namespace-autoclean-0.29 and Params-ValidationCompiler-0.30

Recommended (required for the testsuite)

Installation of DateTime::Locale

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

DateTime::TimeZone-2.51

Introduction to DateTime::TimeZone

This class is the base class for all time zone objects. A time zone is represented internally as a set of observances, each of which describes the offset from GMT for a given time period.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
DateTime::TimeZone Dependencies
Required

Class-Singleton-1.6, Module-Runtime-0.016, and Params-ValidationCompiler-0.30, also

Recommended (required for the testsuite)

Installation of DateTime::TimeZone

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Devel::StackTrace-2.04

Introduction to Devel::StackTrace

Devel::StackTrace provides an object representing a stacvk trace.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Devel::StackTrace

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Dist::CheckConflicts-0.11

Introduction to Dist::CheckConflicts

Dist::CheckConflicts declares version conflicts for a distribution, to support post-install updates of dependant distributions.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Dist::CheckConflicts Dependencies
Required

Module-Runtime-0.016

Recommended (required for the testsuite)

Installation of Dist::CheckConflicts

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Encode::Locale-1.05

Introduction to Encode::Locale

Encode::Locale determines the locale encoding.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Encode::Locale

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Eval::Closure-0.14

Introduction to Eval::Closure

Eval::Closure safely and cleanly creates closures via string eval.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Eval::Closure Dependencies
Recommended (required for the testsuite)

Installation of Eval::Closure

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Exception::Class-1.45

Introduction to Exception::Class

Exception::Class allows you to declare real exception classes in Perl.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Exception::Class Dependencies
Required

Class-Data-Inheritable-0.09, Devel-StackTrace-2.04

Installation of Exception::Class

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Exporter::Tiny-1.002002

Introduction to Exporter::Tiny

Exporter::Tiny is an exporter with the features of Sub::Exporter but only core dependencies.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Exporter::Tiny

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

ExtUtils::LibBuilder-0.08

Introduction to ExtUtils::LibBuilder

ExtUtils::LibBuilder is a tool to build C libraries.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
ExtUtils::LibBuilder Dependencies
Required

Module-Build-0.4231

Installation of ExtUtils::LibBuilder

This module is built using Build.PL:

perl Build.PL &&
./Build       &&
./Build test

Now, as the root user:

./Build install

FFI::CheckLib-0.28

Introduction to FFI::CheckLib

FFI::CheckLib checks whether a particular dynamic library is available for FFI (Foreign Function Interface) to use.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
FFI::CheckLib Dependencies
Recommended (required for the testsuite)

Installation of FFI::CheckLib

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

File::chdir-0.1010

Introduction to File::chdir

File::chdir provides a more sensible way to change directories.

Perl's chdir() has the unfortunate problem of being very, very, very global. If any part of your program calls chdir() or if any library you use calls chdir(), it changes the current working directory for the *whole* program. File::chdir gives you an alternative, $CWD and @CWD.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of File::chdir

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

File::Copy::Recursive-0.45

Introduction to File::Copy::Recursive

This module copies and moves directories recursively (or single files), to an optional depth and attempts to preserve each file or directory's mode.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
File::Copy::Recursive Dependencies
Recommended (required for the testsuite)

Installation of File::Copy::Recursive

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

File::Find::Rule-0.34

Introduction to File::Find::Rule

File::Find::Rule is a friendlier interface to File::Find. It allows you to build rules which specify the desired files and directories.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
File::Find::Rule Dependencies
Required

Number-Compare-0.03, Text-Glob-0.11

Installation of File::Find::Rule

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Contents

Installed Programs: findrule

Short Descriptions

findrule

is a command line wrapper to File::Find::Rule

File::Listing-6.14

Introduction to File::Listing

File::Listing parses a directory listing.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
File::Listing Dependencies
Required

HTTP-Date-6.05,

Installation of File::Listing

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

File::ShareDir-1.118

Introduction to File::ShareDir

File::ShareDir allows you to access data files which have been installed by File::ShareDir::Install.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
File::ShareDir Dependencies
Required

Class-Inspector-1.36, File-ShareDir-Install-0.13

Installation of File::ShareDir

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

File::ShareDir::Install-0.13

Introduction to File::ShareDir::Install

File::ShareDir::Install allows you to install read-only data files from a distribution.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of File::ShareDir::Install

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

HTML::Tagset-3.20

Introduction to HTML::Tagset

HTML::Tagset provides several data tables useful in parsing HTML.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of HTML::Tagset

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

HTTP::Cookies-6.10

Introduction to HTTP::Cookies

HTTP::Cookies provides a class for objects that represent a "cookie jar" -- that is, a database of all the HTTP cookies that a given LWP::UserAgent (from libwww-perl-6.61) object knows about.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
HTTP::Cookies Dependencies
Required

HTTP-Message-6.36

Installation of HTTP::Cookies

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

HTTP::Date-6.05

Introduction to HTTP::Date

HTTP::Date provides functions to deal with the date formats used by the HTTP protocol and also with some other date formats.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
HTTP::Date Dependencies
Recommended

Installation of HTTP::Date

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

HTTP::Message-6.36

Introduction to HTTP::Message

HTTP::Message provides a base class for HTTP style message objects.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
HTTP::Message Dependencies
Required

Encode-Locale-1.05, HTTP-Date-6.05, IO-HTML-1.004, LWP-MediaTypes-6.04 and URI-5.10

Recommended (required for the testsuite)

Installation of HTTP::Message

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

HTTP::Negotiate-6.01

Introduction to HTTP::Negotiate

HTTP::Negotiate provides a complete implementation of the HTTP content negotiation algorithm.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
HTTP::Negotiate Dependencies
Recommended (required for the testsuite)

Installation of HTTP::Negotiate

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Importer-0.026

Introduction to Importer

Importer provides an alternative but compatible interface to modules that export symbols.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Importer

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

IO::HTML-1.004

Introduction to IO::HTML

IO::HTML opens an HTML file with automatic character set detection.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of IO::HTML

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

IPC::System::Simple-1.30

Introduction to IPC::System::Simple

IPC::System::Simple takes the hard work out of calling external commands and producing detailed diagnostics.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of IPC::System::Simple

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

libwww-perl-6.61

Introduction to LWP - The World-wide Web library for Perl

The libwww-perl collection is a set of Perl modules which provides a simple and consistent application programming interface (API) to the World-Wide Web. The main focus of the library is to provide classes and functions that allow you to write WWW clients. The library also contains modules that are of more general use and even classes that help you implement simple HTTP servers.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
libwww-perl Dependencies
Required

File-Listing-6.14, HTTP-Cookies-6.10, HTTP-Daemon-6.13, HTTP-Negotiate-6.01, HTML-Parser-3.76, Net-HTTP-6.22, Try-Tiny-0.31 and WWW-RobotRules-6.02

Recommended (required for the testsuite)

Installation of libwww-perl

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

After installing this package, if you want HTTPS protocol support install LWP-Protocol-https-6.10.

Contents

Installed Programs: lwp-download, lwp-dump, lwp-mirror, lwp-request

Short Descriptions

lwp-download

is a script to fetch a large file from the web

lwp-dump

is used to see what headers and content is returned for a URL

lwp-mirror

is a simple mirror utility

lwp-request

is a simple command line user agent

List::MoreUtils::XS-0.430

Introduction to List::MoreUtils::XS

List::MoreUtils::XS is a compiled backend for List::MoreUtils

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of List::MoreUtils::XS

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

List::SomeUtils-0.58

Introduction to List::SomeUtils

List::SomeUtils provides the stuff misisng in List::Util.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
List::SomeUtils Dependencies
Required

Module-Implementation-0.09, List-SomeUtils-XS-0.58

Installation of List::SomeUtils

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

List::SomeUtils::XS-0.58

Introduction to List::SomeUtils::XS

List::SomeUtils::XS is a (faster) XS (eXternal Subroutine) implementation for List::SomeUtils.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
List::SomeUtils::XS Dependencies
Recommended (required for the testsuite)

Installation of List::SomeUtils::XS

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

List::UtilsBy-0.11

Introduction to List::UtilsBy

List::UtilsBy provides a number of higher-order list utility functions.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of List::UtilsBy

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

LWP::MediaTypes-6.04

Introduction to LWP::MediaTypes

LWP::MediaTypes guesses the media type (i.e. the MIME Type) for a file or URL.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
LWP::MediaTypes Dependencies
Recommended (required for the testsuite)

Installation of LWP::MediaTypes

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

MIME::Charset-1.012.2

Introduction to MIME::Charset

MIME::Charset provides information about character sets used for MIME messages o nthe internet, such as their encodings.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
MIME::Charset Dependencies
Recommended

Installation of MIME::Charset

This module uses a variant of the standard build and installation instructions:

yes '' | perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Command Explanations

yes |: Perl will ask if you wish to install a further module for handling legacy Japanese encodings, and another which it would use for translating documentation to Japanese. The default option is 'n', using 'yes' allows you to script the build.

Module::Implementation-0.09

Introduction to Module::Implementation

Module::Implementation loads one of several alternate underlying implementations of a module (e.g. eXternal Subroutine or pure Perl, or an implementation for a given OS).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Module::Implementation Dependencies
Required

Module-Runtime-0.016, Try-Tiny-0.31

Recommended (required for the testsuite)

Installation of Module::Implementation

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Module::Pluggable-5.2

Introduction to Module::Pluggable

Module::Pluggable provides a way of having 'plugins' for your module.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Module::Pluggable

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Module::Runtime-0.016

Introduction to Module::Runtime

Module::Runtime provides functions to deal with runtime handling of Perl modules.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Module::Runtime

Although Module::Build is still listed as a prerequisite, it is no-longer necessary on systems with a working make.

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

MRO::Compat-0.15

Introduction to MRO::Compat

The "mro" namespace provides several utilities for dealing with method resolution order and method caching in general in Perl 5.9.5 and higher. This module provides those interfaces for earlier versions of Perl.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of MRO::Compat

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

namespace::autoclean-0.29

Introduction to namespace::autoclean

This module is very similar to namespace::clean, except it will clean all imported functions, no matter if you imported them before or after you used the pragma. It will also not touch anything that looks like a method.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
namespace::autoclean Dependencies
Required

namespace-clean-0.27, Sub-Identify-0.14

Recommended (required for the testsuite)

Installation of namespace::autoclean

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

namespace::clean-0.27

Introduction to namespace::clean

This package allows you to keep imports and functions out of your namespace.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
namespace::clean Dependencies
Required

B-Hooks-EndOfScope-0.25, Package-Stash-0.39

Installation of namespace::clean

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Net::HTTP-6.22

Introduction to Net::HTTP

The Net::HTTP class is a low level HTTP client. An instance of the class represents a connection to an HTTP server.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Net::HTTP Dependencies
Required

URI-5.10

Installation of Net::HTTP

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Net::SSLeay-1.92

Introduction to Net::SSLeay

Net::SSLeay is a PERL extension for using OpenSSL.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Net::SSLeay

Note

If enabling the external tests, one test in t/external/15_altnames.t may fail.

This module uses a variant of the standard build and installation instructions:

yes '' | perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Command Explanations

yes '': Perl will ask if you wish to run external tests, which will fail if you do not have network connectivity. The default is 'n', specifying this allows you to script the build.

Number::Compare-0.03

Introduction to Number::Compare

Number::Compare compiles a simple comparison to an anonymous subroutine, which you can call with a value to be tested against. It understands IEC standard magnitudes (k, ki, m, mi, g, gi).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Number::Compare

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Package::Stash-0.39

Introduction to Package::Stash

Manipulating stashes (Perl's symbol tables) is occasionally necessary, but incredibly messy, and easy to get wrong. This module hides all of that behind a simple API.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Package::Stash Dependencies
Required

Dist-CheckConflicts-0.11, Module-Implementation-0.09

Recommended (required for the testsuite)

Installation of Package::Stash

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Params::Validate-1.30

Introduction to Params::Validate

Params::Validate allows you to validate method or function call parameters to an arbitrary level of specificity.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Params::Validate Dependencies
Required

Module-Build-0.4231, Module-Implementation-0.09

Recommended (required for the testsuite)

Installation of Params::Validate

This module is built using Build.PL:

perl Build.PL &&
./Build       &&
./Build test

Now, as the root user:

./Build install

Params::ValidationCompiler-0.30

Introduction to Params::ValidationCompiler

Params::ValidationCompiler builds an optimized subroutine parameter validator.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Params::ValidationCompiler Dependencies
Required

Exception-Class-1.45, Specio-0.47

Recommended (required for the testsuite)

Installation of Params::ValidationCompiler

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Path::Tiny-0.122

Introduction to Path::Tiny

Path::Tiny provides a small fast utility for working with file paths.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Path::Tiny

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Role::Tiny-2.002004

Introduction to Role::Tiny

Role::Tiny is a minimalist role composition tool.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Role::Tiny

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Scalar::List::Utils-1.60

Introduction to Scalar::List::Utils

Scalar::List::Utils provides a selection of list and scalar subroutines.

The module List::Util from this distribution is part of core perl, but List-AllUtils-0.19 requires a newer version than what is in current perl.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Scalar::List::Utils

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Scope::Guard-0.21

Introduction to Scope::Guard

Scope::Guard provides a convenient way to perform cleanup or other forms of resource management at the end of a scope.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Scope::Guard

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Specio-0.47

Introduction to Specio

Specio provides classes for representing type constraints and coercion, along with syntax sugar for declaring them.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Specio Dependencies
Required

Devel-StackTrace-2.04, Eval-Closure-0.14, Module-Runtime-0.016, Role-Tiny-2.002004, Sub-Quote-2.006006 and Try-Tiny-0.31

Recommended (required for the testsuite)
Optional

namespace-autoclean-0.29 (for the testsuite)

Installation of Specio

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Sub::Exporter::Progressive-0.001013

Introduction to Sub::Exporter::Progressive

Sub::Exporter::Progressive is a wrapper for Sub::Exporter.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Sub::Exporter::Progressive

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Sub::Identify-0.14

Introduction to Sub::Identify

Sub::Identify allows you to retrieve the real name of code references. It is encouraged to migrate to Sub::Util (a core module) when possible.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Sub::Identify

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Sub::Info-0.002

Introduction to Sub::Info

Sub::Info is a tool for inspecting subroutines.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Sub::Info Dependencies
Required

Importer-0.026

Installation of Sub::Info

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Sub::Quote-2.006006

Introduction to Sub::Quote

Sub::Quote provides ways to generate subroutines from strings.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Sub::Quote Dependencies
Recommended (required for the testsuite)

Installation of Sub::Quote

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Sub::Uplevel-0.2800

Introduction to Sub::Uplevel

Sub::Uplevel allows you to fool a caller that it is running in a higher stack frame.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Sub::Uplevel

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

SUPER-1.20190531

Introduction to SUPER

SUPER provides easier methods to dispatch control to the superclass (when subclassing a class).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
SUPER Dependencies
Recommended (required for the testsuite)

Installation of SUPER

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Term::Table-0.016

Introduction to Term::Table

Term::Table formats a header and rows into a table. This is used by some failing tests to provide diagnostics about what has goen wrong.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Term::Table Dependencies
Required

Importer-0.026

Installation of Term::Table

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Test::Deep-1.130

Introduction to Test::Deep

Test::Deep gives you very flexible ways to check that the result you got is the result you were expecting.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Test::Deep

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Test::Exception-0.43

Introduction to Test::Exception

Test::Exception provides convenience methods for testing exception based code.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Test::Exception Dependencies
Required

Sub-Uplevel-0.2800

Installation of Test::Exception

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Test::Fatal-0.016

Introduction to Test::Fatal

The Test::Fatal module provides simple helpers for testing code which throws exceptions.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Test::Fatal Dependencies
Required

Try-Tiny-0.31

Installation of Test::Fatal

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Test::File-1.991

Introduction to Test::File

Test::File provides a collection of test utilities for file attributes.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Test::File Dependencies
Recommended (required for the testsuite)

Installation of Test::File

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Test::File::ShareDir-1.001002

Introduction to Test::File::ShareDir

Test::File::ShareDir is some low level plumbing to enable a distribution to perform tests while consuming its own share directories in a manner similar to how they will be once installed. This allows File-ShareDir-1.118 to see the latest version of content instead of whatever is installed on the target system where you are testing.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Test::File::ShareDir Dependencies
Required

Class-Tiny-1.008, File-Copy-Recursive-0.45, File-ShareDir-1.118, Path-Tiny-0.122 and Scope-Guard-0.21

Recommended (required for the testsuite)

Installation of Test::File::ShareDir

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Test::LeakTrace-0.17

Introduction to Test::LeakTrace

Test::LeakTrace traces memory leaks.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Test::LeakTrace

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Test::MockModule-v0.176.0

Introduction to Test::MockModule

Test::MockModule lets you temporarily redefine subroutines in other packages for the purposes of unit testing.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Test::MockModule Dependencies
Required

Module-Build-0.4231, SUPER-1.20190531

Recommended (required for the testsuite)

Installation of Test::MockModule

This module is built using Build.PL:

perl Build.PL &&
./Build       &&
./Build test

Now, as the root user:

./Build install

Test::Needs-0.002009

Introduction to Test::Needs

Test::Needs skips tests if a requested module is not present.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Test::Needs

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Test::Requires-0.11

Introduction to Test::Requires

The Test::Requires module checks if another (optional) module can be loaded, and if not it skips all the current tests.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Test::Requires

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Test::RequiresInternet-0.05

Introduction to Test::RequiresInternet

Test::RequiresInternet is intended to easily test network connectivity before functional tests begin to non-local Internet resources.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Test::RequiresInternet

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Test::utf8-1.02

Introduction to Test::utf8

Test::utf8 is a collection of tests useful for dealing with utf8 strings in Perl.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Test::utf8

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Test::Warnings-0.031

Introduction to Test::Warnings

Test::Warnings tests for warnings and the lack of them.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Test::Warnings

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Test::Without::Module-0.20

Introduction to Test::Without::Module

This module allows you to deliberately hide modules from a program even though they are installed. This is mostly useful for testing modules that have a fallback when a certain dependency module is not installed.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Test::Without::Module

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Test2::Plugin::NoWarnings-0.09

Introduction to Test2::Plugin::NoWarnings

Test2::Plugin::NoWarnings causes tests to fail if there are any warnings while they run.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Test2::Plugin::NoWarnings Dependencies
Required

Test2-Suite-0.000144

Recommended (required for the testsuite)

Installation of Test2::Plugin::NoWarnings

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Test2::Suite-0.000144

Introduction to Test2::Suite

Test2::Suite is a distribution with a rich set of tools built upon the Test2 framework.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Test2::Suite Dependencies
Required

Module-Pluggable-5.2, Scope-Guard-0.21, Sub-Info-0.002 and Term-Table-0.016

Installation of Test2::Suite

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Text::CSV_XS-1.47

Introduction to Text::CSV_XS

Text::CSV_XS provides facilities for the composition and decomposition of comma-separated values.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Text::CSV_XS

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Text::Diff-1.45

Introduction to Text::Diff

Text::Diff performs diffs on files and record sets.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Text::Diff Dependencies
Required

Algorithm-Diff-1.201

Installation of Text::Diff

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Text::Glob-0.11

Introduction to Text::Glob

Text::Glob implements glob(3) style matching that can be used to match against text, rather than fetching names from a filesystem.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Text::Glob

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Tie::Cycle-1.227

Introduction to Tie::Cycle

You use Tie::Cycle to go through a list over and over again. Once you get to the end of the list, you go back to the beginning. You don't have to worry about any of this since the magic of tie does that for you.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Tie::Cycle

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

TimeDate-2.33

Introduction to TimeDate

TimeDate provides miscellaneous timezone manipulation routines.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of TimeDate

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Try::Tiny-0.31

Introduction to Try::Tiny

Try::Tiny provides try and catch to expect and handle exceptional conditions, avoiding quirks in Perl and common mistakes.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Try::Tiny Dependencies
Optional (can be used by the testsuite)

Capture-Tiny-0.48

Installation of Try::Tiny

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Variable::Magic-0.62

Introduction to Variable::Magic

Magic is Perl's way of enhancing variables. With this module, you can add your own magic to any variable.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of Variable::Magic

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

WWW::RobotRules-6.02

Introduction to WWW::RobotRules

WWW::RobotRules parses robots.txt files, creating a WWW::RobotRules object with methods to check if access to a given URL is prohibited.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
WWW::RobotRules Dependencies
Required (runtime)

libwww-perl-6.61 (install this module first and install that later)

Installation of WWW::RobotRules

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

XML::LibXML-2.0207

Introduction to XML::LibXML

XML::LibXML is a perl binding for libxml2-2.9.13.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
XML::LibXML Dependencies
Required

Alien-Libxml2-0.17, XML-SAX-1.02

Installation of XML::LibXML

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

XML::NamespaceSupport-1.12

Introduction to XML::NamespaceSupport

XML::NamespaceSupport offers a simple way to process namespaced XML names from within any application that may need them.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of XML::NamespaceSupport

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

XML::SAX-1.02

Introduction to XML::SAX

XML::SAX is a SAX parser access API for Perl. It includes classes and APIs required for implementing SAX drivers, along with a factory class for returning any SAX parser installed on the user's system.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
XML::SAX Dependencies
Required

libxml2-2.9.13, XML-NamespaceSupport-1.12 and XML-SAX-Base-1.09

Installation of XML::SAX

This module uses a variant of the standard build and installation instructions:

yes | perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Command Explanations

yes: Perl will ask if you want it to alter ParserDetails.ini and then wait for a response. The default is 'y'. Using 'yes' allows you to script this.

XML::SAX::Base-1.09

Introduction to XML::SAX::Base

This module has a very simple task - to be a base class for PerlSAX drivers and filters.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Installation of XML::SAX-Base

This module uses the standard build and installation instructions:

perl Makefile.PL &&
make             &&
make test

Now, as the root user:

make install

Last updated on

PHP-8.1.3

Introduction to PHP

PHP is the PHP Hypertext Preprocessor. Primarily used in dynamic web sites, it allows for programming code to be directly embedded into the HTML markup. It is also useful as a general purpose scripting language.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://www.php.net/distributions/php-8.1.3.tar.xz

  • Download MD5 sum: 495972570d055fef1255e296051a13a5

  • Download size: 11 MB

  • Estimated disk space required: 638 MB (with documentation)

  • Estimated build time: 2.6 SBU (with parallelism=4; add 2.8 SBU for tests)

Additional Downloads

PHP Dependencies

Recommended
Optional System Utilities and Libraries

Aspell-0.60.8, enchant-2.3.2, libxslt-1.1.35, an MTA (that provides a sendmail command), pcre2-10.39, Pth-2.0.7, AppArmor, Dmalloc, Net-SNMP, oniguruma, OSSP mm, re2c, and XMLRPC-EPI

Optional Graphics Utilities and Libraries

FreeType-2.11.1, libexif-0.6.24, libjpeg-turbo-2.1.2, libpng-1.6.37, libtiff-4.3.0, libwebp-1.2.2, a graphical environment, FDF Toolkit, GD, and t1lib

Optional Web Utilities

cURL-7.81.0, tidy-html5-5.8.0, Caudium, Hyperwave, mnoGoSearch, Roxen WebServer, and WDDX

Optional Data Management Utilities and Libraries

Berkeley DB-5.3.28 (Note that PHP does not officially support versions above 5.3), libiodbc-3.52.15, lmdb-0.9.29, MariaDB-10.6.7 or MySQL, OpenLDAP-2.6.1, PostgreSQL-14.2, SQLite-3.37.2, unixODBC-2.3.9, Adabas, Birdstep, cdb, DBMaker, Empress, FrontBase, IBM DB2, Mini SQL, Monetra, and QDBM

PHP also provides support for many commercial database tools such as Oracle, SAP and ODBC Router.

Optional Security/Encryption Utilities and Libraries

Cyrus SASL-2.1.27, MIT Kerberos V5-1.19.2, libmcrypt, and mhash

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/php

Installation of PHP

You can use PHP for server-side scripting, command-line scripting or client-side GUI applications. This book provides instructions for setting up PHP for server-side scripting as it is the most common form.

Note

PHP has many more configure options that will enable support for various things. You can use ./configure --help to see a full list of the available options. Also, use of the PHP web site is highly recommended, as their online docs are very good. An example of a configure command that utilizes many of the most common dependencies can be found at https://anduin.linuxfromscratch.org/BLFS/files/php_configure.txt.

If, for whatever reason, you don't have libxml2-2.9.13 installed, you need to add --disable-libxml to the configure command in the instructions below. Note that this will prevent the pear command from being built.

Install PHP by running the following commands:

./configure --prefix=/usr                \
            --sysconfdir=/etc            \
            --localstatedir=/var         \
            --datadir=/usr/share/php     \
            --mandir=/usr/share/man      \
            --without-pear               \
            --enable-fpm                 \
            --with-fpm-user=apache       \
            --with-fpm-group=apache      \
            --with-config-file-path=/etc \
            --with-zlib                  \
            --enable-bcmath              \
            --with-bz2                   \
            --enable-calendar            \
            --enable-dba=shared          \
            --with-gdbm                  \
            --with-gmp                   \
            --enable-ftp                 \
            --with-gettext               \
            --enable-mbstring            \
            --disable-mbregex            \
            --with-readline              &&
make

To test the results, issue: make test. Several tests (out of over 16000) may fail, in which case you are asked whether you want to send the report to the PHP developers. If you want to automate the test, you may prefix the command with yes "n" | .

Now, as the root user:

make install                                     &&
install -v -m644 php.ini-production /etc/php.ini &&

install -v -m755 -d /usr/share/doc/php-8.1.3 &&
install -v -m644    CODING_STANDARDS* EXTENSIONS NEWS README* UPGRADING* \
                    /usr/share/doc/php-8.1.3

The default configuration files for the fastCGI process manager are installed only if they do not already exist on the system. If this is the first installation, they should be renamed, as the root user:

if [ -f /etc/php-fpm.conf.default ]; then
  mv -v /etc/php-fpm.conf{.default,} &&
  mv -v /etc/php-fpm.d/www.conf{.default,}
fi

The pre-built HTML documentation is packaged in two forms: a tarball containing many individual files, useful for quick loading into your browser, and one large individual file, which is useful for using the search utility of your browser. If you downloaded either, or both, of the documentation files, issue the following commands as the root user to install them (note these instructions assume English docs, modify the tarball names below if necessary).

For the Single HTML file:

install -v -m644 ../php_manual_en.html.gz \
    /usr/share/doc/php-8.1.3 &&
gunzip -v /usr/share/doc/php-8.1.3/php_manual_en.html.gz

For the Many HTML files tarball:

tar -xvf ../php_manual_en.tar.gz \
    -C /usr/share/doc/php-8.1.3 --no-same-owner

The bundled pear is not installed because of a bug which might pollute the filesystem with several hidden files and directories. If pear is needed, execute the following commands to install it:

wget http://pear.php.net/go-pear.phar
php ./go-pear.phar

Command Explanations

--datadir=/usr/share/php: This works around a bug in the build machinery, which installs some data to a wrong location.

--enable-fpm: This parameter allows building the fastCGI Process Manager.

--without-pear: This switch disables installation of bundled pear software.

--with-config-file-path=/etc: This parameter makes PHP look for the php.ini configuration file in /etc.

--with-zlib: This parameter adds support for Zlib compression.

--enable-bcmath: Enables bc style precision math functions.

--with-bz2: Adds support for Bzip2 compression functions.

--enable-calendar: This parameter provides support for calendar conversion.

--enable-dba=shared: This parameter enables support for database (dbm-style) abstraction layer functions.

--enable-ftp: This parameter enables FTP functions.

--with-gettext: Enables functions that use Gettext text translation.

--enable-mbstring: This parameter enables multibyte string support.

--with-readline: This parameter enables command line Readline support.

--disable-libxml: This option allows building PHP without libxml2 installed.

--with-apxs2: Instead of building the fastCGI process manager, it is possible to build an apache module. This has some performance penalty for heavy loaded servers, but may be easier to set up. This switch is incompatible with the --enable-fpm and --with-fpm-... switches.

--with-mysqli=shared: This option includes MySQLi support.

--with-mysql-sock=/run/mysqld/mysqld.sock: Location of the MySQL unix socket pointer.

--with-pdo-mysql=shared: This option includes PDO: MySQL support.

--with-tidy=shared: This option includes tidy library support.

Configuring PHP

Config Files

/etc/php.ini, /etc/pear.conf, /etc/php-fpm.conf, and /etc/php-fpm.d/www.conf

Configuration Information

The file used as the default /etc/php.ini configuration file is recommended by the PHP development team. This file modifies the default behavior of PHP. If no /etc/php.ini is used, all configuration settings fall to the defaults. You should review the comments in this file and ensure the changes are acceptable in your particular environment.

The fastCGI process manager uses the configuration file /etc/php-fpm.conf. The default file shipped with PHP includes all the /etc/php-fpm.d/*.conf in turn. There is a shipped /etc/php-fpm.d/www.conf file, that contains the parameters related to the interaction with the Apache Web server.

You may have noticed the following from the output of the make install command:

You may want to add: /usr/lib/php to your php.ini include_path

If desired, add the entry using the following command as the root user:

sed -i 's@php/includes"@&\ninclude_path = ".:/usr/lib/php"@' \
    /etc/php.ini

To enable fastCGI support in the Apache web server, two LoadModule directives must be added to the httpd.conf file. They are commented out, so just issue the following command as root user:

sed -i -e '/proxy_module/s/^#//'      \
       -e '/proxy_fcgi_module/s/^#//' \
       /etc/httpd/httpd.conf

Those modules accept various ProxyPass directives. One possibility is (as the root user):

echo \
'ProxyPassMatch ^/(.*\.php)$ fcgi://127.0.0.1:9000/srv/www/$1' >> \
/etc/httpd/httpd.conf

Additionally, it may be useful to add an entry for index.php to the DirectoryIndex directive of the httpd.conf file. Lastly, adding a line to setup the .phps extension to show highlighted PHP source may be desirable:

AddType application/x-httpd-php-source .phps

You'll need to restart the Apache web server after making any modifications to the httpd.conf file.

Boot Script

To automatically start the php-fpm daemon when the system is rebooted, install the /etc/rc.d/init.d/php bootscript from the blfs-bootscripts-20210826 package as the root user:

make install-php

Contents

Installed Programs: phar (symlink), phar.phar, php, php-cgi, php-config, php-fpm, phpdbg, and phpize
Installed Libraries: dba.so and opcache.so in /usr/lib/php/extensions/no-debug-non-zts-20210902
Installed Directories: /etc/php-fpm.d, /usr/{include,lib,share}/php, and /usr/share/doc/php-8.1.3

Short Descriptions

php

is a command line interface that enables you to parse and execute PHP code

pear

is the PHP Extension and Application Repository (PEAR) package manager. This isn't installed by default

php-fpm

is the fastCGI process manager for PHP

phpdbg

is the interactive PHP debugger

Last updated on

Python-2.7.18

Introduction to Python 2

The Python 2 package contains the Python development environment. It is useful for object-oriented programming, writing scripts, prototyping large programs or developing entire applications. This version is for backward compatibility with other dependent packages.

Note

Python2 has been deprecated by the upstream developers. Support for Python2 was discontinued on January 1st, 2020.

BLFS is attempting to use Python3 as much as possible, but some packages have not been updated to support Python3.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Python 2 Dependencies

Recommended
Optional

BlueZ-5.63 and Valgrind-3.18.1

Optional (For more additional modules)

libnsl-2.0.0 and Tk-8.6.12

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Python

Installation of Python 2

First, disable the installation of a script that overwrites a more recent script:

sed -i '/2to3/d' ./setup.py

Install Python 2 by running the following commands:

patch -Np1 -i ../Python-2.7.18-security_fixes-1.patch &&
./configure --prefix=/usr                              \
            --enable-shared                            \
            --with-system-expat                        \
            --with-system-ffi                          \
            --enable-unicode=ucs4                     &&
make

If you invoke the tests, they will run through twice. To test the results, issue: make -k test. Several tests are known to fail, including test_ftplib, test_ssl, test_urllib2_localnet, test_xml_etree, and test_minidom. These failures are due to OpenSSL-3 and Expat-2.4.6.

Now, as the root user:

make altinstall                                &&
ln -s python2.7        /usr/bin/python2        &&
ln -s python2.7-config /usr/bin/python2-config &&
chmod -v 755 /usr/lib/libpython2.7.so.1.0

Since Python 2 is in maintenance mode, and Python 3 is recommended by upstream for development, you probably do not need to install the documentation. However, if you still want to install documentation for both Python versions, be sure to define the PYTHONDOCS variable for the version you want to use, each time you need to consult the documentation. If you have downloaded the preformatted documentation from http://docs.python.org/download.html, install it as the root user:

install -v -dm755 /usr/share/doc/python-2.7.18 &&

tar --strip-components=1                     \
    --no-same-owner                          \
    --directory /usr/share/doc/python-2.7.18 \
    -xvf ../python-2.7.18-docs-html.tar.bz2 &&

find /usr/share/doc/python-2.7.18 -type d -exec chmod 0755 {} \; &&
find /usr/share/doc/python-2.7.18 -type f -exec chmod 0644 {} \;

Command Explanations

--with-system-expat: This switch enables linking against system version of Expat.

--with-system-ffi: This switch enables linking against system version of libffi.

--enable-unicode=ucs4: This switch enables 32bit Unicode support in Python.

--with-ensurepip=yes : This switch enables building pip and setuptools packaging programs. setuptools is needed for building some Python modules. This switch is not recommended because this version of Python is being phased out.

--with-dbmliborder=bdb:gdbm:ndbm: Use this switch if you want to build Python DBM Module against Berkeley DB instead of GDBM.

make altinstall: This make target omits some default symbolic links that may interfere with Python 3.

chmod ...: Fix permissions for libraries to be consistent with other libraries.

Configuring Python 2

In order for python to find the installed documentation, you must add the following environment variable to individual user's or the system's profile:

export PYTHONDOCS=/usr/share/doc/python-2.7.18

Contents

Installed Programs: pydoc, python2 (symlink), python2-config (symlink), python2.7, python2.7-config, smtpd.py, and idle
Installed Library: libpython2.7.so
Installed Directories: /usr/{include,lib}/python2.7 and /usr/share/doc/python-2.7.18

Short Descriptions

idle

is a wrapper script that opens a Python aware GUI editor. For this script to run, you must have installed Tk before Python so that the Tkinter Python module is built

pydoc

is the Python documentation tool

python2

is an interpreted, interactive, object-oriented programming language

python2.7

is a version-specific name for the python program

smtpd.py

is an SMTP proxy implemented in Python

Last updated on

Python-3.10.2

Introduction to Python 3

The Python 3 package contains the Python development environment. This is useful for object-oriented programming, writing scripts, prototyping large programs or developing entire applications.

Note

Python 3 was installed in LFS. The only reason to rebuild it here is if optional modules are needed.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Python 3 Dependencies

Recommended
Optional

BlueZ-5.63, GDB-11.2 (required for some tests), Valgrind-3.18.1, and libmpdec

Optional (For Additional Modules)

Berkeley DB-5.3.28, libnsl-2.0.0, and Tk-8.6.12

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Python3

Installation of Python 3

Install Python 3 by running the following commands:

CXX="/usr/bin/g++"               \
./configure --prefix=/usr        \
            --enable-shared      \
            --with-system-expat  \
            --with-system-ffi    \
            --with-ensurepip=yes \
            --enable-optimizations &&
make

To test the result, issue make test. Some tests may need an Internet connection. Two tests named test_xml_etree and test_minidom are known to fail.

Now, as the root user:

make install

Command Explanations

CXX="/usr/bin/g++" ./configure ...: Avoid an annoying message during configuration.

--with-system-expat: This switch enables linking against the system version of Expat.

--with-system-ffi: This switch enables linking against the system version of libffi.

--with-ensurepip=yes : This switch enables building the pip and setuptools packaging programs. setuptools is needed for building some Python modules.

--with-dbmliborder=bdb:gdbm:ndbm: Use this switch if you want to build the Python DBM Module against Berkeley DB instead of GDBM.

--enable-optimizations: This switch enables stable, but expensive, optimizations.

--with-lto: This optional switch enables thick Link Time Optimization. Unusually, it creates a much larger /usr/lib/python3.10/config-3.10-<arch>-linux-gnu/libpython3.10.a with a small increase in the time to compile Python. Run-time results do not appear to show any benefit from doing this.

Configuring Python 3

In order for python3 to find the installed documentation, create the following version independent symlink:

ln -svfn python-3.10.2 /usr/share/doc/python-3

and add the following environment variable to the individual user's or system's profile:

export PYTHONDOCS=/usr/share/doc/python-3/html

Contents

Installed Programs: 2to3 (symlink) and 2to3-3.10, idle3 (symlink) and idle3.10, pip3 (symlink) and pip3.10, pydoc3 and pydoc3.10, python3 (symlink); python3.10, and python3-config (symlink) and python3.10-config
Installed Libraries: libpython3.10.so and libpython3.so
Installed Directories: /usr/include/python3.10, /usr/lib/python3.10, and /usr/share/doc/python-3.10.2

Short Descriptions

idle3

is a wrapper script that opens a Python aware GUI editor. For this script to run, you must have installed Tk before Python so that the Tkinter Python module is built

pydoc3

is the Python documentation tool

python3

is an interpreted, interactive, object-oriented programming language

python3.10

is a version-specific name for the python program

Last updated on

Python Modules

Introduction to Python Modules

The Python module packages add useful objects to the Python language. Modules utilized by packages throughout BLFS are listed here, along with their dependencies.

Asciidoc-10.1.1

Introduction to Asciidoc

The Asciidoc package is a text document format for writing notes, documentation, articles, books, ebooks, slideshows, web pages, man pages and blogs. AsciiDoc files can be translated to many formats including HTML, PDF, EPUB, and man page.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Asciidoc Dependencies
Optional (tests and runtime)

docbook-xsl-1.79.2, fop-2.7, libxslt-1.1.35, Lynx-2.8.9rel.1, dblatex, and W3m

Installation of Asciidoc

If you are upgrading from version 9.x, remove the previously installed executables, as the root user:

rm -rf /usr/bin/{asciidoc*,a2x*}

Build and install the Python 3 module by running the following commands as the root user:

python3 setup.py install --optimize=1

Contents

Installed Programs: a2x and asciidoc
Installed Libraries: None
Installed Directories: /usr/lib/python3.10/site-packages/asciidoc-10.1.1-py3.10.egg
Short Descriptions

a2x

is a toolchain manager for AsciiDoc (converts Asciidoc text files to other file formats)

asciidoc

converts an AsciiDoc text file to HTML or DocBook

D-Bus Python-1.2.18

Introduction to D-Bus Python Module

D-Bus Python provides Python bindings to the D-Bus API interface.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
D-Bus Python Dependencies
Required

dbus-1.12.20 and GLib-2.70.4

Recommended
Optional

PyGObject-3.42.0 and tap.py (required for some tests)

Optional (Required to build the API and HTML Documentation)

docutils-0.18.1 and Sphinx with sphinx_rtd_theme

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/dbus-python

Installation of D-Bus Python

Note

Both Python 2 and Python 3 modules can be built and installed without any conflicts.

To build D-Bus Python as the Python 2 module, run the following commands:

mkdir python2 &&
pushd python2 &&
PYTHON=/usr/bin/python2     \
../configure --prefix=/usr --disable-documentation &&
make &&
popd

To test the results, issue: make -C python2 check. Several tests report an error due to dbus issues.

To build D-Bus Python as the Python 3 module, run the following commands:

mkdir python3 &&
pushd python3 &&
PYTHON=/usr/bin/python3    \
../configure --prefix=/usr --docdir=/usr/share/doc/dbus-python-1.2.18 &&
make &&
popd

To test the results, issue: make -C python3 check.

To install the Python 2 module, run the following command as the root user:

make -C python2 install

To install the Python 3 module, run the following command as the root user:

make -C python3 install

Contents

Installed Programs: None
Installed Libraries: None
Installed Directories: /usr/share/doc/dbus-python-1.2.18 and /usr/lib/python2.7/site-packages/dbus and/or /usr/lib/python3.10/site-packages/dbus

docutils-0.18.1

Introduction to docutils

docutils is a set of Python modules and programs for processing plaintext docs into formats such as HTML, XML, or LaTeX.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/docutils

Installation of docutils

To build the Python 3 applications, run the following command:

python3 setup.py build

To install the Python applications run the following as the root user:

python3 setup.py install --optimize=1 &&

for f in /usr/bin/rst*.py; do
  ln -svf $(basename $f) /usr/bin/$(basename $f .py)
done

Contents

Installed Programs: rst2html4, rst2html5, rst2html, rst2latex, rst2man, rst2odt_prepstyles, rst2odt, rst2pseudoxml, rst2s5, rst2xetex, rst2xml, and rstpep2html
Installed Libraries: None
Installed Directories: /usr/lib/python3.10/site-packages/docutils

Py3c-1.4

Introduction to Py3c

Py3c helps you port C extensions to Python 3. It provides a detailed guide, and a set of macros to make porting easy and reduce boilerplate.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/py3c

Installation of Py3c

The Py3c package is a headers-only package and because of that, no configuration and compilation is required.

To test the package, issue:

make test-python3 &&
make test-python3-cpp

To install the Python 3 module, run the following command as the root user:

make prefix=/usr install

Contents

Installed Programs: None
Installed Libraries: None
Installed Directories: /usr/include/py3c

PyAtSpi2-2.38.2

Introduction to PyAtSpi2

The PyAtSpi2 package contains Python bindings for the core components of the GNOME Accessibility.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
PyAtSpi2 Dependencies
Required

PyGObject-3.42.0

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pyatspi2

Installation of PyAtSpi2

To build PyAtSpi2 as a Python 3 module, run the following commands:

./configure --prefix=/usr --with-python=/usr/bin/python3

This package does not come with a testsuite.

To install the Python 3 module, run the following command as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: None
Installed Directories: /usr/lib/python3.10/site-packages/pyatspi

PyCairo-1.20.1

Introduction to PyCairo Module

PyCairo provides Python bindings to Cairo.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
PyCairo Dependencies
Required

Cairo-1.17.4

Optional

Hypothesis (for tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pycairo

Installation of PyCairo

Note

The current version of pycairo no longer builds the Python2 module. If you need that module for packages such as Gimp-2.10.30, use PyCairo-1.18.2

Install PyCairo for Python3 by running the following commands:

python3 setup.py build

This package does not come with a test suite.

Now, as the root user:

python3 setup.py install --optimize=1   &&
python3 setup.py install_pycairo_header &&
python3 setup.py install_pkgconfig

Contents

Installed Program: None
Installed Library: _cairo.cpython-310-<arch>-linux-gnu.so
Installed Directories: /usr/include/pycairo, and /usr/lib/python3.10/site-packages/pycairo-1.20.1-py3.10.egg

PyCairo-1.18.2

Introduction to PyCairo for Python2 Module

This version of PyCairo provides Python2 bindings to Cairo.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
PyCairo Dependencies
Required

Cairo-1.17.4 and Python-2.7.18

Optional

Hypothesis (for tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pycairo

Installation of PyCairo

Note

This version of PyCairo is only retained for packages such as Gimp-2.10.30 which is stuck on Python2 until Gimp-3 is released.

Install PyCairo for Python2 by running the following commands:

python2 setup.py build

This package does not come with a test suite.

Now, as the root user:

python2 setup.py install --optimize=1   &&
python2 setup.py install_pycairo_header &&
python2 setup.py install_pkgconfig

Contents

Installed Program: None
Installed Library: _cairo.so
Installed Directories: /usr/include/pycairo, /usr/lib/python2.7/site-packages/cairo, /usr/lib/python2.7/site-packages/pycairo-1.18.2-py2.7.egg,

PyCryptodome-3.14.1

Introduction to the PyCryptodome Module

PyCryptodome is a collection of both secure hash functions (such as SHA256 and RIPEMD160), and various encryption algorithms (AES, DES, RSA, ElGamal, etc.), and is a drop-in replacement for PyCrypto.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pycryptodome

Installation of PyCryptodome

To build PyCryptodome as a Python 3 module, run the following command:

python3 setup.py build

To install the module, run the following command as the root user:

python3 setup.py install --optimize=1

Contents

Installed Programs: None
Installed Libraries: None
Installed Directories: /usr/lib/python3.10/site-packages/pycryptodome-3.14.1-py3.10.egg

dbusmock-0.25.0

Introduction to dbusmock

dbusmock is a Python library useful for writing tests for software which talks to D-Bus services.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
dbusmock Dependencies
Required

D-Bus Python-1.2.18 (runtime)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/dbusmock

Installation of dbusmock

Build the package with:

python3 setup.py build

To install the package run the following as the root user:

python3 setup.py install --optimize=1

Contents

Installed Programs: None
Installed Libraries: python_dbusmock-0.25.0-py3.10.egg
Installed Directories: /usr/lib/python3.10/site-packages/dbusmock

Pygments-2.11.2

Introduction to Pygments Module

Pygments is a general syntax highlighter written in Python, for more than 300 languages.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pygments

Installation of Pygments

Build and install the Python 3 module by running the following commands as the root user:

python3 setup.py install --optimize=1

Contents

Installed Programs: pygmentize
Installed Library: None
Installed Directories: /usr/lib/python3.10/site-packages/Pygments-2.11.2-py3.10.egg

PyGObject-2.28.7

Introduction to PyGObject Module

PyGObject-2.28.7 provides Python 2 bindings to the GObject class from GLib.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
PyGObject Dependencies
Required

GLib-2.70.4, PyCairo-1.18.2 and Python-2.7.18

Optional

gobject-introspection-1.70.0 and libxslt-1.1.35 (to Build Documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pygobject2

Installation of PyGObject

Install PyGObject by running the following commands:

./configure --prefix=/usr --disable-introspection &&
make

This package does not have a working testsuite.

Now, as the root user:

make install

Command Explanations

--disable-introspection: Omit this switch if you have installed gobject-introspection-1.70.0. Note that it conflicts with PyGObject-3.42.0.

--disable-docs: This option disables the rebuilding of the html documentation if libxslt-1.1.35 is installed.

Contents

Installed Programs: pygobject-codegen-2.0
Installed Libraries: libpyglib-2.0-python.so, _gio.so, unix.so, _glib.so and _gobject.so.
Installed Directories: /usr/include/pygtk-2.0, /usr/lib/python2.7/site-packages/gtk-2.0/{gio,glib,gobject}, /usr/share/gtk-doc/html/pygobject and /usr/share/pygobject/2.0

PyGObject-3.42.0

Introduction to PyGObject3 Module

PyGObject3 provides Python bindings to the GObject class from GLib.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
PyGObject3 Dependencies
Required

gobject-introspection-1.70.0 and PyCairo-1.20.1 (Python 3 module)

Optional (for the tests)

GTK-4.6.1, pep8, pyflakes, and pytest

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pygobject3

Installation of PyGObject3

First, remove a faulty test:

mv -v tests/test_gdbus.py{,.nouse}

Install pygobject3 by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test. An already active graphical session with a bus address is necessary to run the tests. One test, tests/test_gdbus.py, is known to fail. Another round of tests may report ERROR if GTK-4.6.1 is not installed.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: None
Installed Library: /usr/lib/python3.10/site-packages/gi/_gi{,_cairo}.cpython-310-<arch>-linux-gnu.so
Installed Directories: /usr/include/pygobject-3.0 and /usr/lib/python3.10/site-packages/{gi,pygtkcompat}

PyGTK-2.24.0

Introduction to PyGTK Module

PyGTK lets you to easily create programs with a graphical user interface using the Python programming language.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
PyGTK Dependencies
Required

PyGObject-2.28.7 and Python-2.7.18

Required (atk module)

ATK-2.36.0

Required (pango module)

Pango-1.50.4

Required (pangocairo module)

PyCairo-1.18.2 and Pango-1.50.4

Required (gtk and gtk.unixprint modules)

PyCairo-1.18.2 and GTK+-2.24.33.

Required (gtk.glade module)

PyCairo-1.18.2 and libglade-2.6.4.

Optional

NumPy

Optional (to Build Documentation)

libxslt-1.1.35

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pygtk

Installation of PyGTK

First, adapt PyGTK to changes in Pango by removing undefined APIs:

sed -i '1394,1402 d' pango.defs

Install PyGTK by running the following commands:

./configure --prefix=/usr &&
make

The tests must be run from an active X display. If this is so, issue: make check.

Now, as the root user:

make install

Command Explanations

--enable-docs: This option enables rebuilding the html documentation if libxslt-1.1.35 is installed.

Contents

Installed Programs: pygtk-codegen-2.0 and pygtk-demo.
Installed Libraries: atk.so, _gtk.so, glade.so, gtkunixprint.so, pango.so and pangocairo.so.
Installed Directories: /usr/include/pygtk-2.0, /usr/lib/pygtk, /usr/lib/python2.7/site-packages/gtk-2.0, /usr/share/gtk-doc/html/pygtk and /usr/share/pygtk.
Short Descriptions

pygtk-codegen-2.0

is a wrapper script to run the PyGTK codegen module

pygtk-demo

is a Python wrapper to run the PyGTK demo program

PyXDG-0.27

Introduction to PyXDG Module

PyXDG is a Python library to access freedesktop.org standards.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
PyXDG Dependencies
Optional

Python-2.7.18

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pyxdg

Installation of PyXDG

To install the module, run the following command as the root user:

python3 setup.py install --optimize=1

Contents

Installed Directory: /usr/lib/python3.10/site-packages/xdg

libxml2-2.9.13 (for its Python2 module)

Introduction to the libxml2 Python2 module

These instructions provide the Python2 bindings for libxml2: the Python3 bindings are built as part of libxml2-2.9.13 and most packages in the book do not use these bindings for the older Python2.

By building these bindings after libxml2-2.9.13 has been installed, there is no need to rebuild the time-consuming (if all dependencies are used) main part of that package.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
libxml2 (Python2) Dependencies
Required

libxml2-2.9.13 and Python-2.7.18

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libxml2

Installation of libxml2 Python2 module

To build the Python 2 module, run:

cd python                                            &&
sed -i 's/ModuleNotFoundError/ImportError/' setup.py &&
python2 setup.py build

To install the Python 2 module, as the root user run:

python2 setup.py install --optimize=1

Contents

Installed Programs: drv_libxml2.py, libxml2.py
Installed Libraries: libxml2mod.so
Installed Directories: None

Short Descriptions

drv_libxml2.py

is a SAX Python2 driver for libxml2

libxml2.py

is the Python2 binding for libxml2

libxml2mod.so

is the interface for Python2 to use libxml2.so

lxml-4.7.1

Introduction to lxml

lxml provides Python bindings for libxslt-1.1.35 and libxml2-2.9.13.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
lxml Dependencies
Required

libxslt-1.1.35

Optional (to run more tests)

GDB-11.2, Valgrind-3.18.1, and cssselect

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lxml

Installation of lxml

To build the Python 3 module, run:

python3 setup.py build

If you wish to run the tests, enter: make PYTHON=python3 test. This will rebuild the package for inplace use before running the tests. Several tests (32 of 1948) are known to fail with Python-3.10.1.

To install the module, issue the following command as the root user:

python3 setup.py install --optimize=1

Contents

Installed Programs: None
Installed Libraries: None
Installed Directories: /usr/lib/python3.10/site-packages/lxml, /usr/lib/python3.10/site-packages/lxml-4.7.1-py3.10-linux-$ARCH.egg-info

MarkupSafe-2.0.1

Introduction to MarkupSafe Module

MarkupSafe is a Python module that implements a XML/HTML/XHTML Markup safe string.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/MarkupSafe

Installation of MarkupSafe

Install MarkupSafe with the following commands:

python3 setup.py build

Then, as the root user:

python3 setup.py install --optimize=1

Contents

Installed Programs: None
Installed Libraries: None
Installed Directories: /usr/lib/python3.10/site-packages/markupsafe and /usr/lib/python3.10/site-packages/MarkupSafe-2.0.1-py3.10.egg-info

Jinja2-3.0.3

Introduction to Jinja2 Module

Jinja2 is a Python module that implements a simple pythonic template language.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Jinja2 Dependencies
Required

MarkupSafe-2.0.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Jinja2

Installation of Jinja2

To install the Python 3 module, run the following command as the root user:

python3 setup.py install --optimize=1

Contents

Installed Programs: None
Installed Libraries: None
Installed Directories: /usr/lib/python3.10/site-packages/Jinja2 and /usr/lib/python3.10/site-packages/Jinja2-3.0.3-py3.10.egg-info

Mako-1.1.6

Introduction to Mako Module

Mako is a Python module that implements hyperfast and lightweight templating for the Python platform.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Mako Dependencies
Required

MarkupSafe-2.0.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Mako

Installation of Mako

To install the Python 3 module, run the following command as the root user:

python3 setup.py install --optimize=1

Contents

Installed Programs: mako-render
Installed Libraries: None
Installed Directories: /usr/lib/python3.10/site-packages/Mako-1.1.6-py3.10.egg

PyYAML-5.3.1

Introduction to PyYAML Module

PyYAML is a Python module that implements the next generation YAML parser and emitter.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
PyYAML Dependencies
Required

libyaml-0.2.5

Optional

Python-2.7.18

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/PyYAML

Installation of PyYAML

Install PyYAML with the following commands:

python3 setup.py build

Now, as the root user:

python3 setup.py install --optimize=1

Contents

Installed Programs: None
Installed Libraries: _yaml.so
Installed Directories: /usr/lib/python2.7/site-packages/yaml and/or /usr/lib/python3.10/site-packages/yaml

Scour-0.38.2

Introduction to Scour

Scour is an SVG (Scalable Vector Graphics) optimizer/cleaner that reduces their size by optimizing structure and removing unnecessary data.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Scour Dependencies
Required

six-1.16.0 (will be automatically downloaded and installed if not already present)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/scour

Installation of scour

To build the Python 3 module run the following commands:

python3 setup.py build

To partially test the results, issue: python3 test_css.py. If you have installed Six you can run the main tests by issuing: python3 test_scour.py.

To install the module, run the following command as the root user:

python3 setup.py install --optimize=1

Contents

Installed Programs: scour
Installed Libraries: None
Installed Directories: None

Short Descriptions

scour

is a program to optimize and clean SVG files

six-1.16.0

Introduction to Six Module

Six is a Python 2 and 3 compatibility library.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Six Dependencies
Recommended Dependencies

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/six

Installation of six

Note

Both Python 2 and Python 3 modules can be built and installed without any conflicts.

Install six for Python 2 and Python 3 by running the following commands:

python2 setup.py build &&
python3 setup.py build

This package does not come with a test suite.

Now, as the root user:

python2 setup.py install --optimize=1 &&
python3 setup.py install --optimize=1

Contents

Installed Programs: None
Installed Libraries: None
Installed Directories: /usr/lib/python2.7/site-packages/six-1.16.0-py2.7.egg and/or /usr/lib/python3.10/site-packages/six-1.16.0-py3.10.egg

Last updated on

Ruby-3.1.0

Introduction to Ruby

The Ruby package contains the Ruby development environment. This is useful for object-oriented scripting.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://cache.ruby-lang.org/pub/ruby/3.1/ruby-3.1.0.tar.xz

  • Download MD5 sum: cdc345178b63098728e9b6d2188bd1bd

  • Download size: 14 MB

  • Estimated disk space required: 600 MB (add 1.1 GB for C API docs)

  • Estimated build time: 1.8 SBU (using parallelism=4; add 8.8 SBU for tests; add 1.9 SBU for C API docs)

Ruby Dependencies

Optional

Berkeley DB-5.3.28, Doxygen-1.9.3, Graphviz-2.50.0, libyaml-0.2.5, Tk-8.6.12, Valgrind-3.18.1, and DTrace

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/ruby

Installation of Ruby

Install Ruby by running the following command:

./configure --prefix=/usr   \
            --enable-shared \
            --docdir=/usr/share/doc/ruby-3.1.0 &&
make

Optionally, build the CAPI documents by running the following commands:

make capi

To test the results, issue: make check. There are over 21,000 tests. Some tests related to ipv6 may indicate errors. If the tests are run in a directory that has a world writable component (e.g. /tmp) then several additional tests may fail. A few tests may fail due to system configuration expectations.

Now, as the root user:

make install

Command Explanations

--enable-shared: This switch enables building of the libruby shared library.

--disable-install-doc: This switch disables building and installing rdoc indexes and C API documents.

--disable-install-rdoc: This switch disables building and installing rdoc indexes.

--disable-install-capi: This switch disables building and installing C API documents.

Contents

Installed Programs: bundle, bundler, erb, gem, irb, racc, rake, rbs, rdbg, rdoc, ri, ruby, and typeprof
Installed Libraries: libruby.so
Installed Directories: /usr/include/ruby-3.1.0, /usr/lib/ruby, /usr/share/doc/ruby-3.1.0 and /usr/share/ri

Short Descriptions

bundle

creates bundles of Ruby Gems

bundler

manages an application's dependencies throughout it's lifecycle

erb

is Tiny eRuby. It interprets a Ruby code embedded text file

gem

command for RubyGems - a sophisticated package manager for Ruby

irb

is the interactive interface for Ruby

rake

a make-like build utility for Ruby

rdbg

is an interactive debugger for Ruby

rdoc

generates Ruby documentation

ri

displays documentation from a database on Ruby classes, modules, and methods

ruby

is an interpreted scripting language for quick and easy object-oriented programming

libruby.so

contains the API functions required by Ruby

Last updated on

Rustc-1.58.1

Introduction to Rust

The Rust programming language is designed to be a safe, concurrent, practical language.

This package is updated on a six-weekly release cycle. Because it is such a large and slow package to build, is at the moment only required by a few packages in this book, and particularly because newer versions tend to break older mozilla packages, the BLFS editors take the view that it should only be updated when that is necessary (either to fix problems, or to allow a new version of a package to build).

As with many other programming languages, rustc (the rust compiler) needs a binary from which to bootstrap. It will download a stage0 binary and many cargo crates (these are actually .tar.gz source archives) at the start of the build, so you cannot compile it without an internet connection.

These crates will then remain in various forms (cache, directories of extracted source), in ~/.cargo for ever more. It is common for large rust packages to use multiple versions of some crates. If you purge the files before updating this package, very few crates will need to be updated by the packages in this book which use it (and they will be downloaded as required). But if you retain an older version as a fallback option and then use it (when not building in /usr), it is likely that it will then have to re-download some crates. For a full download (i.e. starting with an empty or missing ~/.cargo) downloading the external cargo files for this version only takes a minute or so on a fast network.

Note

Although BLFS usually installs in /usr, when you later upgrade to a newer version of rust the old libraries in /usr/lib/rustlib will remain, with various hashes in their names, but will not be usable and will waste space. The editors recommend placing the files in the /opt directory. In particular, if you have reason to rebuild with a modified configuration (e.g. using the shipped LLVM after building with shared LLVM, perhaps to compile crates for architectures which the BLFS LLVM build does not support) it is possible for the install to leave a broken cargo program. In such a situation, either remove the existing installation first, or use a different prefix such as /opt/rustc-1.58.1-build2.

If you prefer, you can of course change the prefix to /usr and omit the ldconfig and the actions to add rustc to the PATH.

The current rustbuild build-system will use all processors, although it does not scale well and often falls back to just using one core while waiting for a library to compile. However it can be mostly limited to a specified number of processors by a combination of adding the switch --jobs <N> (e.g. '--jobs 4' to limit to 4 processors) on each invocation of python3 ./x.py and using an environment variable CARGO_BUILD_JOBS=<N>. At the moment this is not effective when some of the rustc tests are run.

The current version of rust's num_cpus crate now recognizes that cgroups can be used to restrict which processors it is allowed to use. So if your machine lacks DRAM (typically, less than 2GB DRAM per core) that might be an alternative to taking CPUs offline. In sysv systems cgroups requires libcgroup.

At the moment Rust does not provide any guarantees of a stable ABI.

Note

Rustc defaults to building for ALL supported architectures, using a shipped copy of LLVM. In BLFS the build is only for the X86 architecture. If you intend to develop rust crates, this build may not be good enough for your purposes.

The build times of this version when repeated on the same machine are often reasonably consistent, but as with all compilations using rustc there can be some very slow outliers.

Unusually, a DESTDIR-style method is being used to install this package. This is because running the install as root not only downloads all of the cargo files again (to /root/.cargo), it then spends a very long time recompiling. Using this method saves a lot of time, at the cost of extra disk space.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://static.rust-lang.org/dist/rustc-1.58.1-src.tar.gz

  • Download MD5 sum: 275744c77bf07fd07abe0fd829e6dafb

  • Download size: 176 MB

  • Estimated disk space required: 8.7 GB (417 MB installed) including 296 MB of ~/.cargo files for the user building this. Add 6.5 GB including extra 281 MB of ~/.cargo files if running the tests

  • Estimated build time: 25 SBU (including download time; add 13 SBU for tests, both on a 4-core machine)

Rust Dependencies

Required

cURL-7.81.0, CMake-3.22.2, and libssh2-1.10.0

Recommended
Optional

GDB-11.2 (used by the testsuite if it is present)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/rust

Installation of Rust

To install into the /opt directory, remove the symlink and create a new directory (i.e. with a different name if trying a modified build). As the root user:

mkdir /opt/rustc-1.58.1             &&
ln -svfin rustc-1.58.1 /opt/rustc

Note

If multiple versions of Rust are installed in /opt, changing to another version only requires changing the /opt/rustc symbolic link and then running ldconfig.

Create a suitable config.toml file which will configure the build.

cat << EOF > config.toml
# see config.toml.example for more possible options
# See the 8.4 book for an example using shipped LLVM
# e.g. if not installing clang, or using a version before 10.0
[llvm]
# by default, rust will build for a myriad of architectures
targets = "X86"

# When using system llvm prefer shared libraries
link-shared = true

[build]
# omit docs to save time and space (default is to build them)
docs = false

# install cargo as well as rust
extended = true

[install]
prefix = "/opt/rustc-1.58.1"
docdir = "share/doc/rustc-1.58.1"

[rust]
channel = "stable"
rpath = false

# BLFS does not install the FileCheck executable from llvm,
# so disable codegen tests
codegen-tests = false

[target.x86_64-unknown-linux-gnu]
# NB the output of llvm-config (i.e. help options) may be
# dumped to the screen when config.toml is parsed.
llvm-config = "/usr/bin/llvm-config"

[target.i686-unknown-linux-gnu]
# NB the output of llvm-config (i.e. help options) may be
# dumped to the screen when config.toml is parsed.
llvm-config = "/usr/bin/llvm-config"


EOF

Compile Rust by running the following commands:

export RUSTFLAGS="$RUSTFLAGS -C link-args=-lffi" &&
python3 ./x.py build --exclude src/tools/miri

Note

The testsuite will generate some messages in the system log for traps on invalid opcodes, and for segmentation faults. In themselves these are nothing to worry about, just a way for the test to be terminated.

To run the tests issue python3 ./x.py test --verbose --no-fail-fast | tee rustc-testlog: as with the build, that will use all available CPUs.

At a minimum, 49 tests will fail: all 48 of the tests in the assembly suite which are not skipped (various lints cause the warnings in these tests to be treated as errors), and run-make-fulldeps/long-linker-command-lines.

As with all large testsuites, other tests might fail on some machines - if the number of additional failures is in the single digits, check the log for 'failures:' and review lines above that, particularly the 'stderr:' lines. Any mention of SIGSEGV or signal 11 in a failing test is a cause for concern.

If you get any other failing test which reports an issue number then you should search for that issue. For example, when rustc >= 1.41.1 was built with a version of sysllvm before 10.0 the test for issue 69225 failed https://github.com/rust-lang/rust/issues/69225 and that should be regarded as a critical failure (they released 1.41.1 because of it). Most other failures will not be critical.

Therefore, you should determine the number of failures.

The number of tests which failed can be found by running:

grep '^test result:' rustc-testlog | awk  '{ sum += $6 } END { print sum }'

And similarly if you care about how many tests passed use $4, for those which were ignored (i.e. skipped) use $8 (and $10 for 'measured', $12 for 'filtered out' but both are probably zero).

Still as your normal user, do a DESTDIR install:

export LIBSSH2_SYS_USE_PKG_CONFIG=1 &&
DESTDIR=${PWD}/install python3 ./x.py install &&
unset LIBSSH2_SYS_USE_PKG_CONFIG

Now, as the root user install the files from the DESTDIR:

chown -R root:root install &&
cp -a install/* /

Command Explanations

ln -svfn rustc-1.58.1 /opt/rustc: if this is not the first use of the /opt/rustc symlink, overwrite it by forcing, and use the '-n' flag to avoid getting confusing results from e.g. ls -l.

targets = "X86": this avoids building all the available linux cross-compilers (Aarch64, MIPS, PowerPC, SystemZ, etc). Unfortunately, rust insists on installing source files for these below /opt/rustc/lib/src.

extended = true: this installs Cargo alongside Rust.

channel = "stable": this ensures only stable features can be used, the default in config.toml is to use development features, which is not appropriate for a released version.

rpath = false: by default, rust can be run from where it was built, without being installed. That adds DT_RPATH entries to all of the ELF files, which produces very messy output from ldd, showing the libraries in the place they were built, even if they have been deleted from there after the install.

[target.x86_64-unknown-linux-gnu]: the syntax of config.toml requires an llvm-config entry for each target for which system-llvm is to be used. Change the target to [target.i686-unknown-linux-gnu] if you are building on 32-bit x86. This whole section may be omitted if you wish to build against the shipped llvm, or do not have clang, but the resulting build will be larger and take longer.

export RUSTFLAGS="$RUSTFLAGS -C link-args=-lffi": This adds a link to libffi to any RUSTFLAGS you may already be passing to the build. On some systems, linking fails to include libffi unless this is used. The reason why this is needed is not clear.

--exclude src/tools/miri: For a long time, the miri crate (an interpreter for the Midlevel Intermediate Representation) has failed to build on releases. It is optional, but the failure messages can persuade people that the whole build failed. However, although it is not built in the main compile, with rustc-1.35.0 it now got compiled during the install, but it was broken in that version. Omitting it should save a little time.

--verbose: this switch can sometimes provide more information about a test which fails.

--no-fail-fast: this switch ensures that the testsuite will not stop at the first error.

export LIBSSH2_SYS_USE_PKG_CONFIG=1: On some systems, cairo fails to link during the install because it cannot find libssh2. This seems to fix it, but again the reason why the problem occurs is not understood.

DESTDIR=${PWD}/install python3 ./x.py install: This effects a DESTDIR-style install in the source tree,creating an install directory. Note that DESTDIR installs need an absolute path, passing 'install' will not work.

chown -R root:root install: the DESTDIR install was run by a regular user, who owns the files. For security, change their owner before doing a simple copy to install them.

Configuring Rust

Configuration Information

If you installed rustc in /opt, you need to update the following configuration files so that rustc is correctly found by other packages and system processes.

As the root user, update the /etc/ld.so.conf file and the dynamic linker's run-time cache file:

cat >> /etc/ld.so.conf << EOF
# Begin rustc addition

/opt/rustc/lib

# End rustc addition
EOF

ldconfig

As the root user, create the /etc/profile.d/rustc.sh file:

cat > /etc/profile.d/rustc.sh << "EOF"
# Begin /etc/profile.d/rustc.sh

pathprepend /opt/rustc/bin           PATH

# Include /opt/rustc/man in the MANPATH variable to access manual pages
pathappend  /opt/rustc/share/man     MANPATH

# End /etc/profile.d/rustc.sh
EOF

Immediately after installation, update the current PATH for your current shell as a normal user:

source /etc/profile.d/rustc.sh

Contents

Installed Programs: cargo-clippy, cargo-fmt, cargo-miri (optional), cargo, clippy-driver, miri (optional), rls, rust-demangler, rust-gdb, rust-gdbgui, rust-lldb, rustc, rustdoc, rustfmt.
Installed Libraries: librustc-driver-<16-byte-hash>.so, libstd-<16-byte-hash>.so, and libtest-<16-byte-hash>.so
Installed Directories: ~/.cargo, /opt/rustc, symbolic link to /opt/rustc-1.58.1

Short Descriptions

cargo-clippy

provides lint checks for a cargo package

cargo-fmt

formats all bin and lib files of the current crate using rustfmt

cargo-miri

is for use by Miri to interpret bin crates and tests

cargo

is the Package Manager for Rust

clippy-driver

provides lint checks for Rust

miri

is an interpreter for Rust's mid-level intermediate representation (MIR). It is broken in this version

rls

is the Rust Language Server. This can run in the background to provide IDEs, editors, and other tools with information about Rust programs

rust-analyzer

is an implementation of Language Server Protocol for the Rust programming language.

rust-gdb

is a wrapper script for gdb, pulling in Python pretty-printing modules installed in /opt/rustc-1.58.1/lib/rustlib/etc

rust-gdbgui

is a wrapper script for a graphical front end to gdb that runs in a browser

rust-lldb

is a wrapper script for LLDB (the LLVM debugger) pulling in the Python pretty-printing modules

rustc

is the rust compiler

rustdoc

generates documentation from rust source code

rustfmt

formats rust code

libstd-<16-byte-hash>.so

is the Rust Standard Library, the foundation of portable Rust software

Last updated on

SCons-4.3.0

Introduction to SCons

SCons is a tool for building software (and other files) implemented in Python.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

SCons Dependencies

Optional

docbook-xsl-1.79.2 and libxslt-1.1.35

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/scons

Installation of SCons

Install SCons by running the following commands as the root user:

sed -i 's/env python/&3/' SCons/Utilities/*.py              &&
sed -i 's:build/doc/man/::' setup.cfg                       &&
python3 setup.py install --prefix=/usr  \
                         --optimize=1   \
                         --install-data=/usr/share/man/man1 &&
cp scons{,ign}.1 /usr/share/man/man1

Contents

Installed Programs: scons, scons-configure-cache, and sconsign
Installed Libraries: None
Installed Directory: /usr/lib/python3.10/site-packages/SCons

Short Descriptions

scons

is a software construction tool

scons-configure-cache

shows or converts the configuration of an SCons cache directory

sconsign

prints SCons .sconsign file information

Last updated on

slang-2.3.2

Introduction to slang

S-Lang (slang) is an interpreted language that may be embedded into an application to make the application extensible. It provides facilities required by interactive applications such as display/screen management, keyboard input and keymaps.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Slang Dependencies

Optional

libpng-1.6.37, PCRE-8.45, and Oniguruma

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/slang

Installation of Slang

Note

This package does not support parallel build.

Install slang by running the following commands:

./configure --prefix=/usr \
            --sysconfdir=/etc \
            --with-readline=gnu &&
make -j1

To test the results, issue: make check.

Now, as the root user:

make install_doc_dir=/usr/share/doc/slang-2.3.2   \
     SLSH_DOC_DIR=/usr/share/doc/slang-2.3.2/slsh \
     install &&

chmod -v 755 /usr/lib/slang/v2/modules/*.so

Command Explanations

--with-readline=gnu: This parameter sets GNU Readline to be used by the parser interface instead of the slang internal version.

make install_doc_dir=/usr/share/doc/slang-2.3.2 SLSH_DOC_DIR=/usr/share/doc/slang-2.3.2/slsh install: This command installs this package with a versioned documentation installation directory.

Configuring slang

Config Files

~/.slshrc and /etc/slsh.rc

Contents

Installed Program: slsh
Installed Libraries: libslang.so and numerous support modules
Installed Directories: /usr/lib/slang, /usr/share/doc/slang-2.3.2 and /usr/share/slsh

Short Descriptions

slsh

is a simple program for interpreting slang scripts. It supports dynamic loading of slang modules and includes a Readline interface for interactive use

Last updated on

Subversion-1.14.1

Introduction to Subversion

Subversion is a version control system that is designed to be a compelling replacement for CVS in the open source community. It extends and enhances CVS' feature set, while maintaining a similar interface for those already familiar with CVS. These instructions install the client and server software used to manipulate a Subversion repository. Creation of a repository is covered at Running a Subversion Server.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://archive.apache.org/dist/subversion/subversion-1.14.1.tar.bz2

  • Download MD5 sum: 2eccc2c7451397e01a13682600af9563

  • Download size: 8.1 MB

  • Estimated disk space required: 208 MB (add 228 MB for bindings, 52 MB for docs, 1.3 GB for tests)

  • Estimated build time: 0.5 SBU (Using parallelism=4; add 1.9 SBU for bindings, 35 SBU for tests)

Subversion Dependencies

Required

Apr-Util-1.6.1 and SQLite-3.37.2

Recommended
Optional

Apache-2.4.52, Boost-1.78.0, Cyrus SASL-2.1.27, dbus-1.12.20, Doxygen-1.9.3 (for generating HTML documentation), gnome-keyring-40.0, libsecret-0.20.5, Py3c-1.4 (for the python bindings, and tests) Python-2.7.18 (with sqlite support for the tests), Ruby-3.1.0, SWIG-4.0.2 (for building Perl, Python and Ruby bindings), LZ4, and UTF8proc

Optional (for the Java Bindings)

One of OpenJDK-17.0.2, Dante or Jikes, JUnit 4 (to test the Java bindings) and apache-ant-1.10.12.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/subversion

Installation of Subversion

First, adapt some Python scripts to use python3:

grep -rl '^#!.*python$' | xargs sed -i '1s/python/&3/'

Install Subversion by running the following commands:

PYTHON=python3 ./configure --prefix=/usr             \
            --disable-static          \
            --with-apache-libexecdir  \
            --with-lz4=internal       \
            --with-utf8proc=internal &&
make

If you have Doxygen-1.9.3 installed and you wish to build the API documentation, issue:

doxygen doc/doxygen.conf

If you wish to build the Java bindings pass the --enable-javahl parameter to the configure command. In addition, if you want to run the Java test suite, you have to specify the location of the JUnit file by adding --with-junit=<path to junit jar> (for instance --with-junit=/usr/local/java/lib/junit-4.13.jar) to configure. The JUnit jar file is no longer included in apache-ant-1.10.12 and must be downloaded separately. To build the Java bindings, issue the following command:

make javahl

If you want to compile Perl, Python, or Ruby bindings, issue any of the following command:

make swig-pl # for Perl
make swig-py \
     swig_pydir=/usr/lib/python3.10/site-packages/libsvn \
     swig_pydir_extra=/usr/lib/python3.10/site-packages/svn # for Python
make swig-rb # for Ruby

To test the results, issue: make check. Four tests in the commit_tests.py, prop_tests.py, and update_tests.py suites are known to fail.

To test the results of the Java bindings build, issue LANG=C make check-javahl.

To test the results of any of the SWIG bindings, you can use any of the following commands: make check-swig-pl, make check-swig-py, or make check-swig-rb.

Now, as the root user:

make install &&

install -v -m755 -d /usr/share/doc/subversion-1.14.1 &&
cp      -v -R doc/* /usr/share/doc/subversion-1.14.1

If you built the Java bindings, issue the following command as the root user to install them:

make install-javahl

If you built the Perl, Python, or Ruby bindings, issue any of the following commands as the root user to install them:

make install-swig-pl
make install-swig-py \
      swig_pydir=/usr/lib/python3.10/site-packages/libsvn \
      swig_pydir_extra=/usr/lib/python3.10/site-packages/svn
make install-swig-rb

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--with-apache-libexecdir: If Apache-2.4.52 is installed, the shared Apache modules are built. This switch allows to have those modules installed to Apache's configured module dir instead of /usr/libexec. It has no effect if Apache is not installed.

--with-lz4=internal, --with-utf8proc=internal: Remove these switches if you have installed the optional dependencies.

--enable-javahl: enables compilation of Java high level bindings. Running make javahl is necessary to do the compilation.

--with-junit=<location of the junit jar file>: gives the location of the junit jar, otherwise the javahl tests cannot be run.

--disable-gmock: Do not use the Googlemock testing framework.

Configuring Subversion

Config Files

~/.subversion/config and /etc/subversion/config

Configuration Information

/etc/subversion/config is the Subversion system-wide configuration file. This file is used to specify defaults for different svn commands.

~/.subversion/config is the user's personal configuration file. It is used to override the system-wide defaults set in /etc/subversion/config.

Contents

Installed Programs: svn, svnadmin, svnbench, svndumpfilter, svnfsfs, svnlook, svnmucc, svnrdump, svnserve, svnsync, and svnversion
Installed Libraries: libsvn_*-1.so and optionally, a Java library, the mod_dav_svn.so and and mod_authz_svn.so Apache HTTP DSO modules and various Perl, Python and Ruby modules.
Installed Directories: /usr/include/subversion-1, /usr/lib/perl5/site_perl/5.34/{,auto/}SVN, /usr/lib/python3.10/site-packages/{libsvn,svn}, /usr/lib/ruby/site_ruby/<x.y.z>/{,<arch-linux>-linux/}svn, /usr/lib/svn-javahl, and /usr/share/doc/subversion-1.14.1

Short Descriptions

svn

is a command-line client program used to access Subversion repositories

svnadmin

is a tool for creating, tweaking or repairing a Subversion repository

svnbench

is a benchmarking tool

svndumpfilter

is a program for filtering Subversion repository dumpfile format streams

svnfsfs

is the FSFS (FileSystem atop of the FileSystem - Subversion filesystem implementation) repository manipulation tool

svnlook

is a tool for inspecting a Subversion repository

svnmucc

is a Multiple URL Command Client for Subversion

svnrdump

is a tool for dumping or loading a remote Subversion repository

svnserve

is a custom standalone server program, able to run as a daemon process or invoked by SSH

svnsync

is a Subversion repository synchronisation tool

svnversion

is used to report the version number and state of a working Subversion repository copy

libsvn_*-1.so

are the support libraries used by the Subversion programs

mod_authz_svn.so

is a plug-in module for the Apache HTTP server, used to authenticate users to a Subversion repository over the Internet or an intranet

mod_dav_svn.so

is a plug-in module for the Apache HTTP server, used to make a Subversion repository available to others over the Internet or an intranet

Last updated on

Running a Subversion Server

Running a Subversion Server

This section will describe how to set up, administer and secure a Subversion server.

Subversion Server Dependencies

Required

Subversion-1.14.1 and OpenSSH-8.8p1

Setting up a Subversion Server.

The following instructions will install a Subversion server, which will be set up to use OpenSSH as the secure remote access method, with svnserve available for anonymous access.

Configuration of the Subversion server consists of the following steps:

1. Setup Users, Groups, and Permissions

You'll need to be user root for the initial portion of configuration. Create the svn user and group with the following commands:

groupadd -g 56 svn &&
useradd -c "SVN Owner" -d /home/svn -m -g svn -s /bin/false -u 56 svn

If you plan to have multiple repositories, you should have a group dedicated to each repository for ease of administration. Create the svntest group for the test repository and add the svn user to that group with the following commands:

groupadd -g 57 svntest &&
usermod -G svntest -a svn

Additionally you should set umask 002 while working with a repository so that all new files will be writable by owner and group. This is made mandatory by creating a wrapper script for svn and svnserve:

mv /usr/bin/svn /usr/bin/svn.orig &&
mv /usr/bin/svnserve /usr/bin/svnserve.orig &&
cat >> /usr/bin/svn << "EOF"
#!/bin/sh
umask 002
/usr/bin/svn.orig "$@"
EOF
cat >> /usr/bin/svnserve << "EOF"
#!/bin/sh
umask 002
/usr/bin/svnserve.orig "$@"
EOF
chmod 0755 /usr/bin/svn{,serve}

Note

If you use Apache for working with the repository over HTTP, even for anonymous access, you should wrap /usr/sbin/httpd in a similar script.

2. Create a Subversion repository.

There are several ways to set up a subversion repository. It is recommended to have a look at the SVN Book corresponding chapter. A basic repository can be set up with the instructions below.

Create a new Subversion repository with the following commands (as the root user):

install -v -m 0755 -d /srv/svn &&
install -v -m 0755 -o svn -g svn -d /srv/svn/repositories &&
svnadmin create /srv/svn/repositories/svntest

Now that the repository is created, it should be populated with something useful. You'll need to have a predefined directory layout set up exactly as you want your repository to look. For example, here is a sample BLFS layout setup with a root of svntest/. You'll need to setup a directory tree similar to the following:

svntest/            # The name of the repository
   trunk/           # Contains the existing source tree
      BOOK/
      bootscripts/
      edguide/
      patches/
      scripts/
   branches/        # Needed for additional branches
   tags/            # Needed for tagging release points

Once you've created your directory layout as shown above, you are ready to do the initial import:

svn import -m "Initial import." \
    </path/to/source/tree>      \
    file:///srv/svn/repositories/svntest

Now change owner and group information on the repository, and add an unprivileged user to the svn and svntest groups:

chown -R svn:svntest /srv/svn/repositories/svntest    &&
chmod -R g+w         /srv/svn/repositories/svntest    &&
chmod g+s            /srv/svn/repositories/svntest/db &&
usermod -G svn,svntest -a <username>

svntest is the group assigned to the svntest repository. As mentioned earlier, this eases administration of multiple repositories when using OpenSSH for authentication. Going forward, you'll need to add your unprivileged user, and any additional users that you wish to have write access to the repository, to the svn and svntest groups.

In addition, you'll notice that the new repository's db directory is set-groupID. If the reasoning is not immediately obvious, when using any external authentication method (such as ssh), the sticky bit is set so that all new files will be owned by the user, but group of svntest. Anyone in the svntest group can create files, but still give the entire group write access to those files. This avoids locking out other users from the repository.

Now, return to an unprivileged user account, and take a look at the new repository using svnlook:

svnlook tree /srv/svn/repositories/svntest/

Note

You may need to log out and back in again to refresh your group memberships. su <username> should work as well.

3. Configure the Server

As mentioned previously, these instructions will configure the server to use only ssh for write access to the repository and to provide anonymous access using svnserve. There are several other ways to provide access to the repository. These additional configurations are best explained at http://svnbook.red-bean.com/.

Access configuration needs to be done for each repository. Create the svnserve.conf file for the svntest repository using the following commands:

cp /srv/svn/repositories/svntest/conf/svnserve.conf \
   /srv/svn/repositories/svntest/conf/svnserve.conf.default &&

cat > /srv/svn/repositories/svntest/conf/svnserve.conf << "EOF"
[general]
anon-access = read
auth-access = write
EOF

There is not a lot to the configuration file at all. You'll notice that only the general section is required. Take a look at the svnserve.conf.default file for information on using svnserve's built-in authentication method.

4. Starting the Server

To start the server at boot time, install the svn bootscript included in the blfs-bootscripts-20210826 package:

make install-svn

Last updated on

SWIG-4.0.2

Introduction to SWIG

SWIG (Simplified Wrapper and Interface Generator) is a compiler that integrates C and C++ with languages including Perl, Python, Tcl, Ruby, PHP, Java, C#, D, Go, Lua, Octave, R, Scheme, and Ocaml. SWIG can also export its parse tree into Lisp s-expressions and XML.

SWIG reads annotated C/C++ header files and creates wrapper code (glue code) in order to make the corresponding C/C++ libraries available to the listed languages, or to extend C/C++ programs with a scripting language.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://downloads.sourceforge.net/swig/swig-4.0.2.tar.gz

  • Download MD5 sum: 7c3e46cb5af2b469722cafa0d91e127b

  • Download size: 7.7 MB

  • Estimated disk space required: 118 MB (1.3 GB with tests)

  • Estimated build time: 0.2 SBU (add 9.3 SBU for tests; both using parallelism=4)

SWIG Dependencies

Required

PCRE-8.45

Optional

Boost-1.78.0 for tests, and any of the languages mentioned in the introduction, as run-time dependencies

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/swig

Installation of SWIG

Install SWIG by running the following commands:

./configure --prefix=/usr \
            --without-maximum-compile-warnings &&
make

To test the results, issue: PY3=1 make -k check TCL_INCLUDE=. The unsetting of the variable TCL_INCLUDE is necessary since it is not correctly set by configure. The tests are only executed for the languages installed on your machine, so the disk space and SBU values given for the tests may vary, and should be considered as mere orders of magnitude. According to SWIG's documentation, the failure of some tests should not be considered harmful. The go tests are buggy and may generate a lot of meaningless output.

Now, as the root user:

make install &&
install -v -m755 -d /usr/share/doc/swig-4.0.2 &&
cp -v -R Doc/* /usr/share/doc/swig-4.0.2

Command Explanations

--without-maximum-compile-warnings: disables compiler ansi conformance enforcement, which triggers errors in the Lua headers (starting with Lua 5.3).

--without-<language>: allows disabling the building of tests and examples for <language>, but all the languages capabilities of SWIG are always built.

Contents

Installed Programs: swig and ccache-swig
Installed Library: None
Installed Directories: /usr/share/doc/swig-4.0.2 and /usr/share/swig

Short Descriptions

swig

takes an interface file containing C/C++ declarations and SWIG special instructions, and generates the corresponding wrapper code needed to build extension modules

ccache-swig

is a compiler cache, which speeds up re-compilation of C/C++/SWIG code

Last updated on

Sysprof-3.42.1

Introduction to Sysprof

The sysprof package contains a statistical and system-wide profiler for Linux.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Sysprof Dependencies

Required

GTK+-3.24.31, JSON-GLib-1.6.6, libdazzle-3.42.0, Polkit-0.120 , and elogind-246.10

Optional

libunwind

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/sysprof

Installation of Sysprof

Install Sysprof by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release -Dsystemdunitdir=/tmp .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install &&
rm -v /tmp/*.service

Command Explanations

rm -v /tmp/*.service: This command removes systemd units which have no use on SysV systems.

-Dsystemdunitdir=/tmp: This parameter puts systemd units in /tmp on SysV systems so that they can be removed. It also bypasses a check for systemd in the meson.build file.

Contents

Installed Programs: sysprof and sysprof-cli
Installed Libraries: libsysprof-4.so, libsysprof-capture-4.a, libsysprof-memory-4.so, libsysprof-speedtrack-4.so, and libsysprof-ui-4.so
Installed Directories: /usr/include/sysprof-4 and /usr/share/help/*/sysprof

Short Descriptions

sysprof

is a graphical interface to sysprof

sysprof-cli

is a command line interface to sysprof

libsysprof-4.so

provides API functions for profiling processes running on a system

libsysprof-capture-4.a

provides a hook used to capture statistics from a process

libsysprof-memory-4.so

provides API functions for capturing memory statistics

libsysprof-speedtrack-4.so

provides API functions for tracking the speed of a running process

libsysprof-ui-4.so

provides API functions for the sysprof GUI

Last updated on

Tk-8.6.12

Introduction to Tk

The Tk package contains a TCL GUI Toolkit.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Tk Dependencies

Required

Xorg Libraries

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/tk

Installation of Tk

Install Tk by running the following commands:

cd unix &&
./configure --prefix=/usr \
            --mandir=/usr/share/man \
            $([ $(uname -m) = x86_64 ] && echo --enable-64bit) &&

make &&

sed -e "s@^\(TK_SRC_DIR='\).*@\1/usr/include'@" \
    -e "/TK_B/s@='\(-L\)\?.*unix@='\1/usr/lib@" \
    -i tkConfig.sh

Running the tests is not recommended. Failures will be reported during the tests, depending on the screen resolution/capabilities, fonts installed and other X related parameters, but the end report can show 0 failures. Some tests will steal focus and some might crash your X Server. To test the results anyway, issue: make test. Ensure you run it from an X Window display device with the GLX extensions loaded, but even so, tests might hang.

Now, as the root user:

make install &&
make install-private-headers &&
ln -v -sf wish8.6 /usr/bin/wish &&
chmod -v 755 /usr/lib/libtk8.6.so

Command Explanations

$([ $(uname -m) = x86_64 ] && echo --enable-64bit): This switch is used to enable 64 bit support in Tk on 64 bit operating systems.

make install-private-headers: This command is used to install the Tk library interface headers used by other packages if they link to the Tk library.

ln -v -sf wish8.6 /usr/bin/wish: This command is used to create a compatibility symbolic link to the wish8.6 file as many packages expect a file named wish.

sed -e ... tkConfig.sh: The Tk package expects that its source tree is preserved so that packages depending on it for their compilation can utilize it. This sed removes the references to the build directory and replaces them with saner system-wide locations.

Contents

Installed Programs: wish and wish8.6
Installed Libraries: libtk8.6.so and libtkstub8.6.a
Installed Directory: /usr/lib/tk8.6

Short Descriptions

wish

is a symlink to the wish8.6 program

wish8.6

is a simple shell containing the Tk toolkit that creates a main window and then processes Tcl commands

libtk8.6.so

contains the API functions required by Tk

Last updated on

Vala-0.54.7

Introduction to Vala

Vala is a new programming language that aims to bring modern programming language features to GNOME developers without imposing any additional runtime requirements and without using a different ABI compared to applications and libraries written in C.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Vala Dependencies

Required

GLib-2.70.4

Recommended
Optional

dbus-1.12.20 (Required for the tests), libxslt-1.1.35 (Required for generating the documentation), help2man, jing, and weasyprint

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/vala

Installation of Vala

Install Vala by running the following commands:

./configure --prefix=/usr &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-valadoc: This option is required if Graphviz-2.50.0 is not installed.

Contents

Installed Programs: vala, vala-0.54, valac, valadoc, vala-gen-introspect, and vapigen (symlinks); valac-0.54, valadoc-0.54, vala-gen-introspect-0.54, and vapigen-0.54
Installed Library: libvala-0.54.so and libvaladoc-0.54.so
Installed Directories: /usr/include/vala-0.54, /usr/include/valadoc-0.54, /usr/lib/vala-0.54, /usr/lib/valadoc-0.54, /usr/share/vala, /usr/share/vala-0.54, /usr/share/valadoc-0.54, and /usr/share/devhelp/books/vala-0.54

Short Descriptions

valac

is a compiler that translates Vala source code into C source and header files

valadoc

is a documentation generator for generating API documentation from Vala source code based on libvala

vala-gen-introspect

generates a GI file for GObject and GLib based packages

vapigen

is an utility which generates Vala API (VAPI) files from GI files

libvala-0.54.so

contains the Vala API functions

Last updated on

Valgrind-3.18.1

Introduction to Valgrind

Valgrind is an instrumentation framework for building dynamic analysis tools. There are Valgrind tools that can automatically detect many memory management and threading bugs, and profile programs in detail. Valgrind can also be used to build new tools.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Valgrind Dependencies

Optional

GDB-11.2 (for tests), LLVM-13.0.1 (with Clang), and Which-2.21 (for tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/valgrind

Installation of Valgrind

First, make several changes that are required for Valgrind to function on systems with glibc-2.35 installed:

patch -Np1 -i ../valgrind-3.18.1-upstream_fixes-1.patch

Install Valgrind by running the following commands:

sed -i 's|/doc/valgrind||' docs/Makefile.in &&

./configure --prefix=/usr \
            --datadir=/usr/share/doc/valgrind-3.18.1 &&
make

To test the results, issue: make regtest. The tests may hang forever if GDB-11.2 is not installed. Some tests are known to hang also, depending on the version of glibc. A few test can fail in various suites. Problematic tests can be disabled by changing the prereq: line in the corresponding .vgtest file to prereq: false. For example:

sed -e 's@prereq:.*@prereq: false@' \
    -i {helgrind,drd}/tests/pth_cond_destroy_busy.vgtest

Note

The OpenMP tests are skipped if libgomp has been compiled with --enable-linux-futex (the default). If needed, just recompile the libgomp library from the gcc build tree, passing --disable-linux-futex to configure, storing the library to some place and changing the link from /usr/lib/libgomp.so.1 to point to the new library.

Now, as the root user:

make install

Command Explanations

sed -i ... docs/Makefile.in : This sed provides for installing the documentation in a versioned directory.

--enable-lto=yes: This option allows building Valgrind with LTO (link time optimization). This produces a smaller/faster Valgrind (up to 10%), but build time increases to about 5.5 SBU.

Contents

Installed Programs: callgrind_annotate, callgrind_control, cg_annotate, cg_diff, cg_merge, ms_print, valgrind, valgrind-di-server, valgrind-listener, and vgdb
Installed Libraries: None
Installed Directories: /usr/lib/valgrind, /usr/libexec/valgrind, /usr/include/valgrind, and /usr/share/doc/valgrind-3.18.1

Short Descriptions

valgrind

is a program for debugging and profiling Linux executables

callgrind_annotate

takes an output file produced by the Valgrind tool Callgrind and prints the information in an easy-to-read form

callgrind_control

controls programs being run by the Valgrind tool Callgrind

cg_annotate

is a post-processing tool for the Valgrind tool Cachegrind

cg_diff

compares two Cachegrind output files

cg_merge

merges multiple Cachegrind output files into one

ms_print

takes an output file produced by the Valgrind tool Massif and prints the information in an easy-to-read form

valgrind-di-server

is a server that reads debuginfo from objects stored on a different machine

valgrind-listener

listens on a socket for Valgrind commentary

vgdb

is an intermediary between Valgrind and GDB or a shell

Last updated on

yasm-1.3.0

Introduction to yasm

Yasm is a complete rewrite of the NASM-2.15.05 assembler. It supports the x86 and AMD64 instruction sets, accepts NASM and GAS assembler syntaxes and outputs binary, ELF32 and ELF64 object formats.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

yasm Dependencies

Optional

Python-2.7.18 and Cython

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/yasm

Installation of yasm

Install yasm by running the following commands:

sed -i 's#) ytasm.*#)#' Makefile.in &&

./configure --prefix=/usr &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

sed -i 's#) ytasm.*#)#' Makefile.in: This sed prevents it compiling 2 programs (vsyasm and ytasm) that are only of use on Microsoft Windows.

Contents

Installed Program: yasm
Installed Library: libyasm.a
Installed Directory: /usr/include/libyasm

Short Descriptions

yasm

is a portable, retargetable assembler that supports the x86 and AMD64 instruction sets, accepts NASM and GAS assembler syntaxes and outputs binaries in ELF32 and ELF64 object formats

libyasm.a

provides all of the core functionality of yasm, for manipulating machine instructions and object file constructs

Last updated on

Java

Last updated on

Java-17.0.2

About Java

Java is different from most of the packages in LFS and BLFS. It is a programming language that works with files of bytecode to obtain instructions and executes them in a Java Virtual Machine (JVM). An introductory java program looks like:

public class HelloWorld
{
    public static void main(String[] args)
    {
        System.out.println("Hello, World");
    }
}

This program is saved as HelloWorld.java. The file name, HelloWorld, must match the class name. It is then converted into byte code with javac HelloWorld.java. The output file is HelloWorld.class. The program is executed with java HelloWorld. This creates a JVM and runs the code. The 'class' extension must not be specified.

Several class files can be combined into one file with the jar command. This is similar to the standard tar command. For instance, the command jar cf myjar.jar *.class will combine all class files in a directory into one jar file. These act as library files.

The JVM can search for and use classes in jar files automatically. It uses the CLASSPATH environment variable to search for jar files. This is a standard list of colon-separated directory names similar to the PATH environment variable.

Binary JDK Information

Creating a JVM from source requires a set of circular dependencies. The first thing that's needed is a set of programs called a Java Development Kit (JDK). This set of programs includes java, javac, jar, and several others. It also includes several base jar files.

To start, we set up a binary installation of the JDK created by the BLFS editors. It is installed in the /opt directory to allow for multiple installations, including a source based version.

This package is known to build and work properly using an LFS-11.1 platform.

Binary Package Information

Java Binary Runtime Dependencies

alsa-lib-1.2.6.1, Cups-2.4.1, giflib-5.2.1, and Xorg Libraries

Installation of the Java BinaryJDK

Note

The tarball openjdk-17.0.2_linux-x64_bin.tar.gz will untar to the jdk-17.0.2 directory.

Begin by extracting the appropriate binary tarball for your architecture and changing to the extracted directory. Install the binary OpenJDK with the following commands as the root user:

install -vdm755 /opt/OpenJDK-17.0.2-bin &&
mv -v * /opt/OpenJDK-17.0.2-bin         &&
chown -R root:root /opt/OpenJDK-17.0.2-bin

The binary version is now installed. You may create a symlink to that version by issuing, as the root user:

ln -sfn OpenJDK-17.0.2-bin /opt/jdk

You may now proceed to Configuring the JAVA environment, where the instructions assume that the above link exists.

Last updated on

OpenJDK-17.0.2

Introduction to OpenJDK

OpenJDK is an open-source implementation of Oracle's Java Standard Edition platform. OpenJDK is useful for developing Java programs, and provides a complete runtime environment to run Java programs.

This package is known to build and work properly using an LFS-11.1 platform.

OpenJDK is GPL'd code, with a special exception made for non-free projects to use these classes in their proprietary products. In similar fashion to the LGPL, which allows non-free programs to link to libraries provided by free software, the GNU General Public License, version 2, with the Classpath Exception allows third party programs to use classes provided by free software without the requirement that the third party software also be free. As with the LGPL, any modifications made to the free software portions of a third party application, must also be made freely available.

Note

The OpenJDK source includes a very thorough, open source test suite using the JTreg test harness. The testing instructions below allow testing the just built JDK for reasonable compatibility with the proprietary Oracle JDK. However, in order for an independent implementation to claim compatibility, it must pass a proprietary JCK/TCK test suite. No claims of compatibility, or even partial compatibility, may be made without passing an approved test suite.

Oracle does provide free community access, on a case by case basis, to a closed toolkit to ensure 100% compatibility with its proprietary JDK. Neither the binary version provided on the Java-17.0.2 page nor the JVM built with the instructions below have been tested against the TCK. Any version that is built using the instructions given, cannot claim to be compatible with the proprietary JDK, without the user applying for, and completing the compatibility tests themselves.

With that in mind, the binaries produced using this build method are regularly tested against the TCK by the members listed on the site above. In addition to the community license above, an educational, non-commercial license for the TCK can be obtained here.

Package Information

Additional Downloads

Optional test harness

OpenJDK Dependencies

Required Dependencies

An existing binary (Java-17.0.2 or an earlier built version of this package. The instructions below assume that you are using Configuring the JAVA environment), alsa-lib-1.2.6.1, cpio-2.13, Cups-2.4.1, UnZip-6.0, Which-2.21, Xorg Libraries, and Zip-3.0

Recommended
Optional

git-2.35.1, Graphviz-2.50.0, Mercurial-6.0.2, pandoc, and pigz

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/openjdk

Installation of OpenJDK

If you have downloaded the optional test harness, unpack it now:

tar -xf ../jtreg-6.1+1.tar.gz

Note

Before proceeding, you should ensure that your environment PATH variable contains the location of the Java compiler used for bootstrapping OpenJDK. This is the only requirement for the environment. Modern Java installations do not need JAVA_HOME and CLASSPATH is not used here. Furthermore, OpenJDK developers recommend unsetting JAVA_HOME.

The build system does not allow the -j switch in MAKEFLAGS. See the command explanation for --with-jobs= for more information on customizing parallelization.

Configure and build the package with the following commands:

unset JAVA_HOME                                       &&
bash configure --enable-unlimited-crypto              \
               --disable-warnings-as-errors           \
               --with-stdc++lib=dynamic               \
               --with-giflib=system                   \
               --with-jtreg=$PWD/jtreg                \
               --with-lcms=system                     \
               --with-libjpeg=system                  \
               --with-libpng=system                   \
               --with-zlib=system                     \
               --with-version-build="8"               \
               --with-version-pre=""                  \
               --with-version-opt=""                  \
               --with-cacerts-file=/etc/pki/tls/java/cacerts &&
make images

To test the results, you will need to execute the jtreg program. You can set the number of concurrent tests by adding the -conc:<X> value in the below command (tests will run sequentially otherwise):

export JT_JAVA=$(echo $PWD/build/*/jdk) &&
jtreg/bin/jtreg -jdk:$JT_JAVA -automatic -ignore:quiet -v1 \
    test/jdk:tier1 test/langtools:tier1 &&
unset JT_JAVA

For more control over the test suite, review the documentation available in jtreg/doc/jtreg/usage.txt. To review the results, see the files JTreport/test_{jdk,langtools}/text/stats.txt and JTreport/test_{jdk,langtools}/text/summary.txt. You should expect to see around 40 failures and 10 errors.

Install the package with the following commands as the root user:

install -vdm755 /opt/jdk-17.0.2+8             &&
cp -Rv build/*/images/jdk/* /opt/jdk-17.0.2+8 &&
chown -R root:root /opt/jdk-17.0.2+8          &&
for s in 16 24 32 48; do
  install -vDm644 src/java.desktop/unix/classes/sun/awt/X11/java-icon${s}.png \
                  /usr/share/icons/hicolor/${s}x${s}/apps/java.png
done

Note

If you only wish to install the Java Runtime Environment, you can substitute build/*/images/jre in the above cp command.

There are now two OpenJDK SDKs installed in /opt. You should decide on which one you would like to use as the default. Normally, you would opt for the just installed OpenJDK. If so, do the following as the root user:

ln -v -nsf jdk-17.0.2+8 /opt/jdk

If desired, you can create .desktop files to add entries in the menu for java and jconsole. The needed icons have already been installed. As the root user:

mkdir -pv /usr/share/applications &&

cat > /usr/share/applications/openjdk-java.desktop << "EOF" &&
[Desktop Entry]
Name=OpenJDK Java 17.0.2 Runtime
Comment=OpenJDK Java 17.0.2 Runtime
Exec=/opt/jdk/bin/java -jar
Terminal=false
Type=Application
Icon=java
MimeType=application/x-java-archive;application/java-archive;application/x-jar;
NoDisplay=true
EOF
cat > /usr/share/applications/openjdk-jconsole.desktop << "EOF"
[Desktop Entry]
Name=OpenJDK Java 17.0.2 Console
Comment=OpenJDK Java 17.0.2 Console
Keywords=java;console;monitoring
Exec=/opt/jdk/bin/jconsole
Terminal=false
Type=Application
Icon=java
Categories=Application;System;
EOF

Command Explanations

bash configure...: the top level configure is a wrapper around the autotools one. It is not executable and must be run through bash.

--enable-unlimited-crypto: Because of limitations on the usage of cryptography in some countries, there is the possibility to limit the size of encryption keys and the use of some algorithms in a policy file. This switch allows to ship a policy file with no restriction. It is the responsibility of the user to ensure proper adherence to the law.

--disable-warnings-as-errors: This switch disables use of -Werror in the build.

--with-stdc++lib=dynamic: This switch forces the build system to link to libstdc++.so (dynamic) instead of libstdc++.a (static).

--with-jobs=<X>: The -j passed to make does not work with make as invoked here. By default, the build system will use the number of CPUs - 1.

--with-jtreg=$PWD/jtreg: This switch tells configure where to find jtreg. Omit if you have not downloaded the optional test suite.

--with-{giflib,lcms,libjpeg,libpng,zlib}=system: These switches force the build system to use the system libraries instead of the bundled versions.

--with-version-build: Currently, the build system does not include the build number in the version string. It has to be specified here.

--with-version-pre: This switch allows you to prefix the version string with a custom string.

--with-version-opt: This switch allows you to add an optional build description to the version string.

--with-cacerts-file=/etc/pki/tls/java/cacerts: Specifies where to find a cacerts file, /etc/pki/tls/java/ on a BLFS system. Otherwise, an empty one is created. You can use the /usr/sbin/make-ca --force command to generate it, once you have installed the Java binaries.

--with-boot-jdk: This switch provides the location of the temporary JDK. It is normally not needed if java is found in the PATH.

Configuring OpenJDK

Configuration Information

Normally, the JAVA environment has been configured after installing the binary version, and can be used with the just built package as well. Review Configuring the JAVA environment in case you want to modify something.

To test if the man pages are correctly installed, issue source /etc/profile and man java to display the respective man page.

Settting up the JRE Certificate Authority Certificates (cacerts) file

If you have run the instructions on the make-ca-1.10 page, you only need to create a symlink in the default location for the cacerts file. As user root:

ln -sfv /etc/pki/tls/java/cacerts /opt/jdk/lib/security/cacerts

To check the installation, issue:

cd /opt/jdk
bin/keytool -list -cacerts

At the prompt Enter keystore password:, enter changeit (the default) or just press the Enter key. If the cacerts file was installed correctly, you will see a list of the certificates with related information for each one. If not, you need to reinstall them.

Contents

Installed Programs: jar, jarsigner, java, javac, javadoc, javap, jcmd, jconsole, jdb, jdeprscan, jdeps, jfr, jhsdb, jimage, jinfo, jlink, jmap, jmod, jpackage, jps, jrunscript, jshell, jstack, jstat, jstatd, keytool, rmiregistry, and serialver
Installed Libraries: /opt/jdk-17.0.2/lib/*
Installed Directory: /opt/jdk-17.0.2

Short Descriptions

jar

combines multiple files into a single jar archive

jarsigner

signs jar files and verifies the signatures and integrity of a signed jar file

java

launches a Java application by starting a Java runtime environment, loading a specified class and invoking its main method

javac

reads class and interface definitions, written in the Java programming language, and compiles them into bytecode class files

javadoc

parses the declarations and documentation comments in a set of Java source files and produces a corresponding set of HTML pages describing the classes, interfaces, constructors, methods, and fields

javap

disassembles a Java class file

jcmd

is a utility to send diagnostic command requests to a running Java Virtual Machine

jconsole

is a graphical console tool to monitor and manage both local and remote Java applications and virtual machines

jdb

is a simple command-line debugger for Java classes

jdeprscan

scans class or jar files for uses of deprecated API elements

jdeps

shows the package-level or class-level dependencies of Java class files

jfr

is a tool for working with Flight Recorder files

jhsdb

is a tool to analyze the content of a core dump from a crashed Java Virtual Machine (JVM)

jimage

is used to list, extract, verify, or get information about modules in jimage format

jinfo

prints Java configuration information for a given Java process, core file, or a remote debug server

jlink

is used to assemble and optimize a set of modules and their dependencies into a custom runtime image

jmap

prints shared object memory maps or heap memory details of a given process, core file, or a remote debug server

jmod

creates JMOD files and lists the content of existing JMOD files

jpackage

generates java application packages and images

jps

lists the instrumented JVMs on the target system

jrunscript

is a command line script shell

jshell

is an interactive tool for learning the Java programming language and prototyping Java code

jstack

prints Java stack traces of Java threads for a given Java process, core file, or a remote debug server

jstat

displays performance statistics for an instrumented JVM

jstatd

is an RMI server application that monitors for the creation and termination of instrumented JVMs

keytool

is a key and certificate management utility

rmiregistry

creates and starts a remote object registry on the specified port on the current host

serialver

returns the serialVersionUID for one or more classes in a form suitable for copying into an evolving class

Last updated on

Configuring the JAVA environment

Setting up the environment

After the package installation is complete, the next step is to make sure that the system can properly find the files. If you set up your login scripts as recommended in The Bash Shell Startup Files, update the environment by creating the openjdk.sh script, as the root user:

cat > /etc/profile.d/openjdk.sh << "EOF"
# Begin /etc/profile.d/openjdk.sh

# Set JAVA_HOME directory
JAVA_HOME=/opt/jdk

# Adjust PATH
pathappend $JAVA_HOME/bin

# Add to MANPATH
pathappend $JAVA_HOME/man MANPATH

# Auto Java CLASSPATH: Copy jar files to, or create symlinks in, the
# /usr/share/java directory. Note that having gcj jars with OpenJDK 8
# may lead to errors.

AUTO_CLASSPATH_DIR=/usr/share/java

pathprepend . CLASSPATH

for dir in `find ${AUTO_CLASSPATH_DIR} -type d 2>/dev/null`; do
    pathappend $dir CLASSPATH
done

for jar in `find ${AUTO_CLASSPATH_DIR} -name "*.jar" 2>/dev/null`; do
    pathappend $jar CLASSPATH
done

export JAVA_HOME
unset AUTO_CLASSPATH_DIR dir jar

# End /etc/profile.d/openjdk.sh
EOF

If Sudo-1.9.9 is installed, the super user should have access to the above variables. Execute the following commands as the root user:

cat > /etc/sudoers.d/java << "EOF"
Defaults env_keep += JAVA_HOME
Defaults env_keep += CLASSPATH
EOF

To use mandb to include the OpenJDK man pages in its database, issue, as the root user:

cat >> /etc/man_db.conf << "EOF" &&
# Begin Java addition
MANDATORY_MANPATH     /opt/jdk/man
MANPATH_MAP           /opt/jdk/bin     /opt/jdk/man
MANDB_MAP             /opt/jdk/man     /var/cache/man/jdk
# End Java addition
EOF

mkdir -p /var/cache/man &&
mandb -c /opt/jdk/man

Setting up the Certificate Authority Certificates for Java

OpenJDK uses its own format for the CA certificates. The Java security modules use $JAVA_HOME/lib/security/cacerts by default. In order to keep all the certificates in one place, we use /etc/ssl/java/cacerts. The instructions on the make-ca-1.10 page previously created the file located in /etc/ssl/java. Setup a symlink in the default location as the root user:

ln -sfv /etc/pki/tls/java/cacerts /opt/jdk/lib/security/cacerts

Use the following command to check if the cacerts file has been successfully installed:

/opt/jdk/bin/keytool -list -cacerts

At the prompt Enter keystore password:, enter changeit (the default) or just press the Enter key. If the cacerts file was installed correctly, you will see a list of the certificates with related information for each one. If not, you need to reinstall them.

If you later install a new JVM, you just have to create the symlink in the default location to be able to use the cacerts.

Last updated on

apache-ant-1.10.12

Introduction to Apache Ant

The Apache Ant package is a Java-based build tool. In theory, it is like the make command, but without make's wrinkles. Ant is different. Instead of a model that is extended with shell-based commands, Ant is extended using Java classes. Instead of writing shell commands, the configuration files are XML-based, calling out a target tree that executes various tasks. Each task is run by an object that implements a particular task interface.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Apache Ant Dependencies

Required

A JDK (Java Binary or OpenJDK-17.0.2) and GLib-2.70.4

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/apache-ant

Installation of Apache Ant

Build a limited bootstrap version of Apache Ant using the following command:

./bootstrap.sh

Download the runtime dependencies using the fetch.xml ant build script:

bootstrap/bin/ant -f fetch.xml -Ddest=optional

Build Apache Ant by running the following command:

./build.sh -Ddist.dir=$PWD/ant-1.10.12 dist

Install, as the root user:

cp -rv ant-1.10.12 /opt/            &&
chown -R root:root /opt/ant-1.10.12 &&
ln -sfv ant-1.10.12 /opt/ant

Command Explanations

bootstrap/bin/ant -f fetch.xml -Ddest=optional: Downloads the missing dependencies to the user's home directory, and copies them into the source tree (in the lib/optional directory, where ant picks them up at build time).

./build.sh -Ddist.dir=$PWD/ant-1.10.12 dist: This command builds, tests, then installs the package into a temporary directory.

Configuring Apache Ant

Config Files

/etc/ant/ant.conf, ~/.ant/ant.conf, and ~/.antrc

Configuration Information

Some packages will require ant to be in the search path and the ANT_HOME environment variable defined. Satisfy these requirements by issuing, as the root user:

cat > /etc/profile.d/ant.sh << EOF
# Begin /etc/profile.d/ant.sh

pathappend /opt/ant/bin
export ANT_HOME=/opt/ant

# End /etc/profile.d/ant.sh
EOF

The above instructions assume you have configured your system as described in The Bash Shell Startup Files.

Contents

Installed Programs: ant, antRun, antRun.pl, complete-ant-cmd.pl, runant.pl, and runant.py
Installed Libraries: Numerous ant*.jar and dependant libraries in $ANT_HOME/lib
Installed Directories: /opt/ant-1.10.12

Short Descriptions

ant

is a Java based build tool used by many packages instead of the conventional make program

antRun

is a support script used to start ant build scripts in a given directory

antRun.pl

is a Perl script that provides similar functionality offered by the antRun script

complete-ant-cmd.pl

is a Perl script that allows Bash to complete an ant command-line

runant.pl

is a Perl wrapper script used to invoke ant

runant.py

is a Python wrapper script used to invoke ant

ant*.jar

files are the Apache Ant Java class libraries

Last updated on

Part IV. Networking

Chapter 14. Connecting to a Network

The LFS book covers setting up networking by connecting to a LAN with a static IP address. There are other methods used to obtain an IP address and connect to a LAN and other networks (such as the Internet). The most popular methods (DHCP and PPP) are covered in this chapter.

DHCP stands for Dynamic Host Configuration Protocol. It is a protocol used by many sites to automatically provide information such as IP addresses, subnet masks and routing information to computers. If your network uses DHCP, you will need a DHCP client in order to connect to it.

dhcpcd-9.4.1

Introduction to dhcpcd

dhcpcd is an implementation of the DHCP client specified in RFC2131. A DHCP client is useful for connecting your computer to a network which uses DHCP to assign network addresses. dhcpcd strives to be a fully featured, yet very lightweight DHCP client.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

dhcpcd Dependencies

Optional

LLVM-13.0.1 (with Clang), ntp-4.2.8p15, chronyd, and ypbind

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/dhcpcd

Installation of dhcpcd

Recent releases of dhcpcd implement privilege separation. Additional installation steps are necessary to set up the proper environment, which are performed by issuing the following commands as the root user:

install  -v -m700 -d /var/lib/dhcpcd &&

groupadd -g 52 dhcpcd        &&
useradd  -c 'dhcpcd PrivSep' \
         -d /var/lib/dhcpcd  \
         -g dhcpcd           \
         -s /bin/false     \
         -u 52 dhcpcd &&
chown    -v dhcpcd:dhcpcd /var/lib/dhcpcd 

Install dhcpcd by running the following commands:

./configure --prefix=/usr                \
            --sysconfdir=/etc            \
            --libexecdir=/usr/lib/dhcpcd \
            --dbdir=/var/lib/dhcpcd      \
            --runstatedir=/run           \
            --privsepuser=dhcpcd         &&
make

To test the results, issue: make test.

Now, as the root user:

make install

Command Explanations

--libexecdir=/usr/lib/dhcpcd: Set a more proper location for dhcpcd internal libraries.

--dbdir=/var/lib/dhcpcd: The default /var/db is not FHS-compliant

--runstatedir=/run: The default /var/run is a symbolic link to /run.

--with-hook=...: You can optionally install more hooks, for example to install some configuration files such as ntp.conf. The set of hooks is in the dhcpcd-hooks directory in the build tree.

Configuring dhcpcd

Config Files

/etc/dhcpcd.conf

General Configuration Information

To configure dhcpcd, you need to first install the network service script, /usr/lib/services/dhcpcd included in the blfs-bootscripts-20210826 package (as user root):

make install-service-dhcpcd

Note

the network service script /usr/lib/services/dhcpcd contained in bootscripts up to blfs-bootscripts-20191204 is not compatible with latest dhcpcd, as the location of the pidfile changed. To work around this, issue the following command:

sed -i "s;/run/dhcpcd-;/run/dhcpcd/;g" /lib/services/dhcpcd

Note

The default for dhcpcd is to set the hostname and mtu. It also overwrites /etc/resolv.conf and /etc/ntp.conf. These modifications to system files are done by hooks which are stored in /usr/lib/dhcpcd/dhcpcd-hooks. Setup dhcpcd by removing or adding hooks from/to that directory. The execution of hooks can be disabled by using the --nohook (-C) command line option or by the nohook option in the /etc/dhcpcd.conf file.

Finally, as the root user create the /etc/sysconfig/ifconfig.eth0 configuration file using the following commands. Adjust appropriately for additional interfaces:

cat > /etc/sysconfig/ifconfig.eth0 << "EOF"
ONBOOT="yes"
IFACE="eth0"
SERVICE="dhcpcd"
DHCP_START="-b -q <insert appropriate start options here>"
DHCP_STOP="-k <insert additional stop options here>"
EOF

For more information on the appropriate DHCP_START and DHCP_STOP values, examine the man page for dhcpcd.

Configuration Information: fixed ip

Although not usual, it is possible that you need to configure dhcpcd to use a fixed ip. Here, we give an example. As the root user create the /etc/sysconfig/ifconfig.eth0 configuration file using the following commands. Adjust appropriately for additional interfaces and for the actual ip and router you need:

cat > /etc/sysconfig/ifconfig.eth0 << "EOF"
ONBOOT="yes"
IFACE="eth0"
SERVICE="dhcpcd"
DHCP_START="-b -q -S ip_address=192.168.0.10/24 -S routers=192.168.0.1"
DHCP_STOP="-k"
EOF

You can either use DNS servers in /etc/resolv.conf from another system, your preferred servers, or just the example /etc/resolv.conf.head file below as is:

cat > /etc/resolv.conf.head << "EOF"
# OpenDNS servers
nameserver 208.67.222.222
nameserver 208.67.220.220
EOF

Contents

Installed Program: dhcpcd
Installed Library: /usr/lib/dhcpcd/dev/udev.so
Installed Directory: /{usr,var}/lib/dhcpcd and /usr/share/dhcpcd

Short Descriptions

dhcpcd

is an implementation of the DHCP client specified in RFC2131

udev.so

adds udev support for interface arrival and departure; this is because udev likes to rename the interface, which it can't do if dhcpcd grabs it first

Last updated on

DHCP-4.4.2-P1

Introduction to ISC DHCP

The ISC DHCP package contains both the client and server programs for DHCP. dhclient (the client) is used for connecting to a network which uses DHCP to assign network addresses. dhcpd (the server) is used for assigning network addresses on private networks.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/dhcp

Kernel Configuration

You must have Packet Socket support. IPv6 support is optional.

[*] Networking support --->        [CONFIG_NET]
      Networking options --->
        <*> Packet socket          [CONFIG_PACKET]
        <*> The IPv6 Protocol ---> [CONFIG_IPV6]

Installation of ISC DHCP

First, fix a build issue with GCC 10 and later:

sed -i '/o.*dhcp_type/d' server/mdb.c &&
sed -r '/u.*(local|remote)_port/d'    \
    -i client/dhclient.c              \
       relay/dhcrelay.c

Note

This package does not support parallel build.

Note

Be careful with the instructions below. The single and double quotes are important because the defined variables are used verbatim in the code.

Install ISC DHCP by running the following commands:

( export CFLAGS="${CFLAGS:--g -O2} -Wall -fno-strict-aliasing                 \
        -D_PATH_DHCLIENT_SCRIPT='\"/usr/sbin/dhclient-script\"'     \
        -D_PATH_DHCPD_CONF='\"/etc/dhcp/dhcpd.conf\"'               \
        -D_PATH_DHCLIENT_CONF='\"/etc/dhcp/dhclient.conf\"'"        &&

./configure --prefix=/usr                                           \
            --sysconfdir=/etc/dhcp                                  \
            --localstatedir=/var                                    \
            --with-srv-lease-file=/var/lib/dhcpd/dhcpd.leases       \
            --with-srv6-lease-file=/var/lib/dhcpd/dhcpd6.leases     \
            --with-cli-lease-file=/var/lib/dhclient/dhclient.leases \
            --with-cli6-lease-file=/var/lib/dhclient/dhclient6.leases
) &&
make -j1

This package does not come with a test suite.

If you only want to install the ISC DHCP client, issue the following commands as the root user:

make -C client install             &&
install -v -m755 client/scripts/linux /usr/sbin/dhclient-script

Skip to the section called “Client Configuration” in order to configure the client

If you only want to install the ISC DHCP server, issue the following command as the root user:

make -C server install

Skip to the section called “Server Configuration” in order to configure the server.

Alternatively, you can install whole package which includes the client, server, relay, static libraries and development headers by running the following commands as the root user:

make install &&
install -v -m755 client/scripts/linux /usr/sbin/dhclient-script

Configuring ISC DHCP

Config Files

/etc/dhcp/dhclient.conf and /etc/dhcp/dhcpd.conf

Client Configuration

Create a basic /etc/dhcp/dhclient.conf by running the following command as the root user:

install -vdm755 /etc/dhcp &&
cat > /etc/dhcp/dhclient.conf << "EOF"
# Begin /etc/dhcp/dhclient.conf
#
# Basic dhclient.conf(5)

#prepend domain-name-servers 127.0.0.1;
request subnet-mask, broadcast-address, time-offset, routers,
        domain-name, domain-name-servers, domain-search, host-name,
        netbios-name-servers, netbios-scope, interface-mtu,
        ntp-servers;
require subnet-mask, domain-name-servers;
#timeout 60;
#retry 60;
#reboot 10;
#select-timeout 5;
#initial-interval 2;

# End /etc/dhcp/dhclient.conf
EOF

See man 5 dhclient.conf for additional options.

Now create the /var/lib/dhclient directory which will contain DHCP Client leases by running the following command as the root user:

install -v -dm 755 /var/lib/dhclient

At this point you can test if dhclient is behaving as expected by running the following command as the root user:

dhclient <eth0>

Replace <eth0> with your desired interface. If you want more verbose output, add the -v parameter to the command above.

If you want to configure network interfaces at boot using dhclient, you need to install the /lib/services/dhclient script included in blfs-bootscripts-20210826 package:

make install-service-dhclient

Next, create the /etc/sysconfig/ifconfig.eth0 configuration file with the following commands as the root user:

cat > /etc/sysconfig/ifconfig.eth0 << "EOF"
ONBOOT="yes"
IFACE="eth0"
SERVICE="dhclient"
DHCP_START=""
DHCP_STOP=""

# Set PRINTIP="yes" to have the script print
# the DHCP assigned IP address
PRINTIP="no"

# Set PRINTALL="yes" to print the DHCP assigned values for
# IP, SM, DG, and 1st NS. This requires PRINTIP="yes".
PRINTALL="no"
EOF

Adjust the file to suit your needs.

For more information on the appropriate DHCP_START and DHCP_STOP values see man 8 dhclient.

Server Configuration

Note that you only need the DHCP server if you want to issue LAN addresses over your network. The DHCP client doesn't need the server in order to function properly.

Start with creating /etc/dhcp/dhcpd.conf by running the following command as the root user:

cat > /etc/dhcp/dhcpd.conf << "EOF"
# Begin /etc/dhcp/dhcpd.conf
#
# Example dhcpd.conf(5)

# Use this to enable / disable dynamic dns updates globally.
ddns-update-style none;

# option definitions common to all supported networks...
option domain-name "example.org";
option domain-name-servers ns1.example.org, ns2.example.org;

default-lease-time 600;
max-lease-time 7200;

# This is a very basic subnet declaration.
subnet 10.254.239.0 netmask 255.255.255.224 {
  range 10.254.239.10 10.254.239.20;
  option routers rtr-239-0-1.example.org, rtr-239-0-2.example.org;
}

# End /etc/dhcp/dhcpd.conf
EOF

Adjust the file to suit your needs. See man 5 dhcpd.conf for additional options.

Now create the /var/lib/dhcpd directory which will contain DHCP Server leases by running the following command as the root user:

install -v -dm 755 /var/lib/dhcpd

If you want to start the DHCP Server at boot, install the /etc/rc.d/init.d/dhcpd inti script included in the blfs-bootscripts-20210826 package:

make install-dhcpd

You will need to edit the /etc/sysconfig/dhcpd in order to set the interface on which dhcpd will serve the DHCP requests.

Contents

Installed Programs: dhclient, dhclient-script, dhcpd, dhcrelay and omshell
Installed Libraries: libdhcpctl.a and libomapi.a
Installed Directories: /etc/dhcp, /usr/include/dhcpctl, /usr/include/isc-dhcp, /usr/include/omapip, /var/lib/dhclient and /var/lib/dhcpd

Short Descriptions

dhclient

is the implementation of the DHCP client

dhclient-script

is used by dhclient to (re)configure interfaces. It can make extra changes by invoking custom dhclient-{entry,exit}-hooks

dhcpd

implements Dynamic Host Configuration Protocol (DHCP) and Internet Bootstrap Protocol (BOOTP) requests for network addresses

dhcrelay

provides a means to accept DHCP and BOOTP requests on a subnet without a DHCP server and relay them to a DHCP server on another subnet

omshell

provides an interactive way to connect to, query and possibly change the ISC DHCP Server's state via OMAPI, the Object Management API

Last updated on

Chapter 15. Networking Programs

These applications are generally client applications used to access the appropriate server across the building or across the world. Tcpwrappers and portmap are support programs for daemons that you may have running on your machine.

bridge-utils-1.7.1

Introduction to bridge-utils

The bridge-utils package contains a utility needed to create and manage bridge devices. This is useful in setting up networks for a hosted virtual machine (VM).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

bridge-utils Dependencies

Optional (to run tests)

Net-tools-2.10

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/bridge

Kernel Configuration

Enable the following options in the kernel configuration and recompile the kernel if necessary:

[*] Networking support --->            [CONFIG_NET]
      Networking options --->
        <*/M> 802.1d Ethernet Bridging [CONFIG_BRIDGE]

Installation of bridge-utils

Install bridge-utils by running the following commands:

autoconf                  &&
./configure --prefix=/usr &&
make

Testing the results requires running the six shell scripts in the tools/ directory. Two of the tests require two ethernet ports. Some tests will not preserve the current network configuration. See tests/README for details.

Now, as the root user:

make install

Configuring bridge-utils

Configuration Information

To automate bridge creation and configuration, install the /usr/lib/services/bridge service script included in the blfs-bootscripts-20210826 package.

make install-service-bridge

Note

The bridge script depends on the commands /sbin/ifup and /sbin/ifdown and the service script ipv4-static from the LFS bootscripts dated January 27, 2012 or later.

The following configuration file will create a bridge device at boot time and attach the eth0 device to it. If more than one device is desired, use a space separated list of INTERFACE_COMPONENTS. This configuration is useful when planning to run a virtual machine such as kvm/qemu.

Other SERVICE combinations are possible, for example, SERVICE="bridge dhcp". In that case, the address parameters are not needed, but do not interfere if present. The bridge service may also be used alone, but will require additional subsequent configuration.

Caution

Do not run a parallel configuration for a device in the INTERFACE_COMPONENTS list. For instance, in the example below, do not configure /etc/sysconfig/ifconfig.eth0 to run at boot time. The command ifdown br0 followed by command ifup eth0 will work, but don't try to have both up at the same time.

cat > /etc/sysconfig/ifconfig.br0 << "EOF"
ONBOOT=yes
IFACE=br0
VIRTINT=yes
SERVICE="bridge ipv4-static"  # Space separated
IP=192.168.1.32
GATEWAY=192.168.1.1
PREFIX=24
BROADCAST=192.168.1.255
CHECK_LINK=no                 # Don't check before bridge is created
STP=no                        # Spanning tree protocol, default no
INTERFACE_COMPONENTS="eth0"   # Add to IFACE, space separated devices
IP_FORWARD=true
EOF

All addresses should be changed to meet your circumstance.

Contents

Installed Program: brctl
Installed Libraries: None
Installed Directories: None

Short Descriptions

brctl

is a program used to set up, maintain, and inspect the ethernet bridge configuration in the linux kernel

Last updated on

cifs-utils-6.14

Introduction to cifs-utils

The cifs-utils package provides a means for mounting SMB/CIFS shares on a Linux system.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

cifs-utils Dependencies

Required

Talloc-2.3.3

Optional

keyutils-1.6.1 (required to build PAM module), Linux-PAM-1.5.2, MIT Kerberos V5-1.19.2, Samba-4.15.5, and libcap-2.63 with PAM or libcap-ng

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/cifsutils

Kernel Configuration

Enable the following options in the kernel configuration and recompile the kernel if necessary:

File systems  --->
  [*] Network File Systems  --->                              [CONFIG_NETWORK_FILESYSTEMS]
    <*/M> SMB3 and CIFS support (advanced network filesystem) [CONFIG_CIFS]

Depending on your server configuration, additional kernel options may be required.

Installation of cifs-utils

Install cifs-utils by running the following commands:

./configure --prefix=/usr \
            --disable-pam \
            --disable-systemd &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-pam: Do not build PAM support. Remove it and use --with-pamdir (see below), if Linux-PAM-1.5.2 is installed and you wish PAM support.

--disable-systemd: Disable systemd specific behavior for mount.cifs.

--with-pamdir=/usr/lib/security: Install the PAM module in /usr/lib/security.

Contents

Installed Programs: cifs.idmap, cifs.upcall, cifscreds, getcifsacl, mount.cifs, mount.smb3, setcifsacl, smb2-quota, and smbinfo
Installed Library: /usr/lib/cifs-utils/idmapwb.so and optionally PAM module /usr/lib/security/pam_cifscreds.so
Installed Directory: /usr/lib/cifs-utils

Short Descriptions

cifs.idmap

is a userspace helper program for the linux CIFS client filesystem. There are a number of activities that the kernel cannot easily do itself. This program is a callout program that does these things for the kernel and then returns the result. It is not intended to be run from the command-line

cifs.upcall

is a userspace helper program for the linux CIFS client filesystem. It is intended to be run when the kernel calls request-key for a particular key type. It is not intended to be run from the command-line

cifscreds

is a tool for managing credentials (username and password) for the purpose of establishing sessions in multiuser mounts

getcifsacl

is a userspace helper to display an ACL in a security descriptor for Common Internet File System (CIFS)

mount.cifs

mounts a Linux CIFS filesystem. It is usually invoked indirectly by the mount(8) command when using the "-t cifs" option

mount.smb3

mounts a SMB3-based filesystem. It is usually invoked indirectly by the mount(8) command when using the "-t smb3" option

setcifsacl

is intended to alter an ACL of a security descriptor for a file system object

smb3-quota

displays quota information for a SMB filesystem

smbinfo

displays SMB-specific file information, such as security descriptors and quotas

Last updated on

iw-5.16

Introduction to iw

iw is a new nl80211 based CLI configuration utility for wireless devices. It supports all new drivers that have been added to the kernel recently. The old tool iwconfig, which uses Wireless Extensions interface, is deprecated and it's strongly recommended to switch to iw and nl80211.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

iw Dependencies

Required

libnl-3.5.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/iw

Kernel Configuration

To use iw, the kernel must have the appropriate drivers and other support available. The appropriate bus must also be available. For older laptops, the PCMCIA bus (CONFIG_PCCARD) needs to be built. In some cases, this bus support will also need to be built for embedded iw cards. The appropriate bridge support also needs to be built. For many modern laptops, the CardBus host bridge (CONFIG_YENTA) will be needed.

In addition to the bus, the actual driver for the specific wireless card must also be available. There are many wireless cards and they don't all work with Linux. The first place to look for card support is the kernel. The drivers are located in Device Drivers → Network Device Support → Wireless LAN (non-hamradio). There are also external drivers available for some very common cards. For more information, look at the user notes.

After the correct drivers are loaded, the interface will appear in /proc/net/wireless.

Installation of iw

To install iw, use the following commands:

sed -i "/INSTALL.*gz/s/.gz//" Makefile &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

sed ...: Install uncompressed manual pages in accordance with other man pages.

Contents

Installed Programs: iw
Installed Libraries: None
Installed Directories: None

Short Descriptions

iw

shows / manipulates wireless devices and their configuration

Last updated on

NcFTP-3.2.6

Introduction to NcFTP

The NcFTP package contains a powerful and flexible interface to the Internet standard File Transfer Protocol. It is intended to replace or supplement the stock ftp program.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

NcFTP Dependencies

Optional

LLVM-13.0.1 (with Clang, used by default if installed)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/ncftp

Installation of NcFTP

There are two ways to build NcFTP. The first (and optimal) way builds most of the functionality as a shared library and then builds and installs the program linked against this library. The second method simply links all of the functionality into the binary statically. This doesn't make the dynamic library available for linking by other applications. You need to choose which method best suits you. Note that the second method does not create an entirely statically linked binary; only the libncftp parts are statically linked in, in this case. Be aware that building and using the shared library is covered by the Clarified Artistic License; however, developing applications that utilize the shared library is subject to a different license.

First, fix an issue caused by a change in behavior in GCC-10:

sed -i 's/^Bookmark/extern Bookmark/' sh_util/gpshare.c

To install NcFTP using the first (and optimal) method, run the following commands:

./configure --prefix=/usr --sysconfdir=/etc &&
make -C libncftp shared &&
make

This package does not come with a test suite.

Now, as the root user:

make -C libncftp soinstall &&
make install

To install NcFTP using the second method (with the libncftp functionality linked in statically) run the following commands:

./configure --prefix=/usr --sysconfdir=/etc &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

make -C ... && make -C ...: These commands make and install the dynamic library libncftp which is then used to link against when compiling the main program.

Configuring NcFTP

Config Files

/etc/ncftp.* and ~/.ncftp/*; especially /etc/ncftp.prefs_v3 and ~/.ncftp/prefs_v3

Configuration Information

Most NcFTP configuration is done while in the program, and the configuration files are dealt with automatically. One exception to this is ~/.ncftp/prefs_v3. There are various options to alter in there, including:

yes-i-know-about-NcFTPd=yes

This disables the splash screen advertising the NcFTPd server.

There are other options in the prefs_v3 file. Most of these are self-explanatory. Global defaults can be set in /etc/ncftp.prefs_v3.

Contents

Installed Programs: ncftp, ncftpbatch, ncftpbookmarks, ncftpget, ncftpls, ncftpput, and ncftpspooler
Installed Library: libncftp.so
Installed Directories: None

Short Descriptions

ncftp

is a browser program for File Transfer Protocol

ncftpbatch

is an individual batch FTP job processor

ncftpbookmarks

is the NcFTP Bookmark Editor (NCurses-based)

ncftpget

is an internet file transfer program for scripts used to retrieve files

ncftpls

is an internet file transfer program for scripts used to list files

ncftpput

is an internet file transfer program for scripts used to transfer files

ncftpspooler

is a global batch FTP job processor daemon

Last updated on

Net-tools-2.10

Introduction to Net-tools

The Net-tools package is a collection of programs for controlling the network subsystem of the Linux kernel.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/net-tools

Installation of Net-tools

The instructions below automate the configuration process by piping yes to the make command. If you wish to run the interactive configuration process (by changing the instruction to just make), but you are not sure how to answer all the questions, then just accept the defaults. This will be just fine in the majority of cases. What you're asked here is a bunch of questions about which network protocols you've enabled in your kernel. The default answers will enable the tools from this package to work with the most common protocols: TCP, PPP, and several others. You still need to actually enable these protocols in the kernel—what you do here is merely tell the package to include support for those protocols in its programs, but it's up to the kernel to make the protocols available.

Note

This package has several unneeded protocols and hardware device specific functions that are obsolete. To only build the minimum needed for your system, skip the yes command and answer each question interactively. The minimum needed options are 'UNIX protocol family' and 'INET (TCP/IP) protocol family'.

For this package, we use the DESTDIR method of installation in order to easily remove files from the build that overwrite those that we want to keep or are not appropriate for our system.

Install Net-tools by running the following commands:

export BINDIR='/usr/bin' SBINDIR='/usr/bin' &&
yes "" | make -j1                           &&
make DESTDIR=$PWD/install -j1 install       &&
rm    install/usr/bin/{nis,yp}domainname    &&
rm    install/usr/bin/{hostname,dnsdomainname,domainname,ifconfig} &&
rm -r install/usr/share/man/man1            &&
rm    install/usr/share/man/man8/ifconfig.8 &&
unset BINDIR SBINDIR

This package does not come with a test suite.

Now, as the root user:

chown -R root:root install &&
cp -a install/* /

Command Explanations

export BINDIR='/usr/bin' SBINDIR='/usr/bin': Ensure the executables are installed in the correct location.

yes "" | make : Piping yes to make config skips the interactive configuration and accepts the defaults.

rm ...: Remove unneeded programs and man pages.

Contents

Installed Programs: arp, ipmaddr, iptunnel, mii-tool, nameif, netstat, plipconfig, rarp, route, and slattach
Installed Libraries: None
Installed Directories: None

Short Descriptions

arp

is used to manipulate the kernel's ARP cache, usually to add or delete an entry, or to dump the entire cache

ipmaddr

adds, deletes and shows an interface's multicast addresses

iptunnel

adds, changes, deletes and shows an interface's tunnels

mii-tool

checks or sets the status of a network interface's Media Independent Interface (MII) unit

nameif

names network interfaces based on MAC addresses

netstat

is used to report network connections, routing tables, and interface statistics

plipconfig

is used to fine tune the PLIP device parameters, to improve its performance

rarp

is used to manipulate the kernel's RARP table

route

is used to manipulate the IP routing table

slattach

attaches a network interface to a serial line. This allows you to use normal terminal lines for point-to-point links to others computers

Last updated on

NFS-Utils-2.6.1

Introduction to NFS Utilities

The NFS Utilities package contains the userspace server and client tools necessary to use the kernel's NFS abilities. NFS is a protocol that allows sharing file systems over the network.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

NFS Utilities Dependencies

Required

libtirpc-1.3.2 and rpcsvc-proto-1.4.3

Optional

Cyrus SASL-2.1.27 (for SASL authentication), LVM2-2.03.15 (libdevmapper for NFSv4 support), libnsl-2.0.0 (for NIS client support), OpenLDAP-2.6.1 (for LDAP authentication), SQLite-3.37.2, MIT Kerberos V5-1.19.2 or libgssapi , and librpcsecgss (for GSS and RPC security support), and libcap-2.63 with PAM

Required (runtime)

rpcbind-1.2.6

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/nfs-utils

Kernel Configuration

Enable the following options in the kernel configuration (choose client and/or server support as appropriate) and recompile the kernel if necessary:

File systems  --->
  [*] Network File Systems  --->         [CONFIG_NETWORK_FILESYSTEMS]
    <*/M> NFS client support             [CONFIG_NFS_FS]
    <*/M> NFS server support             [CONFIG_NFSD]

Select the appropriate sub-options that appear when the above options are selected.

Note

In BLFS we assume that nfs v3 will be used. If the server offers nfs v4 (for linux, CONFIG_NFSD_V4) then auto-negotiation for v3 will fail and you will need to add nfsver=3 to the mount options. This also applies if that option is enabled in the client's kernel, for example in a distro trying to mount from a BLFS v3 server.

Even if neither end of the connection supports nfs v4, adding nfsver=3 is still beneficial because it prevents an error message "NFS: bad mount option value specified: minorversion=1" being logged on every mount.

Installation of NFS Utilities

Before you compile the program, ensure that the nobody user and nogroup group have been created as done in the current LFS book. You can add them by running the following commands as the root user:

groupadd -g 99 nogroup &&
useradd -c "Unprivileged Nobody" -d /dev/null -g nogroup \
    -s /bin/false -u 99 nobody

Note

The classic uid and gid values are 65534 which is also -2 when interpreted as a signed 16-bit number. These values impact other files on some filesystems that do not have support for sparse files. The nobody and nogroup values are relatively arbitrary. The impact on a server is nil if the exports file is configured correctly. If it is misconfigured, an ls -l or ps listing will show a uid or gid number of 65534 instead of a name. The client uses nobody only as the user running rpc.statd.

Install NFS Utilities by running the following commands:

./configure --prefix=/usr          \
            --sysconfdir=/etc      \
            --sbindir=/usr/sbin    \
            --disable-nfsv4        \
            --disable-gss &&
make

This package does not come with a working test suite.

Now, as the root user:

make install                      &&
chmod u+w,go+r /usr/sbin/mount.nfs    &&
chown nobody.nogroup /var/lib/nfs

Command Explanations

--disable-gss: Disables support for RPCSEC GSS (RPC Security).

chown nobody.nogroup /var/lib/nfs: The rpc.statd program uses the ownership of this directory to set it's UID and GID. This command sets those to unprivileged entries.

Configuring NFS Utilities

Server Configuration

/etc/exports contains the exported directories on NFS servers. Refer to the exports.5 manual page for the syntax of this file. Also refer to the "NFS HowTo" available at http://nfs.sourceforge.net/nfs-howto/ for information on how to configure the servers and clients in a secure manner. For example, for sharing the /home directory over the local network, the following line may be added:

cat >> /etc/exports << EOF
/home 192.168.0.0/24(rw,subtree_check,anonuid=99,anongid=99)
EOF

Note

Be sure to replace the directory, network address. and prefix above to match your network. The only space in the line above should be between the directory and the network address.

Boot Script

Install the /etc/rc.d/init.d/nfs-server init script included in the blfs-bootscripts-20210826 package to start the server at boot.

make install-nfs-server

Now create the /etc/sysconfig/nfs-server configuration file:

cat > /etc/sysconfig/nfs-server << "EOF"
PORT="2049"
PROCESSES="8"
KILLDELAY="10"
EOF

Note

The above parameters may be optionally placed in /etc/sysconfig/rc.site.

Client Configuration

/etc/fstab contains the directories that are to be mounted on the client. Alternately the partitions can be mounted by using the mount command with the proper options. To mount the /home and /usr partitions, add the following to the /etc/fstab:

<server-name>:/home  /home nfs   rw,_netdev 0 0
<server-name>:/usr   /usr  nfs   ro,_netdev 0 0

The options which can be used are specified in man 5 nfs . If both the client and server are running recent versions of linux, most of the options will be negotiated (but see the Note above on nfsver=3). You can specify either rw or ro, _netdev if the filesystem is to be automatically mounted at boot, or noauto (and perhaps user) for other filesystems.

If the fileserver is not running a recent version of linux, you may need to specify other options.

Boot Script

Note

The following boot script is not required if the nfs-server script is installed.

Install the /etc/rc.d/init.d/nfs-client init script included in the blfs-bootscripts-20210826 package to start the client services at boot.

make install-nfs-client

To automatically mount nfs filesystems, clients will also need to install the netfs bootscript as described in Configuring for Network Filesystems.

Contents

Installed Programs: exportfs, mountstats, mount.nfs, mount.nfs4 (link to mount.nfs), nfsconf, nfsdclnts, nfsiostat, nfsstat, rpc.mountd, rpc.nfsd, rpc.statd, rpcdebug, showmount, sm-notify, start-statd, umount.nfs (link to mount.nfs), and umount.nfs4 (link to mount.nfs)
Installed Libraries: None
Installed Directories: /var/lib/nfs

Short Descriptions

exportfs

maintains a list of NFS exported file systems

mountstats

displays NFS client per-mount statistics

mount.nfs

is used to mount a network share using NFS

mount.nfs4

is used to mount a network share using NFSv4

nfsconf

can be used to test for and retrieve configuration settings from a range of nfs-utils configuration files

nfsdclnts

prints information about NFS clients

nfsiostat

reports input/output statistics for network filesystems

nfsstat

displays statistics kept about NFS client and server activity

rpc.mountd

implements the NFS mount protocol on an NFS server

rpc.nfsd

implements the user level part of the NFS service on the server

rpc.statd

is used by the NFS file locking service. Run on both sides, client as well as server, when you want file locking enabled

rpcdebug

sets or clears the kernel's NFS client and server debug flags

showmount

displays mount information for an NFS server

sm-notify

is used to send Network Status Monitor reboot messages

start-statd

is a script called by nfsmount when mounting a filesystem with locking enabled, if statd does not appear to be running. It can be customised with whatever flags are appropriate for the site

umount.nfs

is used to unmount a network share using NFS

umount.nfs4

is used to unmount a network share using NFSv4

Last updated on

Configuring for Network Filesystems

While LFS is capable of mounting network file systems such as NFS, these are not mounted by the mountfs init script. Network file systems must be mounted after the networking is activated and unmounted before the network goes down. The netfs bootscript was written to handle both boot-time mounting of network filesystems, if the entry in /etc/fstab contains the _netdev option, and unmounting of all network filesystems before the network is brought down.

As the root user, install the /etc/rc.d/init.d/netfs bootscript included with the blfs-bootscripts-20210826 package.

make install-netfs

Last updated on

ntp-4.2.8p15

Introduction to ntp

The ntp package contains a client and server to keep the time synchronized between various computers over a network. This package is the official reference implementation of the NTP protocol.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

ntp Dependencies

Required

IO-Socket-SSL-2.074

Optional

libcap-2.63 with PAM, libevent-2.1.12, libedit, and libopts from AutoGen

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/ntp

Installation of ntp

There should be a dedicated user and group to take control of the ntpd daemon after it is started. Issue the following commands as the root user:

groupadd -g 87 ntp &&
useradd -c "Network Time Protocol" -d /var/lib/ntp -u 87 \
        -g ntp -s /bin/false ntp

The update-leap command needs to be fixed in order to run properly:

sed -e 's/"(\\S+)"/"?([^\\s"]+)"?/' \
    -i scripts/update-leap/update-leap.in

Now fix an issue introduced with glibc-2.34:

sed -e 's/#ifndef __sun/#if !defined(__sun) \&\& !defined(__GLIBC__)/' \
    -i libntp/work_thread.c

Install ntp by running the following commands:

./configure --prefix=/usr         \
            --bindir=/usr/sbin    \
            --sysconfdir=/etc     \
            --enable-linuxcaps    \
            --with-lineeditlibs=readline \
            --docdir=/usr/share/doc/ntp-4.2.8p15 &&
make

To test the results, issue: make check.

Now, as the root user:

make install &&
install -v -o ntp -g ntp -d /var/lib/ntp

Command Explanations

CFLAGS="-O2 -g -fPIC": This environment variable is necessary to generate Position Independent Code needed for use in the package libraries.

--bindir=/usr/sbin: This parameter places the administrative programs in /usr/sbin.

--enable-linuxcaps: ntpd is run as user ntp, so use Linux capabilities for non-root clock control.

--with-lineeditlibs=readline: This switch enables Readline support for ntpdc and ntpq programs. If omitted, libedit will be used if installed, otherwise no readline capabilities will be compiled.

Configuring ntp

Config Files

/etc/ntp.conf

Configuration Information

The following configuration file first defines various ntp servers with open access from different continents. Second, it creates a drift file where ntpd stores the frequency offset and a pid file to store the ntpd process ID. Third, it defines the location for the leap-second definition file /etc/ntp.leapseconds, that the update-leap script checks and updates, when necessary. This script can be run as a cron job and the ntp developers recommend a frequency of about three weeks for the updates. Since the documentation included with the package is sparse, visit the ntp website at http://www.ntp.org/ and http://www.pool.ntp.org/ for more information.

cat > /etc/ntp.conf << "EOF"
# Asia
server 0.asia.pool.ntp.org

# Australia
server 0.oceania.pool.ntp.org

# Europe
server 0.europe.pool.ntp.org

# North America
server 0.north-america.pool.ntp.org

# South America
server 2.south-america.pool.ntp.org

driftfile /var/lib/ntp/ntp.drift
pidfile   /run/ntpd.pid

leapfile  /var/lib/ntp/ntp.leapseconds
EOF

You may wish to add a Security session. For explanations, see https://www.eecis.udel.edu/~mills/ntp/html/accopt.html#restrict.

cat >> /etc/ntp.conf << "EOF"
# Security session
restrict    default limited kod nomodify notrap nopeer noquery
restrict -6 default limited kod nomodify notrap nopeer noquery

restrict 127.0.0.1
restrict ::1
EOF

Synchronizing the Time

There are two options. Option one is to run ntpd continuously and allow it to synchronize the time in a gradual manner. The other option is to run ntpd periodically (using cron) and update the time each time ntpd is scheduled.

If you choose Option one, then install the /etc/rc.d/init.d/ntp init script included in the blfs-bootscripts-20210826 package.

make install-ntpd

If you prefer to run ntpd periodically, add the following command to root's crontab:

ntpd -q

Execute the following command if you would like to set the hardware clock to the current system time at shutdown and reboot:

ln -v -sf ../init.d/setclock /etc/rc.d/rc0.d/K46setclock &&
ln -v -sf ../init.d/setclock /etc/rc.d/rc6.d/K46setclock

The other way around is already set up by LFS.

Contents

Installed Programs: calc_tickadj, ntp-keygen, ntp-wait, ntpd, ntpdate, ntpdc, ntpq, ntptime, ntptrace, sntp, tickadj and update-leap
Installed Libraries: None
Installed Directories: /usr/share/ntp, /usr/share/doc/ntp-4.2.8 and /var/lib/ntp

Short Descriptions

calc_tickadj

calculates optimal value for tick given ntp drift file

ntp-keygen

generates cryptographic data files used by the NTPv4 authentication and identification schemes

ntp-wait

is useful at boot time, to delay the boot sequence until ntpd has set the time

ntpd

is a ntp daemon that runs in the background and keeps the date and time synchronized based on response from configured ntp servers. It also functions as a ntp server

ntpdate

is a client program that sets the date and time based on the response from an ntp server. This command is deprecated

ntpdc

is used to query the ntp daemon about its current state and to request changes in that state

ntpq

is a utility program used to monitor ntpd operations and determine performance

ntptime

reads and displays time-related kernel variables

ntptrace

traces a chain of ntp servers back to the primary source

sntp

is a Simple Network Time Protocol (SNTP) client

tickadj

reads, and optionally modifies, several timekeeping-related variables in older kernels that do not have support for precision timekeeping

update-leap

is a script to verify and, if necessary, update the leap-second definition file

Last updated on

rpcbind-1.2.6

Introduction to rpcbind

The rpcbind program is a replacement for portmap. It is required for import or export of Network File System (NFS) shared directories.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

rpcbind Dependencies

Required

libtirpc-1.3.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/rpcbind

Installation of rpcbind

In order to get rpcbind to work properly, first fix the package to use correct service name:

sed -i "/servname/s:rpcbind:sunrpc:" src/rpcbind.c

Install rpcbind by running the following commands:

patch -Np1 -i ../rpcbind-1.2.6-vulnerability_fixes-1.patch &&

./configure --prefix=/usr                                  \
            --bindir=/usr/sbin                             \
            --with-rpcuser=root                            \
            --enable-warmstarts                            \
            --without-systemdsystemunitdir                 &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--with-rpcuser=root: This works around an error in the configure script.

--without-systemdsystemunitdir: This version of BLFS does not support systemd.

Configuring rpcbind

Boot Script

Install the /etc/rc.d/init.d/rpcbind init script included in the blfs-bootscripts-20210826 package.

make install-rpcbind

Contents

Installed Program: rpcbind and rpcinfo
Installed Libraries: None
Installed Directories: None

Short Descriptions

rpcbind

is a server that converts RPC program numbers into universal addresses. It must be running on the host to be able to make RPC calls on a server on that machine

rpcinfo

makes an RPC call to an RPC server and reports data according to the requested options

Last updated on

rsync-3.2.3

Introduction to rsync

The rsync package contains the rsync utility. This is useful for synchronizing large file archives over a network.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://www.samba.org/ftp/rsync/src/rsync-3.2.3.tar.gz

  • Download MD5 sum: 209f8326f5137d8817a6276d9577a2f1

  • Download size: 1.0 MB

  • Estimated disk space required: 10 MB (with tests - additional 47 MB for HTML API documentation)

  • Estimated build time: 0.7 SBU (with tests)

rsync Dependencies

Recommended
Optional

Doxygen-1.9.3, lz4, and xxhash

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/rsync

Installation of rsync

For security reasons, running the rsync server as an unprivileged user and group is encouraged. If you intend to run rsync as a daemon, create the rsyncd user and group with the following commands issued by the root user:

groupadd -g 48 rsyncd &&
useradd -c "rsyncd Daemon" -m -d /home/rsync -g rsyncd \
    -s /bin/false -u 48 rsyncd

Install rsync by running the following commands:

./configure --prefix=/usr    \
            --disable-lz4    \
            --disable-xxhash \
            --without-included-zlib &&
make

If you have Doxygen-1.9.3 installed and wish to build HTML API documentation, issue:

doxygen

To test the results, issue: make check.

Now, as the root user:

make install

If you built the documentation, install it using the following commands as the root user:

install -v -m755 -d          /usr/share/doc/rsync-3.2.3/api &&
install -v -m644 dox/html/*  /usr/share/doc/rsync-3.2.3/api

Command Explanations

--disable-lz4: This switch disables LZ4 compression support. Note that it uses the superior 'zstd' algorithm when this switch is in use, and zstd is provided in LFS.

--disable-xxhash: This switch disables advanced xxhash checksum support. Remove this switch if you have installed xxhash.

--without-included-zlib: This switch enables compilation with the system-installed zlib library.

Configuring rsync

Config Files

/etc/rsyncd.conf

Configuration Information

For client access to remote files, you may need to install the OpenSSH-8.8p1 package to connect to the remote server.

This is a simple download-only configuration to set up running rsync as a server. See the rsyncd.conf(5) man-page for additional options (i.e., user authentication).

cat > /etc/rsyncd.conf << "EOF"
# This is a basic rsync configuration file
# It exports a single module without user authentication.

motd file = /home/rsync/welcome.msg
use chroot = yes

[localhost]
    path = /home/rsync
    comment = Default rsync module
    read only = yes
    list = yes
    uid = rsyncd
    gid = rsyncd

EOF

You can find additional configuration information and general documentation about rsync at https://rsync.samba.org/documentation.html.

Boot Script

Note that you only need to start the rsync server if you want to provide an rsync archive on your local machine. You don't need this script to run the rsync client.

Install the /etc/rc.d/init.d/rsyncd init script included in the blfs-bootscripts-20210826 package.

make install-rsyncd

Contents

Installed Program: rsync and rsync-ssl
Installed Libraries: None
Installed Directories: Optionally, /usr/share/doc/rsync-3.2.3

Short Descriptions

rsync

is a replacement for rcp (and scp) that has many more features. It uses the rsync algorithm which provides a very fast method of syncing remote files. It does this by sending just the differences in the files across the link, without requiring that both sets of files are present at one end of the link beforehand

rsync-ssl

is a helper script used when connecting to an rsync daemon that has SSL support built in

Last updated on

Samba-4.15.5

Introduction to Samba

The Samba package provides file and print services to SMB/CIFS clients and Windows networking to Linux clients. Samba can also be configured as a Windows Domain Controller replacement, a file/print server acting as a member of a Windows Active Directory domain and a NetBIOS (rfc1001/1002) nameserver (which among other things provides LAN browsing support).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Samba Dependencies

Required

GnuTLS-3.7.3, jansson-2.14, libtirpc-1.3.2, lmdb-0.9.29, and rpcsvc-proto-1.4.3

Recommended
Optional

Avahi-0.8, BIND-9.18.0, Cups-2.4.1, Cyrus SASL-2.1.27, GDB-11.2, git-2.35.1, GnuPG-2.2.34 (required for ADS and testsuite), libaio-0.3.112, libarchive-3.6.0, libcap-2.63 with PAM, libgcrypt-1.10.0, libnsl-2.0.0, MIT Kerberos V5-1.19.2, nss-3.75, popt-1.18, Talloc-2.3.3 (included), Vala-0.54.7, Valgrind-3.18.1 (optionally used by the test suite), xfsprogs-5.14.2, cmocka, cryptography, ctdb (included), cwrap, dnspython, FAM, Gamin, GlusterFS, Heimdal (included), iso8601, libunwind, ldb (included), M2Crypto (required for ADS), OpenAFS, pyasn1, PyGPGME (recommended for ADS), tevent (included), tdb (included), and tracker-2

Optional (for the Developer Test Suite)

Install in listed order: six-1.16.0, argparse, extras, py, hypothesis, pytest, coverage, pytest-cov, doctools, unittest2, testtools, fixtures, python-mimeparse, contextlib2, traceback2, linecache2, testscenarios, testresources, virtualenv, pbr, and python-subunit

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/samba4

Installation of Samba

To support the test suite, set up a Python virtual environment for some Python modules out of the scope of BLFS:

python3 -m venv pyvenv &&
./pyvenv/bin/pip3 install cryptography pyasn1 iso8601

Fix a test that always fails:

echo "^samba4.rpc.echo.*on.*ncacn_np.*with.*object.*nt4_dc" >> selftest/knownfail

Install Samba by running the following commands:

PYTHON=$PWD/pyvenv/bin/python3             \
CPPFLAGS="-I/usr/include/tirpc"            \
LDFLAGS="-ltirpc"                          \
PATH=$PWD/pyvenv/bin:$PATH                 \
./configure                                \
    --prefix=/usr                          \
    --sysconfdir=/etc                      \
    --localstatedir=/var                   \
    --with-piddir=/run/samba               \
    --with-pammodulesdir=/usr/lib/security \
    --enable-fhs                           \
    --without-ad-dc                        \
    --without-systemd                      \
    --enable-selftest                      &&
make

To test the results, issue: PATH=$PWD/pyvenv/bin:$PATH make quicktest. The test suite will produce lines that look like failures, but these are innocuous. The last few lines of output should report "ALL OK" for a good test run. A summary of any failures can be found in ./st/summary. With Samba-4.14.4, many tests are known to fail.

Note

Additionally, developer test suites are available. If you've installed the optional python modules above in the Python virtual environment for building this package, you can run these tests with make test. It is not recommended for the average builder at around 290 SBU and over a gigabyte of disk space, and you should expect ~73 errors and ~30 failures from the 3000+ tests.

Fix a hard coded path to Python 3 interpreter:

sed '1s@^.*$@#!/usr/bin/python3@' \
    -i ./bin/default/source4/scripting/bin/samba-gpupdate.inst

If upgrading from an old version of samba, as the root user, remove the old Python support files to prevent some issues:

rm -rf /usr/lib/python3.10/site-packages/samba

Still as the root user, install the package:

make install &&

install -v -m644    examples/smb.conf.default /etc/samba &&

sed -e "s;log file =.*;log file = /var/log/samba/%m.log;" \
    -e "s;path = /usr/spool/samba;path = /var/spool/samba;" \
    -i /etc/samba/smb.conf.default &&

mkdir -pv /etc/openldap/schema                        &&

install -v -m644    examples/LDAP/README              \
                    /etc/openldap/schema/README.LDAP  &&

install -v -m644    examples/LDAP/samba*              \
                    /etc/openldap/schema              &&

install -v -m755    examples/LDAP/{get*,ol*} \
                    /etc/openldap/schema

Command Explanations

--enable-fhs: Assigns all other file paths in a manner compliant with the Filesystem Hierarchy Standard (FHS).

--without-systemd: Disable systemd integration, since it is not built in the System V version of LFS/BLFS.

--without-ad-dc: Disables Active Directory Domain Controller functionality. See Setup a Samba Active Directory Domain Controller for detailed information. Remove this switch if you've installed the Python modules needed for ADS support. Note that BLFS does not provide a samba bootscript or systemd unit for an Active Directory domain controller.

--with-selftest-prefix=SELFTEST_PREFIX: This option specifies the test suite work directory (default=./st).

install -v -m644 examples/LDAP/* /etc/openldap/schema: These commands are used to copy sample Samba schemas to the OpenLDAP schema directory.

install -v -m644 ../examples/smb.conf.default /etc/samba: This copies a default smb.conf file into /etc/samba. This sample configuration will not work until you copy it to /etc/samba/smb.conf and make the appropriate changes for your installation. See the configuration section for minimum values which must be set.

Configuring Samba

Config Files

/etc/samba/smb.conf

Printing to SMB Clients

If you use CUPS for print services, and you wish to print to a printer attached to an SMB client, you need to create an SMB backend device. To create the device, issue the following command as the root user:

install -dvm 755 /usr/lib/cups/backend &&
ln -v -sf /usr/bin/smbspool /usr/lib/cups/backend/smb

Configuration Information

Due to the complexity and the many various uses for Samba, complete configuration for all the package's capabilities is well beyond the scope of the BLFS book. This section provides instructions to configure the /etc/samba/smb.conf file for two common scenarios. The complete contents of /etc/samba/smb.conf will depend on the purpose of Samba installation.

Note

You may find it easier to copy the configuration parameters shown below into an empty /etc/samba/smb.conf file instead of copying and editing the default file as mentioned in the Command Explanations section. How you create/edit the /etc/samba/smb.conf file will be left up to you. Do ensure the file is only writeable by the root user (mode 644).

Scenario 1: Minimal Standalone Client-Only Installation

Choose this variant if you only want to transfer files using smbclient, mount Windows shares and print to Windows printers, and don't want to share your files and printers to Windows machines.

A /etc/samba/smb.conf file with the following three parameters is sufficient:

[global]
    workgroup = WORKGROUP
    dos charset = cp850
    unix charset = ISO-8859-1

The values in this example specify that the computer belongs to a Windows workgroup named WORKGROUP, uses the cp850 character set on the wire when talking to MS-DOS and MS Windows 9x, and that the filenames are stored in the ISO-8859-1 encoding on the disk. Adjust these values appropriately for your installation. The unix charset value must be the same as the output of locale charmap when executed with the LANG variable set to your preferred locale, otherwise the ls command may not display correct filenames of downloaded files.

There is no need to run any Samba servers in this scenario, thus you don't need to install the provided bootscripts.

Scenario 2: Standalone File/Print Server

Choose this variant if you want to share your files and printers to Windows machines in your workgroup in addition to the capabilities described in Scenario 1.

In this case, the /etc/samba/smb.conf.default file may be a good template to start from. Also, you should add the dos charset and unix charset parameters to the [global] section as described in Scenario 1 in order to prevent filename corruption. For security reasons, you may wish to define path = /home/alice/shared-files, assuming your user name is alice and you only want to share the files in that directory, instead of your entire home. Then, replace homes by shared-files and change also the comment if used the configuration file below or the /etc/samba/smb.conf.default to create yours.

The following configuration file creates a separate share for each user's home directory and also makes all printers available to Windows machines:

[global]
    workgroup = WORKGROUP
    dos charset = cp850
    unix charset = ISO-8859-1

[homes]
    comment = Home Directories
    browseable = no
    writable = yes

[printers]
    comment = All Printers
    path = /var/spool/samba
    browseable = no
    guest ok = no
    printable = yes

Other parameters you may wish to customize in the [global] section include:

    server string =
    security =
    hosts allow =
    load printers =
    log file =
    max log size =
    socket options =
    local master =

Reference the comments in the /etc/samba/smb.conf.default file for information regarding these parameters.

Since the smbd and nmbd daemons are needed in this case, install the samba bootscript. Be sure to run smbpasswd (with the -a option to add users) to enable and set passwords for all accounts that need Samba access. Using the default Samba passdb backend, any user you attempt to add will also be required to exist in the /etc/passwd file.

Advanced Requirements

More complex scenarios involving domain control or membership are possible. Such setups are advanced topics and cannot be adequately covered in BLFS. Many complete books have been written on these topics alone. Note that in some domain membership scenarios, the winbindd daemon and the corresponding bootscript are needed.

Guest account

The default Samba installation uses the nobody user for guest access to the server. This can be overridden by setting the guest account = parameter in the /etc/samba/smb.conf file. If you utilize the guest account = parameter, ensure this user exists in the /etc/passwd file.

Boot Script

For your convenience, boot scripts have been provided for Samba. There are two included in the blfs-bootscripts-20210826 package. The first, samba, will start the smbd and nmbd daemons needed to provide SMB/CIFS services. The second script, winbind, starts the winbindd daemon, used for providing Windows domain services to Linux clients.

make install-samba
make install-winbindd

Contents

Installed Programs: cifsdd, dbwrap_tool, dumpmscat, eventlogadm, gentest, ldbadd, ldbdel, ldbedit, ldbmodify, ldbrename, ldbsearch, locktest, masktest, mdsearch, mvxattr, ndrdump, net, nmbd, nmblookup, ntlm_auth, oLschema2ldif, pdbedit, profiles, regdiff, regpatch, regshell, regtree, rpcclient, samba, samba-gpupdate, samba-regedit, samba-tool, sharesec, smbcacls, smbclient, smbcontrol, smbcquotas, smbd, smbget, smbpasswd, smbspool, smbstatus, smbtar, smbtorture, smbtree, tdbbackup, tdbdump, tdbrestore, tdbtool, testparm, wbinfo, and winbindd
Installed Libraries: libdcerpc-binding.so, libdcerpc-samr.so, libdcerpc-server-core.so, libdcerpc-server.so, libdcerpc.so, libndr-krb5pac.so, libndr-nbt.so, libndr.so, libndr-standard.so, libnetapi.so, libnss_winbind.so, libnss_wins.so, libsamba-credentials.so, libsamba-errors.so, libsamba-hostconfig.so, libsamba-passdb.so, libsamba-policy.cpython-310-x86_64-linux-gnu.so, libsamba-util.so, libsamdb.so, libsmbclient.so, libsmbconf.so, libsmbldap.so, libtevent-util.so, libwbclient.so, and filesystem and support modules under /usr/lib/{python3.10,samba}
Installed Directories: /etc/samba, /run/samba, /usr/include/samba-4.0, /usr/lib/python3.10/site-packages/samba, /usr/{lib,libexec,share}/samba, and /var/{cache,lib,lock,log,run}/samba

Short Descriptions

cifsdd

is the dd command for SMB

dbwrap_tool

is used to read and manipulate TDB/CTDB databases using the dbwrap interface

dumpmscat

dumps the content of MS catalog files

eventlogadm

is used to write records to eventlogs from STDIN, add the specified source and DLL eventlog registry entries and display the active eventlog names (from smb.conf)

gentest

is used to run random generic SMB operations against two SMB servers and show the differences in behavior

ldbadd

is a command-line utility for adding records to an LDB database

ldbdel

is a command-line program for deleting LDB database records

ldbedit

allows you to edit LDB databases using your preferred editor

ldbmodify

allows you to modify records in an LDB database

ldbrename

allows you to rename LDB databases

ldbsearch

searches an LDB database for records matching a specified expression

locktest

is used to find differences in locking between two SMB servers

masktest

is used to find differences in wildcard matching between Samba's implementation and that of a remote server

mdsearch

runs Spotlight searches against a SMB server

mvxattr

is used to recursively rename extended attributes

ndrdump

is a DCE/RPC Packet Parser and Dumper

net

is a tool for administration of Samba and remote CIFS servers, similar to the net utility for DOS/Windows

nmbd

is the Samba NetBIOS name server

nmblookup

is used to query NetBIOS names and map them to IP addresses

ntlm_auth

is a tool to allow external access to Winbind's NTLM authentication function

oLschema2ldif

converts LDAP schema's to LDB-compatible LDIF

pdbedit

is a tool used to manage the SAM database

profiles

is a utility that reports and changes SIDs in Windows registry files. It currently only supports Windows NT

regdiff

is a Diff program for Windows registry files

regpatch

applies registry patches to registry files

regshell

is a Windows registry file browser using readline

regtree

is a text-mode registry viewer

rpcclient

is used to execute MS-RPC client side functions

samba

is a server to provide AD and SMB/CIFS services to clients

samba-gpupdate

allows you to edit Microsoft Group Policy Objects (GPOs)

samba-regedit

is a ncurses based tool to manage the Samba registry

samba-tool

is the main Samba administration tool

sharesec

manipulates share ACL permissions on SMB file shares

smbcacls

is used to manipulate Windows NT access control lists

smbclient

is a SMB/CIFS access utility, similar to FTP

smbcontrol

is used to control running smbd, nmbd and winbindd daemons

smbcquotas

is used to manipulate Windows NT quotas on SMB file shares

smbd

is the main Samba daemon which provides SMB/CIFS services to clients

smbget

is a simple utility with wget-like semantics, that can download files from SMB servers. You can specify the files you would like to download on the command-line

smbpasswd

changes a user's Samba password

smbspool

sends a print job to a SMB printer

smbstatus

reports current Samba connections

smbtar

is a shell script used for backing up SMB/CIFS shares directly to Linux tape drives or to a file

smbtorture

is a testsuite that runs several tests against a SMB server

smbtree

is a text-based SMB network browser

tdbbackup

is a tool for backing up or validating the integrity of Samba .tdb files

tdbdump

is a tool used to print the contents of a Samba .tdb file

tdbrestore

is a tool for creating a Samba .tdb file out of a ntdbdump

tdbtool

is a tool which allows simple database manipulation from the command line

testparm

checks an smb.conf file for proper syntax

wbinfo

queries a running winbindd daemon

winbindd

resolves names from Windows NT servers

libnss_winbind.so

provides Name Service Switch API functions for resolving names from NT servers

libnss_wins.so

provides API functions for Samba's implementation of the Windows Internet Naming Service

libnetapi.so

provides API functions for the administration tools used for Samba and remote CIFS servers

libsmbclient.so

provides API functions for the Samba SMB client tools

libwbclient.so

provides API functions for Windows domain client services

Last updated on

Wget-1.21.2

Introduction to Wget

The Wget package contains a utility useful for non-interactive downloading of files from the Web.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Wget Dependencies

Recommended
Optional

GnuTLS-3.7.3, HTTP-Daemon-6.13 (for the test suite), IO-Socket-SSL-2.074 (for the test suite), libidn2-2.3.2, libpsl-0.21.1, PCRE-8.45 or pcre2-10.39, and Valgrind-3.18.1 (for the test suite)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/wget

Installation of Wget

Install Wget by running the following commands:

./configure --prefix=/usr      \
            --sysconfdir=/etc  \
            --with-ssl=openssl &&
make

To test the results, issue: make check.

HTTPS tests are known to fail if Perl module IO::Socket::INET6 is installed.

Now, as the root user:

make install

Command Explanations

--sysconfdir=/etc: This relocates the configuration file from /usr/etc to /etc.

--with-ssl=openssl: This allows the program to use openssl instead of GnuTLS-3.7.3.

--enable-valgrind-tests: This allows the tests to be run under valgrind.

Configuring Wget

Config Files

/etc/wgetrc and ~/.wgetrc

Contents

Installed Program: wget
Installed Libraries: None
Installed Directories: None

Short Descriptions

wget

retrieves files from the Web using the HTTP, HTTPS and FTP protocols. It is designed to be non-interactive, for background or unattended operations

Last updated on

Wireless Tools-29

Introduction to Wireless Tools

The Wireless Extension (WE) is a generic API in the Linux kernel allowing a driver to expose configuration and statistics specific to common Wireless LANs to user space. A single set of tools can support all the variations of Wireless LANs, regardless of their type as long as the driver supports Wireless Extensions. WE parameters may also be changed on the fly without restarting the driver (or Linux).

The Wireless Tools (WT) package is a set of tools allowing manipulation of the Wireless Extensions. They use a textual interface to support the full Wireless Extension.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/WirelessTools

Kernel Configuration

To use Wireless Tools, the kernel must have the appropriate drivers and other support available. The appropriate bus must also be available. For many laptops, the PCMCIA bus (CONFIG_PCCARD) needs to be built. In some cases, this bus support will also need to be built for embedded wireless cards. The appropriate bridge support also needs to be built. For many modern laptops, the CardBus host bridge (CONFIG_YENTA) will be needed.

In addition to the bus, the actual driver for the specific wireless card must also be available. There are many wireless cards and they don't all work with Linux. The first place to look for card support is the kernel. The drivers are located in Device Drivers → Network Device Support → Wireless LAN (non-hamradio). There are also external drivers available for some very common cards. For more information, look at the user notes.

After the correct drivers are loaded, the interface will appear in /proc/net/wireless.

Installation of Wireless Tools

First, apply a patch that fixes a problem when numerous networks are available:

patch -Np1 -i ../wireless_tools-29-fix_iwlist_scanning-1.patch

To install Wireless Tools, use the following commands:

make

This package does not come with a test suite.

Now, as the root user:

make PREFIX=/usr INSTALL_MAN=/usr/share/man install

Command Explanations

INSTALL_MAN=/usr/share/man: Install manual pages in /usr/share/man instead of /usr/man.

Contents

Installed Programs: ifrename, iwconfig, iwevent, iwgetid, iwlist, iwpriv, and iwspy
Installed Library: libiw.so
Installed Directories: None

Short Descriptions

ifrename

renames network interfaces based on various static criteria

iwconfig

configures a wireless network interface

iwevent

displays wireless events generated by drivers and setting changes

iwgetid

reports ESSID, NWID or AP/Cell Address of wireless networks

iwlist

gets detailed wireless information from a wireless interface

iwpriv

configures optional (private) parameters of a wireless network interface

iwspy

gets wireless statistics from specific node

libiw.so

contains functions required by the wireless programs and provides an API for other programs

Last updated on

wpa_supplicant-2.10

Introduction to WPA Supplicant

WPA Supplicant is a Wi-Fi Protected Access (WPA) client and IEEE 802.1X supplicant. It implements WPA key negotiation with a WPA Authenticator and Extensible Authentication Protocol (EAP) authentication with an Authentication Server. In addition, it controls the roaming and IEEE 802.11 authentication/association of the wireless LAN driver. This is useful for connecting to a password protected wireless access point.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

WPA Supplicant Dependencies

Recommended
Optional

dbus-1.12.20, libxml2-2.9.13, and Qt-5.15.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/wpa_supplicant

Kernel Configuration

Enable the following options in the kernel configuration as well as specific device drivers for your hardware and recompile the kernel if necessary:

[*] Networking support  --->                              [CONFIG_NET]
  [*] Wireless  --->                                      [CONFIG_WIRELESS]
    <*/M> cfg80211 - wireless configuration API           [CONFIG_CFG80211]
    [*]     cfg80211 wireless extensions compatibility    [CONFIG_CFG80211_WEXT]
    <*/M> Generic IEEE 802.11 Networking Stack (mac80211) [CONFIG_MAC80211]
Device Drivers  --->
  [*] Network device support  --->                        [CONFIG_NETDEVICES]
    [*] Wireless LAN  --->                                [CONFIG_WLAN]

Open the submenu and select the options that support your hardware: lspci from pciutils-3.7.0 can be used to view your hardware configuration.

Installation of WPA Supplicant

First you will need to create an initial configuration file for the build process. You can read wpa_supplicant/README and wpa_supplicant/defconfig for the explanation of the following options as well as other options that can be used. Create a build configuration file that should work for standard WiFi setups by running the following command:

cat > wpa_supplicant/.config << "EOF"
CONFIG_BACKEND=file
CONFIG_CTRL_IFACE=y
CONFIG_DEBUG_FILE=y
CONFIG_DEBUG_SYSLOG=y
CONFIG_DEBUG_SYSLOG_FACILITY=LOG_DAEMON
CONFIG_DRIVER_NL80211=y
CONFIG_DRIVER_WEXT=y
CONFIG_DRIVER_WIRED=y
CONFIG_EAP_GTC=y
CONFIG_EAP_LEAP=y
CONFIG_EAP_MD5=y
CONFIG_EAP_MSCHAPV2=y
CONFIG_EAP_OTP=y
CONFIG_EAP_PEAP=y
CONFIG_EAP_TLS=y
CONFIG_EAP_TTLS=y
CONFIG_IEEE8021X_EAPOL=y
CONFIG_IPV6=y
CONFIG_LIBNL32=y
CONFIG_PEERKEY=y
CONFIG_PKCS12=y
CONFIG_READLINE=y
CONFIG_SMARTCARD=y
CONFIG_WPS=y
CFLAGS += -I/usr/include/libnl3
EOF

If you wish to use WPA Supplicant with NetworkManager-1.34.0, make sure that you have installed dbus-1.12.20 and libxml2-2.9.13, then add the following options to the WPA Supplicant build configuration file by running the following command:

cat >> wpa_supplicant/.config << "EOF"
CONFIG_CTRL_IFACE_DBUS=y
CONFIG_CTRL_IFACE_DBUS_NEW=y
CONFIG_CTRL_IFACE_DBUS_INTRO=y
EOF
cd wpa_supplicant &&
make BINDIR=/usr/sbin LIBDIR=/usr/lib

If you have installed Qt-5.15.2 and wish to build the WPA Supplicant GUI program, run the following commands:

Note

The following directory name is labelled qt4, but is compatible with Qt-5.15.2.

pushd wpa_gui-qt4 &&
qmake wpa_gui.pro &&
make &&
popd

This package does not come with a test suite.

Now, as the root user:

install -v -m755 wpa_{cli,passphrase,supplicant} /usr/sbin/ &&
install -v -m644 doc/docbook/wpa_supplicant.conf.5 /usr/share/man/man5/ &&
install -v -m644 doc/docbook/wpa_{cli,passphrase,supplicant}.8 /usr/share/man/man8/

If you have built WPA Supplicant with D-Bus support, you will need to install D-Bus configuration files. Install them by running the following commands as the root user:

install -v -m644 dbus/fi.w1.wpa_supplicant1.service \
                 /usr/share/dbus-1/system-services/ &&
install -v -d -m755 /etc/dbus-1/system.d &&
install -v -m644 dbus/dbus-wpa_supplicant.conf \
                 /etc/dbus-1/system.d/wpa_supplicant.conf

If you have built the WPA Supplicant GUI program, install it by running the following commands as the root user:

install -v -m755 wpa_gui-qt4/wpa_gui /usr/bin/ &&
install -v -m644 doc/docbook/wpa_gui.8 /usr/share/man/man8/ &&
install -v -m644 wpa_gui-qt4/wpa_gui.desktop /usr/share/applications/ &&
install -v -m644 wpa_gui-qt4/icons/wpa_gui.svg /usr/share/pixmaps/

Note

You will need to restart the system D-Bus daemon before you can use the WPA Supplicant D-Bus interface.

Note

This package installs desktop files into the /usr/share/applications hierarchy and you can improve system performance and memory usage by updating /usr/share/applications/mimeinfo.cache. To perform the update you must have desktop-file-utils-0.26 installed and issue the following command as the root user:

update-desktop-database -q

Configuring wpa_supplicant

Config File

/etc/sysconfig/wpa_supplicant-*.conf

Configuration Information

To connect to an access point that uses a password, you need to put the pre-shared key in /etc/sysconfig/wpa_supplicant-wifi0.conf. SSID is the string that the access point/router transmits to identify itself. Run the following command as the root user:

wpa_passphrase SSID SECRET_PASSWORD > /etc/sysconfig/wpa_supplicant-wifi0.conf

/etc/sysconfig/wpa_supplicant-wifi0.conf can hold the details of several access points. When wpa_supplicant is started, it will scan for the SSIDs it can see and choose the appropriate password to connect.

If you want to connect to an access point that isn't password protected, put an entry like this in /etc/sysconfig/wpa_supplicant-wifi0.conf. Replace "Some-SSID" with the SSID of the access point/router.

network={
  ssid="Some-SSID"
  key_mgmt=NONE
}

Connecting to a new access point that is not in the configuration file can be accomplished manually via the command line or GUI, but it must be done via a privileged user. To do that, add the following to the configuration file:

                ctrl_interface=DIR=/run/wpa_supplicant GROUP=<privileged group>
update_config=1

Replace the <privileged group> above with a system group where members have the ability to connect to a wireless access point.

There are many options that you could use to tweak how you connect to each access point. They are described in some detail in the wpa_supplicant/wpa_supplicant.conf file in the source tree.

Connecting to an Access Point

If you want to configure network interfaces at boot using wpa_supplicant, you need to install the /lib/services/wpa script included in blfs-bootscripts-20210826 package:

make install-service-wpa

If your router/access point uses DHCP to allocate IP addresses, you can install DHCP-4.4.2-P1 client and use it to automatically obtain network addresses. Create the /etc/sysconfig/ifconfig-wifi0 by running the following command as the root user:

cat > /etc/sysconfig/ifconfig.wifi0 << "EOF"
ONBOOT="yes"
IFACE="wlan0"
SERVICE="wpa"

# Additional arguments to wpa_supplicant
WPA_ARGS=""

WPA_SERVICE="dhclient"
DHCP_START=""
DHCP_STOP=""

# Set PRINTIP="yes" to have the script print
# the DHCP assigned IP address
PRINTIP="no"

# Set PRINTALL="yes" to print the DHCP assigned values for
# IP, SM, DG, and 1st NS. This requires PRINTIP="yes".
PRINTALL="no"
EOF

If you prefer dhcpcd-9.4.1 instead of DHCP-4.4.2-P1 client, then create the /etc/sysconfig/ifconfig-wifi0 by running the following command as the root user:

cat > /etc/sysconfig/ifconfig.wifi0 << "EOF"
ONBOOT="yes"
IFACE="wlan0"
SERVICE="wpa"

# Additional arguments to wpa_supplicant
WPA_ARGS=""

WPA_SERVICE="dhcpcd"
DHCP_START="-b -q <insert appropriate start options here>"
DHCP_STOP="-k <insert additional stop options here>"
EOF

Alternatively, if you use static addresses on your local network, then create the /etc/sysconfig/ifconfig-wifi0 by running the following command as the root user:

cat > /etc/sysconfig/ifconfig.wifi0 << "EOF"
ONBOOT="yes"
IFACE="wlan0"
SERVICE="wpa"

# Additional arguments to wpa_supplicant
WPA_ARGS=""

WPA_SERVICE="ipv4-static"
IP="192.168.1.1"
GATEWAY="192.168.1.2"
PREFIX="24"
BROADCAST="192.168.1.255"
EOF

You can connect to the wireless access point by running the following command as the root user:

ifup wifi0

Replace wlan0 with the correct wireless interface and wifi0 with desired name for the configuration file. Please note that wpa_supplicant-*.conf and ifconfig.* configuration files need to have identical names, ie both contain wifi0 in their name.

Contents

Installed Programs: wpa_gui, wpa_supplicant, wpa_passphrase and wpa_cli
Installed Libraries: None
Installed Directories: None

Short Descriptions

wpa_gui

is a graphical frontend program for interacting with wpa_supplicant

wpa_supplicant

is a daemon that can connect to a password protected wireless access point

wpa_passphrase

takes an SSID and a password and generates a simple configuration that wpa_supplicant can understand

wpa_cli

is a command line interface used to control a running wpa_supplicant daemon

Last updated on

Chapter 16. Networking Utilities

This chapter contains some tools that come in handy when the network needs investigating.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/basicnetworkingutilities

Avahi-0.8

Introduction to Avahi

The Avahi package is a system which facilitates service discovery on a local network.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Avahi Dependencies

Required

GLib-2.70.4

Recommended
Optional

D-Bus Python-1.2.18, libevent-2.1.12, PyGTK-2.24.0, Doxygen-1.9.3 and xmltoman (for generating documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/avahi

Installation of Avahi

There should be a dedicated user and group to take control of the avahi-daemon daemon after it is started. Issue the following commands as the root user:

groupadd -fg 84 avahi &&
useradd -c "Avahi Daemon Owner" -d /var/run/avahi-daemon -u 84 \
        -g avahi -s /bin/false avahi

There should also be a dedicated privileged access group for Avahi clients. Issue the following command as the root user:

groupadd -fg 86 netdev

Fix a regression that results in a race condition when IPv6 is in use and multiple network adapters are present on the system:

patch -Np1 -i ../avahi-0.8-ipv6_race_condition_fix-1.patch

Fix a security vulnerability in avahi-daemon:

sed -i '426a if (events & AVAHI_WATCH_HUP) { \
client_free(c); \
return; \
}' avahi-daemon/simple-protocol.c

Install Avahi by running the following commands:

./configure --prefix=/usr        \
            --sysconfdir=/etc    \
            --localstatedir=/var \
            --disable-static     \
            --disable-libevent   \
            --disable-mono       \
            --disable-monodoc    \
            --disable-python     \
            --disable-qt3        \
            --disable-qt4        \
            --enable-core-docs   \
            --with-distro=none   \
            --with-systemdsystemunitdir=no &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--disable-libevent: This parameter disables the use of libevent-2.1.12. Remove if you have it installed.

--disable-mono: This parameter disables the Mono bindings.

--disable-monodoc: This parameter disables documentation for the Mono bindings.

--disable-python: This parameter disables the scripts that depend on Python. It also allows a regular install to complete successfully.

--disable-qt3: This parameter disables the attempt to build the obsolete Qt3 portions of the package.

--disable-qt4: This parameter disables the attempt to build the obsolete Qt4Core portions of the package.

--enable-core-docs: This parameter enables the building of documentation.

--with-distro=none: There is an obsolete boot script in the distribution for LFS. This option disables it.

--with-systemdsystemunitdir=no: Without it, the daemon fails to start in BLFS, which does not support systemd.

--disable-dbus: This parameter disables the use of D-Bus.

--disable-gtk: This parameter disables the use of GTK+2.

--disable-gtk3: This parameter disables the use of GTK+3.

--disable-qt5: This parameter disables the use of Qt5, and allows building without it.

--disable-libdaemon: This parameter disables the use of libdaemon. If you use this option, avahi-daemon won't be built.

--enable-tests: This option enables the building of tests and examples.

--enable-compat-howl: This option enables the compatibility layer for HOWL.

--enable-compat-libdns_sd: This option enables the compatibility layer for libdns_sd.

Configuring avahi

Boot Script

To automatically start the avahi-daemon when the system is rebooted, install the /etc/rc.d/init.d/avahi bootscript from the blfs-bootscripts-20210826 package.

make install-avahi

Contents

Installed Programs: avahi-autoipd, avahi-browse, avahi-browse-domains, avahi-daemon, avahi-discover-standalone, avahi-dnsconfd, avahi-publish, avahi-publish-address, avahi-publish-service, avahi-resolve, avahi-resolve-address, avahi-resolve-host-name, avahi-set-host-name, bshell, bssh, and bvnc
Installed Libraries: libavahi-client.so, libavahi-common.so, libavahi-core.so, libavahi-glib.so, libavahi-gobject.so, libavahi-libevent.so libavahi-ui-gtk3.so, libavahi-qt5, libavahi-ui.so, libdns_sd.so, and libhowl.so,
Installed Directories: /etc/avahi/services, /usr/include/{avahi-client,avahi-common, avahi-compat-howl, avahi-compat-libdns_sd, avahi-core, avahi-glib, avahi-gobject, avahi-libevent, avahi-qt5, avahi-ui}, /usr/lib/avahi, /usr/share/avahi

Short Descriptions

avahi-autoipd

is a IPv4LL network address configuration daemon

avahi-browse

browses for mDNS/DNS-SD services using the Avahi daemon

avahi-browse-domains

browses for mDNS/DNS-SD services using the Avahi daemon

avahi-daemon

is the Avahi mDNS/DNS-SD daemon

avahi-discover-standalone

browses for mDNS/DNS-SD services using the Avahi daemon

avahi-dnsconfd

is a Unicast DNS server from mDNS/DNS-SD configuration daemon

avahi-publish

registers a mDNS/DNS-SD service or host name or address mapping using the Avahi daemon

avahi-publish-address

registers a mDNS/DNS-SD service or host name or address mapping using the Avahi daemon

avahi-publish-service

registers a mDNS/DNS-SD service or host name or address mapping using the Avahi daemon

avahi-resolve

resolves one or more mDNS/DNS host name(s) to IP address(es) (and vice versa) using the Avahi daemon

avahi-resolve-address

resolves one or more mDNS/DNS host name(s) to IP address(es) (and vice versa) using the Avahi daemon

avahi-resolve-host-name

resolves one or more mDNS/DNS host name(s) to IP address(es) (and vice versa) using the Avahi daemon

avahi-set-host-name

changes the mDNS host name

bssh

browses for SSH servers on the local network

bvnc

browses for VNC servers on the local network

Last updated on

BIND Utilities-9.18.0

Introduction to BIND Utilities

BIND Utilities is not a separate package, it is a collection of the client side programs that are included with BIND-9.18.0. The BIND package includes the client side programs nslookup, dig and host. If you install BIND server, these programs will be installed automatically. This section is for those users who don't need the complete BIND server, but need these client side applications.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

BIND Utilities Dependencies

Required

libuv-1.43.0

Recommended
Optional

libcap-2.63 with PAM, libxml2-2.9.13, and Sphinx

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/bind-utils

Installation of BIND Utilities

Install BIND Utilities by running the following commands:

./configure --prefix=/usr &&
make -C lib/isc    &&
make -C lib/dns    &&
make -C lib/ns     &&
make -C lib/isccfg &&
make -C lib/bind9  &&
make -C lib/irs    &&
make -C bin/dig    &&
make -C doc

This portion of the package does not come with a test suite.

Now, as the root user:

make -C lib/isc    install &&
make -C lib/dns    install &&
make -C lib/ns     install &&
make -C lib/isccfg install &&
make -C lib/bind9  install &&
make -C lib/irs    install &&
make -C bin/dig    install &&
cp -v doc/man/{dig.1,host.1,nslookup.1} /usr/share/man/man1

Command Explanations

--disable-doh: Use this option if you have not installed nghttp2-1.46.0 and you don't need DNS over HTTPS support.

make -C lib/...: These commands build the libraries that are needed for the client programs.

make -C bin/dig: This command builds the client programs.

make -C doc: This command builds the manual pages.

cp -v ... /usr/share/man/man1: This command installs the manual pages.

Contents

Installed Programs: dig, host, and nslookup
Installed Libraries: None
Installed Directories: None

Short Descriptions

See the program descriptions in the BIND-9.18.0 section.

Last updated on

NetworkManager-1.34.0

Introduction to NetworkManager

NetworkManager is a set of co-operative tools that make networking simple and straightforward. Whether you use WiFi, wired, 3G, or Bluetooth, NetworkManager allows you to quickly move from one network to another: Once a network has been configured and joined once, it can be detected and re-joined automatically the next time it's available.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

NetworkManager Dependencies

Required

jansson-2.14 and libndp-1.8

Recommended
Optional

BlueZ-5.63, D-Bus Python-1.2.18 (for the test suite), GnuTLS-3.7.3 (used if nss-3.75 is not found), GTK-Doc-1.33.2, libpsl-0.21.1, Qt-5.15.2 (for examples), ModemManager-1.18.6, Valgrind-3.18.1, dnsmasq, firewalld, libaudit, libteam, mobile-broadband-provider-info, PPP, and RP-PPPoE

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/NetworkManager

Kernel Configuration

If you wish to run the tests, enable the following options in the kernel configuration and recompile the kernel if necessary:

Device Drivers --->
  [*] Network device support         [CONFIG_NETDEVICES] --->
    [*] Bonding driver support       [CONFIG_BONDING]
    [*] Dummy net driver support     [CONFIG_DUMMY]
    [*] Ethernet team driver support [CONFIG_NET_TEAM]

Installation of NetworkManager

If Qt-5.15.2 is installed and the Qt based examples are desired, fix two meson.build files:

sed -e 's/-qt4/-qt5/'              \
    -e 's/moc_location/host_bins/' \
    -i examples/C/qt/meson.build   &&

sed -e 's/Qt/&5/'                  \
    -i meson.build

Fix the python scripts so that they use Python 3:

grep -rl '^#!.*python$' | xargs sed -i '1s/python/&3/'

Install NetworkManager by running the following commands:

mkdir build &&
cd    build &&

CXXFLAGS+="-O2 -fPIC"            \
meson --prefix=/usr              \
      --buildtype=release        \
      -Dlibaudit=no              \
      -Dlibpsl=false             \
      -Dnmtui=true               \
      -Dovs=false                \
      -Dppp=false                \
      -Dselinux=false            \
      -Dsession_tracking=elogind \
      -Dmodem_manager=false      \
      -Dsystemdsystemunitdir=no  \
      -Dsystemd_journal=false    \
      -Dqt=false                 \
      .. &&
ninja

An already active graphical session with a bus address is necessary to run the tests. To test the results, as the root user, issue: ninja test. Five tests, platform/test-tc-linux, test-l3cfg, devices/test-acd, platform/test-route-linux, and platform/test-link-linux, are known to fail.

Now, as the root user:

ninja install &&
mv -v /usr/share/doc/NetworkManager{,-1.34.0}

Command Explanations

CXXFLAGS="-O2 -fPIC": These compiler options are necessary to build the Qt5 based examples.

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Ddocs=true: Use this switch to enable building man pages and documentation if GTK-Doc-1.33.2 is installed.

-Dnmtui=true: This parameter enables building nmtui.

-Dsystemdsystemunitdir=no and -Dsystemd_journal=false: systemd is not used for sysv init systems.

-Dlibpsl=false and -Dovs=false: These switches disable building with the respective libraries. Remove if you have the needed libraries installed.

-Dmodem_manager=false: This switch is required if ModemManager is not installed. Omit if you have built ModemManager and mobile-broadband-provider-info.

-Dsession_tracking=elogind: This switch is used to set elogind as the default program for session tracking.

-Dppp=false: This parameter disables PPP support in NetworkManager.

-Dlibaudit=no and -Dselinux=false: libaudit and SELinux are not used in BLFS.

-Dqt=false: disables the QT examples. Omit if you have QT available and wish to install the examples.

Configuring NetworkManager

Config Files

/etc/NetworkManager/NetworkManager.conf

Configuration Information

For NetworkManager to work, at least a minimal configuration file must be present. Such a file is not installed with make install. Issue the following command as the root user to create a minimal NetworkManager.conf file:

cat >> /etc/NetworkManager/NetworkManager.conf << "EOF"
[main]
plugins=keyfile
EOF

This file should not be modified directly by users of the system. Instead, system specific changes should be made using configuration files in the /etc/NetworkManager/conf.d directory.

To allow polkit to manage authorizations, add the following configuration file:

cat > /etc/NetworkManager/conf.d/polkit.conf << "EOF"
[main]
auth-polkit=true
EOF

To use something other than the built-in dhcp client (recommended if using only nmcli), use the following configuration (valid values include either dhclient or internal):

cat > /etc/NetworkManager/conf.d/dhcp.conf << "EOF"
[main]
dhcp=dhclient
EOF

To prevent NetworkManager from updating the /etc/resolv.conf file, add the following configuration file:

cat > /etc/NetworkManager/conf.d/no-dns-update.conf << "EOF"
[main]
dns=none
EOF

For additional configuation options, see man 5 NetworkManager.conf.

To allow regular users to configure network connections, you should add them to the netdev group, and create a polkit rule that grants access. Run the following commands as the root user:

groupadd -fg 86 netdev &&
/usr/sbin/usermod -a -G netdev <username>

cat > /usr/share/polkit-1/rules.d/org.freedesktop.NetworkManager.rules << "EOF"
polkit.addRule(function(action, subject) {
    if (action.id.indexOf("org.freedesktop.NetworkManager.") == 0 && subject.isInGroup("netdev")) {
        return polkit.Result.YES;
    }
});
EOF

Boot Script

To automatically start the NetworkManager daemon when the system is rebooted, install the /etc/rc.d/init.d/networkmanagerbootscript from the blfs-bootscripts-20210826 package.

Note

If using Network Manager to manage an interface, any previous configuration for that interface should be removed, and the interface brought down prior to starting Network Manager.

make install-networkmanager

Contents

Installed Programs: NetworkManager, nmcli, nm-online, nmtui, and, symlinked to nmtui: nmtui-connect, nmtui-edit, and nmtui-hostname
Installed Libraries: libnm.so and several modules under /usr/lib/NetworkManager
Installed Directories: /etc/NetworkManager, /usr/include/libnm, /usr/lib/NetworkManager, /usr/share/doc/NetworkManager-1.34.0, /usr/share/gtk-doc/html/{libnm,NetworkManager} (if the documentation is built), and /var/lib/NetworkManager

Short Descriptions

nmcli

is a command-line tool for controlling NetworkManager and getting its status

nm-online

is an utility to determine whether you are online

nmtui

is an interactive ncurses-based user interface for nmcli

nmtui-connect

is an interactive ncurses-based user interface to activate/deactivate connections

nmtui-edit

is an interactive ncurses-based user interface to edit connections

nmtui-hostname

is an interactive ncurses-based user interface to edit the hostname

NetworkManager

is the network management daemon

libnm.so

contains functions used by NetworkManager

Last updated on

network-manager-applet-1.24.0

Introduction to NetworkManager Applet

The NetworkManager Applet provides a tool and a panel applet used to configure wired and wireless network connections through GUI. It's designed for use with any desktop environment that uses GTK+, such as Xfce and LXDE.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

NetworkManager Applet Dependencies

Required

GTK+-3.24.31, libnma-1.8.34, libnotify-0.7.9, and libsecret-0.20.5

Recommended
Required (Runtime)

Since this package uses Polkit-0.120 for authorization, one Polkit Authentication Agent should be running when the functionality of this package is used.

Optional

gnome-bluetooth-3.34.5 and libindicator

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/network-manager-applet

Installation of NetworkManager Applet

First, fix building with newer versions of meson:

sed -i '/merge_file/{n;d}' meson.build

Install NetworkManager Applet by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr       \
      --buildtype=release \
      -Dappindicator=no   \
      -Dselinux=false     &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

-Dappindicator=no: This switch disables AppIndicator support in network-manager-applet because it requires libindicator, which is not in BLFS. The build will fail without this option.

-Dselinux=false: This switch forcibly disables SELinux support since it is not currently in BLFS and the build will fail without it.

-Dwwan=false: This switch disables WWAN support. Use this if you do not have ModemManager-1.18.6 installed.

Contents

Installed Programs: nm-applet and nm-connection-editor
Installed Libraries: None
Installed Directories: None

Short Descriptions

nm-connection-editor

allows users to view and edit network connection settings

Last updated on

Nmap-7.92

Introduction to Nmap

Nmap is a utility for network exploration and security auditing. It supports ping scanning, port scanning and TCP/IP fingerprinting.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://nmap.org/dist/nmap-7.92.tar.bz2

  • Download MD5 sum: 849f7298a786ce4cd5728db989cff763

  • Download size: 11 MB

  • Estimated disk space required: 148 MB (add 24 MB for tests)

  • Estimated build time: 0.3 SBU (Using parallelism=4; add 0.2 SBU for tests)

Nmap Dependencies

Recommended

Note

These packages are recommended because if they're not installed, the build process will compile and link against its own (often older) version.

Optional

PyGTK-2.24.0 (required for zenmap), Python-2.7.18 (required for ndiff), and libssh2-1.10.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/nmap

Installation of Nmap

Install Nmap by running the following commands:

./configure --prefix=/usr &&
make

If you wish to run the test suite, run the following command:

sed -i 's/lib./lib/' zenmap/test/run_tests.py

To test the results, issue: make check as the root user. Tests need a graphical session.

Now, as the root user:

make install

Contents

Installed Programs: ncat, ndiff, nmap, nping, uninstall_ndiff, uninstall_zenmap, zenmap, and 2 symlinks to zenmap: nmapfe and xnmap
Installed Libraries: None
Installed Directories: /usr/lib/python2.7/site-packages/{radialnet,zenmapCore,zenmapGUI}, and /usr/share/{ncat,nmap,zenmap}

Short Descriptions

ncat

is a utility for reading and writing data across networks from the command line

ndiff

is a tool to aid in the comparison of Nmap scans

nmap

is a utility for network exploration and security auditing. It supports ping scanning, port scanning and TCP/IP fingerprinting

nping

is an open-source tool for network packet generation, response analysis and response time measurement

uninstall_ndiff

is a Python script to uninstall ndiff

uninstall_zenmap

is a Python script to uninstall zenmap

zenmap

is a Python based graphical nmap frontend viewer

Last updated on

Traceroute-2.1.0

Introduction to Traceroute

The Traceroute package contains a program which is used to display the network route that packets take to reach a specified host. This is a standard network troubleshooting tool. If you find yourself unable to connect to another system, traceroute can help pinpoint the problem.

Note

This package overwrites the version of traceroute that was installed in the inetutils package in LFS. This version is more powerful and allows many more options than the standard version.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/traceroute

Installation of Traceroute

Install Traceroute by running the following commands:

make

This package does not come with a test suite.

Now, as the root user:

make prefix=/usr install                                 &&
ln -sv -f traceroute /usr/bin/traceroute6                &&
ln -sv -f traceroute.8 /usr/share/man/man8/traceroute6.8 &&
rm -fv /usr/share/man/man1/traceroute.1

The traceroute.1 file that was installed in LFS by inetutils is no longer relevant. This package overwrites that version of traceroute and installs the man page in man chapter 8.

Contents

Installed Program: traceroute and traceroute6 (symlink)
Installed Libraries: None
Installed Directories: None

Short Descriptions

traceroute

does basically what it says: it traces the route your packets take from the host you are working on to another host on a network, showing all the intermediate hops (gateways) along the way

traceroute6

is equivalent to traceroute -6

Last updated on

Whois-5.4.3

Introduction to Whois

Whois is a client-side application which queries the whois directory service for information pertaining to a particular domain name. This package will install two programs by default: whois and mkpasswd. The mkpasswd command is also installed by the expect package in LFS.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Whois Dependencies

Optional

libidn-1.38 or libidn2-2.3.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/whois

Installation of Whois

Build the application with:

make

You can install the whois program, the mkpasswd program, and the locale files independently. Control your choice of what is installed with the following commands issued as the root user:

Note

Installing this version of mkpasswd will overwrite the same command installed in LFS.

make prefix=/usr install-whois
make prefix=/usr install-mkpasswd
make prefix=/usr install-pos

Contents

Installed Programs: whois and mkpasswd
Installed Libraries: None
Installed Directories: None

Short Descriptions

whois

is a client-side application which queries the whois directory service for information pertaining to a particular domain name

mkpasswd

generates a new password, and optionally applies it to a user

Last updated on

Wireshark-3.6.2

Introduction to Wireshark

The Wireshark package contains a network protocol analyzer, also known as a sniffer. This is useful for analyzing data captured off the wire from a live network connection, or data read from a capture file.

Wireshark provides both a graphical and a TTY-mode front-end for examining captured network packets from over 500 protocols, as well as the capability to read capture files from many other popular network analyzers.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Wireshark dependencies

Required

CMake-3.22.2, GLib-2.70.4, libgcrypt-1.10.0, and Qt-5.15.2

Recommended
Optional

asciidoctor-2.0.17, Brotli-1.0.9, c-ares-1.18.1, Doxygen-1.9.3, git-2.35.1, GnuTLS-3.7.3, libnl-3.5.0, libxslt-1.1.35, libxml2-2.9.13, Lua-5.2.4, MIT Kerberos V5-1.19.2, nghttp2-1.46.0, SBC-1.5, Speex-1.2.0, BCG729, libilbc, libsmi, lz4, libssh, MaxMindDB, Minizip, Snappy, and Spandsp

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/wireshark

Kernel Configuration

The kernel must have the Packet protocol enabled for Wireshark to capture live packets from the network:

[*] Networking support --->          [CONFIG_NET]
      Networking options --->
        <*/M> Packet socket          [CONFIG_PACKET]

If built as a module, the name is af_packet.ko.

Installation of Wireshark

Wireshark is a very large and complex application. These instructions provide additional security measures to ensure that only trusted users are allowed to view network traffic. First, set up a system group for wireshark. As the root user:

groupadd -g 62 wireshark

Continue to install Wireshark by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_BUILD_TYPE=Release  \
      -DCMAKE_INSTALL_DOCDIR=/usr/share/doc/wireshark-3.6.2 \
      -G Ninja \
      .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install &&

install -v -m755 -d /usr/share/doc/wireshark-3.6.2 &&
install -v -m644    ../README.linux ../doc/README.* ../doc/randpkt.txt \
                    /usr/share/doc/wireshark-3.6.2 &&

pushd /usr/share/doc/wireshark-3.6.2 &&
   for FILENAME in ../../wireshark/*.html; do
      ln -s -v -f $FILENAME .
   done &&
popd
unset FILENAME

If you downloaded any of the documentation files from the page listed in the 'Additional Downloads', install them by issuing the following commands as the root user:

install -v -m644 <Downloaded_Files> \
                 /usr/share/doc/wireshark-3.6.2

Now, set ownership and permissions of sensitive applications to only allow authorized users. As the root user:

chown -v root:wireshark /usr/bin/{tshark,dumpcap} &&
chmod -v 6550 /usr/bin/{tshark,dumpcap}

Finally, add any users to the wireshark group (as root user):

usermod -a -G wireshark <username>

If you are installing wireshark for the first time, it will be necessary to logout of your session and login again. This will put wireshark in your groups, because otherwise Wireshark will not function properly.

Configuring Wireshark

Config Files

/etc/wireshark.conf and ~/.config/wireshark/* (unless there is already ~/.wireshark/* in the system)

Configuration Information

Though the default configuration parameters are very sane, reference the configuration section of the Wireshark User's Guide for configuration information. Most of Wireshark 's configuration can be accomplished using the menu options of the wireshark graphical interfaces.

Note

If you want to look at packets, make sure you don't filter them out with iptables-1.8.7. If you want to exclude certain classes of packets, it is more efficient to do it with iptables than it is with Wireshark.

Contents

Installed Programs: capinfos, captype, dumpcap, editcap, idl2wrs, mergecap, randpkt, rawshark, reordercap, sharkd, text2pcap, tshark, and wireshark
Installed Libraries: libwireshark.so, libwiretap.so, libwsutil.so, and numerous modules under /usr/lib/wireshark/plugins
Installed Directories: /usr/{include,lib,share}/wireshark and /usr/share/doc/wireshark-3.6.2

Short Descriptions

capinfos

reads a saved capture file and returns any or all of several statistics about that file. It is able to detect and read any capture supported by the Wireshark package

captype

prints the file types of capture files

dumpcap

is a network traffic dump tool. It lets you capture packet data from a live network and write the packets to a file

editcap

edits and/or translates the format of capture files. It knows how to read libpcap capture files, including those of tcpdump, Wireshark and other tools that write captures in that format

idl2wrs

is a program that takes a user specified CORBA IDL file and generates C source code for a Wireshark plugin. It relies on two Python programs wireshark_be.py and wireshark_gen.py, which are not installed by default. They have to be copied manually from the tools directory to the $PYTHONPATH/site-packages/ directory

mergecap

combines multiple saved capture files into a single output file

randpkt

creates random-packet capture files

rawshark

dumps and analyzes raw libpcap data

reordercap

reorders timestamps of input file frames into an output file

sharkd

is a daemon that listens on UNIX sockets

text2pcap

reads in an ASCII hex dump and writes the data described into a libpcap-style capture file

tshark

is a TTY-mode network protocol analyzer. It lets you capture packet data from a live network or read packets from a previously saved capture file

wireshark

is the Qt GUI network protocol analyzer. It lets you interactively browse packet data from a live network or from a previously saved capture file

libwireshark.so

contains functions used by the Wireshark programs to perform filtering and packet capturing

libwiretap.so

is a library being developed as a future replacement for libpcap, the current standard Unix library for packet capturing. For more information, see the README file in the source wiretap directory

Last updated on

Chapter 17. Networking Libraries

These applications are support libraries for other applications in the book. It is unlikely that you would just install these libraries, you will generally find that you will be referred to this chapter to satisfy a dependency of other applications.

c-ares-1.18.1

Introduction to c-ares

c-ares is a C library for asynchronous DNS requests.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

c-ares Dependencies

Required

CMake-3.22.2

Installation of c-ares

Install c-ares by running the following commands:

mkdir build &&
cd    build &&

cmake  -DCMAKE_INSTALL_PREFIX=/usr .. &&
make

This package does not include a test suite.

Now, as the root user:

make install

Contents

Installed Programs: acountry, adig, and ahost
Installed Libraries: libcares.so
Installed Directories: None

Short Descriptions

acountry

prints the country where an IPv4 address or host is located

adig

queries information from DNS servers

ahost

prints the A or AAAA record associated with a hostname or IP address

libcares.so

is a C library for asynchronous DNS requests

Last updated on

cURL-7.81.0

Introduction to cURL

The cURL package contains an utility and a library used for transferring files with URL syntax to any of the following protocols: FTP, FTPS, HTTP, HTTPS, SCP, SFTP, TFTP, TELNET, DICT, LDAP, LDAPS and FILE. Its ability to both download and upload files can be incorporated into other programs to support functions like streaming media.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://curl.se/download/curl-7.81.0.tar.xz

  • Download MD5 sum: 41954fa09f879fccb57d88be23fe8606

  • Download size: 2.4 MB

  • Estimated disk space required: 100 MB (add 20 MB for tests)

  • Estimated build time: 0.2 SBU (with parallelism=4; add 19 SBU for tests)

cURL Dependencies

Recommended
Optional

Brotli-1.0.9, c-ares-1.18.1, GnuTLS-3.7.3, libidn2-2.3.2, libpsl-0.21.1, libssh2-1.10.0, MIT Kerberos V5-1.19.2, nghttp2-1.46.0, OpenLDAP-2.6.1, Samba-4.15.5, impacket, libmetalink, librtmp, ngtcp2, quiche, and SPNEGO

Optional if Running the Test Suite

stunnel-5.62 (for the HTTPS and FTPS tests) and Valgrind-3.18.1 (this will slow the tests down and may cause failures.)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/curl

Installation of cURL

Install cURL by running the following commands:

./configure --prefix=/usr                           \
            --disable-static                        \
            --with-openssl                          \
            --enable-threaded-resolver              \
            --with-ca-path=/etc/ssl/certs &&
make

To run the test suite, issue: make test. Four tests, 1139, 1140, 1173, and 1177, are known to fail due to missing executables from the optional dependencies.

Now, as the root user:

make install &&

rm -rf docs/examples/.deps &&

find docs \( -name Makefile\* -o -name \*.1 -o -name \*.3 \) -exec rm {} \; &&

install -v -d -m755 /usr/share/doc/curl-7.81.0 &&
cp -v -R docs/*     /usr/share/doc/curl-7.81.0

Simple tests to the new installed curl: curl --trace-ascii debugdump.txt http://www.example.com/ and curl --trace-ascii d.txt --trace-time http://example.com/. Inspect the locally created trace files debugdump.txt and d.txt, which contain version downloaded files information, etc. One file has the time for each action logged.

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-threaded-resolver: This switch enables cURL's builtin threaded DNS resolver.

--with-ca-path=/etc/ssl/certs: This switch sets the location of the BLFS Certificate Authority store.

--with-openssl: This parameter chooses OpenSSL as SSL/TLS implementation. This seems mandatory now.

--with-gssapi: This parameter adds Kerberos 5 support to libcurl.

--without-ssl --with-gnutls: Use to build with GnuTLS support instead of OpenSSL for SSL/TLS.

--with-ca-bundle=/etc/pki/tls/certs/ca-bundle.crt: Use this switch instead of --with-ca-path if building with GnuTLS support instead of OpenSSL for SSL/TLS.

--with-libssh2: This parameter adds SSH support to cURL. This is disabled by default.

--enable-ares: This parameter adds support for DNS resolution through the c-ares library. It is disabled by default, but does speed up DNS resolution queries.

find docs ... -exec rm {} \;: This command removes Makefiles and man files from the documentation directory that would otherwise be installed by the commands that follow.

Contents

Installed Programs: curl and curl-config
Installed Library: libcurl.so
Installed Directories: /usr/include/curl and /usr/share/doc/curl-7.81.0

Short Descriptions

curl

is a command line tool for transferring files with URL syntax

curl-config

prints information about the last compile, like libraries linked to and prefix setting

libcurl.so

provides the API functions required by curl and other programs

Last updated on

GeoClue-2.6.0

Introduction to GeoClue

GeoClue is a modular geoinformation service built on top of the D-Bus messaging system. The goal of the GeoClue project is to make creating location-aware applications as simple as possible.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GeoClue Dependencies

Required

JSON-GLib-1.6.6 and libsoup-2.74.2

Recommended
Optional

GTK-Doc-1.33.2 and libnotify-0.7.9

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/geoclue2

Installation of GeoClue

Install GeoClue by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release -Dgtk-doc=false .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-D3g-source=false: This switch disables the 3G backend. Use it if you have not installed the ModemManager package.

-Dmodem-gps-source=false: This switch disables the modem GPS backend. Use it if you have not installed the ModemManager package.

-Dcdma-source=false: This switch disables the CDMA source backend. Use it if you have not installed the ModemManager package.

-Dnmea-source=false: This switch disables the NMEA source. Use it if you have not installed the Avahi package.

-Ddemo-agent=false: This switch disables the demo. Use it if you have not installed the libnotify package.

Contents

Installed Programs: None
Installed Libraries: libgeoclue-2.so
Installed Directories: /etc/geoclue, /usr/include/libgeoclue-2.0, /usr/libexec/geoclue-2.0, and /usr/share/gtk-doc/html/{geoclue,libgeoclue}

Last updated on

glib-networking-2.70.1

Introduction to GLib Networking

The GLib Networking package contains Network related gio modules for GLib.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GLib Networking Dependencies

Required

GLib-2.70.4 and GnuTLS-3.7.3

Recommended
Optional

libproxy

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/glib-networking

Installation of GLib Networking

Install GLib Networking by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr       \
      --buildtype=release &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Program: None
Installed Libraries: libgiognomeproxy.so and libgiognutls.so (GIO Modules installed in /usr/lib/gio/modules)
Installed Directories: None

Last updated on

kdsoap-2.0.0

Introduction to kdsoap

The kdsoap is Qt-based client-side and server-side SOAP component. It can be used to create client applications for web services and also provides the means to create web services without the need for any further component such as a dedicated web server.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

kdsoap Dependencies

Required

Qt-5.15.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/kdsoap

Installation of kdsoap

Install kdsoap by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_BUILD_TYPE=Release  \
      -DCMAKE_INSTALL_DOCDIR=/usr/share/doc/kdsoap-2.0.0 \
      .. &&
make

The package does not come with atest suite.

Now, as the root user:

make install

Contents

Installed Programs: kdwsdl2cpp
Installed Libraries: libkdsoap.so and libkdsoap-server.so
Installed Directories: /usr/lib/cmake/KDSoap, /usr/share/doc/kdsoap-2.0.0, /usr/include/KDSoapClient. and /usr/include/KDSoapServer

ldns-1.8.1

Introduction to ldns

ldns is a fast DNS library with the goal to simplify DNS programming and to allow developers to easily create software conforming to current RFCs and Internet drafts. This packages also includes the drill tool.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

ldns Dependencies

Optional

make-ca-1.10 and libpcap-1.10.1 (for example programs), Python-2.7.18 and SWIG-4.0.2 (for Python bindings), and Doxygen-1.9.3 (for html documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/ldns

Installation of ldns

Install ldns by running the following commands:

./configure --prefix=/usr           \
            --sysconfdir=/etc       \
            --disable-static        \
            --with-drill            &&
make

If you have Doxygen-1.9.3 installed and want to build html documentation, run the following command:

make doc

This package does not come with a working test suite.

Now, as the root user:

make install

If you built html documentation, install it by running the following commands as the root user:

install -v -m755 -d /usr/share/doc/ldns-1.8.1 &&
install -v -m644 doc/html/* /usr/share/doc/ldns-1.8.1

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--with-drill: This option enables building of the drill tool (used for obtaining debug information from DNS(SEC))

--disable-dane-ta-usage: This option disables DANE-TA (DNS-Based Authentication of Named Entities) support. It is only needed if OpenSSL-1.1.0 or later is not installed.

--with-examples: This option enables building of the example programs.

--with-pyldns: This option enables building of the Python bindings.

Contents

Installed Programs: drill and ldns-config
Installed Library: libldns.so and /usr/lib/python2.7/site-packages/_ldns.so
Installed Directories: /usr/include/ldns and /usr/share/doc/ldns-1.8.1

Short Descriptions

drill

is a tool like dig from BIND Utilities-9.18.0 designed to get all sorts of information out of the DNS

ldns-config

shows compiler and linker flags for ldns usage

libldns.so

provides the ldns API functions to programs

Last updated on

libevent-2.1.12

Introduction to libevent

libevent is an asynchronous event notification software library. The libevent API provides a mechanism to execute a callback function when a specific event occurs on a file descriptor or after a timeout has been reached. Furthermore, libevent also supports callbacks due to signals or regular timeouts.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libevent Dependencies

Optional

Doxygen-1.9.3 (for API documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libevent

Installation of libevent

First, fix an issue that prevents rpcgen_event.py from working:

sed -i 's/python/&3/' event_rpcgen.py

Install libevent by running the following commands:

./configure --prefix=/usr --disable-static &&
make

If you have Doxygen-1.9.3 installed and wish to build API documentation, issue :

doxygen Doxyfile

To test the results, issue: make verify. Six tests in every suite related to regress_ssl.c and regress_http.c are known to fail due to incompatibilities with OpenSSL-3.

Now, as the root user:

make install

If you built the API documentation, install it by issuing the following commands as the root user:

install -v -m755 -d /usr/share/doc/libevent-2.1.12/api &&
cp      -v -R       doxygen/html/* \
                    /usr/share/doc/libevent-2.1.12/api

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Program: event_rpcgen.py
Installed Libraries: libevent_core.so, libevent_extra.so, libevent_openssl.so, libevent_pthreads.so and libevent.so
Installed Directory: /usr/include/event2 and /usr/share/doc/libevent-2.1.12

Last updated on

libmnl-1.0.4

Introduction to libmnl

The libmnl library provides a minimalistic user-space library oriented to Netlink developers. There are a lot of common tasks in parsing, validating, constructing of both the Netlink header and TLVs that are repetitive and easy to get wrong. This library aims to provide simple helpers that allows you to re-use code and to avoid re-inventing the wheel.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libmnl

Installation of libmnl

Install libmnl by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Library: libmnl.so

Short Descriptions

libmnl.so

provides functions for parsing, validating, constructing of both the Netlink header and TLVs

Last updated on

libnl-3.5.0

Introduction to libnl

The libnl suite is a collection of libraries providing APIs to netlink protocol based Linux kernel interfaces.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Optional Download

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libnl

Installation of libnl

Install libnl by running the following commands:

./configure --prefix=/usr     \
            --sysconfdir=/etc \
            --disable-static  &&
make

To test the results, issue: make check.

Now, as the root user:

make install

If you wish to install the API documentation, as the root user:

mkdir -vp /usr/share/doc/libnl-3.5.0 &&
tar -xf ../libnl-doc-3.5.0.tar.gz --strip-components=1 --no-same-owner \
    -C  /usr/share/doc/libnl-3.5.0

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--disable-cli: Use this parameter if you don't want to install cli tools provided by the package.

Contents

Installed Programs: genl-ctrl-list, idiag-socket-details, nl-class-add, nl-class-delete, nl-classid-lookup, nl-class-list, nl-cls-add, nl-cls-delete, nl-cls-list, nl-link-list, nl-pktloc-lookup, nl-qdisc-add, nl-qdisc-delete, nl-qdisc-list, and 48 other helper programs with nl- and nf- prefixes
Installed Libraries: libnl-3.so, libnl-cli-3.so, libnl-genl-3.so, libnl-idiag-3.so, libnl-nf-3.so, libnl-route-3.so, libnl-xfrm-3.so, and cli modules under /usr/lib/libnl/cli tree
Installed Directories: /etc/libnl, /usr/include/libnl3, /usr/lib/libnl, and /usr/share/doc/libnl-3.5.0

Short Descriptions

genl-ctrl-list

queries the Generic Netlink controller in the kernel and prints a list of all registered Generic Netlink families including the version of the interface that has been registered

nl-class-add

adds, updates, or replaces Traffic Classes

nl-class-delete

deletes Traffic Classes

nl-classid-lookup

is used to resolve qdisc/class names to classid values and vice versa

nl-class-list

lists Traffic Classes

nl-cls-add

adds a classifier

nl-cls-delete

deletes a classifier

nl-cls-list

lists classifiers

nl-link-list

dumps link attributes

nl-pktloc-lookup

allows the lookup of packet location definitions

nl-qdisc-add

adds queueing disciplines (qdiscs) in the kernel

nl-qdisc-delete

deletes queueing disciplines (qdiscs) in the kernel

nl-qdisc-list

lists queueing disciplines (qdiscs) in the kernel

libnl*-3.so

These libraries contain API functions used to access Netlink interfaces in Linux kernel

Last updated on

libnma-1.8.34

Introduction to libnma

The libnma package contains an implementation of the NetworkManager GUI functions.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libnma Dependencies

Required

Gcr-3.40.0, GTK+-3.24.31, ISO Codes-4.9.0, and NetworkManager-1.34.0

Recommended
Optional

mobile-broadband-provider-info

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libnma

Installation of libnma

Install libnma by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr                             \
      --buildtype=release                       \
      -Dgtk_doc=false                           \
      -Dmobile_broadband_provider_info=false .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dgtk_doc=false: This parameter disables generating API documentation using gtk-doc. If you have GTK-Doc-1.33.2 installed and wish to generate the API documentation, omit this switch.

-Dmobile_broadband_provider_info=false: This switch disables WWAN support because mobile-broadband-provider-info is not in BLFS. Omit this switch if you have it installed and wish to enable WWAN support.

Contents

Installed Programs: None
Installed Libraries: libnma.so
Installed Directories: /usr/include/libnma

Short Descriptions

libnma.so

contains the NetworkManager GUI library

Last updated on

libnsl-2.0.0

Introduction to libnsl

The libnsl package contains the public client interface for NIS(YP). It replaces the NIS library that used to be in glibc.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libnsl Dependencies

Required

rpcsvc-proto-1.4.3 and libtirpc-1.3.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libnsl

Installation of libnsl

Install libnsl by running the following commands:

./configure --sysconfdir=/etc --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Libraries: libnsl.so
Installed Directories: None

Short Descriptions

libnsl.so

provides the NIS (YP) API functions required by other programs

Last updated on

libpcap-1.10.1

Introduction to libpcap

libpcap provides functions for user-level packet capture, used in low-level network monitoring.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libpcap Dependencies

Optional

BlueZ-5.63, libnl-3.5.0, libusb-1.0.25, Software distribution for the DAG, and Septel range of passive network monitoring cards.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libpcap

Installation of libpcap

Install libpcap by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

If you want to disable installing the static library, use this sed:

sed -i '/INSTALL_DATA.*libpcap.a\|RANLIB.*libpcap.a/ s/^/#/' Makefile

Now, as the root user:

make install

Contents

Installed Program: pcap-config
Installed Libraries: libpcap.so
Installed Directory: /usr/include/pcap

Short Descriptions

pcap-config

provides configuration information for libpcap

libpcap.{a,so}

are libraries used for user-level packet capture

Last updated on

libpsl-0.21.1

Introduction to libpsl

The libpsl package provides a library for accessing and resolving information from the Public Suffix List (PSL). The PSL is a set of domain names beyond the standard suffixes, such as .com.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libpsl Dependencies

Required

libidn2-2.3.2

Optional

GTK-Doc-1.33.2 (for documentation) and Valgrind-3.18.1 (for tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libpsl

Installation of libpsl

Install libpsl by running the following commands:

sed -i 's/env python/&3/' src/psl-make-dafsa &&
./configure --prefix=/usr --disable-static       &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

sed -i ...: This command forces the use of Python 3 in an utility.

Contents

Installed Program: psl
Installed Library: libpsl.so
Installed Directories: None

Short Descriptions

psl

queries the Public Suffix List

libpsl.so

contains a library used to access the Public Suffix List

Last updated on

libndp-1.8

Introduction to libndp

The libndp package provides a wrapper for IPv6 Neighbor Discovery Protocol. It also provides a tool named ndptool for sending and receiving NDP messages.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): http://libndp.org/files/libndp-1.8.tar.gz

  • Download MD5 sum: c7e775fd5a9d676e8cba9c3732c4df93

  • Download size: 360 KB

  • Estimated disk space required: 2.5 MB

  • Estimated build time: less than 0.1 SBU

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libndp

Installation of libndp

Install libndp by running the following command:

./configure --prefix=/usr        \
            --sysconfdir=/etc    \
            --localstatedir=/var \
            --disable-static     &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Program: ndptool
Installed Library: libndp.so
Installed Directory: None

Short Descriptions

ndptool

is a tool for sending and receiving NDP messages

libndp.so

provides a wrapper for the IPv6 Neighbor Discovery Protocol

Last updated on

libsoup-2.74.2

Introduction to libsoup

The libsoup is a HTTP client/server library for GNOME. It uses GObject and the GLib main loop to integrate with GNOME applications and it also has an asynchronous API for use in threaded applications.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Warning

You may have noticed newer libsoup releases versioned 3.x.y is available. However, currently some downstream packages support libsoup-3.x, while the others do not. Installing libsoup-3.x into BLFS is known to cause troubles, even if both libsoup-2.x and 3.x are installed. So, do not install libsoup-3.x into BLFS unless you know what you are doing. We plan to keep using libsoup-2.x for BLFS until GNOME-42 release.

libsoup Dependencies

Required

glib-networking-2.70.1, libpsl-0.21.1, libxml2-2.9.13, and SQLite-3.37.2

Recommended
Optional

Apache-2.4.52 (required to run the test suite), Brotli-1.0.9, cURL-7.81.0 (required to run the test suite), sysprof-3.42.1 (for profiling), MIT Kerberos V5-1.19.2 (required to run the test suite), GTK-Doc-1.33.2, PHP-8.1.3 compiled with XMLRPC-EPI support (only used for the XMLRPC regression tests), and Samba-4.15.5 (ntlm_auth is required to run the test suite)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libsoup

Installation of libsoup

Install libsoup by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr       \
      --buildtype=release \
      -Dvapi=enabled      \
      -Dgssapi=disabled   \
      -Dsysprof=disabled  \
      ..                  &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dvapi=disabled: Use this if you have not installed Vala, e.g. because you are not building GNOME.

-Ddoc=enabled: Use this option if you want to build the documentation. Note that you must have GTK-Doc-1.33.2 installed.

-Dgssapi=disabled: libsoup defaults to building with GSSAPI support, which requires Kerberos (as does the test suite). If you are building GNOME or have kerberos installed, remove this option.

-Dsysprof=disabled: libsoup will automatically download a git version of sysprof-3.42.1 if git is available or use the installed version if available. If you need profiling, remove this option.

Contents

Installed Programs: None
Installed Libraries: libsoup-2.4.so and libsoup-gnome-2.4.so
Installed Directories: /usr/include/libsoup-2.4, /usr/include/libsoup-gnome-2.4 and /usr/share/gtk-doc/html/libsoup-2.4

Short Descriptions

libsoup-2.4.so

provides functions for asynchronous HTTP connections

libsoup-gnome-2.4.so

provides GNOME specific features

Last updated on

libtirpc-1.3.2

Introduction to libtirpc

The libtirpc package contains libraries that support programs that use the Remote Procedure Call (RPC) API. It replaces the RPC, but not the NIS library entries that used to be in glibc.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libtirpc Dependencies

Optional

MIT Kerberos V5-1.19.2 for the GSSAPI

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libtirpc

Installation of libtirpc

Note

If updating this package, you will also need to update any existing version of rpcbind-1.2.6

./configure --prefix=/usr                                   \
            --sysconfdir=/etc                               \
            --disable-static                                \
            --disable-gssapi                                &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--disable-gssapi: This switch is needed if no GSSAPI is installed. Remove this switch if you have one installed (for example MIT Kerberos V5-1.19.2) and you wish to use it.

Contents

Installed Programs: None
Installed Libraries: libtirpc.so
Installed Directory: /usr/include/tirpc

Short Descriptions

libtirpc.so

provides the Remote Procedure Call (RPC) API functions required by other programs

Last updated on

neon-0.32.2

Introduction to neon

neon is an HTTP and WebDAV client library, with a C interface.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://notroj.github.io/neon/neon-0.32.2.tar.gz

  • Download MD5 sum: 09dd5c5e2cf4a0e01b20dd62767a1df7

  • Download size: 864 KB

  • Estimated disk space required: 6.6 MB (additional 20 MB for tests)

  • Estimated build time: less than 0.1 SBU (add 0.5 SBU for tests)

neon Dependencies

Optional

GnuTLS-3.7.3, libxml2-2.9.13, MIT Kerberos V5-1.19.2, xmlto-0.0.28 (to regenerate the documentation), libproxy, and PaKChoiS

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/neon

Installation of neon

Install neon by running the following commands:

./configure --prefix=/usr    \
            --with-ssl       \
            --enable-shared  \
            --disable-static &&
make

To test the results, issue: make check.

If you wish to regenerate the documentation, issue:

make docs

Now, as the root user:

make install

Command Explanations

--with-ssl: This switch enables SSL support using OpenSSL. GnuTLS can be used instead, by passing --with-ssl=gnutls and --with-ca-bundle=/etc/pki/tls/certs/ca-bundle.crt to the configure script.

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Program: neon-config
Installed Library: libneon.so
Installed Directories: /usr/include/neon and /usr/share/doc/neon-0.32.2

Short Descriptions

neon-config

is a script that provide information about an installed copy of the neon library

libneon.so

is used as a high-level interface to common HTTP and WebDAV methods

Last updated on

nghttp2-1.46.0

Introduction to nghttp2

nghttp2 is an implementation of HTTP/2 and its header compression algorithm, HPACK.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

nghttp2 Dependencies

Recommended

libxml2-2.9.13

Optional

Boost-1.78.0, c-ares-1.18.1, jansson-2.14, libevent-2.1.12, CUnit (required for the testsuite), Cython, jemalloc, libev, mruby, Spdylay, and Sphinx.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/nghttp2

Installation of nghttp2

Install nghttp2 by running the following commands:

./configure --prefix=/usr     \
            --disable-static  \
            --enable-lib-only \
            --docdir=/usr/share/doc/nghttp2-1.46.0 &&
make

This package does not come with a usable test suite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-lib-only: only build libnghttp2. Omit this switch if you'd like to build the example applications, Python bindings, or the C++ asio library.

Contents

Installed Programs: None
Installed Libraries: libnghttp2.so
Installed Directories: /usr/include/nghttp2, /usr/share/nghttp2, and /usr/share/doc/nghttp2-1.46.0

Short Descriptions

libnghttp2.so

an implementation of the Hypertext Transfer Protocol version 2 in C

Last updated on

rpcsvc-proto-1.4.3

Introduction to rpcsvc-proto

The rpcsvc-proto package contains the rcpsvc protocol files and headers, formerly included with glibc, that are not included in replacement libtirpc-1.3.2, along with the rpcgen program.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/rpcsvc-proto

Installation of rpcsvc-proto

Install rpcsvc-proto by running the following commands:

./configure --sysconfdir=/etc &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: rpcgen
Installed Libraries: None
Installed Directories: /usr/include/rpcsvc

Short Descriptions

rpcgen

Generates C code to implement the RPC protocol

Last updated on

Serf-1.3.9

Introduction to Serf

The Serf package contains a C-based HTTP client library built upon the Apache Portable Runtime (APR) library. It multiplexes connections, running the read/write communication asynchronously. Memory copies and transformations are kept to a minimum to provide high performance operation.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Serf Dependencies

Required

Apr-Util-1.6.1 and SCons-4.3.0

Optional

MIT Kerberos V5-1.19.2, for the GSSAPI

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/serf

Installation of Serf

First, fix an issue that causes compilation issues in other packages when using OpenSSL-3:

patch -Np1 -i ../serf-1.3.9-openssl3_fixes-1.patch

Install Serf by running the following commands:

sed -i "/Append/s:RPATH=libdir,::"          SConstruct &&
sed -i "/Default/s:lib_static,::"           SConstruct &&
sed -i "/Alias/s:install_static,::"         SConstruct &&
sed -i "/  print/{s/print/print(/; s/$/)/}" SConstruct &&
sed -i "/get_contents()/s/,/.decode()&/"    SConstruct &&

scons PREFIX=/usr

This package does not come with a functional testsuite.

Now, as the root user:

scons PREFIX=/usr install

Command Explanations

sed -i "...": The first command removes the runtime path from a shared library and the next two commands disable building and installing of the static library. The fourth command corrects for changes in scons-3.x. The last command allows to use Python 3.

GSSAPI=/usr: Use this switch if you have installed a GSSAPI library and you want serf to use it.

Contents

Installed Programs: None
Installed Library: libserf-1.so
Installed Directory: /usr/include/serf-1

Short Descriptions

libserf-1.so

contains the Serf API functions

Last updated on

uhttpmock-0.5.3

Introduction to uhttpmock

The uhttpmock package contains a library for mocking web service APIs which use HTTP or HTTPS.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

uhttpmock Dependencies

Required

libsoup-2.74.2

Recommended
Optional

GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/uhttpmock

Installation of uhttpmock

Install uhttpmock by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Libraries: libuhttpmock-0.0.so
Installed Directories: /usr/include/libuhttpmock-0.0 and /usr/share/gtk-doc/html/libuhttpmock-0.0

Short Descriptions

libuhttpmock-0.0.so

contains the uhttpmock API functions

Last updated on

Chapter 18. Text Web Browsers

People who are new to Unix-based systems tend to ask the question "Why on earth would I want a text-mode browser? I'm going to compile X and use Konqueror/Mozilla/Whatever!". Those who have been around systems for a while know that when (not if) you manage to mess up your graphical browser install and you need to look up some information on the web, a console based browser will save you. Also, there are quite a few people who prefer to use one of these browsers as their primary method of browsing; either to avoid the clutter and bandwidth which accompanies images or because they may use a text-to-speech synthesizer which can read the page to them (of use for instance to partially sighted or blind users). In this chapter you will find installation instructions for three console web browsers:

Links-2.25

Introduction to Links

Links is a text and graphics mode WWW browser. It includes support for rendering tables and frames, features background downloads, can display colors and has many other features.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Links Dependencies

Recommended
Optional

Graphics mode requires at least one of GPM-1.20.7 (mouse support to be used with a framebuffer-based console), SVGAlib, DirectFB , and a graphical environment

For decoding various image formats Links can utilize libpng-1.6.37, libjpeg-turbo-2.1.2, librsvg-2.52.6, and libtiff-4.3.0

For decompressing web pages that are compressed with Brotli, Links can utilize Brotli-1.0.9

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/LinksBrowser

Installation of Links

Install Links by running the following commands:

./configure --prefix=/usr --mandir=/usr/share/man &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&
install -v -d -m755 /usr/share/doc/links-2.25 &&
install -v -m644 doc/links_cal/* KEYS BRAILLE_HOWTO \
    /usr/share/doc/links-2.25

Command Explanations

--enable-graphics: This switch enables support for graphics mode.

Configuring Links

Config Files

~/.links/*

Configuration Information

Links stores its configuration in per-user files in the ~/.links directory. These files are created automatically when links is run for the first time.

Contents

Installed Program: links
Installed Libraries: None
Installed Directories: /usr/share/doc/links-2.25

Short Descriptions

links

is a text and graphics mode WWW browser

Last updated on

Lynx-2.8.9rel.1

Introduction to Lynx

Lynx is a text based web browser.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Lynx Dependencies

Optional

GnuTLS-3.7.3 (experimental, to replace openssl), Zip-3.0, UnZip-6.0, an MTA (that provides a sendmail command), and Sharutils-4.15.2 (for the uudecode program)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Lynx

Installation of Lynx

First, apply a patch to fix a security vulnerability:

patch -p1 -i ../lynx-2.8.9rel.1-security_fix-1.patch

Install Lynx by running the following commands:

./configure --prefix=/usr          \
            --sysconfdir=/etc/lynx \
            --datadir=/usr/share/doc/lynx-2.8.9rel.1 \
            --with-zlib            \
            --with-bzlib           \
            --with-ssl             \
            --with-screen=ncursesw \
            --enable-locale-charset &&
make

This package does not come with a test suite.

Now, as the root user:

make install-full &&
chgrp -v -R root /usr/share/doc/lynx-2.8.9rel.1/lynx_doc

Command Explanations

--sysconfdir=/etc/lynx: This parameter is used so that the configuration files are located in /etc/lynx instead of /usr/etc.

--datadir=/usr/share/doc/lynx-2.8.9rel.1: This parameter is used so that the documentation files are installed into /usr/share/doc/lynx-2.8.9rel.1 instead of /usr/share/lynx_{doc,help}.

--with-zlib: This enables support for linking libz into Lynx.

--with-bzlib: This enables support for linking libbz2 into Lynx.

--with-ssl: This enables support for linking SSL into Lynx.

--with-screen=ncursesw: This switch enables the use of advanced wide-character support present in the system NCurses library. This is needed for proper display of characters and line wrapping in multibyte locales.

--enable-locale-charset: This switch allows Lynx to deduce the proper character encoding for terminal output from the current locale. A configuration step is still needed (see below), but unlike the situation without this switch, the configuration step becomes the same for all users (without the switch one must specify the display character set explicitly). This is important for environments such as a LiveCD, where the amount of system-specific configuration steps has to be reduced to the minimum.

--enable-ipv6: This switch allows Lynx to use IPv6, along with IPv4. Use it if your ISP provides an IPv6 configuration.

--enable-nls: This switch allows Lynx to print translated messages (such as questions about cookies and SSL certificates).

--with-gnutls: This enables experimental support for linking GnuTLS into Lynx. Remove the --with-ssl switch if you want to use gnutls.

make install-full: In addition to the standard installation, this target installs the documentation and help files.

chgrp -v -R root /usr/share/doc/lynx-2.8.9rel.1/lynx_doc : This command corrects the improper group ownership of installed documentation files.

Configuring Lynx

Config Files

/etc/lynx/lynx.cfg

Configuration Information

The proper way to get the display character set is to examine the current locale. However, Lynx does not do this by default. As the root user, change this setting:

sed -e '/#LOCALE/     a LOCALE_CHARSET:TRUE'     \
    -i /etc/lynx/lynx.cfg

The built-in editor in Lynx Breaks Multibyte Characters. This issue manifests itself in multibyte locales, e.g., as the Backspace key not erasing non-ASCII characters properly, and as incorrect data being sent to the network when one edits the contents of text areas. The only solution to this problem is to configure Lynx to use an external editor (bound to the Ctrl+X e key combination by default). Still as the root user:

sed -e '/#DEFAULT_ED/ a DEFAULT_EDITOR:vi'       \
    -i /etc/lynx/lynx.cfg

Lynx handles the following values of the DEFAULT_EDITOR option specially by adding cursor-positioning arguments: emacs, jed, jmacs, joe, jove, jpico, jstar, nano, pico, rjoe, vi (but not vim: in order to position the cursor in Vim-8.2.4383, set this option to vi).

By default, Lynx doesn't save cookies between sessions. Again as the root user, change this setting:

sed -e '/#PERSIST/    a PERSISTENT_COOKIES:TRUE' \
    -i /etc/lynx/lynx.cfg

Many other system-wide settings such as proxies can also be set in the /etc/lynx/lynx.cfg file.

Contents

Installed Program: lynx
Installed Libraries: None
Installed Directories: /etc/lynx and /usr/share/doc/lynx-2.8.9rel.1

Short Descriptions

lynx

is a general purpose, text-based, distributed information browser for the World Wide Web

Last updated on

Chapter 19. Mail/News Clients

Mail Clients help you retrieve (Fetchmail), sort (Procmail), read and compose responses (Heirloom mailx, Mutt, Pine, Kmail, Balsa, Evolution, SeaMonkey) to email.

News clients also help you retrieve, sort, read and compose responses, but these messages travel through USENET (a worldwide bulletin board system) using the Network News Transfer Protocol (NNTP).

Fetchmail-6.4.27

Introduction to Fetchmail

The Fetchmail package contains a mail retrieval program. It retrieves mail from remote mail servers and forwards it to the local (client) machine's delivery system, so it can then be read by normal mail user agents.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Fetchmail Dependencies

Recommended
Optional

MIT Kerberos V5-1.19.2 and libgssapi

Optional (for running fetchmailconf)

Python-3.10.2, built after Tk-8.6.12, with the py-future package

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/fetchmail

Installation of Fetchmail

Create a dedicated user for the fetchmail program. Issue the following commands as the root user:

useradd -c "Fetchmail User" -d /dev/null -g nogroup \
        -s /bin/false -u 38 fetchmail

Install Fetchmail by running the following commands:

PYTHON=python3 \
./configure --prefix=/usr \
            --enable-fallback=procmail &&
make

To test the results, issue: make check.

Now, as the root user:

make install                                  &&
chown -v fetchmail:nogroup /usr/bin/fetchmail

Command Explanations

PYTHON=python3: a version of Python is required, but only used to install a module to allow fetchmailconf to be run. That module is unmaintained and should not be used.

--enable-fallback=procmail: This tells Fetchmail to hand incoming mail to Procmail for delivery, if the port 25 mail server is not present or not responding.

Configuring Fetchmail

Config Files

~/.fetchmailrc

Configuration Information

Note

If you are connecting to a mailserver that supports SSL/TLS-wrapped or "implicit" mode on a dedicated port (default 993) you should use fetchmail --ssl or add the option 'ssl' in an rcfile.

cat > ~/.fetchmailrc << "EOF"

# The logfile needs to exist when fetchmail is invoked, otherwise it will
# dump the details to the screen. As with all logs, you will need to rotate
# or clear it from time to time.
set logfile fetchmail.log
set no bouncemail
# You probably want to set your local username as the postmaster
set postmaster <username>

poll SERVERNAME :
    user <isp_username> pass <password>;
    mda "/usr/bin/procmail -f %F -d %T";
EOF

touch ~/fetchmail.log       &&
chmod -v 0600 ~/.fetchmailrc

This is an example configuration that should suffice for most people. You can add as many users and servers as you need using the same syntax.

man fetchmail: Look for the section near the bottom named CONFIGURATION EXAMPLES. It gives some quick examples. There are countless other configuration options once you get used to it.

If you expect to receive very little mail you can invoke fetchmail when you wish to receive any incoming mail. More commonly, it is either invoked in daemon mode with the -d option either on the command line, or in .fetchmailrc (see 'DAEMON MODE' in man fetchmailconf), or alternatively it is invoked from a cron job.

Contents

Installed Programs: fetchmail and fetchmailconf
Installed Libraries: None
Installed Directories: None

Short Descriptions

fetchmail

when executed as a user, this will source ~/.fetchmailrc and download the appropriate mail

fetchmailconf

is intended to assist you in setting up and editing a ~/.fetchmailrc configuration file, by using a Tk GUI interface. It is written for Python and the Tkinter module but is labelled with a WARNING that it needs to be updated for fetchmail 6.4's SSL options and other recent new options

Last updated on

mailx-12.5

Introduction to Heirloom mailx

The Heirloom mailx package (formerly known as the Nail package) contains mailx, a command-line Mail User Agent derived from Berkeley Mail. It is intended to provide the functionality of the POSIX mailx command with additional support for MIME messages, IMAP (including caching), POP3, SMTP, S/MIME, message threading/sorting, scoring, and filtering. Heirloom mailx is especially useful for writing scripts and batch processing.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Heirloom mailx Dependencies

Optional

nss-3.75, MIT Kerberos V5-1.19.2 (for IMAP GSSAPI authentication), and an MTA

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/mailx

Installation of Heirloom mailx

Note

This package does not support parallel build.

Install Heirloom mailx by running the following commands.

patch -Np1 -i ../heirloom-mailx-12.5-fixes-1.patch &&

sed 's@<openssl@<openssl-1.0/openssl@' \
    -i openssl.c fio.c makeconfig      &&

make -j1 LDFLAGS+="-L /usr/lib/openssl/" \
         SENDMAIL=/usr/sbin/sendmail

This package does not come with a test suite.

Now, as the root user:

make PREFIX=/usr UCBINSTALL=/usr/bin/install install &&

ln -v -sf mailx /usr/bin/mail &&
ln -v -sf mailx /usr/bin/nail &&

install -v -m755 -d     /usr/share/doc/heirloom-mailx-12.5 &&
install -v -m644 README /usr/share/doc/heirloom-mailx-12.5

Command Explanations

make SENDMAIL=/usr/sbin/sendmail: This changes the default MTA path of /usr/lib/sendmail.

make PREFIX=/usr UCBINSTALL=/usr/bin/install install: This changes the default installation path of /usr/local and the default install command path of /usr/ucb.

Configuring Heirloom mailx

Config Files

/etc/nail.rc, ~/.mailrc and ~/.nailrc

Contents

Installed Programs: mail, mailx and nail
Installed Libraries: None
Installed Directories: None

Short Descriptions

mailx

is a command-line mail user agent compatible with the mailx command found on commercial Unix versions

mail

is a symbolic link to mailx

nail

is a symbolic link to mailx

Last updated on

Mutt-2.2.1

Introduction to Mutt

The Mutt package contains a Mail User Agent. This is useful for reading, writing, replying to, saving, and deleting your email.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Mutt Dependencies

Recommended (for a text version of the manual)
Optional

Aspell-0.60.8, Cyrus SASL-2.1.27, GDB-11.2, GnuPG-2.2.34, GnuTLS-3.7.3, GPGME-1.17.0, libidn-1.38, MIT Kerberos V5-1.19.2, an MTA (that provides a sendmail command), slang-2.3.2, SQLite-3.37.2, libgssapi, Mixmaster, QDBM or Tokyo Cabinet

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/mutt

Installation of Mutt

Note

Mutt ships with an HTML version of its manual, but the text version is no longer provided because differences in the formatting from different text browsers compared to the shipped version caused complaints. To get a text file, the following are used in order of preference: lynx with overstriking (backspaces) for emphasis, w3m or elinks: the latter two apparently provide plain text. Plain text is generally preferred unless reading the HTML manual, so the instructions below use lynx if available, or else links to produce plain text.

Mutt requires a group named mail. You can add this group, if it does not exist, with this command:

groupadd -g 34 mail

If you did not install an MTA, you need to modify the ownership of /var/mail with this command:

chgrp -v mail /var/mail

Install Mutt by running the following commands:

To ensure that a plain text manual is created when using lynx or to otherwise use links to produce it (instead of elinks), run the following command:

sed -i -e 's/ -with_backspaces//' -e 's/elinks/links/' \
  -e 's/-no-numbering -no-references//' doc/Makefile.in

Now configure and build the application:

./configure --prefix=/usr                           \
            --sysconfdir=/etc                       \
            --with-docdir=/usr/share/doc/mutt-2.2.1 \
            --with-ssl                              \
            --enable-external-dotlock               \
            --enable-pop                            \
            --enable-imap                           \
            --enable-hcache                         \
            --enable-sidebar                        &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Note

If you used a DESTDIR method to only install to a temporary location as a regular user (as part of a package menagement process), you will need to run the following as the root user after completing the real install:

chown root:mail /usr/bin/mutt_dotlock &&
chmod -v 2755 /usr/bin/mutt_dotlock

An info file is now installed, so you will also need to recreate the /usr/share/info/dir as described when Texinfo was installed in LFS.

Command Explanations

sed ... -e 's/ -with_backspaces//' ...: This turns off the backspaces used for overstriking when lynx is used, resulting in readable plain text when using view.

sed ... -e 's/elinks/links/' ...: This allows links to be run instead of elinks which is not in the book.

sed ... -e 's/-no-numbering -no-references//' ...: This removes switches which are not understood by links.

--enable-external-dotlock: In some circumstances the mutt-dotlock program is not created. This switch ensures it is always created.

--enable-pop: This switch enables POP3 support.

--enable-imap: This switch enables IMAP support.

--enable-hcache: This switch enables header caching.

--enable-sidebar: This switch enables support for the sidebar (a list of mailboxes). It is off by default, but can be turned on by :set sidebar_visible in mutt (and off again with ':unset'), or it can be enabled in ~/.muttrc.

--with-ssl: This parameter adds SSL/TLS support from openssl in POP3/IMAP/SMTP.

--enable-autocrypt --with-sqlite3: These two switches add support for passive protection against data collection, using gnupg and gpgme (gpgme is enabled by autocrypt). See The Manual.

--enable-gpgme: This switch enables GPG support through the GPGME package. Use this switch if you want GPG support in Mutt.

--enable-smtp: This switch enables SMTP relay support.

--with-idn2: Use this parameter if both libidn and libidn2 have been installed, and you wish to use libidn2 here.

--with-sasl: This parameter adds authentication support from Cyrus SASL-2.1.27 in POP3/IMAP/SMTP if they are enabled. Depending on the server configuration, this may not be needed for POP3 or IMAP. However, it is needed for SMTP authentication.

Configuring Mutt

Config Files

/etc/Muttrc, ~/.muttrc, /etc/mime.types, and ~/.mime.types

Configuration Information

No changes in these files are necessary to begin using Mutt. When you are ready to make changes, the man page for muttrc is a good starting place.

In order to utilize GnuPG, use the following command:

cat /usr/share/doc/mutt-2.2.1/samples/gpg.rc >> ~/.muttrc

Contents

Installed Programs: flea, mutt, mutt_dotlock, muttbug, pgpewrap, pgpring, and smime_keys
Installed Libraries: None
Installed Directories: /usr/share/doc/mutt-2.2.1

Short Descriptions

flea

is a script showing where to report bugs

mutt

is a Mail User Agent (MUA) which enables you to read, write and delete your email

mutt_dotlock

implements the mail spool file lock

muttbug

is a script identical to flea

pgpewrap

prepares a command line for the GnuPG-2.2.34 utilities

pgpring

is a key ring dumper for PGP. It is not needed for GnuPG-2.2.34

smime_keys

manages a keystore for S/MIME certificates

Last updated on

Procmail-3.22

Introduction to Procmail

The Procmail package contains an autonomous mail processor. This is useful for filtering and sorting incoming mail.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Procmail Dependencies

Recommended
Optional

libnsl-2.0.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/procmail

Installation of Procmail

This package does not come with a test suite.

Install Procmail by running the following commands as the root user:

sed -i 's/getline/get_line/' src/*.[ch]                   &&
patch -Np1 -i ../procmail-3.22-consolidated_fixes-1.patch &&

make LOCKINGTEST=/tmp MANDIR=/usr/share/man install       &&
make install-suid

Command Explanations

sed -i 's/getline/get_line/' src/*.[ch]: This renames procmail's getline function to avoid conflict with the getline function from glibc.

make LOCKINGTEST=/tmp install: This prevents make from asking you where to test file-locking patterns.

make install-suid: Modifies permissions of the installed files.

Configuring Procmail

Config Files

/etc/procmailrc and ~/.procmailrc

Configuration Information

Recipes have to be written and placed in ~/.procmailrc for execution. The procmailex man page is the starting place to learn how to write recipes. For additional information, see also http://pm-doc.sourceforge.net/.

Contents

Installed Programs: formail, lockfile, mailstat and procmail
Installed Libraries: None
Installed Directories: None

Short Descriptions

formail

is a filter that can be used to format mail into mailbox format

lockfile

is a utility that can lock a file for single use interactively or in a script

mailstat

prints a summary report of mail that has been filtered by procmail since the last time mailstat was ran

procmail

is an autonomous mail processor. It performs all the functions of an MDA (Mail Delivery Agent)

Last updated on

Other Mail and News Programs

Balsa-2.6.3 is a GTK2 based mail client.

SeaMonkey-2.53.10.2 includes both a mail client and newsreader in its installation.

Thunderbird-91.6.1 is a mail/news client based on the Mozilla code base.

Last updated on

Part V. Servers

Chapter 20. Major Servers

Major servers are the programs that provide content or services to users or other programs.

Apache-2.4.52

Introduction to Apache HTTPD

The Apache HTTPD package contains an open-source HTTP server. It is useful for creating local intranet web sites or running huge web serving operations.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Apache HTTPD Dependencies

Required

Apr-Util-1.6.1 and PCRE-8.45

Optional

Brotli-1.0.9, Berkeley DB-5.3.28, Doxygen-1.9.3, libxml2-2.9.13, Lua-5.4.4, Lynx-2.8.9rel.1 or Links-2.25 or ELinks, nghttp2-1.46.0, OpenLDAP-2.6.1 (Apr-Util-1.6.1 needs to be installed with ldap support), rsync-3.2.3, and Distcache

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/apache

Installation of Apache HTTPD

For security reasons, running the server as an unprivileged user and group is strongly encouraged. Create the following group and user using the following commands as root:

groupadd -g 25 apache &&
useradd -c "Apache Server" -d /srv/www -g apache \
        -s /bin/false -u 25 apache

Build and install Apache HTTPD by running the following commands:

patch -Np1 -i ../httpd-2.4.52-blfs_layout-1.patch             &&

sed '/dir.*CFG_PREFIX/s@^@#@' -i support/apxs.in              &&

./configure --enable-authnz-fcgi                              \
            --enable-layout=BLFS                              \
            --enable-mods-shared="all cgi"                    \
            --enable-mpms-shared=all                          \
            --enable-suexec=shared                            \
            --with-apr=/usr/bin/apr-1-config                  \
            --with-apr-util=/usr/bin/apu-1-config             \
            --with-suexec-bin=/usr/lib/httpd/suexec           \
            --with-suexec-caller=apache                       \
            --with-suexec-docroot=/srv/www                    \
            --with-suexec-logfile=/var/log/httpd/suexec.log   \
            --with-suexec-uidmin=100                          \
            --with-suexec-userdir=public_html                 &&
make

This package does not come with a test suite.

Now, as the root user:

Note

This package does not install properly using DESTDIR techniques as an unpriviledged user.

make install  &&

mv -v /usr/sbin/suexec /usr/lib/httpd/suexec &&
chgrp apache           /usr/lib/httpd/suexec &&
chmod 4754             /usr/lib/httpd/suexec &&

chown -v -R apache:apache /srv/www

Command Explanations

sed '/dir.*CFG_PREFIX/s@^@#@'...: Forces the apxs utility to use absolute pathnames for modules, when instructed to do so.

--enable-authnz-fcgi: Build FastCGI authorizer-based authentication and authorization (mod_authnz_fcgi.so fast CGI module).

--enable-mods-shared="all cgi": The modules should be compiled and used as Dynamic Shared Objects (DSOs) so they can be included and excluded from the server using the run-time configuration directives.

--enable-mpms-shared=all: This switch ensures that all MPM (Multi Processing Modules) are built as Dynamic Shared Objects (DSOs), so the user can choose which one to use at runtime.

--enable-suexec: This switch enables building of the Apache suEXEC module which can be used to allow users to run CGI and SSI scripts under user IDs different from the user ID of the calling web server.

--with-suexec-*: These switches control suEXEC module behavior, such as default document root, minimal UID that can be used to run the script under the suEXEC. Please note that with minimal UID 100, you can't run CGI or SSI scripts under suEXEC as the apache user.

... /usr/lib/httpd/suexec: These commands put suexec wrapper into proper location, since it is not meant to be run directly. They also adjust proper permissions of the binary, making it setgid apache.

chown -R apache:apache /srv/www: By default, the installation process installs files (documentation, error messages, default icons, etc.) with the ownership of the user that extracted the files from the tar file. If you want to change the ownership to another user, you should do so at this point. The only requirement is that the document directories need to be accessible by the httpd process with (r-x) permissions and files need to be readable (r--) by the apache user.

Configuring Apache

Config Files

/etc/httpd/httpd.conf and /etc/httpd/extra/*

Configuration Information

See file:///usr/share/httpd/manual/configuring.html for detailed instructions on customising your Apache HTTP server configuration file.

Boot Script

If you want the Apache server to start automatically when the system is booted, install the /etc/rc.d/init.d/httpd init script included in the blfs-bootscripts-20210826 package:

make install-httpd

Contents

Installed Programs: ab, apachectl, apxs, checkgid, dbmmanage, fcgistarter, htcacheclean, htdbm, htdigest, htpasswd, httpd, httxt2dbm, logresolve, and rotatelogs
Installed Libraries: Several libraries under /usr/lib/httpd/modules/
Installed Directories: /etc/httpd, /srv/www, /usr/include/httpd, /usr/lib/httpd, /usr/share/httpd, /var/log/httpd, and /var/run/httpd

Short Descriptions

ab

is a tool for benchmarking your Apache HTTP server

apachectl

is a front end to the Apache HTTP server which is designed to help the administrator control the functioning of the Apache httpd daemon

apxs

is a tool for building and installing extension modules for the Apache HTTP server

checkgid

is a program that checks whether it can setgid to the group specified. This is to see if it is a valid group for Apache2 to use at runtime. If the user (should be run as superuser) is in that group, or can setgid to it, it will return 0

dbmmanage

is used to create and update the DBM format files used to store usernames and passwords for basic authentication of HTTP users

fcgistarter

is a tool to start a FastCGI program

htcacheclean

is used to clean up the disk cache

htdbm

is used to manipulate the DBM password databases

htdigest

is used to create and update the flat-files used to store usernames, realms and passwords for digest authentication of HTTP users

htpasswd

is used to create and update the flat-files used to store usernames and passwords for basic authentication of HTTP users

httpd

is the Apache HTTP server program

httxt2dbm

is used to generate DBM files from text, for use in RewriteMap

logresolve

is a post-processing program to resolve IP-addresses in Apache's access log files

rotatelogs

is a simple program for use in conjunction with Apache's piped log file feature

suexec

allows users to run CGI and SSI applications as a different user

Last updated on

BIND-9.18.0

Introduction to BIND

The BIND package provides a DNS server and client utilities. If you are only interested in the utilities, refer to the BIND Utilities-9.18.0.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

BIND Dependencies

Required

libuv-1.43.0

Recommended
Optional

cURL-7.81.0, libidn2-2.3.2, libxml2-2.9.13, lmdb-0.9.29, MIT Kerberos V5-1.19.2, cmocka, geoip, pytest, Sphinx, and w3m

Optional database backends

Berkeley DB-5.3.28, MariaDB-10.6.7 or MySQL, OpenLDAP-2.6.1, PostgreSQL-14.2, and unixODBC-2.3.9

Optional (to run the test suite)

Net-DNS-1.33

Optional (to rebuild the documentation)

Doxygen-1.9.3, libxslt-1.1.35, and texlive-20210325 (or install-tl-unx)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/bind

Installation of BIND

Install BIND by running the following commands:

./configure --prefix=/usr           \
            --sysconfdir=/etc       \
            --localstatedir=/var    \
            --mandir=/usr/share/man \
            --disable-static        &&
make

Issue the following commands to run the complete suite of tests. First, as the root user, set up some test interfaces:

Note

If IPv6 is not enabled in the kernel, there will be several error messages: "RTNETLINK answers: Operation not permitted". These messages do not affect the tests.

bin/tests/system/ifconfig.sh up

The test suite may indicate some skipped tests depending on what configuration options are used. Some tests are marked UNTESTED if Net-DNS-1.33 is not installed. To run the tests, as an unprivileged user, execute:

make -k check

Again as root, clean up the test interfaces:

bin/tests/system/ifconfig.sh down

Finally, install the package as the root user:

make install

Command Explanations

--sysconfdir=/etc: This parameter forces BIND to look for configuration files in /etc instead of /usr/etc.

--with-libidn2: This parameter enables the IDNA2008 (Internationalized Domain Names in Applications) support.

--enable-fetchlimit: Use this option if you want to be able to limit the rate of recursive client queries. This may be useful on servers which receive a large number of queries.

--disable-linux-caps: BIND can also be built without capability support by using this option, at the cost of some loss of security.

--with-dlz-{mysql,bdb,filesystem,ldap,odbc,stub}: Use one (or more) of those options to add Dynamically Loadable Zones support. For more information refer to bind-dlz.sourceforge.net.

--disable-static: This switch prevents installation of static versions of the libraries.

Configuring BIND

Config files

named.conf, root.hints, 127.0.0, rndc.conf, and resolv.conf

Configuration Information

BIND will be configured to run in a chroot jail as an unprivileged user (named). This configuration is more secure in that a DNS compromise can only affect a few files in the named user's HOME directory.

Create the unprivileged user and group named:

groupadd -g 20 named &&
useradd -c "BIND Owner" -g named -s /bin/false -u 20 named &&
install -d -m770 -o named -g named /srv/named

Set up some files, directories and devices needed by BIND:

mkdir -p /srv/named &&
cd       /srv/named &&
mkdir -p dev etc/named/{slave,pz} usr/lib/engines var/run/named &&
mknod /srv/named/dev/null c 1 3 &&
mknod /srv/named/dev/urandom c 1 9 &&
chmod 666 /srv/named/dev/{null,urandom} &&
cp /etc/localtime etc

The rndc.conf file contains information for controlling named operations with the rndc utility. Generate a key for use in the named.conf and rndc.conf with the rndc-confgen command:

rndc-confgen -a -b 512 -t /srv/named

Complete the named.conf file from which named will read the location of zone files, root name servers and secure DNS keys:

cat >> /srv/named/etc/named.conf << "EOF"
options {
    directory "/etc/named";
    pid-file "/var/run/named.pid";
    statistics-file "/var/run/named.stats";

};
zone "." {
    type hint;
    file "root.hints";
};
zone "0.0.127.in-addr.arpa" {
    type master;
    file "pz/127.0.0";
};

// Bind 9 now logs by default through syslog (except debug).
// These are the default logging rules.

logging {
    category default { default_syslog; default_debug; };
    category unmatched { null; };

  channel default_syslog {
      syslog daemon;                      // send to syslog's daemon
                                          // facility
      severity info;                      // only send priority info
                                          // and higher
  };

  channel default_debug {
      file "named.run";                   // write to named.run in
                                          // the working directory
                                          // Note: stderr is used instead
                                          // of "named.run"
                                          // if the server is started
                                          // with the '-f' option.
      severity dynamic;                   // log at the server's
                                          // current debug level
  };

  channel default_stderr {
      stderr;                             // writes to stderr
      severity info;                      // only send priority info
                                          // and higher
  };

  channel null {
      null;                               // toss anything sent to
                                          // this channel
  };
};
EOF

Create a zone file with the following contents:

cat > /srv/named/etc/named/pz/127.0.0 << "EOF"
$TTL 3D
@      IN      SOA     ns.local.domain. hostmaster.local.domain. (
                        1       ; Serial
                        8H      ; Refresh
                        2H      ; Retry
                        4W      ; Expire
                        1D)     ; Minimum TTL
                NS      ns.local.domain.
1               PTR     localhost.
EOF

Create the root.hints file with the following commands:

Note

Caution must be used to ensure there are no leading spaces in this file.

cat > /srv/named/etc/named/root.hints << "EOF"
.                       6D  IN      NS      A.ROOT-SERVERS.NET.
.                       6D  IN      NS      B.ROOT-SERVERS.NET.
.                       6D  IN      NS      C.ROOT-SERVERS.NET.
.                       6D  IN      NS      D.ROOT-SERVERS.NET.
.                       6D  IN      NS      E.ROOT-SERVERS.NET.
.                       6D  IN      NS      F.ROOT-SERVERS.NET.
.                       6D  IN      NS      G.ROOT-SERVERS.NET.
.                       6D  IN      NS      H.ROOT-SERVERS.NET.
.                       6D  IN      NS      I.ROOT-SERVERS.NET.
.                       6D  IN      NS      J.ROOT-SERVERS.NET.
.                       6D  IN      NS      K.ROOT-SERVERS.NET.
.                       6D  IN      NS      L.ROOT-SERVERS.NET.
.                       6D  IN      NS      M.ROOT-SERVERS.NET.
A.ROOT-SERVERS.NET.     6D  IN      A       198.41.0.4
A.ROOT-SERVERS.NET.     6D  IN      AAAA    2001:503:ba3e::2:30
B.ROOT-SERVERS.NET.     6D  IN      A       192.228.79.201
B.ROOT-SERVERS.NET.     6D  IN      AAAA    2001:500:200::b
C.ROOT-SERVERS.NET.     6D  IN      A       192.33.4.12
C.ROOT-SERVERS.NET.     6D  IN      AAAA    2001:500:2::c
D.ROOT-SERVERS.NET.     6D  IN      A       199.7.91.13
D.ROOT-SERVERS.NET.     6D  IN      AAAA    2001:500:2d::d
E.ROOT-SERVERS.NET.     6D  IN      A       192.203.230.10
E.ROOT-SERVERS.NET.     6D  IN      AAAA    2001:500:a8::e
F.ROOT-SERVERS.NET.     6D  IN      A       192.5.5.241
F.ROOT-SERVERS.NET.     6D  IN      AAAA    2001:500:2f::f
G.ROOT-SERVERS.NET.     6D  IN      A       192.112.36.4
G.ROOT-SERVERS.NET.     6D  IN      AAAA    2001:500:12::d0d
H.ROOT-SERVERS.NET.     6D  IN      A       198.97.190.53
H.ROOT-SERVERS.NET.     6D  IN      AAAA    2001:500:1::53
I.ROOT-SERVERS.NET.     6D  IN      A       192.36.148.17
I.ROOT-SERVERS.NET.     6D  IN      AAAA    2001:7fe::53
J.ROOT-SERVERS.NET.     6D  IN      A       192.58.128.30
J.ROOT-SERVERS.NET.     6D  IN      AAAA    2001:503:c27::2:30
K.ROOT-SERVERS.NET.     6D  IN      A       193.0.14.129
K.ROOT-SERVERS.NET.     6D  IN      AAAA    2001:7fd::1
L.ROOT-SERVERS.NET.     6D  IN      A       199.7.83.42
L.ROOT-SERVERS.NET.     6D  IN      AAAA    2001:500:9f::42
M.ROOT-SERVERS.NET.     6D  IN      A       202.12.27.33
M.ROOT-SERVERS.NET.     6D  IN      AAAA    2001:dc3::35
EOF

The root.hints file is a list of root name servers. This file must be updated periodically with the dig utility. A current copy of root.hints can be obtained from ftp://rs.internic.net/domain/named.root. For details, consult the "BIND 9 Administrator Reference Manual", included in every source archive of BIND 9 distributed by ISC, in HTML and PDF formats, also available at BIND 9 Administrator Reference Manual.

Create or modify resolv.conf to use the new name server with the following commands:

Note

Replace <yourdomain.com> with your own valid domain name.

cp /etc/resolv.conf /etc/resolv.conf.bak &&
cat > /etc/resolv.conf << "EOF"
search <yourdomain.com>
nameserver 127.0.0.1
EOF

Set permissions on the chroot jail with the following command:

chown -R named:named /srv/named

Boot Script

To start the DNS server at boot, install the /etc/rc.d/init.d/bind init script included in the blfs-bootscripts-20210826 package:

make install-bind

Now start BIND with the following command:

/etc/rc.d/init.d/bind start

Testing BIND

Test out the new BIND 9 installation. First query the local host address with dig:

dig -x 127.0.0.1

Now try an external name lookup, taking note of the speed difference in repeated lookups due to the caching. Run the dig command twice on the same address:

dig www.linuxfromscratch.org &&
dig www.linuxfromscratch.org

You can see almost instantaneous results with the named caching lookups. Consult the BIND Administrator Reference Manual located at https://bind9.readthedocs.io/en/v9_16/ for further configuration options.

Contents

Installed Programs: arpaname, ddns-confgen, delv, dig, dnssec-cds, dnssec-checkds, dnssec-coverage, dnssec-dsfromkey, dnssec-importkey, dnssec-keyfromlabel, dnssec-keygen, dnssec-keymgr, dnssec-revoke, dnssec-settime, dnssec-signzone, dnssec-verify, host, mdig, named, named-checkconf, named-checkzone, named-compilezone (symlink), named-journalprint, named-nzd2nzf, named-rrchecker, nsec3hash, nslookup, nsupdate, rndc, rndc-confgen, and tsig-keygen (symlink)
Installed Libraries: libbind9.so, libdns.so, libirs.so, libisc.so, libisccc.so, libisccfg.so, and libns.so
Installed Directories: /usr/include/{bind9,dns,dst,irs,isc,isccc,isccfg,ns,pk11,pkcs11}, /usr/lib/named, /usr/lib/python3.10/site-packages/isc, and /srv/named

Short Descriptions

arpaname

translates IP addresses to the corresponding ARPA names

ddns-confgen

generates a key for use by nsupdate and named

delv

is a new debugging tool that is a successor to dig

dig

interrogates DNS servers

dnssec-cds

changes DS records for a child zone based on CDS/CDNSKEY

dnssec-checkds

is a DNSSEC delegation consistency checking tool

dnssec-coverage

verifies that the DNSSEC keys for a given zone or a set of zones have timing metadata set properly to ensure no future lapses in DNSSEC coverage

dnssec-dsfromkey

outputs the Delegation Signer (DS) resource record (RR)

dnssec-importkey

reads a public DNSKEY record and generates a pair of .key/.private files

dnssec-keyfromlabel

gets keys with the given label from a cryptography hardware device and builds key files for DNSSEC

dnssec-keygen

is a key generator for secure DNS

dnssec-keymgr

ensures correct DNSKEY coverage based on a defined policy

dnssec-revoke

sets the REVOKED bit on a DNSSEC key

dnssec-settime

sets the key timing metadata for a DNSSEC key

dnssec-signzone

generates signed versions of zone files

dnssec-verify

verifies that a zone is fully signed for each algorithm found in the DNSKEY RRset for the zone, and that the NSEC / NSEC3 chains are complete

host

is a utility for DNS lookups

mdig

is a version of dig that allows multiple queries at once

named

is the name server daemon

named-checkconf

checks the syntax of named.conf files

named-checkzone

checks zone file validity

named-compilezone

is similar to named-checkzone, but it always dumps the zone contents to a specified file in a specified format

named-journalprint

prints the zone journal in human-readable form

named-rrchecker

reads an individual DNS resource record from standard input and checks if it is syntactically correct

named-nzd2nzf

converts an NZD database to NZF text format

nsec3hash

generates an NSEC3 hash based on a set of NSEC3 parameters

nslookup

is a program used to query Internet domain nameservers

nsupdate

is used to submit DNS update requests

rndc

controls the operation of BIND

rndc-confgen

generates rndc.conf files

tsig-keygen

is a symlink to ddns-confgen

Last updated on

ProFTPD-1.3.7c

Introduction to ProFTPD

The ProFTPD package contains a secure and highly configurable FTP daemon. This is useful for serving large file archives over a network.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

ProFTPD Dependencies

Optional

libcap-2.63 with PAM, libssh2-1.10.0, Linux-PAM-1.5.2, MariaDB-10.6.7 or MySQL, PCRE-8.45, PostgreSQL-14.2, and Net::SSH2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/proftpd

Installation of ProFTPD

For security reasons, you should install ProFTPD using an unprivileged user and group. As the root user:

groupadd -g 46 proftpd                             &&
useradd -c proftpd -d /srv/ftp -g proftpd \
        -s /usr/bin/proftpdshell -u 46 proftpd     &&

install -v -d -m775 -o proftpd -g proftpd /srv/ftp &&
ln -v -s /bin/false /usr/bin/proftpdshell          &&
echo /usr/bin/proftpdshell >> /etc/shells

Install ProFTPD as an unprivileged user by running the following commands:

./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var/run &&
make

This packages does not come with a usable test suite.

Now, as the root user:

make install                                   &&
install -d -m755 /usr/share/doc/proftpd-1.3.7c &&
cp -Rv doc/*     /usr/share/doc/proftpd-1.3.7c

Command Explanations

install -v -d -m775 -o proftpd -g proftpd /srv/ftp: Create the home directory for ProFTPD.

ln -v -s /bin/false /usr/bin/proftpdshell: Set the default shell as a link to an invalid shell.

echo /usr/bin/proftpdshell >> /etc/shells: Fake a valid shell for compatibility purposes.

Note

The above two commands can be omitted if the following directive is placed in the configuration file:

RequireValidShell off

By default, proftpd will require that users logging in have valid shells. The RequireValidShell directive turns off this requirement. This is only recommended if you are setting up your FTP server exclusively for anonymous downloads.

Note

Support for most of the dependency packages requires using options passed to the configure script. View the output from ./configure --help for complete information about enabling dependency packages.

Configuring ProFTPD

Config Files

/etc/proftpd.conf

Configuration Information

This is a simple, download-only sample configuration. See the ProFTPD documentation in /usr/share/doc/proftpd and consult the website at http://www.proftpd.org/ for example configurations.

cat > /etc/proftpd.conf << "EOF"
# This is a basic ProFTPD configuration file
# It establishes a single server and a single anonymous login.

ServerName                      "ProFTPD Default Installation"
ServerType                      standalone
DefaultServer                   on

# Port 21 is the standard FTP port.
Port                            21
# Umask 022 is a good standard umask to prevent new dirs and files
# from being group and world writable.
Umask                           022

# To prevent DoS attacks, set the maximum number of child processes
# to 30.  If you need to allow more than 30 concurrent connections
# at once, simply increase this value.  Note that this ONLY works
# in standalone mode, in inetd mode you should use an inetd server
# that allows you to limit maximum number of processes per service

MaxInstances                    30

# Set the user and group that the server normally runs at.
User                            proftpd
Group                           proftpd

# To cause every FTP user to be "jailed" (chrooted) into their home
# directory, uncomment this line.
#DefaultRoot ~


# Normally, files should be overwritable.
<Directory /*>
  AllowOverwrite                on
</Directory>

# A basic anonymous configuration, no upload directories.
<Anonymous ~proftpd>
  User                          proftpd
  Group                         proftpd
  # Clients should be able to login with "anonymous" as well as "proftpd"
  UserAlias                     anonymous proftpd

  # Limit the maximum number of anonymous logins
  MaxClients                    10

  # 'welcome.msg' should be displayed at login, and '.message' displayed
  # in each newly chdired directory.
  DisplayLogin                  welcome.msg
  DisplayChdir                  .message

  # Limit WRITE everywhere in the anonymous chroot
  <Limit WRITE>
    DenyAll
  </Limit>
</Anonymous>
EOF

Boot Script

Install the /etc/rc.d/init.d/proftpd init script included in the blfs-bootscripts-20210826 package:

make install-proftpd

Contents

Installed Programs: ftpasswd, ftpcount, ftpdctl, ftpmail, ftpquota, ftpscrub, ftpshut, ftptop, ftpwho, in.proftpd (symlink to proftpd), proftpd, and prxs
Installed Libraries: None
Installed Directory: /usr/{include,lib}/proftpd, /usr/share/doc/proftpd-1.3.7c, and /srv/ftp

Short Descriptions

proftpd

is the FTP daemon

ftpcount

shows the current number of connections

ftpdctl

is used to control the proftpd daemon while it is running

ftpasswd

is a Perl script designed to create and manage AuthUserFiles and AuthGroupFiles of the correct format for proftpd

ftpmail

is a Perl script for sending email based on the proftpd TransferLog

ftpquota

is a Perl script designed to create and manage limits and tally files for the mod_quotatab + mod_quotatab_file module combination for proftpd

ftpscrub

provides a way to scrub the scoreboard file on demand

ftpshut

shuts down all proftpd servers at a given time

ftptop

displays running status on connections

ftpwho

shows current process information for each session

prxs

is a Perl script designed to compile and install third-party modules, from source code, as DSO modules for the installed proftpd

Last updated on

vsftpd-3.0.5

Introduction to vsftpd

The vsftpd package contains a very secure and very small FTP daemon. This is useful for serving files over a network.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

vsftpd Dependencies

Required

libnsl-2.0.0

Recommended
Optional

libcap-2.63 with PAM

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/vsftpd

Installation of vsftpd

For security reasons, running vsftpd as an unprivileged user and group is encouraged. Also, a user should be created to map anonymous users. As the root user, create the needed directories, users, and groups with the following commands:

install -v -d -m 0755 /usr/share/vsftpd/empty &&
install -v -d -m 0755 /home/ftp               &&
groupadd -g 47 vsftpd                         &&
groupadd -g 45 ftp                            &&

useradd -c "vsftpd User"  -d /dev/null -g vsftpd -s /bin/false -u 47 vsftpd &&
useradd -c anonymous_user -d /home/ftp -g ftp    -s /bin/false -u 45 ftp

Gcc-10 and later flags an error for an implicit type cast. Make it explicit:

sed -e "s/kVSFSysStrOpenUnknown;/(enum EVSFSysUtilOpenMode)&/" -i sysstr.c

Build vsftpd as an unprivileged user using the following command:

make

This package does not come with a test suite.

Once again, become the root user and install vsftpd with the following commands:

install -v -m 755 vsftpd        /usr/sbin/vsftpd    &&
install -v -m 644 vsftpd.8      /usr/share/man/man8 &&
install -v -m 644 vsftpd.conf.5 /usr/share/man/man5 &&
install -v -m 644 vsftpd.conf   /etc

Command Explanations

install -v -d ...: This creates the directory that anonymous users will use (/home/ftp) and the directory the daemon will chroot into (/usr/share/vsftpd/empty).

Note

/home/ftp should not be owned by the user vsftpd, or the user ftp.

echo "#define VSF_BUILD_TCPWRAPPERS" >>builddefs.h: Use this prior to make to add support for tcpwrappers.

echo "#define VSF_BUILD_SSL" >>builddefs.h: Use this prior to make to add support for SSL.

install -v -m ...: The Makefile uses non-standard installation paths. These commands install the files in /usr and /etc.

Configuring vsftpd

Config Files

/etc/vsftpd.conf

Configuration Information

vsftpd comes with a basic anonymous-only configuration file that was copied to /etc above. While still as root, this file should be modified because it is now recommended to run vsftpd in standalone mode. Also, you should specify the privilege separation user created above. Finally, you should specify the chroot directory. man vsftpd.conf will give you all the details.

cat >> /etc/vsftpd.conf << "EOF"
background=YES
nopriv_user=vsftpd
secure_chroot_dir=/usr/share/vsftpd/empty
EOF

The vsftpd daemon uses seccomp to improve security by default. But it's known to cause vsftpd unable to handle ftp LIST command with recent kernel versions. Append a line to /etc/vsftpd.conf (as the root user) to disable seccomp and workaround this issue:

cat >> /etc/vsftpd.conf << "EOF"
seccomp_sandbox=NO
EOF

To enable local logins, append the following to the /etc/vsftpd.conf file (as the root user):

cat >> /etc/vsftpd.conf << "EOF"
local_enable=YES
EOF

In addition, if using Linux-PAM and vsftpd with local user logins, you will need a Linux-PAM configuration file. As the root user, create the /etc/pam.d/vsftpd file, and add the needed configuration changes for Linux-PAM session support using the following commands:

cat > /etc/pam.d/vsftpd << "EOF" &&
# Begin /etc/pam.d/vsftpd
auth       required     /lib/security/pam_listfile.so item=user sense=deny \
                                                      file=/etc/ftpusers \
                                                      onerr=succeed
auth       required     pam_shells.so
auth       include      system-auth
account    include      system-account
session    include      system-session
EOF

cat >> /etc/vsftpd.conf << "EOF"
session_support=YES
pam_service_name=vsftpd
EOF

Boot Script

Install the /etc/rc.d/init.d/vsftpd init script included in the blfs-bootscripts-20210826 package:

make install-vsftpd

Contents

Installed Program: vsftpd
Installed Libraries: None
Installed Directories: /usr/share/vsftpd, /home/ftp

Short Descriptions

vsftpd

is the FTP daemon

Last updated on

Chapter 21. Mail Server Software

MTAs are the programs which transport mail from one machine to the other. The traditional MTA is Sendmail, however there are several other choices.

As well as SMTP servers there is a POP server (qpopper) and an IMAP server (Courier-IMAP).

Dovecot-2.3.18

Introduction to Dovecot

Dovecot is an Internet Message Access Protocol (IMAP) and Post Office Protocol (POP) server, written primarily with security in mind. Dovecot aims to be lightweight, fast and easy to set up as well as highly configurable and easily extensible with plugins.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Dovecot Dependencies

Required

libtirpc-1.3.2

Optional

CLucene-2.3.3.4, ICU-70.1, libcap-2.63 with PAM, Linux-PAM-1.5.2, Lua-5.4.4, MariaDB-10.6.7 or MySQL, OpenLDAP-2.6.1, PostgreSQL-14.2, SQLite-3.37.2, Valgrind-3.18.1, xfsprogs-5.14.2, Cassandra, lz4, stemmer and libsodium

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/dovecot

Installation of Dovecot

There should be dedicated users and groups for unprivileged Dovecot processes and for processing users' logins. Issue the following commands as the root user:

groupadd -g 42 dovecot &&
useradd -c "Dovecot unprivileged user" -d /dev/null -u 42 \
        -g dovecot -s /bin/false dovecot &&
groupadd -g 43 dovenull &&
useradd -c "Dovecot login user" -d /dev/null -u 43 \
        -g dovenull -s /bin/false dovenull

First, apply a patch to fix problems with OpenSSL-3:

patch -Np1 -i ../dovecot-2.3.18-openssl3_fixes-1.patch

Install Dovecot by running the following commands:

CPPFLAGS="-I/usr/include/tirpc" \
LDFLAGS+=" -ltirpc" \
./configure --prefix=/usr                          \
            --sysconfdir=/etc                      \
            --localstatedir=/var                   \
            --with-systemd=no                      \
            --docdir=/usr/share/doc/dovecot-2.3.18 \
            --disable-static &&
make

To test the results, issue make -k check.

Now, as the root user:

make install

Command Explanations

CPPFLAGS=... LDFLAGS+=...: build with libtirpc instead of the recently removed RPC code provided by GlibC.

--disable-static: This switch prevents installation of static versions of the libraries.

--with-ldap: This switch enables OpenLDAP authentication support.

--with-pgsql: This switch enables PostgreSQL database support.

--with-mysql: This switch enables MySQL database support.

--with-sqlite: This switch enables SQLite database support.

--with-lucene: This switch enables CLucene full text search support.

--with-lua: This switch enables Lua plugin support. This includes a mail and push notification plugin.

Configuring Dovecot

Config Files

/etc/dovecot/dovecot.conf, /etc/dovecot/conf.d/*, and /etc/dovecot/local.conf

Configuration Information

Copy an example configuration, which you can use as a starting point:

cp -rv /usr/share/doc/dovecot-2.3.18/example-config/* /etc/dovecot

The following configuration is a simple proof of concept with IMAP service using local users for authentication and mailbox location. Reading files from the conf.d directory is commented out since the included example configuration requires OpenSSL and Linux PAM.

sed -i '/^\!include / s/^/#/' /etc/dovecot/dovecot.conf &&
chmod -v 1777 /var/mail &&
cat > /etc/dovecot/local.conf << "EOF"
protocols = imap
ssl = no
# The next line is only needed if you have no IPv6 network interfaces
listen = *
mail_location = mbox:~/Mail:INBOX=/var/mail/%u
userdb {
  driver = passwd
}
passdb {
  driver = shadow
}
EOF

You will definitely want to read the official documentation at http://wiki2.dovecot.org/ if you plan to use Dovecot in a production environment.

Boot Script

If you want the Dovecot server to start automatically when the system is booted, install the /etc/rc.d/init.d/dovecot init script included in the blfs-bootscripts-20210826 package.

make install-dovecot

Contents

Installed Programs: doveadm, doveconf, dovecot, dovecot-sysreport, and dsync (symbolic link)
Installed Libraries: various internal plugins in /usr/lib/dovecot
Installed Directories: /etc/dovecot, /usr/{include,lib,libexec,share}/dovecot and /usr/share/doc/dovecot-2.3.18

Short Descriptions

doveadm

is the Dovecot administration tool

doveconf

is Dovecot's configuration dumping utility

dovecot

is the IMAP and POP server

dovecot-sysreport

prints system information that is useful to the Dovecot developers when submitting bug reports upstream

dsync

is Dovecot's mailbox synchronization utility

Last updated on

Exim-4.95

Introduction to Exim

The Exim package contains a Mail Transport Agent written by the University of Cambridge, released under the GNU Public License.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Exim Dependencies

Required

libnsl-2.0.0 and PCRE-8.45

Optional

TDB (alternative to GDBM, built in LFS), Cyrus SASL-2.1.27, libidn-1.38, Linux-PAM-1.5.2, MariaDB-10.6.7 or MySQL, OpenLDAP-2.6.1, GnuTLS-3.7.3, PostgreSQL-14.2, SQLite-3.37.2, a graphical environment, Heimdal GSSAPI, and OpenDMARC

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/exim

Installation of Exim

Before building Exim, as the root user you should create the group and user exim which will run the exim daemon:

groupadd -g 31 exim &&
useradd -d /dev/null -c "Exim Daemon" -g exim -s /bin/false -u 31 exim

If you want to build with PAM support, apply the following patch:

patch -Np2 -i ../exim-4.95-call_pam-1.patch

Apply a patch required for building against openssl version 3:

patch -Np2 -i ../exim-4.95-openssl3_fix-1.patch

Configure Exim with the following commands:

sed -e 's,^BIN_DIR.*$,BIN_DIRECTORY=/usr/sbin,'    \
    -e 's,^CONF.*$,CONFIGURE_FILE=/etc/exim.conf,' \
    -e 's,^EXIM_USER.*$,EXIM_USER=exim,'           \
    -e '/# SUPPORT_TLS=yes/s,^#,,'                   \
    -e '/# USE_OPENSSL/s,^#,,'                       \
    -e 's,^EXIM_MONITOR,#EXIM_MONITOR,' src/EDITME > Local/Makefile &&

printf "USE_GDBM = yes\nDBMLIB = -lgdbm\n" >> Local/Makefile &&

If you want to add Linux PAM support, also run the following commands:

sed -i '/# SUPPORT_PAM=yes/s,^#,,' Local/Makefile
echo "EXTRALIBS=-lpam" >> Local/Makefile

Build Exim with the following command:

make

This package does not come with a test suite.

Now, as the root user:

make install                                    &&
install -v -m644 doc/exim.8 /usr/share/man/man8 &&

install -v -d -m755    /usr/share/doc/exim-4.95 &&
install -v -m644 doc/* /usr/share/doc/exim-4.95 &&

ln -sfv exim /usr/sbin/sendmail                 &&
install -v -d -m750 -o exim -g exim /var/spool/exim

Command Explanations

sed -e ... > Local/Makefile: Most of Exim's configuration options are defined in Local/Makefile, which is created from the src/EDITME file. This command specifies the minimum set of options. Descriptions for the options are listed below.

printf ... > Local/Makefile: Setting those variables allows to use GDBM instead of the default Berkeley DB. Remove this command if you have installed Berkeley DB-5.3.28.

BIN_DIRECTORY=/usr/sbin: This installs all of Exim's binaries and scripts in /usr/sbin.

CONFIGURE_FILE=/etc/exim.conf: This installs Exim's main configuration file in /etc.

EXIM_USER=exim: This tells Exim that after the daemon no longer needs root privileges, the process hands off the daemon to the exim user.

SUPPORT_TLS=yes: This allows to support STARTTLS connections. If you use this option, you need to select whether OpenSSL or GnuTLS is used (see src/EDITME).

USE_OPENSSL_PC=openssl: This tells the build system to use OpenSSL, and to find the needed libraries with pkg-config.

#EXIM_MONITOR: This defers building the Exim monitor program, as it requires X Window System support, by commenting out the EXIM_MONITOR line in the Makefile. If you wish to build the monitor program, omit this sed command and issue the following command before building the package (modify Local/eximon.conf, if necessary): cp exim_monitor/EDITME Local/eximon.conf.

ln -sfv exim /usr/sbin/sendmail: Creates a link to sendmail for applications which need it. Exim will accept most Sendmail command-line options.

install -v -m750 -o exim -g exim /var/spool/exim: Since /var/spool is owned by root and this version of exim drops root privileges early, to run as user exim, it cannot create the /var/spool/exim directory. As a work around, it is created manually.

Adding Additional Functionality

To utilize some or all of the dependency packages, you'll need to modify Local/Makefile to include the appropriate directives and parameters to link additional libraries before you build Exim. Local/Makefile is heavily commented with instructions on how to do this. Listed below is additional information to help you link these dependency packages or add additional functionality.

If you wish to build and install the .info documentation, refer to http://exim.org/exim-html-4.95/doc/html/spec_html/ch04.html#SECTinsinfdoc.

If you wish to build in Exim's interfaces for calling virus and spam scanning software directly from access control lists, uncomment the WITH_CONTENT_SCAN=yes parameter and review the information found at http://exim.org/exim-html-4.95/doc/html/spec_html/ch45.html.

To use a backend database other than GDBM , see the instructions at http://exim.org/exim-html-4.95/doc/html/spec_html/ch04.html#SECTdb.

For SSL functionality, see the instructions at http://exim.org/exim-html-4.95/doc/html/spec_html/ch04.html#SECTinctlsssl and http://exim.org/exim-html-4.95/doc/html/spec_html/ch42.html.

For tcpwrappers functionality, see the instructions at http://exim.org/exim-html-4.95/doc/html/spec_html/ch04.html#SECID27.

For information about adding authentication mechanisms to the build, see chapters 33—41 of http://exim.org/exim-html-4.95/doc/html/spec_html/index.html.

For information about linking Linux-PAM, refer to the instructions http://exim.org/exim-html-4.95/doc/html/spec_html/ch11.html#SECTexpcond.

For information about linking database engine libraries used for Exim name lookups, see the instructions at http://exim.org/exim-html-4.95/doc/html/spec_html/ch09.html.

If you wish to add Readline support to Exim when invoked in test expansion (-be) mode, see the information in the -be section of http://exim.org/exim-html-4.95/doc/html/spec_html/ch05.html#id2525974.

You may wish to modify the default configuration and send log files to syslog instead of the default /var/spool/exim/log directory. See the information at http://exim.org/exim-html-4.95/doc/html/spec_html/ch-log_files.html.

A wealth of information can be also found at the Exim Wiki.

Configuring Exim

Config Files

/etc/exim.conf and /etc/aliases

Configuration Information

Review the file /etc/exim.conf, and modify any settings to suit your needs. Note that the default configuration assumes that the /var/mail directory is world writable, but has the sticky bit set. If you want to use the default configuration, issue as the root user:

chmod -v a+wt /var/mail

A default (nothing but comments) /etc/aliases file is installed during the package installation if this file did not exist on your system. Create the necessary aliases and start the Exim daemon using the following commands:

cat >> /etc/aliases << "EOF"
postmaster: root
MAILER-DAEMON: root
EOF
/usr/sbin/exim -bd -q15m

Note

To protect an existing /etc/aliases file, the command above appends these aliases to it. This file should be checked and duplicate aliases removed, if present.

The /usr/sbin/exim -bd -q15m command starts the Exim daemon with a 15 minute interval in processing the mail queue. Adjust this parameter to suit your desires.

Linux PAM Configuration

If you have built Exim with Linux PAM support, you need to create a PAM configuration file to get it working correctly with BLFS.

Issue the following command as the root user to create the configuration file for Linux PAM:

cat > /etc/pam.d/exim << "EOF"
# Begin /etc/pam.d/exim

auth    include system-auth
account include system-account
session include system-session

# End /etc/pam.d/exim
EOF

Boot Script

To automatically start exim at boot, install the /etc/rc.d/init.d/exim init script included in the blfs-bootscripts-20210826 package:

make install-exim

The bootscript also starts the Exim daemon and dispatches a queue runner process every 15 minutes. Modify the -q<time interval> parameter in /etc/rc.d/init.d/exim, if necessary for your installation.

Contents

Installed Programs: exicyclog, exigrep, exim, exim-4.95-2, exim_checkaccess, exim_dbmbuild, exim_dumpdb, exim_fixdb, exim_lock, exim_tidydb, eximstats, exinext, exipick, exiqgrep, exiqsumm, exiwhat, and optionally, eximon, eximon.bin, and sendmail (symlink)
Installed Libraries: None
Installed Directories: /usr/share/doc/exim-4.95 and /var/spool/exim

Short Descriptions

exicyclog

cycles Exim log files

exigrep

searches Exim log files

exim

is a symlink to the exim-4.95-2 MTA daemon

exim-4.95-2

is the Exim mail transport agent daemon

exim_checkaccess

states whether a given recipient address from a given host is acceptable or not

exim_dbmbuild

creates and rebuilds Exim databases

exim_dumpdb

writes the contents of Exim databases to the standard output

exim_fixdb

modifies data in Exim databases

exim_lock

locks a mailbox file

exim_tidydb

removes old records from Exim databases

eximstats

generates mail statistics from Exim log files

exinext

queries remote host retry times

exipick

selects messages based on various criteria

exiqgrep

is a utility for selective queue listing

exiqsumm

produces a summary of the messages in the mail queue

exiwhat

queries running Exim processes

eximon

is a start-up shell script for eximon.bin used to set the required environment variables before running the program

eximon.bin

is a monitor program which displays current information in an X window, and also contains a menu interface to Exim's command line administration options

Last updated on

Postfix-3.7.0

Introduction to Postfix

The Postfix package contains a Mail Transport Agent (MTA). This is useful for sending email to other users of your host machine. It can also be configured to be a central mail server for your domain, a mail relay agent or simply a mail delivery agent to your local Internet Service Provider.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Postfix Dependencies

Recommended
Optional

ICU-70.1 for Email Address Internationalization (SMTPUTF8) support, MariaDB-10.6.7 or MySQL, OpenLDAP-2.6.1, PCRE-8.45, PostgreSQL-14.2, SQLite-3.37.2, and CDB or TinyCDB

Note that SQLite, MySQL, PostgreSQL and CDB are only useful if there is a known need for them.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/postfix

Installation of Postfix

Adding Users and Groups

Before you compile the program, you need to create users and groups that will be expected to be in place during the installation. Add the users and groups with the following commands issued by the root user:

groupadd -g 32 postfix &&
groupadd -g 33 postdrop &&
useradd -c "Postfix Daemon User" -d /var/spool/postfix -g postfix \
        -s /bin/false -u 32 postfix &&
chown -v postfix:postfix /var/mail

Configuring the Build

The README files are formatted to be read with a pager like Less or More. If you want to use a text editor, make them legible with the following sed:

sed -i 's/.\x08//g' README_FILES/*

The Postfix source tree does not contain a configure script, rather the makefile in the top-level directory contains a makefiles target that regenerates all the other makefiles in the build tree. If you wish to use additional software such as a database back-end for virtual users, or TLS/SSL authentication, you will need to regenerate the makefiles using one or more of the appropriate CCARGS and AUXLIBS settings listed below.

Note

For all variants of the CCARGS you should ensure that -DNO_NIS is specified so that the build does not attempt to access an rpcsvc header which does not exist in BLFS.

For more details read the readme files.

Cyrus-SASL

To use Cyrus-SASL with Postfix, use the following arguments:

CCARGS='-DNO_NIS -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/include/sasl'
AUXLIBS='-lsasl2'
OpenLDAP

To use OpenLDAP with Postfix, use the following arguments:

CCARGS='-DNO_NIS -DHAS_LDAP'
AUXLIBS='-lldap -llber'
Sqlite

To use Sqlite with Postfix, use the following arguments:

CCARGS='-DNO_NIS -DHAS_SQLITE'
AUXLIBS='-lsqlite3 -lpthread'
MySQL

To use MySQL with Postfix, use the following arguments:

CCARGS='-DNO_NIS -DHAS_MYSQL -I/usr/include/mysql'
AUXLIBS='-lmysqlclient -lz -lm'
PostgreSQL

To use PostgreSQL with Postfix, use the following arguments:

CCARGS='-DNO_NIS -DHAS_PGSQL -I/usr/include/postgresql'
AUXLIBS='-lpq -lz -lm'
CDB/TinyCDB

To use CDB or TinyCDB with Postfix, use the following arguments:

CCARGS='-DNO_NIS -DHAS_CDB'
AUXLIBS='</path/to/CDB>/libcdb.a'
StartTLS Authentication

To use OpenSSL with Postfix, use the following arguments:

CCARGS='-DNO_NIS -DUSE_TLS -I/usr/include/openssl/'
AUXLIBS='-lssl -lcrypto'

Installing Postfix

Adjust the following according to your needs. For example, if you have Cyrus SASL, install Postfix by running the following commands:

make CCARGS="-DNO_NIS -DUSE_TLS -I/usr/include/openssl/            \
             -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/include/sasl" \
     AUXLIBS="-lssl -lcrypto -lsasl2"                              \
     makefiles &&
make

This package does not come with a useful test suite.

Now, as the root user:

sh postfix-install -non-interactive \
   daemon_directory=/usr/lib/postfix \
   manpage_directory=/usr/share/man \
   html_directory=/usr/share/doc/postfix-3.7.0/html \
   readme_directory=/usr/share/doc/postfix-3.7.0/readme

Command Explanations

make makefiles: This command rebuilds the makefiles throughout the source tree to use the options contained in the CCARGS and AUXLIBS variables.

sh postfix-install -non-interactive: This keeps the install script from asking any questions, thereby accepting default destination directories in all but the few cases. If the html_directory and readme_directory options are not set then the documentation will not be installed.

CCARGS="-DNO_EAI ...": this will turn off SMTPUTF8 support, for example if the rest of your email address infrastructure cannot handle UTF-8 email addresses and message header values.

Configuring Postfix

Config Files

/etc/aliases, /etc/postfix/main.cf, and /etc/postfix/master.cf

Configuration Information

Create (or append to an existing) /etc/aliases with the following command. Change <LOGIN> to your non-root login identity so mail addressed to root can be forwarded to you. As the root user:

cat >> /etc/aliases << "EOF"
# Begin /etc/aliases

MAILER-DAEMON:    postmaster
postmaster:       root

root:             <LOGIN>
# End /etc/aliases
EOF

To protect an existing /etc/aliases file, the above command appends these aliases to it if it exists. This file should be checked and duplicate aliases removed, if present.

Note

The /etc/postfix/main.cf and /etc/postfix/master.cf files must be personalized for your system. The main.cf file needs your fully qualified hostname. You will find that main.cf is self documenting, so load it into your editor to make the changes you need for your situation.

Note

Postfix can also be set up to run in a chroot jail. See the file in the source examples/chroot-setup/LINUX2 for details.

If you have an existing configuration, you can run the postfix utility to add any necessary definitions to your existing files. As the root user:

/usr/sbin/postfix upgrade-configuration

Before starting Postfix, you should check that your configuration and file permissions will work properly. Run the following commands as the root user to check and start your Postfix server:

/usr/sbin/postfix check &&
/usr/sbin/postfix start

Boot Script

To automate the running of Postfix at startup, install the /etc/rc.d/init.d/postfix init script included in the blfs-bootscripts-20210826 package:

make install-postfix

Contents

Installed Programs: mailq (symlink), newaliases (symlink), postalias, postcat, postconf, postdrop, postfix, postkick, postlock, postlog, postmap, postmulti, postqueue, postsuper, and sendmail
Installed Libraries: None
Installed Directories: /{etc,usr/lib}/postfix, /usr/share/doc/postfix-3.7.0 and /var/{lib,spool}/postfix

Short Descriptions

mailq

A symlink to sendmail

newaliases

A symlink to sendmail

postalias

is a utility for Postfix alias database maintenance

postcat

Prints the contents of files from the Postfix queue in human readable format

postconf

Displays or changes the value of Postfix configuration parameters

postdrop

Creates a file in the maildrop directory and copies its standard input to the file

postfix

is the Postfix control program

postkick

Sends requests to the specified service over a local transport channel

postlock

Locks a mail folder for exclusive use, and executes commands passed to it

postlog

A Postfix-compatible logging interface for use in, for example, shell scripts

postmap

Creates or queries one or more Postfix lookup tables, or updates an existing one

postmulti

is the Postfix multi-instance manager. It allows a system administrator to manage multiple Postfix instances on a single host

postqueue

The Postfix user interface for queue management

postsuper

The Postfix user interface for superuser queue management

sendmail

is the Postfix to Sendmail compatibility interface

Last updated on

sendmail-8.17.1

Introduction to sendmail

The sendmail package contains a Mail Transport Agent (MTA).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

sendmail Dependencies

Required

OpenLDAP-2.6.1 (client)

Recommended
Optional

ghostscript-9.55.0 (for creating PDF documentation), Procmail-3.22 (the configuration proposed below requires that procmail be present at run-time), and nph

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/sendmail

Installation of sendmail

Before building sendmail, create the required user, group and directory with the following commands issued as the root user:

groupadd -g 26 smmsp                               &&
useradd -c "Sendmail Daemon" -g smmsp -d /dev/null \
        -s /bin/false -u 26 smmsp                  &&
chmod -v 1777 /var/mail                            &&
install -v -m700 -d /var/spool/mqueue

Note

See the source tree sendmail/README file for information on linking optional packages into the build. Use the example below, which adds support for SASL, StartTLS (OpenSSL) and OpenLDAP, as a starting point. Of course, modify it to suit your particular needs.

cat >> devtools/Site/site.config.m4 << "EOF"
APPENDDEF(`confENVDEF',`-DSTARTTLS -DSASL -DLDAPMAP -DHASFLOCK')
APPENDDEF(`confLIBS', `-lssl -lcrypto -lsasl2 -lldap -llber -ldb')
APPENDDEF(`confINCDIRS', `-I/usr/include/sasl')
EOF

Install sendmail with the following commands:

cat >> devtools/Site/site.config.m4 << "EOF"
define(`confMANGRP',`root')
define(`confMANOWN',`root')
define(`confSBINGRP',`root')
define(`confUBINGRP',`root')
define(`confUBINOWN',`root')
EOF

sed -i 's|/usr/man/man|/usr/share/man/man|' \
    devtools/OS/Linux           &&

cd sendmail                     &&
sh Build                        &&
cd ../cf/cf                     &&
cp generic-linux.mc sendmail.mc &&
sh Build sendmail.cf

This package does not come with a test suite.

Now, as the root user:

install -v -d -m755 /etc/mail &&
sh Build install-cf &&

cd ../..            &&
sh Build install    &&

install -v -m644 cf/cf/{submit,sendmail}.mc /etc/mail &&
cp -v -R cf/* /etc/mail                               &&

install -v -m755 -d /usr/share/doc/sendmail-8.17.1/{cf,sendmail} &&

install -v -m644 CACerts FAQ KNOWNBUGS LICENSE PGPKEYS README RELEASE_NOTES \
        /usr/share/doc/sendmail-8.17.1 &&

install -v -m644 sendmail/{README,SECURITY,TRACEFLAGS,TUNING} \
        /usr/share/doc/sendmail-8.17.1/sendmail &&

install -v -m644 cf/README /usr/share/doc/sendmail-8.17.1/cf &&

for manpage in sendmail editmap mailstats makemap praliases smrsh
do
    install -v -m644 $manpage/$manpage.8 /usr/share/man/man8
done &&

install -v -m644 sendmail/aliases.5    /usr/share/man/man5 &&
install -v -m644 sendmail/mailq.1      /usr/share/man/man1 &&
install -v -m644 sendmail/newaliases.1 /usr/share/man/man1 &&
install -v -m644 vacation/vacation.1   /usr/share/man/man1

Install the sendmail Installation and Operations Guide with the following commands:

Note

Remove op.pdf from the make and install commands below if you don't have Ghostscript installed.

cd doc/op                                       &&
sed -i 's/groff/GROFF_NO_SGR=1 groff/' Makefile &&
make op.txt op.pdf

Now, as the root user:

install -v -d -m755 /usr/share/doc/sendmail-8.17.1 &&
install -v -m644 op.ps op.txt op.pdf /usr/share/doc/sendmail-8.17.1 &&
cd ../..

Command Explanations

cat > devtools/Site/site.config.m4 << "EOF": This creates a configuration file changing some of the default settings.

sed ... devtools/OS/Linux: The site.config.m4 does not honor a change to the man directory, so fix it in the OS definitions.

sh Build; sh Build sendmail.cf; sh Build install-cf; sh Build install: sendmail uses an m4 based build script to create the various Makefiles. These commands build and install the package.

for manpage in...;do...;done; install ...: The man pages are installed already formatted and man displays them somewhat garbled. These commands replace the formatted pages with pages man can display properly.

Configuring sendmail

Config Files

/etc/mail/*

Configuration Information

Note

Ensure you have a fully qualified domain name defined in /etc/hosts for your system before proceeding.

Create the /etc/mail/local-host-names and /etc/mail/aliases files using the following commands as the root user:

echo $(hostname) > /etc/mail/local-host-names
cat > /etc/mail/aliases << "EOF"
postmaster: root
MAILER-DAEMON: root

EOF
newaliases

sendmail's primary configuration file, /etc/mail/sendmail.cf, is complex and not meant to be directly edited. The recommended method for changing it is to modify /etc/mail/sendmail.mc and various m4 files, then run the m4 macro processor from within /etc/mail as follows:

cd /etc/mail &&
m4 m4/cf.m4 sendmail.mc > sendmail.cf

A full explanation of the files to modify, and the available parameters can be found in /etc/mail/README.

Boot Script

To automate the running of sendmail at startup, install the /etc/rc.d/init.d/sendmail init script included in the blfs-bootscripts-20210826 package:

make install-sendmail

Note

The -qNm option to sendmail, where N is number of minutes, controls how often sendmail will process the mail queue. A default of 5 minutes is used in the init script. Individual workstation users may want to set this as low as 1 minute, large installations handling more mail may want to set it higher.

Contents

Installed Programs: editmap, mailstats, makemap, praliases, sendmail, smrsh, and vacation; symlinks to /usr/sbin/sendmail: hoststat, mailq, newaliases, and purgestat
Installed Libraries: None
Installed Directories: /etc/mail, /usr/share/doc/sendmail-8.17.1, and /var/spool/clientmqueue

Short Descriptions

editmap

queries and edits sendmail map files

hoststat

prints sendmail's persistent host status

mailstats

displays sendmail statistics

mailq

prints a summary of outbound mail messages waiting for delivery

makemap

creates sendmail map files

newaliases

rebuilds /etc/mail/aliases.db from the contents of /etc/mail/aliases

praliases

displays current sendmail aliases

purgestat

causes sendmail to clear (purge) all its host-status information

sendmail

is the sendmail mail transport agent

smrsh

is a restricted shell for sendmail

vacation

is an email auto responder

Last updated on

Chapter 22. Databases

This chapter includes databases that range from single-user read/write to industrial database servers with transaction support. Generally, you will be sent here to satisfy dependencies to other applications although building a SQL server on a base LFS system is entirely possible.

Important notes about upgrading Database Server Software

Note

This section is about reinstalling database software when an existing database is in use. It is not applicable for initial installations or if there is no existing database for the package being updated, but users should read through it to become aware of issues that can arise in the future.

Lets start this chapter with a dramatic screenshot of an issue that really happened. This issue will not occur if you are going to install the software the first time:

$ sudo systemctl status postgresql
-- postgresql.service - PostgreSQL database server
     Loaded: loaded (/usr/lib/systemd/system/postgresql.service; enabled; vendor preset: enabled)
     Active: failed (Result: exit-code) since Tue 2021-10-26 17:11:53 CDT; 2min 49s ago
    Process: 17336 ExecStart=/usr/bin/pg_ctl -s -D ${PGROOT}/data start -w -t 120 (code=exited, status=1/FAILURE)
        CPU: 7ms

Oct 26 17:11:53 SVRNAME systemd[1]: Starting PostgreSQL database server...
Oct 26 17:11:53 SRVNAME postgres[17338]: 2021-10-26 17:11:53.420 CDT [17338] FATAL:  
                database files are incompatible with server
Oct 26 17:11:53 SRVNAME postgres[17338]: 2021-10-26 17:11:53.420 CDT [17338] DETAIL:  
                The data directory was initialized by PostgreSQL version 13,
                which is not compatible with this version 14.0.
Oct 26 17:11:53 SRVNAME postgres[17336]: pg_ctl: could not start server
Oct 26 17:11:53 SRVNAME postgres[17336]: Examine the log output.
Oct 26 17:11:53 SRVNAME systemd[1]: postgresql.service: Control process exited, code=exited, status=1/FAILURE
Oct 26 17:11:53 SRVNAME systemd[1]: postgresql.service: Failed with result 'exit-code'.
Oct 26 17:11:53 SRVNAME systemd[1]: Failed to start PostgreSQL database server.

To avoid situations like the one above finding your database server software refusing to start, read the following thoughts about how to upgrade a DBMS (Database Management System) prior to actually doing the upgrade.

The root cause of the issue shown above was an upgrade of the server software to a newer major version but leaving the data files untouched. The administrator was able to recover without any loss of data.

Even if you are doing an install DBMS install, read through this section. Tt will provide you information about how to set up backup and restore procedures (at least the strategy for building them) which are sufficient for your needs and for the safety of your data.

Upgrade database server packages

Database systems work on files which hold the database metadata and the data itself. Those files are highly optimized in their internal structures for use by the server software. When upgrading such server software, newer server software may expect a different file format than was created by previous versions. In the best case, the new software can act on the old format as well—but not benefitting from newer formats which might result in better performance or of other improvements. It can also happen that the new server software will reformat the data files automatically when starting.

Unfortunately, the most likly case is that the new server software complains about out of date file formats and exits. When this happens and you have overwritten the installed server software, you may not be able to read the data files and the new software is unwilling to do so.

Changes in data file formats usually happen at major version changes but potentially can come at other times. Before upgrading the server software, check the documentation if there are changes which will require reformatting the database.

Of course, if you have databases with content which is not easy to rebuild, it is always a good idea to create backups of the database from time to time. When upgrading the server software, it is time to run another backup.

Upgrade by backup and restore

Note

A backup is meaningless if there is no verified process to restore the data from this backup. When running a database server, you should not only create backups but you should also verify that the process you designed to fulfill the restore task is working properly. When you encounter a problem with the restore when you urgently have to rely on the backup data, it is too late—your database is in danger.

In general, most (all?) database server software provides some basic tools to create backups of your data. Usually the backups created with those tools can be read by newer versions of the software (via a restore tool). Using older restore tools with newer backup data is not defined and you should never blindly assume that it will work. It might, but usually it doesn't.

The easiest way to upgrade your database files is to

  • Create a full database backup using the old tools.

    This step creates an offline copy of the database files ready to be used for long term archiving, for disaster recovery, or just preparation for upgrade. This offline backup consists of the full one-to-one copy of the current database files or a backup of the files from a certain time in history plus all journal data (that is Oracle® terminology, it is called "Continuous Archiving" or "write ahead log (WAL)" in Postgresql) containing information about changes made to the data content. The later take less time to create if the DB software provides this type of journaling as you only have to save the changes after creating the last backup. The amount of data to backup is much less than doing a full backup every time.

    In terms of upgrading database server software, a full backup (which can be used for subsequent incremental backups) should be made, but if the amount of data is too big, an incremental backup will be sufficient. Which strategy is appropriate for you depends on the amount of data stored in your database (is it a few hundred table rows or is it hundreds of terabytes?). A full backup of the later one isn't done quickly (and we assume that the underlying system of such a database is probably not on an LFS system). To close the last gap to fully protect your data, create a backup of the corresponding old binaries (and/or their sources) and store it along with the data files to make sure that there is a fallback solution if the newer software is not able to read the older data.

  • Upgrade the server software

    In this step, instructions to build the database server software are executed just as they are shown in subsequent sections talking about the DBMs like MariaDB or Postgresql. That is, build the software as usual using BLFS instructions.

  • Restore the database by using the new tools.

    To restore the data, the tools of the newly installed server software should be used. During the restoration process, the new tools will create and/or upgrade the data files in the format the software requires. It is assumed that newer software is capable of reading old data.

Since you have already have a backup procedure in place (and you have tested your restore procedure, right?), this might be the easiest way to upgrade as you are going to use your well known processes to upgrade just as you allways do—at least in terms of the backup and restore.

Upgrade the database files by using system tools

Some database systems (for instance Postgresql) provide a tool which can reformat (upgrade) the existing database files to the new format. Since the upgrading tool has to be used from the new server software (the old one cannot know anything about a new file format), the old software might be overwritten due to installation of the new software.

In case you have to restore a backup (for example, running the upgrade tool failed) you have to reinstall the old version to get back the access to your data.

Even though those tools might work with one of the actual database files, you should create a full backup before running them. A failure might result in a serious damage of the database files.

Notes for specific DBMS

PostgreSQL

Upstream documentation for Backup/Restore: https://www.postgresql.org/docs/current/backup.html

MariaDB

Upstream documentation for Backup/Restore: https://mariadb.com/kb/en/backup-and-restore-overview/

Sqlite

Do not underestimate Sqlite. It is a feature rich DBMS. The main difference from the two big players above is that Sqlite does not provide access via a network API. Sqlite databases are files always stored on the same machine as the running program which uses the database. The manipulation of data content is done via API calls to library functions directly within the program.

In the upstream documentation you may find the following useful:

Documentation of the sqlite3 command line tool: https://www.sqlite.org/cli.html

Documentation of backup API calls: https://www.sqlite.org/backup.html

Unfortunately, there is no dedicated chapter in the upstream documentation talking about backup/restore but there are several articles about it on the Internet. One example is shown below.

Documentation for Backup/Restore: https://database.guide/backup-sqlite-database/

Berkeley DB

Just like Sqlite this software acts on local database files meaning there is no network interface.

The relevant resources for Backup/Restore a Berkeley database are the man pages for db_dump and its counterpart db_load.

Last updated on

Berkeley DB-5.3.28

Introduction to Berkeley DB

The Berkeley DB package contains programs and utilities used by many other applications for database related functions.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Berkeley DB Dependencies

Optional

libnsl-2.0.0 and Sharutils-4.15.2 (for the uudecode command)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/db

Installation of Berkeley DB

First apply a fix so that this will compile with current versions of g++:

sed -i 's/\(__atomic_compare_exchange\)/\1_db/' src/dbinc/atomic.h

Install Berkeley DB by running the following commands:

cd build_unix                        &&
../dist/configure --prefix=/usr      \
                  --enable-compat185 \
                  --enable-dbm       \
                  --disable-static   \
                  --enable-cxx       &&
make

Now, as the root user:

make docdir=/usr/share/doc/db-5.3.28 install &&

chown -v -R root:root                        \
      /usr/bin/db_*                          \
      /usr/include/db{,_185,_cxx}.h          \
      /usr/lib/libdb*.{so,la}                \
      /usr/share/doc/db-5.3.28

Command Explanations

cd build_unix && ../dist/configure --prefix=/usr...: This replaces the normal ./configure command, as Berkeley DB comes with various build directories for different platforms.

--enable-compat185: This switch enables building the DB-1.85 compatibility API.

--enable-cxx: This switch enables building C++ API libraries.

--enable-dbm: Enables legacy interface support needed by some older packages.

make docdir=/usr/share/doc/db-5.3.28 install: This installs the documentation in the standard location instead of /usr/docs.

chown -v -R root:root ...:This command changes the ownership of various installed files from the uid:gid of the builder to root:root.

--enable-tcl --with-tcl=/usr/lib: Enables Tcl support in DB and creates the libdb_tcl libraries.

--enable-java: Enables Java support in DB and creates the libdb_java libraries. Support is currently broken with Java-8.x.

Contents

Installed Programs: db_archive, db_checkpoint, db_deadlock, db_dump, db_hotbackup, db_load, db_log_verify, db_printlog, db_recover, db_replicate, db_stat, db_tuner, db_upgrade, and db_verify
Installed Libraries: libdb.so, libdb_cxx.so, and libdb_tcl.so
Installed Directory: /usr/share/doc/db-5.3.28

Short Descriptions

db_archive

prints the pathnames of log files that are no longer in use

db_checkpoint

is a daemon process used to monitor and checkpoint database logs

db_deadlock

is used to abort lock requests when deadlocks are detected

db_dump

converts database files to a flat file format readable by db_load

db_hotbackup

creates "hot backup" or "hot failover" snapshots of Berkeley DB databases

db_load

is used to create database files from flat files created with db_dump

db_log_verify

verifies the log files of a database

db_printlog

converts database log files to human readable text

db_recover

is used to restore a database to a consistent state after a failure

db_replicate

is a daemon process that provides replication/HA services on a transactional environment

db_stat

displays database environment statistics

db_tuner

analyzes the data in a btree database, and suggests a page size that is likely to deliver optimal operation

db_upgrade

is used to upgrade database files to a newer version of Berkeley DB

db_verify

is used to run consistency checks on database files

Last updated on

lmdb-0.9.29

Introduction to lmdb

The lmdb package is a fast, compact, key-value embedded data store. It uses memory-mapped files, so it has the read performance of a pure in-memory database while still offering the persistence of standard disk-based databases, and is only limited to the size of the virtual address space

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lmdb

Installation of lmdb

Note

This package extracts to lmdb-LMDB_0.9.29.

Install lmdb by running the following commands:

cd libraries/liblmdb &&
make                 &&
sed -i 's| liblmdb.a||' Makefile

This package does not come with a test suite.

Now, as the root user:

make prefix=/usr install

Command Explanations

sed ... liblmdb.a ... Makefile: The package executables use a static library so it must be created. This command suppresses installation of the static library.

Contents

Installed Program: mdb_copy, mdb_dump, mdb_load, and mdb_stat
Installed Library: liblmdb.so
Installed Directories: None

Last updated on

MariaDB-10.6.7

Introduction to MariaDB

MariaDB is a community-developed fork and a drop-in replacement for the MySQL relational database management system.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Note

The installed size of MariaDB is 656 MB, but this can be reduced by about 259 MB, if desired, by removing the /usr/share/mysql/test directory after installation.

Additional Downloads

MariaDB Dependencies

Required

CMake-3.22.2

Recommended
Optional

Boost-1.78.0, libaio-0.3.112, libxml2-2.9.13, Linux-PAM-1.5.2, MIT Kerberos V5-1.19.2, pcre2-10.39, Ruby-3.1.0, unixODBC-2.3.9, Valgrind-3.18.1, Groonga, KyTea, Judy, lz4, MeCab, MessagePack, mruby, MyRocks, Snappy, Sphinx, and ZeroMQ

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/mariadb

Installation of MariaDB

Warning

MariaDB and MySQL cannot be installed on the same system without extensive changes to the build configuration of one of the two applications.

For security reasons, running the server as an unprivileged user and group is strongly encouraged. Issue the following (as root) to create the user and group:

groupadd -g 40 mysql &&
useradd -c "MySQL Server" -d /srv/mysql -g mysql -s /bin/false -u 40 mysql

Fix a stack smashing error introduced by openssl-3:

patch -Np1 -i ../mariadb-10.6.7-openssl3_fix-1.patch

Install MariaDB by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_BUILD_TYPE=Release                      \
      -DCMAKE_INSTALL_PREFIX=/usr                     \
      -DINSTALL_DOCDIR=share/doc/mariadb-10.6.7       \
      -DINSTALL_DOCREADMEDIR=share/doc/mariadb-10.6.7 \
      -DINSTALL_MANDIR=share/man                      \
      -DINSTALL_MYSQLSHAREDIR=share/mysql             \
      -DINSTALL_MYSQLTESTDIR=share/mysql/test         \
      -DINSTALL_PLUGINDIR=lib/mysql/plugin            \
      -DINSTALL_SBINDIR=sbin                          \
      -DINSTALL_SCRIPTDIR=bin                         \
      -DINSTALL_SQLBENCHDIR=share/mysql/bench         \
      -DINSTALL_SUPPORTFILESDIR=share/mysql           \
      -DMYSQL_DATADIR=/srv/mysql                      \
      -DMYSQL_UNIX_ADDR=/run/mysqld/mysqld.sock       \
      -DWITH_EXTRA_CHARSETS=complex                   \
      -DWITH_EMBEDDED_SERVER=ON                       \
      -DSKIP_TESTS=ON                                 \
      -DTOKUDB_OK=0                                   \
      .. &&
make

To test the results, issue: make test. One test, test-connect, is known to fail.

Note

A more extensive set of tests can be run with the following:

pushd mysql-test
./mtr --parallel <N> --mem --force
popd

Where N is the number of tests to run in parallel. Over 5400 tests are run in about 24 SBU with N=4. A few tests may fail, mainly due to character set issues.

Now, as the root user:

make install

Command Explanations

-DWITH_EMBEDDED_SERVER=ON: This switch enables compiling the embedded server library needed by certain applications, such as Amarok.

-DWITH_EXTRA_CHARSETS=complex: This switch enables support for the complex character sets.

-DSKIP_TESTS=ON: This switch disables tests for MariaDB Connector/C which are not supported without additional setup.

-DWITHOUT_SERVER=ON: Use this switch if you don't want the server and would like to build the client only.

Note

There are numerous options available to cmake. Check the output of the cmake . -LH for additional customization options.

Configuring MySQL

Config Files

/etc/mysql/my.cnf and ~/.my.cnf

Configuration Information

Create basic /etc/mysql/my.cnf using the following command as the root user:

install -v -dm 755 /etc/mysql &&
cat > /etc/mysql/my.cnf << "EOF"
# Begin /etc/mysql/my.cnf

# The following options will be passed to all MySQL clients
[client]
#password       = your_password
port            = 3306
socket          = /run/mysqld/mysqld.sock

# The MySQL server
[mysqld]
port            = 3306
socket          = /run/mysqld/mysqld.sock
datadir         = /srv/mysql
skip-external-locking
key_buffer_size = 16M
max_allowed_packet = 1M
sort_buffer_size = 512K
net_buffer_length = 16K
myisam_sort_buffer_size = 8M

# Don't listen on a TCP/IP port at all.
skip-networking

# required unique id between 1 and 2^32 - 1
server-id       = 1

# Uncomment the following if you are using BDB tables
#bdb_cache_size = 4M
#bdb_max_lock = 10000

# InnoDB tables are now used by default
innodb_data_home_dir = /srv/mysql
innodb_log_group_home_dir = /srv/mysql
# All the innodb_xxx values below are the default ones:
innodb_data_file_path = ibdata1:12M:autoextend
# You can set .._buffer_pool_size up to 50 - 80 %
# of RAM but beware of setting memory usage too high
innodb_buffer_pool_size = 128M
innodb_log_file_size = 48M
innodb_log_buffer_size = 16M
innodb_flush_log_at_trx_commit = 1
innodb_lock_wait_timeout = 50

[mysqldump]
quick
max_allowed_packet = 16M

[mysql]
no-auto-rehash
# Remove the next comment character if you are not familiar with SQL
#safe-updates

[isamchk]
key_buffer = 20M
sort_buffer_size = 20M
read_buffer = 2M
write_buffer = 2M

[myisamchk]
key_buffer_size = 20M
sort_buffer_size = 20M
read_buffer = 2M
write_buffer = 2M

[mysqlhotcopy]
interactive-timeout

# End /etc/mysql/my.cnf
EOF

You can now install a database and change the ownership to the unprivileged user and group (perform as the root user):

mysql_install_db --basedir=/usr --datadir=/srv/mysql --user=mysql &&
chown -R mysql:mysql /srv/mysql

Further configuration requires that the MariaDB server is running. Start the server using the following commands as the root user:

install -v -m755 -o mysql -g mysql -d /run/mysqld &&
mysqld_safe --user=mysql 2>&1 >/dev/null &

A default installation does not set up a password for the administrator, so use the following command as the root user to set one.

mysqladmin -u root password

Configuration of the server is now finished. Shut the server down using the following command as the root user:

mysqladmin -p shutdown

Boot Script

Install the /etc/rc.d/init.d/mysql init script included in the blfs-bootscripts-20210826 package as the root user to start the MariaDB server during system boot-up.

make install-mysql

Note

If you have an existing database already and this installation of binaries was just an upgrade to a newer version, check the upstream documentation for upgrading. It is recommended to run:

mariadb-upgrade

Contents

Installed Programs: aria_chk, aria_dump_log, aria_ftdump, aria_pack, aria_read_log, aria_s3_copy, galera_new_cluster, galera_recovery, innochecksum, mariabackup, mariadb, mariadbd, mariadb-access, mariadb-admin, mariadb-backup, mariadb-binlog, mariadb-check, mariadb-client-test, mariadb-client-test-embedded, mariadb-conv, mariadb-convert-table-format, mariadb-find-rows, mariadbd-multi, mariadbd-safe, mariadbd-safe-helper, mariadb-dump, mariadb-dumpslow, mariadb-embedded, mariadb-fix-extensions, mariadb-hotcopy, mariadb-import, mariadb-install-db, mariadb-ldb, mariadb-plugin, mariadb-secure-installation, mariadb-setpermission, mariadb-service-convert, mariadb-show, mariadb-slap, mariadb-test, mariadb-test-embedded, mariadb-tzinfo-to-sql, mariadb-upgrade, mariadb-waitpid, mariadb_config, mbstream, msql2mysql, my_print_defaults, myisamchk, myisam_ftdump, myisamlog, myisampack, mysql_config, mytop, perror, replace, resolve_stack_dump, resolveip, sst_dump, wsrep_sst_common, wsrep_sst_mariabackup, wsrep_sst_mysqldump, and wsrep_sst_rsync
Installed Libraries: libmariadbclient.a, libmariadb.so, libmariadbd.so, libmysqlclient.a, libmysqlclient_r.a (symbolic links to libmariadbclient.a), libmysqld.{so,a}, libmysqlservices.a, and several under /usr/lib/mysql/plugin/
Installed Directories: /etc/mysql, /usr/{include,lib,share}/mysql, /usr/share/groonga{-normalizer-mysql}, and /usr/share/doc/mariadb-10.6.7

Short Descriptions

There are several symlinks from mysql* to their mariadb counterparts. These are maintained for compatibility.

The Perl DBI modules must be installed for some of the MariaDB support programs to function properly.

Short Descriptions

aria_chk

is used to check, repair, optimize, sort and get information about Aria tables

aria_dump_log

is a tool to dump the contents of Aria log pages

aria_ftdump

displays full-text index information

aria_pack

is a tool to generate compressed, read-only Aria tables

aria_read_log

displays Aria log file contents

aria_s3_copy

copies an aria table to and from AWS S3

galera_new_cluster

bootstraps a new Galera cluster

galera_recovery

recovers data from a Galera cluster

innochecksum

prints checksums for InnoDB files

mariabackup

is an open source backup tool for InnoDB and XtraDB

mariadb

is a simple SQL shell with input line editing capabilities

mariadbd

is the MySQL server daemon

mariadb-access

checks the access privileges for a host name, user name, and database combination

mariadb-admin

is a client for performing administrative operations

mariadb-binlog

reads binary log files

mariadb-check

performs table maintenance: It checks, repairs, optimizes, or analyzes tables

mariadb-client-test

is used for testing aspects of the MySQL client API that cannot be tested using mysqltest and its test language

mariadb-client-test-embedded

is a tool to test the client API for the embedded server

mariadb-conv

converts character sets for use with MariaDB

mariadb-convert-table-format

converts the tables in a database to use a particular storage engine

mariadbd-multi

is designed to manage several mysqld processes that listen for connections on different Unix socket files and TCP/IP ports

mariadbd-safe

is the recommended way to start a mysqld server on Unix and NetWare

mariadb-dump

is a backup program

mariadb-dumpslow

parses MySQL slow query log files and prints a summary of their contents

mariadb-embedded

is a MySQL client statically linked to libmariadbd

mariadb-find-rows

reads files containing SQL statements and extracts statements that match a given regular expression or that contain USE db_name or SET statements

mariadb-fix-extensions

converts the extensions for MyISAM (or ISAM) table files to their canonical forms

mariadb-hotcopy

locks the table, flushes the table and then performs a copy of the database

mariadb-import

reads a range of data formats, and inserts the data into a database

mariadb-install-db

initializes the MySQL data directory and creates the system tables that it contains, if they do not exist

mariadb-ldb

is the RocksDB tool

mariadb-plugin

is a utility that enables MySQL administrators to manage which plugins a MySQL server loads

mariadb-secure-installation

is a tool to improve MySQL installation security

mariadb-service-convert

generates a systemd unit based on the current mariadb settings

mariadb-setpermission

sets permissions in the MySQL grant tables

mariadb-show

shows the structure of a MariaDB database

mariadb-slap

is a diagnostic program designed to emulate client load for a MySQL server and to report the timing of each stage

mariadb-test

runs a test case against a MySQL server and optionally compares the output with a result file

mariadb-test-embedded

is similar to the mysqltest command but is built with support for the libmysqld embedded server

mariadb-tzinfo-to-sql

loads the time zone tables in the mysql database

mariadb-upgrade

examines all tables in all databases for incompatibilities with the current version of MySQL Server

mariadb-waitpid

signals a process to terminate and waits for the process to exit

mariadb_config

gets compiler flags for using the MariaDB Connector/C

mbstream

is an utility for sending InnoDB and XTraDB backups over a stream

msql2mysql

is a tool to convert mSQL programs for use with MySQL

my_print_defaults

displays the options from option groups of option files

myisam_ftdump

displays information about FULLTEXT indexes in MyISAM tables

myisamchk

gets information about your database tables or checks, repairs, or optimizes them

myisamlog

displays MyISAM log file contents

myisampack

is a tool for compressing MyISAM tables

mysql_config

provides you with useful information for compiling your MySQL client and connecting it to MySQL

mytop

is a console-based tool for monitoring the threads and overall performance of a MySQL server

perror

is a utility that displays descriptions for system or storage engine error codes

replace

is a MariaDB/MySQL extension to the SQL standard

resolve_stack_dump

resolves a numeric stack dump to symbols

resolveip

is a utility for resolving IP addresses to host names and vice versa

sst_sump

dumps the content of sst files (the format used by RocksDB)

Last updated on

PostgreSQL-14.2

Introduction to PostgreSQL

PostgreSQL is an advanced object-relational database management system (ORDBMS), derived from the Berkeley Postgres database management system.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

PostgreSQL Dependencies

Optional

Python-2.7.18, ICU-70.1, libxml2-2.9.13, libxslt-1.1.35, OpenLDAP-2.6.1, Linux-PAM-1.5.2, MIT Kerberos V5-1.19.2 and Bonjour

Optional (To Regenerate Documentation)

fop-2.7, docbook-4.5-dtd, docbook-dsssl-1.79, DocBook-utils-0.6.14, OpenJade-1.3.2, and SGMLSpm-1.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/postgresql

Installation of PostgreSQL

For enhanced security, it is better to have a dedicated group and user for running the PostgreSQL server. First, issue as the root user:

groupadd -g 41 postgres &&
useradd -c "PostgreSQL Server" -g postgres -d /srv/pgsql/data \
        -u 41 postgres

Note

There are several configuration items that add additional functionality with optional packages to PostgreSQL. Use ./configure --help to see a list.

Install PostgreSQL with the following commands:

sed -i '/DEFAULT_PGSOCKET_DIR/s@/tmp@/run/postgresql@' src/include/pg_config_manual.h &&

./configure --prefix=/usr          \
            --enable-thread-safety \
            --docdir=/usr/share/doc/postgresql-14.2 &&
make

There are a number of programs in the contrib/ directory. If you are going to run this installation as a server and wish to build some of them, enter make -C contrib or make -C contrib/<SUBDIR-NAME> for each subdirectory.

Tests must be run as an unprivileged user because they need to start a temporary server and this is prevented as the root user. For the same reason, you need to stop all PostgreSQL servers if any are running. If a previous version of PostgreSQL is installed, it may be necessary to use --disable-rpath with configure to avoid failures, but installing the binaries created using this switch is not recommended. To test the results, issue: make check.

Note

If you are installing PostgreSQL to upgrade an existing installation, there are important steps that you need to follow. If the major version of the new build is greater than the previous version, there is a chance that the data file format has changed. new software cannot act on the existing data files. In this case, the server will not start because the old programs have been overwritten, so the data is unavailable until it's file format has been converted.

Before upgrading an existing installation of PostgreSQL, check the documentation for any considerations that you must keep in mind during the upgrade. Note that new major versions might use a different binary format in the data objects, causing potential incompatibilities. For more information, check out upstream's documentation about upgrading PostgreSQL here. https://www.postgresql.org/docs/current/upgrading.html.

At this point, you may have both the old and the new binaries installed on your filesystem. These binaries can be used to perform an upgrade of your existing database files. For the following instructions it is assumed that

  • The actual data files are stored in /srv/pgsql/data

  • The upgraded data files will be stored in /srv/pgsql/newdata

  • There is enough disk space to hold the actual data files twice. The upgrade is not an inline upgrade but it will copy the data to new database files.

Fist, do a temporary install which makes access to the new binaries much easier:

make DESTDIR=$(pwd)/DESTDIR install

Next, create a directory which is writable by the postgres user, as the root user:

install -D -o postgres $(pwd)/DESTDIR/tmp

Now, stop the existing instance of PostgreSQL and start the upgrade process as the root user:

pushd $(pwd)/DESTDIR/tmp
/etc/rc.d/init.d/postgresql stop
su postgres -c "../usr/bin/initdb -D /srv/pgsql/newdata"
su postgres -c "../usr/bin/pg_upgrade \
                    -d /srv/pgsql/data    -b /usr/bin \
                    -D /srv/pgsql/newdata -B ../usr/bin"
popd

At this point, your database files available in two locations on disk. The old data is located in /srv/pgsql/data, and the new data is in /srv/pgsql/newdata. Backing up the old database files is suggested before continuing.

Next, remove the old database files, and rename the new data directory as the root user:

rm -rf /srv/pgsql/data
mv /srv/pgsql/newdata /srv/pgsql/data

Now, as the root user:

make install      &&
make install-docs

If you made any of the contrib/ programs, as the root user:

make -C contrib/<SUBDIR-NAME> install

Tip

If you only intend to use PostgreSQL as a client to connect to a server on another machine, your installation is complete and you should not run the remaining commands.

If you have upgraded an existing database, skip the rest of the commands because your database is ready to use. If this is the first time you install PostgreSQL, continue with the initialization.

Initialize a database cluster with the following commands issued by the root user:

install -v -dm700 /srv/pgsql/data &&
install -v -dm755 /run/postgresql &&
chown -Rv postgres:postgres /srv/pgsql /run/postgresql

Now, initialize the database as the root user:

su - postgres -c '/usr/bin/initdb -D /srv/pgsql/data'

Command Explanations

sed -i ...: This sed changes the server socket location from /tmp to /run/postgresql.

--enable-thread-safety: This switch makes the client libraries thread-safe by allowing concurrent threads in libpq and ECPG programs to safely control their private connection handles.

--with-openssl: builds the package with support for OpenSSL encrypted connections.

--with-perl: builds the PL/Perl server-side language.

--with-python: builds the PL/Python server-side language. Add PYTHON=/usr/bin/python2 for Python2 support, otherwise Python3 is used by default.

--with-tcl: builds the PL/Tcl server-side language.

Configuring PostgreSQL

Config Files

$PGDATA/pg_ident.con, $PGDATA/pg_hba.conf, and $PGDATA/postgresql.conf

The PGDATA environment variable is used to distinguish database clusters from one another by setting it to the value of the directory which contains the cluster desired. The three configuration files exist in every PGDATA/ directory. Details on the format of the files and the options that can be set in each can be found in /usr/share/doc/postgresql-14.2/html/index.html.

Boot Script

Install the /etc/rc.d/init.d/postgresql init script included in the blfs-bootscripts-20210826 package:

make install-postgresql

Starting the PostgreSQL Server and Creating a Sample Database

The database server can be manually started with the following command (as the root user):

su - postgres -c '/usr/bin/postgres -D /srv/pgsql/data > \
                  /srv/pgsql/data/logfile 2>&1 &'

Note

If you are scripting this part, you should wait for the server to start before going on, by adding for example sleep 2 after the above command.

The instructions below show how to create a database, add a table to it, insert some rows into the table and select them, to verify that the installation is working properly. Still as user root, issue:

su - postgres -c '/usr/bin/createdb test' &&
echo "create table t1 ( name varchar(20), state_province varchar(20) );" \
    | (su - postgres -c '/usr/bin/psql test ') &&
echo "insert into t1 values ('Billy', 'NewYork');" \
    | (su - postgres -c '/usr/bin/psql test ') &&
echo "insert into t1 values ('Evanidus', 'Quebec');" \
    | (su - postgres -c '/usr/bin/psql test ') &&
echo "insert into t1 values ('Jesse', 'Ontario');" \
    | (su - postgres -c '/usr/bin/psql test ') &&
echo "select * from t1;" | (su - postgres -c '/usr/bin/psql test')

When you are done with testing, you can shut down the server, by issuing as root:

su - postgres -c "/usr/bin/pg_ctl stop -D /srv/pgsql/data"

Contents

Installed Programs: clusterdb, createdb, createuser, dropdb, dropuser, ecpg, initdb, pg_archivecleanup, pg_basebackup, pg_checksums, pg_config, pg_controldata, pg_ctl, pg_dump, pg_dumpall, pg_isready, pg_receivewal, pg_recvlogical, pg_resetwal, pg_restore, pg_rewind, pg_test_fsync, pg_test_timing, pg_upgrade, pg_verifybackup, pg_waldump, pgbench, postgres, postmaster (deprecated), psql, reindexdb, vacuumdb, optionally, if Tcl support has been built, pltcl_delmod, pltcl_listmod, pltcl_loadmod, and optionally (in contrib/) oid2name, pg_standby, vacuumlo, and many others
Installed Libraries: libecpg.{so,a}, libecpg_compat.{so,a}, libpgcommon.a, libpgcommon_shlib.a, libpgfeutils.a, libpgport.a, libpgport_shlib.a, libpgtypes.{so,a}, libpq.{so,a}, various charset modules and optionally programming language modules under /usr/lib/postgresql
Installed Directories: /usr/include/{libpq,postgresql}, /usr/lib/postgresql, /usr/share/{doc/postgresql-14.2,postgresql}, and /srv/pgsql

Short Descriptions

clusterdb

is a utility for reclustering tables in a PostgreSQL database

createdb

creates a new PostgreSQL database

createuser

defines a new PostgreSQL user account

dropdb

removes a PostgreSQL database

dropuser

removes a PostgreSQL user account

ecpg

is the embedded SQL preprocessor

initdb

creates a new database cluster

oid2name

resolves OIDs (Object IDs) and file nodes in a PostgreSQL data directory

pg_archivecleanup

cleans up PostgreSQL WAL (write-ahead log) archive files

pg_basebackup

takes base backups of a running PostgreSQL cluster

pg_checksums

enables, disables, or checks data checksums in a PostgreSQL database cluster

pg_config

retrieves PostgreSQL version information

pg_controldata

returns information initialized during initdb, such as the catalog version and server locale

pg_ctl

controls stopping and starting the database server

pg_dump

dumps database data and metadata into scripts which are used to recreate the database

pg_dumpall

recursively calls pg_dump for each database in a cluster

pg_isready

checks the connection status of a PostgreSQL server

pg_receivewal

is used to stream write-ahead logs from a PostgreSQL server

pg_recvlogical

controls PostgreSQL logical decoding streams

pg_resetwal

resets the write-ahead log and other control information of a PostgreSQL database cluster

pg_restore

creates databases from dump files created by pg_dump

pg_rewind

synchronizes a PostgreSQL data directory with another data directory that was forked from the first one

pg_standby

supports the creation of a PostgreSQL warm standby server

pg_test_fsync

determines the fastest wal_sync method for PostgreSQL

pg_test_timing

measures timing overhead

pg_upgrade

upgrades a PostgreSQL server instance

pg_verifybackup

verifies the integrity of a base backup of a PostgreSQL cluster

pg_waldump

displays a human-readable rendering of the write-ahead log of a PostgreSQL database cluster

pgbench

runs a benchmark test on PostgreSQL

pltcl_delmod

is a support script used to delete a module from a PL/Tcl table. The command requires the Pgtcl package to be installed

pltcl_listmod

is a support script used to list the modules in a PL/Tcl table. The command requires the Pgtcl package to be installed

pltcl_loadmod

is a support script used to load a module into a PL/Tcl table. The command requires the Pgtcl package to be installed too

postgres

is the PostgreSQL database server

postmaster

(deprecated, a symlink to postgres) is a multi-user database daemon

psql

is a console based database shell

reindexdb

is a utility for rebuilding indexes in a database

vacuumdb

compacts databases and generates statistics for the query analyzer

vacuumlo

removes orphaned large objects from a PostgreSQL database

libecpg.{so,a}

contains functions to support embedded SQL in C programs

libecpg_compat.{so,a}

is the ecpg compatibility library

libgport.a

is the port-specific subsystem of the Postgres backend

libpgtypes.{so,a}

contains functions for dealing with Postgres data types

libpq.{so,a}

is the C programmer's API to Postgres

Last updated on

SQLite-3.37.2

Introduction to SQLite

The SQLite package is a software library that implements a self-contained, serverless, zero-configuration, transactional SQL database engine.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Optional Documentation

SQLite Dependencies

Optional

libedit and UnZip-6.0 (required to unzip the documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/sqlite

Installation of SQLite

If you downloaded the optional documentation, issue the following command to install the documentation into the source tree:

unzip -q ../sqlite-doc-3370200.zip

Install SQLite by running the following commands:

./configure --prefix=/usr     \
            --disable-static  \
            --enable-fts5     \
            CPPFLAGS="-DSQLITE_ENABLE_FTS3=1            \
                      -DSQLITE_ENABLE_FTS4=1            \
                      -DSQLITE_ENABLE_COLUMN_METADATA=1 \
                      -DSQLITE_ENABLE_UNLOCK_NOTIFY=1   \
                      -DSQLITE_ENABLE_DBSTAT_VTAB=1     \
                      -DSQLITE_SECURE_DELETE=1          \
                      -DSQLITE_ENABLE_FTS3_TOKENIZER=1" &&
make

This package does not come with a test suite.

Now, as the root user:

make install

If you downloaded the optional documentation, issue the following commands as the root user to install it:

install -v -m755 -d /usr/share/doc/sqlite-3.37.2 &&
cp -v -R sqlite-doc-3370200/* /usr/share/doc/sqlite-3.37.2

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-fts5: This switch enables support for version 5 of the full text search extension.

CPPFLAGS="-DSQLITE_ENABLE_FTS3=1 -DSQLITE_ENABLE_FTS3_TOKENIZER=1 -DSQLITE_ENABLE_FTS4=1 -DSQLITE_ENABLE_COLUMN_METADATA=1 -DSQLITE_SECURE_DELETE -DSQLITE_ENABLE_UNLOCK_NOTIFY=1 -DSQLITE_ENABLE_DBSTAT_VTAB=1": Applications such as SeaMonkey require these options to be turned on. The only way to do this is to include them in the CFLAGS or CPPFLAGS. We use the latter so the default value (or any value set by the user) of CFLAGS won't be affected. For further information on what can be specified see http://www.sqlite.org/compile.html.

Contents

Installed Program: sqlite3
Installed Library: libsqlite3.so
Installed Directory: /usr/share/doc/sqlite-3.37.2

Short Descriptions

sqlite3

is a terminal-based front-end to the SQLite library that can evaluate queries interactively and display the results

libsqlite3.so

contains the SQLite API functions

Last updated on

Chapter 23. Other Server Software

Here you will find many ways to share your machine with the rest of the world or your local network. Before installing any packages in this chapter, you need to be sure you understand what the package does and how to set it up correctly. It might also be helpful to learn about the consequences of an improper setup so that you can analyze the risks.

OpenLDAP-2.6.1

Introduction to OpenLDAP

The OpenLDAP package provides an open source implementation of the Lightweight Directory Access Protocol.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

OpenLDAP Dependencies

Recommended
Optional

GnuTLS-3.7.3, Pth-2.0.7, unixODBC-2.3.9, MariaDB-10.6.7 or PostgreSQL-14.2 or MySQL, OpenSLP, WiredTiger, and Berkeley DB-5.3.28 (for slapd, but deprecated)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/openldap

Installation of OpenLDAP

Note

If you only need to install the client side ldap* binaries, corresponding man pages, libraries and header files (referred to as a client-only install), issue these commands instead of the following ones (no test suite available):

patch -Np1 -i ../openldap-2.6.1-consolidated-2.patch &&
autoconf &&

./configure --prefix=/usr     \
            --sysconfdir=/etc \
            --disable-static  \
            --enable-dynamic  \
            --enable-versioning=yes  \
            --disable-debug   \
            --disable-slapd &&

make depend &&
make

Then, as the root user:

make install

There should be a dedicated user and group to take control of the slapd daemon after it is started. Issue the following commands as the root user:

groupadd -g 83 ldap &&
useradd  -c "OpenLDAP Daemon Owner" \
         -d /var/lib/openldap -u 83 \
         -g ldap -s /bin/false ldap

Install OpenLDAP by running the following commands:

patch -Np1 -i ../openldap-2.6.1-consolidated-2.patch &&
autoconf &&

./configure --prefix=/usr         \
            --sysconfdir=/etc     \
            --localstatedir=/var  \
            --libexecdir=/usr/lib \
            --disable-static      \
            --enable-versioning=yes \
            --disable-debug       \
            --with-tls=openssl    \
            --with-cyrus-sasl     \
            --enable-dynamic      \
            --enable-crypt        \
            --enable-spasswd      \
            --enable-slapd        \
            --enable-modules      \
            --enable-rlookups     \
            --enable-backends=mod \
            --disable-ndb         \
            --disable-sql         \
            --disable-wt          \
            --enable-overlays=mod &&

make depend &&
make

The tests appear to be fragile. Errors may cause the tests to abort prior to finishing, apparently due to timing issues. The tests take about 65 minutes and are processor independent. To test the results, issue: make test.

Now, as the root user:

make install &&

sed -e "s/\.la/.so/" -i /etc/openldap/slapd.{conf,ldif}{,.default} &&

install -v -dm700 -o ldap -g ldap /var/lib/openldap     &&

install -v -dm700 -o ldap -g ldap /etc/openldap/slapd.d &&
chmod   -v    640     /etc/openldap/slapd.{conf,ldif}   &&
chown   -v  root:ldap /etc/openldap/slapd.{conf,ldif}   &&

install -v -dm755 /usr/share/doc/openldap-2.6.1 &&
cp      -vfr      doc/{drafts,rfc,guide} \
                  /usr/share/doc/openldap-2.6.1

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--disable-debug: This switch disables the debugging code in OpenLDAP.

--enable-dynamic: This switch forces the OpenLDAP libraries to be dynamically linked to the executable programs.

--enable-versioning: This switch enables symbol versioning in the OpenLDAP libraries. Without this, some applications might generate a warning about missing symbol versions.

--enable-crypt: This switch enables using crypt(3) passwords.

--enable-spasswd: This switch enables SASL password verification.

--enable-modules: This switch enables dynamic module support.

--enable-rlookups: This switch enables reverse lookups of client hostnames.

--enable-backends: This switch enables all available backends.

--enable-overlays: This switch enables all available overlays.

--disable-ndb: This switch disables MySQL NDB Cluster backend which causes configure to fail if MySQL is present.

--disable-sql: This switch explicitly disables the SQL backend. Omit this switch if a SQL server is installed and you are going to use a SQL backend.

--disable-wt: This switch explicitly disables the WiredTiger backend. Omit this switch if WiredTiger is installed and you are going to use a WiredTiger backend.

--libexecdir=/usr/lib: This switch controls where the /usr/lib/openldap directory is installed. Everything in that directory is a library, so it belongs under /usr/lib instead of /usr/libexec.

--enable-slp: This switch enables SLPv2 support. Use it if you have installed OpenSLP.

Note

You can run ./configure --help to see if there are other switch you can pass to the configure command to enable other options or dependency packages.

install ..., chown ..., and chmod ...: Having slapd configuration files and ldap databases in /var/lib/openldap readable by anyone is a SECURITY ISSUE, especially since a file stores the admin password in PLAIN TEXT. That's why mode 640 and root:ldap ownership were used. The owner is root, so only root can modify the file, and group is ldap, so that the group which owns slapd daemon could read but not modify the file in case of a security breach.

Configuring OpenLDAP

Config Files

  • For LDAP client: /etc/openldap/ldap.conf and ~/.ldaprc

  • For LDAP server, two configuration mechanisms are used: a legacy /etc/openldap/slapd.conf configuration file and the recommended slapd-config system, using an LDIF database stored in /etc/openldap/slapd.d.

Configuration Information

Configuring the slapd servers can be complex. Securing the LDAP directory, especially if you are storing non-public data such as password databases, can also be a challenging task. In order to set up OpenLDAP, you'll need to modify either the /etc/openldap/slapd.conf file (old method), or the /etc/openldap/slapd.ldif file and then use ldapadd to create the LDAP configuration database in /etc/openldap/slapd.d (recommended by the OpenLDAP documentation).

Warning

The instructions above install an empty LDAP structure and a default /etc/openldap/slapd.conf file, which are suitable for testing the build and other packages using LDAP. Do not use them on a production server.

Resources to assist you with topics such as choosing a directory configuration, backend and database definitions, access control settings, running as a user other than root and setting a chroot environment include:

Boot Script

To automate the startup of the LDAP server at system bootup, install the /etc/rc.d/init.d/slapd init script included in the blfs-bootscripts-20210826 package using the following command:

make install-slapd

Note

You'll need to modify /etc/sysconfig/slapd to include the parameters needed for your specific configuration. See the slapd man page for parameter information.

Testing the Configuration

Start the LDAP server using the init script:

/etc/rc.d/init.d/slapd start

Verify access to the LDAP server with the following command:

ldapsearch -x -b '' -s base '(objectclass=*)' namingContexts

The expected result is:

# extended LDIF
#
# LDAPv3
# base <> with scope baseObject
# filter: (objectclass=*)
# requesting: namingContexts
#

#
dn:
namingContexts: dc=my-domain,dc=com

# search result
search: 2
result: 0 Success

# numResponses: 2
# numEntries: 1

Contents

Installed Programs: ldapadd, ldapcompare, ldapdelete, ldapexop, ldapmodify, ldapmodrdn, ldappasswd, ldapsearch, ldapurl, ldapvc, ldapwhoami, slapacl, slapadd, slapauth, slapcat, slapd, slapdn, slapindex, slapmodify, slappasswd, slapschema, and slaptest
Installed Libraries: liblber.so, libldap.so, and several under /usr/lib/openldap
Installed Directories: /etc/openldap, /{usr,var}/lib/openldap, and /usr/share/doc/openldap-2.6.1

Short Descriptions

ldapadd

opens a connection to an LDAP server, binds and adds entries

ldapcompare

opens a connection to an LDAP server, binds and performs a compare using specified parameters

ldapdelete

opens a connection to an LDAP server, binds and deletes one or more entries

ldapexop

issues the LDAP extended operation specified by oid or one of the special keywords whoami, cancel, or refresh

ldapmodify

opens a connection to an LDAP server, binds and modifies entries

ldapmodrdn

opens a connection to an LDAP server, binds and modifies the RDN of entries

ldappasswd

is a tool used to set the password of an LDAP user

ldapsearch

opens a connection to an LDAP server, binds and performs a search using specified parameters

ldapurl

is a command that allows to either compose or decompose LDAP URIs

ldapvc

verifies LDAP credentials

ldapwhoami

opens a connection to an LDAP server, binds and displays whoami information

slapacl

is used to check the behavior of slapd by verifying access to directory data according to the access control list directives defined in its configuration

slapadd

is used to add entries specified in LDAP Directory Interchange Format (LDIF) to an LDAP database

slapauth

is used to check the behavior of the slapd in mapping identities for authentication and authorization purposes, as specified in slapd.conf

slapcat

is used to generate an LDAP LDIF output based upon the contents of a slapd database

slapd

is the standalone LDAP server

slapdn

checks a list of string-represented DNs based on schema syntax

slapindex

is used to regenerate slapd indexes based upon the current contents of a database

slapmodify

modifies entries in a slapd database

slappasswd

is an OpenLDAP password utility

slapschema

is used to check schema compliance of the contents of a slapd database

slaptest

checks the sanity of the slapd.conf file

liblber.so

is a set of Lightweight Basic Encoding Rules routines. These routines are used by the LDAP library routines to encode and decode LDAP protocol elements using the (slightly simplified) Basic Encoding Rules defined by LDAP. They are not normally used directly by an LDAP application program except in the handling of controls and extended operations

libldap.so

supports the LDAP programs and provide functionality for other programs interacting with LDAP

Last updated on

Unbound-1.15.0

Introduction to Unbound

Unbound is a validating, recursive, and caching DNS resolver. It is designed as a set of modular components that incorporate modern features, such as enhanced security (DNSSEC) validation, Internet Protocol Version 6 (IPv6), and a client resolver library API as an integral part of the architecture.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://nlnetlabs.nl/downloads/unbound/unbound-1.15.0.tar.gz

  • Download MD5 sum: 9a309ea06df20b1f6fc2c10b826082ef

  • Download size: 5.9 MB

  • Estimated disk space required: 135 MB (with docs; add 10 MB for tests)

  • Estimated build time: 0.5 SBU (Using parallelism=4; with docs; add 0.4 SBU for tests)

Unbound Dependencies

Optional

libevent-2.1.12, Nettle-3.7.3, Python-2.7.18, SWIG-4.0.2 (for Python bindings), Doxygen-1.9.3 (for html documentation), dnstap, and Sphinx (for Python bindings documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/unbound

Installation of Unbound

There should be a dedicated user and group to take control of the unbound daemon after it is started. Issue the following commands as the root user:

groupadd -g 88 unbound &&
useradd -c "Unbound DNS Resolver" -d /var/lib/unbound -u 88 \
        -g unbound -s /bin/false unbound

Install Unbound by running the following commands:

./configure --prefix=/usr     \
            --sysconfdir=/etc \
            --disable-static  \
            --with-pidfile=/run/unbound.pid &&
make

If you have Doxygen-1.9.3 package installed and want to build html documentation, run the following command:

make doc

To test the results, issue make check.

Now, as the root user:

make install &&
mv -v /usr/sbin/unbound-host /usr/bin/

If you built the documentation, install it by running the following commands as the root user:

install -v -m755 -d /usr/share/doc/unbound-1.15.0 &&
install -v -m644 doc/html/* /usr/share/doc/unbound-1.15.0

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--with-libevent: This option enables libevent support allowing use of large outgoing port ranges.

--with-pyunbound: This option enables building of the Python bindings.

Configuring Unbound

Config Files

/etc/unbound/unbound.conf

Configuration Information

In the default configuration, unbound will bind to localhost (127.0.0.1 IP address) and allow recursive queries only from localhost clients. If you want to use unbound for local DNS resolution, run the following command as the root user:

echo "nameserver 127.0.0.1" > /etc/resolv.conf

If you are using a DHCP client for connecting to a network, /etc/resolv.conf gets overwritten with values provided by DHCP server. You can override this, for example in DHCP-4.4.2-P1, by running the following command as the root user:

sed -i '/request /i\supersede domain-name-servers 127.0.0.1;' \
       /etc/dhcp/dhclient.conf

For advanced configuration see /etc/unbound/unbound.conf file and the documentation.

When Unbound is installed, some package builds fail if the file /etc/unbound/root.key is not found. This file is created by running the boot script (install instructions below). Alternatively, it can be created by running the following command as the root user:

unbound-anchor

Boot Script

If you want the Unbound server to start automatically when the system is booted, install the /etc/rc.d/init.d/unbound init script included in the blfs-bootscripts-20210826 package:

make install-unbound

Contents

Installed Programs: unbound, unbound-anchor, unbound-checkconf, unbound-control, unbound-control-setup, and unbound-host
Installed Library: libunbound.so and (optional) /usr/lib/python2.7/site-packages/_unbound.so
Installed Directories: /etc/unbound and /usr/share/doc/unbound-1.15.0 (optional)

Short Descriptions

unbound

is a DNS resolver daemon

unbound-anchor

performs setup or update of the root trust anchor for DNSSEC validation

unbound-checkconf

checks the unbound configuration file for syntax and other errors

unbound-control

performs remote administration on the unbound DNS resolver

unbound-control-setup

generates a self-signed certificate and private keys for the server and client

unbound-host

is a DNS lookup utility similar to host from BIND Utilities-9.18.0

libunbound.so

provides the Unbound API functions to programs

Last updated on

Part VI. Graphical Components

Chapter 24. Graphical Environments

This chapter contains instructions to build and configure a graphical user environment.

For a long time the only graphical environment usable with GNU/Linux has been the X Window System. It uses a client/server model which allows writing applications completely independent of the graphical hardware. This has the drawback that accessing modern hardware acceleration is difficult, so that other approaches are developed. Two new systems are available: Wayland and Vulkan. The former is a simpler replacement for X, easier to develop and maintain, using the OpenGL framework. The main desktop environments GNOME and KDE have been ported to it. The later allows direct access to graphical hardware through a portable interface. It is newer and not yet included in BLFS.

This chapter provides the basic components of the X Window System and Wayland. For X, the chosen implementation is Xorg, which is a modular implementation and requires more than 100 packages to be installed. The distribution of Xorg is given a release number by the developers, in this case Xorg-7, and is referred to as the "katamari" by the upstream developers. Individual packages are updated as needed without changing this number.

Introduction to Xorg-7

Xorg is a freely redistributable, open-source implementation of the X Window System. This system provides a client/server interface between display hardware (the mouse, keyboard, and video displays) and the desktop environment, while also providing both the windowing infrastructure and a standardized application interface (API).

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Xorg7

Xorg Download and Installation Instructions

Xorg-7.0 introduced a completely auto-tooled, modular build system. With the new modular build system, it is no longer possible to download the entire package in a single file. In fact, there will be well over 100 packages that need to be fetched from the download location. To assist with such a large task, installing Wget-1.21.2 is strongly recommended for downloading the needed files. A complete wget file list is provided for each page that includes multiple packages.

Given the number of packages available, deciding which packages you need to install for your particular setup may seem a bit overwhelming at first. Take a look at this page and this thread to get an idea of what you will need. If you are unsure, you should install all packages at the cost of extra disk space.

Note

Even if you intend to download only the necessary packages, you should download the wget file lists. The list of files are ordered by dependency, and the package versions listed in the files are known to work well with each other. Further, the wget file lists contain comments for specific packages that are deprecated or are not recommended to install. Newer packages are likely intended for the next release of Xorg and have already proved to be incompatible with current versions of software installed in BLFS. The installed size of Xorg can be reduced considerably by installing only the packages that you will need and use, however, the BLFS book cannot account for all dependencies and build options for the individual Xorg packages. The instructions assume that all packages have been built. A wiki page containing dependency information is under development. You are encouraged to add to these pages if you discover additional information that may be helpful to other users who selectively install individual packages.

Additionally, because of the large number of repetitive commands, you are encouraged to partially automate the build. Instructions have been given that utilize the Sudo-1.9.9 package. It is recommended that you use the :NOPASSWD configuration option for the user that will be building the xorg packages.

Setting up the Xorg Build Environment

Note

The following instructions assume that the shell startup files have been set up as described in The Bash Shell Startup Files.

As with previous releases of the X Window System, it may be desirable to install Xorg into an alternate prefix. This is no longer common practice among Linux distributions. The common installation prefix for Xorg on Linux is /usr. There is no standard alternate prefix, nor is there any exception in the current revision of the Filesystem Hierarchy Standard for Release 7 of the X Window System. Alan Coopersmith of Sun Microsystems, once stated "At Sun, we were using /usr/X11 and plan to stick with it." Only the /opt/* prefix or the /usr prefix adhere to the current FHS guidelines.

Choose your installation prefix, and set the XORG_PREFIX variable with the following command:

export XORG_PREFIX="<PREFIX>"

Throughout these instructions, you will use the following configure switches for all of the packages. Create the XORG_CONFIG variable to use for this parameter substitution:

export XORG_CONFIG="--prefix=$XORG_PREFIX --sysconfdir=/etc \
    --localstatedir=/var --disable-static"

Create an /etc/profile.d/xorg.sh configuration file containing these variables as the root user:

cat > /etc/profile.d/xorg.sh << EOF
XORG_PREFIX="$XORG_PREFIX"
XORG_CONFIG="--prefix=\$XORG_PREFIX --sysconfdir=/etc --localstatedir=/var --disable-static"
export XORG_PREFIX XORG_CONFIG
EOF
chmod 644 /etc/profile.d/xorg.sh

Note

There is some confustion about the above 'here' document. The backslash in front of the dollar sign is correct. Bash will remove it when creating /etc/profile.d/xorg.sh. However, if you are creating the file with an editor, a copy and paste operation will not remove the baskslash. It must then be removed manually.

If you've installed Sudo-1.9.9, ensure that XORG_PREFIX and XORG_CONFIG are available in the sudo environment. As the root user, run the following command:

cat > /etc/sudoers.d/xorg << EOF
Defaults env_keep += XORG_PREFIX
Defaults env_keep += XORG_CONFIG
EOF

If you are not using the standard Xorg prefix...

Warning

If you've decided to use the standard /usr prefix, you must omit the remainder of this page and continue at util-macros-1.19.3.

If you've decided to not use the standard prefix, be sure to add $XORG_PREFIX/bin to your PATH environment variable, and $XORG_PREFIX/lib/pkgconfig and $XORG_PREFIX/share/pkgconfig to your PKG_CONFIG_PATH variable. It is also helpful to specify additional search paths for gcc and an include directory for the aclocal program. Issue the following commands as the root user:

cat >> /etc/profile.d/xorg.sh << "EOF"

pathappend $XORG_PREFIX/bin             PATH
pathappend $XORG_PREFIX/lib/pkgconfig   PKG_CONFIG_PATH
pathappend $XORG_PREFIX/share/pkgconfig PKG_CONFIG_PATH

pathappend $XORG_PREFIX/lib             LIBRARY_PATH
pathappend $XORG_PREFIX/include         C_INCLUDE_PATH
pathappend $XORG_PREFIX/include         CPLUS_INCLUDE_PATH

ACLOCAL="aclocal -I $XORG_PREFIX/share/aclocal"

export PATH PKG_CONFIG_PATH ACLOCAL LIBRARY_PATH C_INCLUDE_PATH CPLUS_INCLUDE_PATH
EOF

The script above needs to be activated. Normally it will be automatic at login, but to activate it now, as a regular user, run:

source /etc/profile.d/xorg.sh

You should also add $XORG_PREFIX/lib to the /etc/ld.so.conf file. Again, as the root user, issue the following command:

echo "$XORG_PREFIX/lib" >> /etc/ld.so.conf

You should also modify /etc/man_db.conf, adding appropriate MANDATORY_MANPATH, MANPATH_MAP, and MANDB_MAP entries following the examples for /usr/X11R6. Issue the following command as the root user:

sed "s@/usr/X11R6@$XORG_PREFIX@g" -i /etc/man_db.conf

Some applications look for shared files in /usr/share/X11. Create a symbolic link to the proper location as the root user:

ln -svf $XORG_PREFIX/share/X11 /usr/share/X11

If building KDE, some cmake files look for Xorg in places other than $XORG_PREFIX. Allow cmake to find Xorg with:

ln -svf $XORG_PREFIX /usr/X11R6

Last updated on

util-macros-1.19.3

Introduction to util-macros

The util-macros package contains the m4 macros used by all of the Xorg packages.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

util-macros Dependencies

Required

Xorg build environment (should be set for the following instructions to work)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/util-macros

Installation of util-macros

Install util-macros by running the following commands:

./configure $XORG_CONFIG

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: None
Installed Directory: $XORG_PREFIX/share/pkgconfig and $XORG_PREFIX/share/util-macros

Last updated on

xorgproto-2021.5

Introduction to xorgproto

The xorgproto package provides the header files required to build the X Window system, and to allow other applications to build against the installed X Window system.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

xorgproto Dependencies

Required

util-macros-1.19.3

Optional

fop-2.7, libxslt-1.1.35, xmlto-0.0.28 and asciidoc-10.1.1 (to build additional documentation)

Note

There is a reciprocal dependency with fop-2.7. If you wish to build the documentation, you'll need to re-install the Protocol Headers after the installation is complete and fop-2.7 has been installed.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Xorg7ProtocolHeaders

Installation of xorgproto

Install xorgproto by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=$XORG_PREFIX -Dlegacy=true .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install &&
mv -v $XORG_PREFIX/share/doc/xorgproto{,-2021.5}

Command Explanations

install -vm 644 ../[^m]*.txt ../PM_spec ...: The meson build system does not install the text files into /usr/share/doc. The [^m] part prevents copying the meson_options.txt file.

-Dlegacy=true: Installs legacy headers needed by old programs (such as LessTif).

Contents

Installed Programs: None
Installed Libraries: None
Installed Directories: $XORG_PREFIX/include/GL, $XORG_PREFIX/include/X11, and $XORG_PREFIX/share/doc/xorgproto-2021.5

Last updated on

libXau-1.0.9

Introduction to libXau

The libXau package contains a library implementing the X11 Authorization Protocol. This is useful for restricting client access to the display.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libXau Dependencies

Required

xorgproto-2021.5

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libXau

Installation of libXau

Install libXau by running the following commands:

./configure $XORG_CONFIG &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Library: libXau.so
Installed Directories: None

Short Descriptions

libXau.so

is the library of X authority database routines

Last updated on

libXdmcp-1.1.3

Introduction to libXdmcp

The libXdmcp package contains a library implementing the X Display Manager Control Protocol. This is useful for allowing clients to interact with the X Display Manager.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libXdmcp Dependencies

Required

xorgproto-2021.5

Optional

xmlto-0.0.28, fop-2.7, and libxslt-1.1.35 (for documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libXdmcp

Installation of libXdmcp

Install libXdmcp by running the following commands:

./configure $XORG_CONFIG --docdir=/usr/share/doc/libXdmcp-1.1.3 &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Library: libXdmcp.so
Installed Directory: $XORG_PREFIX/share/doc/libXdmcp

Short Descriptions

libXdmcp.so

is the X Display Manager Control Protocol library

Last updated on

xcb-proto-1.14.1

Introduction to xcb-proto

The xcb-proto package provides the XML-XCB protocol descriptions that libxcb uses to generate the majority of its code and API.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

xcb-proto Dependencies

Optional

libxml2-2.9.13 (required to run the tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xcb-proto

Installation of xcb-proto

Install xcb-proto by running the following commands:

PYTHON=python3 ./configure $XORG_CONFIG

To test the results, issue: make check.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: None
Installed Directory: $XORG_PREFIX/share/xcb and $XORG_PREFIX/lib/python3.10/site-packages/xcbgen

Last updated on

libxcb-1.14

Introduction to libxcb

The libxcb package provides an interface to the X Window System protocol, which replaces the current Xlib interface. Xlib can also use XCB as a transport layer, allowing software to make requests and receive responses with both.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libxcb Dependencies

Required

libXau-1.0.9 and xcb-proto-1.14.1

Recommended
Optional

Doxygen-1.9.3 (to generate API documentation) and libxslt-1.1.35

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libxcb

Installation of libxcb

Install libxcb by running the following commands:

CFLAGS="${CFLAGS:--O2 -g} -Wno-error=format-extra-args" \
PYTHON=python3                \
./configure $XORG_CONFIG      \
            --without-doxygen \
            --docdir='${datadir}'/doc/libxcb-1.14 &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

CFLAGS=...: This variable fixes building this package with GCC-10 and later.

PYTHON=python3: This variable forces configure to use python3 instead of python2. The configure script for this package will automatically default to python2 if it is present.

--without-doxygen: Do not use doxygen to generate API documentation (default: auto). Without it, if Doxygen-1.9.3 is installed, the API documentation will be generated and installed.

Contents

Installed Programs: None
Installed Libraries: libxcb.so, libxcb-composite.so, libxcb-damage.so, libxcb-dpms.so, libxcb-dri2.so, libxcb-dri3.so, libxcb-glx.so, libxcb-present.so, libxcb-randr.so, libxcb-record.so, libxcb-render.so, libxcb-res.so, libxcb-screensaver.so, libxcb-shape.so, libxcb-shm.so, libxcb-sync.so, libxcb-xf86dri.so, libxcb-xfixes.so, libxcb-xinerama.so, libxcb-xinput.so, libxcb-xkb.so, libxcb-xtest.so, libxcb-xvmc.so, and libxcb-xv.so
Installed Directories: $XORG_PREFIX/include/xcb and $XORG_PREFIX/share/doc/libxcb-1.14

Short Descriptions

libxcb.so

is an interface to the X Window System protocol

Last updated on

Xorg Libraries

Introduction to Xorg Libraries

The Xorg libraries provide library routines that are used within all X Window applications.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Xorg Libraries Dependencies

Required

Fontconfig-2.13.1 and libxcb-1.14

Recommended
Optional

asciidoc-10.1.1, xmlto-0.0.28 with one or more of the following: fop-2.7, Links-2.25, Lynx-2.8.9rel.1, and W3m (to generate additional PDF or text documentation for the libXfont package).

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Xorg7Libraries

Downloading Xorg Libraries

First, create a list of files to be downloaded. This file will also be used to verify the integrity of the downloads when complete:

cat > lib-7.md5 << "EOF"
ce2fb8100c6647ee81451ebe388b17ad  xtrans-1.4.0.tar.bz2
28021759f3cf9ef64eb1465c3b6effc5  libX11-1.7.3.1.tar.xz
f5b48bb76ba327cd2a8dc7a383532a95  libXext-1.3.4.tar.bz2
4e1196275aa743d6ebd3d3d5ec1dff9c  libFS-1.0.8.tar.bz2
76d77499ee7120a56566891ca2c0dbcf  libICE-1.0.10.tar.bz2
87c7fad1c1813517979184c8ccd76628  libSM-1.2.3.tar.bz2
eeea9d5af3e6c143d0ea1721d27a5e49  libXScrnSaver-1.2.3.tar.bz2
b122ff9a7ec70c94dbbfd814899fffa5  libXt-1.2.1.tar.bz2
ac774cff8b493f566088a255dbf91201  libXmu-1.1.3.tar.bz2
6f0ecf8d103d528cfc803aa475137afa  libXpm-3.5.13.tar.bz2
c1ce21c296bbf3da3e30cf651649563e  libXaw-1.0.14.tar.bz2
86f182f487f4f54684ef6b142096bb0f  libXfixes-6.0.0.tar.bz2
3fa0841ea89024719b20cd702a9b54e0  libXcomposite-0.4.5.tar.bz2
802179a76bded0b658f4e9ec5e1830a4  libXrender-0.9.10.tar.bz2
9b9be0e289130fb820aedf67705fc549  libXcursor-1.2.0.tar.bz2
e3f554267a7a04b042dc1f6352bd6d99  libXdamage-1.1.5.tar.bz2
6447db6a689fb530c218f0f8328c3abc  libfontenc-1.1.4.tar.bz2
bdf528f1d337603c7431043824408668  libXfont2-2.0.5.tar.bz2
5004d8e21cdddfe53266b7293c1dfb1b  libXft-2.3.4.tar.bz2
74055672a111a98ce2841d2ec4057b05  libXi-1.8.tar.bz2
0d5f826a197dae74da67af4a9ef35885  libXinerama-1.1.4.tar.bz2
18f3b20d522f45e4dadd34afb5bea048  libXrandr-1.5.2.tar.bz2
e142ef0ed0366ae89c771c27cfc2ccd1  libXres-1.2.1.tar.bz2
ef8c2c1d16a00bd95b9fdcef63b8a2ca  libXtst-1.2.3.tar.bz2
210b6ef30dda2256d54763136faa37b9  libXv-1.0.11.tar.bz2
3569ff7f3e26864d986d6a21147eaa58  libXvMC-1.0.12.tar.bz2
0ddeafc13b33086357cfa96fae41ee8e  libXxf86dga-1.1.5.tar.bz2
298b8fff82df17304dfdb5fe4066fe3a  libXxf86vm-1.1.4.tar.bz2
d2f1f0ec68ac3932dd7f1d9aa0a7a11c  libdmx-1.1.4.tar.bz2
b34e2cbdd6aa8f9cc3fa613fd401a6d6  libpciaccess-0.16.tar.bz2
dd7e1e946def674e78c0efbc5c7d5b3b  libxkbfile-1.1.0.tar.bz2
42dda8016943dc12aff2c03a036e0937  libxshmfence-1.3.tar.bz2
EOF

To download the needed files using wget, use the following commands:

mkdir lib &&
cd lib &&
grep -v '^#' ../lib-7.md5 | awk '{print $2}' | wget -i- -c \
    -B https://www.x.org/pub/individual/lib/ &&
md5sum -c ../lib-7.md5

Installation of Xorg Libraries

Note

When installing multiple packages in a script, the installation needs to be done as the root user. There are three general options that can be used to do this:

  1. Run the entire script as the root user (not recommended).

  2. Use the sudo command from the Sudo-1.9.9 package.

  3. Use su -c "command arguments" (quotes required) which will ask for the root password for every iteration of the loop.

One way to handle this situation is to create a short bash function that automatically selects the appropriate method. Once the command is set in the environment, it does not need to be set again.

as_root()
{
  if   [ $EUID = 0 ];        then $*
  elif [ -x /usr/bin/sudo ]; then sudo $*
  else                            su -c \\"$*\\"
  fi
}

export -f as_root

Some libraries come with a test suite. If you wish to execute them, either comment out the rm -rf ... below, so that, after all libraries are installed, you can come back to the corresponding directory and run make check, or do individual builds, running the tests for each of those distributed with working test suites. Alternatively, you can uncomment the line #make check ..., and at the end, check the test results with:

grep -A9 summary *make_check.log

BLFS developers have confirmed that libX11, libXt and libxshmfence are distributed with working test suites.

First, start a subshell that will exit on error:

bash -e

Install all of the packages by running the following commands:

for package in $(grep -v '^#' ../lib-7.md5 | awk '{print $2}')
do
  packagedir=${package%.tar.?z*}
  tar -xf $package
  pushd $packagedir
  docdir="--docdir=$XORG_PREFIX/share/doc/$packagedir"
  case $packagedir in
    libICE* )
      ./configure $XORG_CONFIG $docdir ICE_LIBS=-lpthread
    ;;

    libXfont2-[0-9]* )
      ./configure $XORG_CONFIG $docdir --disable-devel-docs
    ;;

    libXt-[0-9]* )
      ./configure $XORG_CONFIG $docdir \
                  --with-appdefaultdir=/etc/X11/app-defaults
    ;;

    * )
      ./configure $XORG_CONFIG $docdir
    ;;
  esac
  make
  #make check 2>&1 | tee ../$packagedir-make_check.log
  as_root make install
  popd
  rm -rf $packagedir
  as_root /sbin/ldconfig
done

Finally, exit the shell that was started earlier:

exit

Command Explanations

./configure $XORG_CONFIG ICE_LIBS=-lpthread: This fixes a change in glibc which breaks pulseaudio at runtime.

--disable-devel-docs: Disable generation of text documentation in the libXfont2 package if xmlto-0.0.28 is installed without a text browser. Omit this parameter (or the entire case statement) if a text browser is installed.

--with-fop: Use fop-2.7 to generate PDF documentation (only for the libXfont package).

Configuration of Xorg Libraries

If you've chosen to install Xorg into /usr, then no further configuration is necessary and you can skip the rest of this section. If you've opted for an alternate prefix, you should create two symlinks to satisfy the expected environment of several packages. Execute the following commands as the root user:

ln -sv $XORG_PREFIX/lib/X11 /usr/lib/X11 &&
ln -sv $XORG_PREFIX/include/X11 /usr/include/X11

Contents

Installed Programs: cxpm and sxpm
Installed Libraries: libdmx.so, libfontenc.so, libFS.so, libICE.so, libpciaccess.so, libSM.so, libX11.so, libXaw6.so, libXaw7.so, libXaw.so, libXcomposite.so, libXcursor.so, libXdamage.so, libXext.so, libXfixes.so, libXfont2.so, libXft.so, libXinerama.so, libXi.so, libxkbfile.so, libXmu.so, libXmuu.so, libXpm.so, libXrandr.so, libXrender.so, libXRes.so, libxshmfence.so, libXss.so, libXt.so, libXtst.so, libXvMC.so, libXvMCW.so, libXv.so, libXxf86dga.so and libXxf86vm.so
Installed Directories: $XORG_PREFIX/include/X11/fonts, $XORG_PREFIX/include/X11/Xtrans, $XORG_PREFIX/share/doc/libFS, $XORG_PREFIX/share/doc/libICE, $XORG_PREFIX/share/doc/libSM, $XORG_PREFIX/share/doc/libX11, $XORG_PREFIX/share/doc/libXaw, $XORG_PREFIX/share/doc/libXext, $XORG_PREFIX/share/doc/libXi, $XORG_PREFIX/share/doc/libXmu, $XORG_PREFIX/share/doc/libXrender, $XORG_PREFIX/share/doc/libXt, $XORG_PREFIX/share/doc/libXtst, $XORG_PREFIX/share/doc/libXvMC, $XORG_PREFIX/share/doc/xtrans and $XORG_PREFIX/share/X11/locale

Short Descriptions

cxpm

checks the format of an XPM file

sxpm

shows an XPM file and/or converts XPM 1 or 2 files to XPM 3

libdmx.so

is the X Window System DMX (Distributed Multihead X) extension library

libfontenc.so

is the X11 font encoding library

libFS.so

is the library interface to the X Font Server

libICE.so

is the X Inter Client Exchange Library

libpciaccess.so

is the generic PCI Access library for X

libSM.so

is the X Session Management Library

libX11.so

is the Xlib Library

libXaw6.so

is the X Athena Widgets Library, version 6

libXaw7.so

is the X Athena Widgets Library, version 7

libXaw.so

are symbolic links to the current X Athena Widgets Library, version 7

libXcomposite.so

is the X Composite Library

libXcursor.so

is the X Cursor management library

libXdamage.so

is the X Damage Library

libXext.so

is the Misc X Extension Library

libXfixes.so

provides augmented versions of core protocol requests

libXfont2.so

is the X font library

libXft.so

is the X FreeType interface library

libXinerama.so

is the Xinerama Library

libXi.so

is the X Input Extension Library

libxkbfile.so

is the xkbfile Library

libXmu.so

is the X interface library for miscellaneous utilities not part of the Xlib standard

libXmuu.so

is the Mini Xmu Library

libXpm.so

is the X Pixmap Library

libXrandr.so

is the X Resize, Rotate and Reflection extension library

libXrender.so

is the X Render Library

libXRes.so

is the X-Resource extension client library

libxshmfence.so

exposes an event API on top of Linux futexes

libXss.so

is the X11 Screen Saver extension client library

libXt.so

is the X Toolkit Library

libXtst.so

is the Xtst Library

libXvMC.so

is the X-Video Motion Compensation Library

libXvMCW.so

is the XvMC Wrapper including the Nonstandard VLD extension

libXv.so

is the X Window System video extension library

libXxf86dga.so

is the client library for the XFree86-DGA extension

libXxf86vm.so

is the client library for the XFree86-VidMode X extension

Last updated on

libxcvt-0.1.1

Introduction to libxcvt

libxcvt is a library providing a standalone version of the X server implementation of the VESA CVT standard timing modelines generator. It is meant to be a direct replacement to the version formerly provided by the Xorg server.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libxcvt

Installation of libxcvt

Install libxcvt by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Contents

Installed Program: cvt
Installed Library: libxcvt.so
Installed Directory: /usr/include/libxcvt

Short Descriptions

cvt

calculates VESA Coordinated Video Timing (CVT) modelines for use with X

libxcvt.so

contains functions for calculating VESA CVT

Last updated on

xcb-util-0.4.0

Introduction to xcb-util

The xcb-util package provides additional extensions to the XCB library, many that were previously found in Xlib, but are not part of core X protocol.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

xcb-util Dependencies

Required

libxcb-1.14

Optional

Doxygen-1.9.3 (for documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xcb-util

Installation of xcb-util

Install xcb-util by running the following commands:

./configure $XORG_CONFIG &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Library: libxcb-util.so
Installed Directories: None

Short Descriptions

libxcb-util.so

Provides utility functions for other XCB utilities

Last updated on

xcb-util-image-0.4.0

Introduction to xcb-util-image

The xcb-util-image package provides additional extensions to the XCB library.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

xcb-util-image Dependencies

Required

xcb-util-0.4.0

Optional

Doxygen-1.9.3 (for documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xcb-util-image

Installation of xcb-util-image

Install xcb-util-image by running the following commands:

./configure $XORG_CONFIG &&
make

To test the results, issue: LD_LIBRARY_PATH=$XORG_PREFIX/lib make check.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Library: libxcb-image.so
Installed Directories: None

Short Descriptions

libxcb-image.so

Is a port of Xlib's XImage and XShmImage functions

Last updated on

xcb-util-keysyms-0.4.0

Introduction to xcb-util-keysyms

The xcb-util-keysyms package contains a library for handling standard X key constants and conversion to/from keycodes.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

xcb-util-keysyms Dependencies

Required

libxcb-1.14

Optional

Doxygen-1.9.3 (to generate documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xcb-util-keysyms

Installation of xcb-util-keysyms

Install xcb-util-keysyms by running the following commands:

./configure $XORG_CONFIG &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Library: libxcb-keysyms.so
Installed Directories: None

Short Descriptions

libxcb-keysyms.so

provides the standard X key constants and API functions for conversion to/from keycodes

Last updated on

xcb-util-renderutil-0.3.9

Introduction to xcb-util-renderutil

The xcb-util-renderutil package provides additional extensions to the XCB library.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

xcb-util-renderutil Dependencies

Required

libxcb-1.14

Optional

Doxygen-1.9.3 (for documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xcb-util-renderutil

Installation of xcb-util-renderutil

Install xcb-util-renderutil by running the following commands:

./configure $XORG_CONFIG &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Library: libxcb-render-util.so
Installed Directories: None

Short Descriptions

libxcb-render-util.so

Provides convenience functions for the Render extension

Last updated on

xcb-util-wm-0.4.1

Introduction to xcb-util-wm

The xcb-util-wm package contains libraries which provide client and window-manager helpers for EWMH and ICCCM.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

xcb-util-wm Dependencies

Required

libxcb-1.14

Optional

Doxygen-1.9.3 (for documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xcb-util-wm

Installation of xcb-util-wm

Install xcb-util-wm by running the following commands:

./configure $XORG_CONFIG &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: libxcb-ewmh.so and libxcb-icccm.so
Installed Directories: None

Short Descriptions

libxcb-ewmh.so

provides the client and window-manager helpers for EWMH

libxcb-icccm.so

provides the client and window-manager helpers for ICCCM

Last updated on

xcb-util-cursor-0.1.3

Introduction to xcb-util-cursor

The xcb-util-cursor package provides a module that implements the XCB cursor library. It is the XCB replacement for libXcursor.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

xcb-util-cursor Dependencies

Required

xcb-util-0.4.0

Optional

Doxygen-1.9.3 (for documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xcb-util-cursor

Installation of xcb-util-cursor

Install xcb-util-cursor by running the following commands:

./configure $XORG_CONFIG &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Library: libxcb-cursor.so
Installed Directories: None

Short Descriptions

libxcb-cursor.so

Is a port of Xlib's libXcursor functions

Last updated on

Mesa-21.3.6

Introduction to Mesa

Mesa is an OpenGL compatible 3D graphics library.

Note

Mesa is updated relatively often. You may want to use the latest available 21.3.x mesa version.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Mesa Dependencies

Required

Xorg Libraries, libdrm-2.4.110, and Mako-1.1.6

Recommended
Optional

libgcrypt-1.10.0, lm-sensors-3-6-0 , Nettle-3.7.3, Valgrind-3.18.1, mesa-demos (provides more than 300 extra demos to test Mesa; this includes the same programs added by the patch above), Bellagio OpenMAX Integration Layer (for mobile platforms), libunwind, libtizonia, and libvulkan (for the zink driver)

Note

The instructions below assume that LLVM with the r600/amdgpu and host backends and run-time type information (RTTI - needed for nouveau) are installed. You will need to modify the instructions if you choose not to install all of these. For an explanation of Gallium3D see https://en.wikipedia.org/wiki/Gallium3D.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/mesalib

Installation of Mesa

If you have downloaded the xdemos patch (needed if testing the Xorg installation per BLFS instructions), apply it by running the following command:

patch -Np1 -i ../mesa-21.3.6-add_xdemos-1.patch

Note

The measurements above, and the Contents below, are for a full build. Many people will not wish to install drivers they cannot use, so the following paragraphs explain how to limit the drivers, and give an example which can be be reduced or amended as necessary.

Now, select the drivers you wish to install. For the X86 architecture, the available gallium drivers are auto (in 21.2.1 this does not select crocus ), or alternatively a choice from crocus, i915, iris, nouveau, r300, r600, radeonsi, svga, swrast, and virgl. The latter can provide acceleration in qemu-6.2.0 if that has been linked against virglrenderer (you will need a freedesktop.org account to get to that page, you can download the 0.9.1 release without an account from virglrenderer-0.9.1).

The (non-gallium) DRI drivers available in X86 are auto, or alternatively a choice from i915, i965, nouveau, r100, r200, and swrast. Use 'auto' to build all available DRI drivers, or use an empty string (DRI_DRIVERS="") if you wish to only build gallium drivers.

The platforms ("window systems") available for X86 linux are x11, wayland, and surfaceless. By not specifying anything, the meson build-system will build for all these platforms if you have the dependencies, identical to if you had specified '-Dplatforms=auto'.

Modify the commands below for your desired drivers. The drivers listed below will cover most modern video cards and virtual machines. For help in selecting drivers see https://docs.mesa3d.org/systems.html. For intel drivers, specify crocus for i965 gen 4 through to haswell, iris for broadwell and later.

Note

Although the nouveau drivers can be built for both gallium and dri, the i915 driver can only be built for one or the other.

GALLIUM_DRV="crocus,i915,iris,nouveau,r600,radeonsi,svga,swrast,virgl"
DRI_DRIVERS="i965,nouveau"

Note

If you are using a NVIDIA GPU in your system, a special patch has been created that allows for proper multi-threading in the Mesa driver. This fixes issues with multi-threaded Qt applications, as well as with starting some GNOME Applications. This patch is also essential if you plan to use KDE Plasma. Apply the patch using the following command:

patch -Np1 -i ../mesa-21.3.6-nouveau_fixes-1.patch

Install Mesa by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=$XORG_PREFIX          \
      --buildtype=release            \
      -Ddri-drivers=$DRI_DRIVERS     \
      -Dgallium-drivers=$GALLIUM_DRV \
      -Dgallium-nine=false           \
      -Dglx=dri                      \
      -Dvalgrind=disabled            \
      -Dlibunwind=disabled           \
      ..                             &&

unset GALLIUM_DRV DRI_DRIVERS &&

ninja

If you built the tests (see 'Command Explanations'), to run them issue: ninja test. One test, mesa: intel/anv_state_pool, is known to fail.

Now, as the root user:

ninja install

If desired, install the optional documentation by running the following commands as the root user:

install -v -dm755 /usr/share/doc/mesa-21.3.6 &&
cp -rfv ../docs/* /usr/share/doc/mesa-21.3.6

Command Explanations

--buildtype=release: This switch ensures a fully-optimized build, and disables debug assertions which will severely slow down the libraries in certain use-cases. Without this switch, build sizes can span into the 2GB range.

-Ddri-drivers="...": This parameter controls which (non-gallium) dri drivers should be built.

-Dgallium-drivers="...": This parameter controls which Gallium3D drivers should be built.

-Dgallium-nine=false: Prevents building support for (MS Windows) games designed for DX9. Set it to true if this support is desired.

-Dvalgrind=disabled: This parameter disables the usage of Valgrind during the build process. Remove this parameter if you have Valgrind installed, and wish to check for memory leaks.

-Dlibunwind=disabled: This parameter disables the usage of libunwind.

-Dbuild-tests=true: This option will cause the test code to be enabled. To run the tests, issue: ninja test.

-Dvulkan-drivers=...: This option allows choosing which Vulkan drivers are built. Since those drivers depend on the corresponding Gallium3D drivers, do not enable drivers that are not enabled in Gallium3D drivers. Furthermore, since BLFS does not use Vulkan, it is safe to leave the list of Vulkan drivers empty.

Contents

Installed Programs: glxgears and glxinfo
Installed Libraries: libEGL.so, libGL.so, libGLESv1_CM.so, libGLESv2.so, libXvMCnouveau.so, libXvMCr600.so, libgbm.so, libglapi.so, libvulkan_intel.so, libvulkan_lvp.so, libvulkan_radeon.so, and libxatracker.so,
Installed Drivers: d3dadapter9.so (optional), crocus_dri.so, i915_dri.so, i965_dri.so, iris_dri.so, kms_swrast_dri.so, nouveau_dri.so, nouveau_drv_video.so, nouveau_vieux_dri.so, r200_dri.so (optional), r300_dri.so (optional), r600_dri.so, r600_drv_video.so, radeon_dri.so (optional), radeonsi_dri.so, radeonsi_drv_video.so, swrast_dri.so, virtio_gpu_dri.so, vmwgfx_dri.so, libvdpau_nouveau.so, libvdpau_r300.so (optional), libvdpau_r600.so, and libvdpau_radeonsi.so (Many of these drivers are hard-linked).
Installed Directories: $XORG_PREFIX/{include/{EGL,GL,GLES,GLES2,GLES3,KHR},lib/{dri,vdpau}}, $XORG_PREFIX/include/d3adapter (optional), $XORG_PREFIX/lib/d3d (optional), $XORG_PREFIX/share/drirc.d (contains workarounds for various applications, particularly browsers and games), $XORG_PREFIX/share/vulkan, and /usr/share/doc/mesa-21.3.6 (optional)

Short Descriptions

glxgears

is a GL demo useful for troubleshooting graphics problems

glxinfo

is a diagnostic program that displays information about the graphics hardware and installed GL libraries

libEGL.so

provides a native platform graphics interface as defined by the EGL-1.4 specification

libgbm.so

is the Mesa Graphics Buffer Manager library

libGLESv1_CM.so

is the Mesa OpenGL ES 1.1 library

libGLES2.so

is the Mesa OpenGL ES 2.0 library

libGL.so

is the main Mesa OpenGL library

Last updated on

xbitmaps-1.1.2

Introduction to xbitmaps

The xbitmaps package contains bitmap images used by multiple applications built in Xorg chapter.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

xbitmaps Dependencies

Required

util-macros-1.19.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xbitmaps

Installation of xbitmaps

Install xbitmaps by running the following commands:

./configure $XORG_CONFIG

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: None
Installed Directory: $XORG_PREFIX/include/X11/bitmaps

Last updated on

Xorg Applications

Introduction to Xorg Applications

The Xorg applications provide the expected applications available in previous X Window implementations.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Xorg Applications Dependencies

Required

libpng-1.6.37, Mesa-21.3.6, xbitmaps-1.1.2, and xcb-util-0.4.0

Optional

Linux-PAM-1.5.2 and both cairo-5c and Nickle (only if you wish to try to run the undocumented xkeyhost script).

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Xorg7Applications

Downloading Xorg Applications

First, create a list of files to be downloaded. This file will also be used to verify the integrity of the downloads when complete:

cat > app-7.md5 << "EOF"
3b9b79fa0f9928161f4bad94273de7ae  iceauth-1.0.8.tar.bz2
c4a3664e08e5a47c120ff9263ee2f20c  luit-1.1.1.tar.bz2
215940de158b1a3d8b3f8b442c606e2f  mkfontscale-1.2.1.tar.bz2
92be564d4be7d8aa7b5024057b715210  sessreg-1.1.2.tar.bz2
93e736c98fb75856ee8227a0c49a128d  setxkbmap-1.3.2.tar.bz2
3a93d9f0859de5d8b65a68a125d48f6a  smproxy-1.0.6.tar.bz2
e96b56756990c56c24d2d02c2964456b  x11perf-1.6.1.tar.bz2
325c2321d159d5b93490700960005037  xauth-1.1.1.tar.bz2
5b6405973db69c0443be2fba8e1a8ab7  xbacklight-1.2.3.tar.bz2
9956d751ea3ae4538c3ebd07f70736a0  xcmsdb-1.0.5.tar.bz2
25cc7ca1ce5dcbb61c2b471c55e686b5  xcursorgen-1.0.7.tar.bz2
8809037bd48599af55dad81c508b6b39  xdpyinfo-1.3.2.tar.bz2
480e63cd365f03eb2515a6527d5f4ca6  xdriinfo-1.0.6.tar.bz2
e1d7dc1afd3ddb8fab16d6a76f21a258  xev-1.2.4.tar.bz2
90b4305157c2b966d5180e2ee61262be  xgamma-1.0.6.tar.bz2
a48c72954ae6665e0616f6653636da8c  xhost-1.0.8.tar.bz2
ac6b7432726008b2f50eba82b0e2dbe4  xinput-1.6.3.tar.bz2
c45e9f7971a58b8f0faf10f6d8f298c0  xkbcomp-1.4.5.tar.bz2
c747faf1f78f5a5962419f8bdd066501  xkbevd-1.1.4.tar.bz2
502b14843f610af977dffc6cbf2102d5  xkbutils-1.0.4.tar.bz2
938177e4472c346cf031c1aefd8934fc  xkill-1.0.5.tar.bz2
61671fee12535347db24ec3a715032a7  xlsatoms-1.1.3.tar.bz2
4fa92377e0ddc137cd226a7a87b6b29a  xlsclients-1.1.4.tar.bz2
e50ffae17eeb3943079620cb78f5ce0b  xmessage-1.0.5.tar.bz2
51f1d30a525e9903280ffeea2744b1f6  xmodmap-1.0.10.tar.bz2
eaac255076ea351fd08d76025788d9f9  xpr-1.0.5.tar.bz2
2358e29133d183ff67d4ef8afd70b9d2  xprop-1.2.5.tar.bz2
fe40f7a4fd39dd3a02248d3e0b1972e4  xrandr-1.5.1.tar.xz
85f04a810e2fb6b41ab872b421dce1b1  xrdb-1.2.1.tar.bz2
c56fa4adbeed1ee5173f464a4c4a61a6  xrefresh-1.0.6.tar.bz2
70ea7bc7bacf1a124b1692605883f620  xset-1.2.4.tar.bz2
5fe769c8777a6e873ed1305e4ce2c353  xsetroot-1.1.2.tar.bz2
b13afec137b9b331814a9824ab03ec80  xvinfo-1.1.4.tar.bz2
f783a209f2e3fa13253cedb65eaf9cdb  xwd-1.0.8.tar.bz2
26d46f7ef0588d3392da3ad5802be420  xwininfo-1.1.5.tar.bz2
79972093bb0766fcd0223b2bd6d11932  xwud-1.0.5.tar.bz2
EOF

To download the needed files using wget, use the following commands:

mkdir app &&
cd app &&
grep -v '^#' ../app-7.md5 | awk '{print $2}' | wget -i- -c \
    -B https://www.x.org/pub/individual/app/ &&
md5sum -c ../app-7.md5

Installation of Xorg Applications

Note

When installing multiple packages in a script, the installation needs to be done as the root user. There are three general options that can be used to do this:

  1. Run the entire script as the root user (not recommended).

  2. Use the sudo command from the Sudo-1.9.9 package.

  3. Use su -c "command arguments" (quotes required) which will ask for the root password for every iteration of the loop.

One way to handle this situation is to create a short bash function that automatically selects the appropriate method. Once the command is set in the environment, it does not need to be set again.

as_root()
{
  if   [ $EUID = 0 ];        then $*
  elif [ -x /usr/bin/sudo ]; then sudo $*
  else                            su -c \\"$*\\"
  fi
}

export -f as_root

First, start a subshell that will exit on error:

bash -e

Install all of the packages by running the following commands:

for package in $(grep -v '^#' ../app-7.md5 | awk '{print $2}')
do
  packagedir=${package%.tar.?z*}
  tar -xf $package
  pushd $packagedir
     case $packagedir in
       luit-[0-9]* )
         sed -i -e "/D_XOPEN/s/5/6/" configure
       ;;
     esac

     ./configure $XORG_CONFIG
     make
     as_root make install
  popd
  rm -rf $packagedir
done

Finally, exit the shell that was started earlier:

exit

Unless you installed the optional dependencies, remove an undocumented script which is reported to be broken (xkeystone provided by the xrandr package).

as_root rm -f $XORG_PREFIX/bin/xkeystone

Contents

Installed Programs: iceauth, luit, mkfontdir, mkfontscale, sessreg, setxkbmap, smproxy, x11perf, x11perfcomp, xauth, xbacklight, xcmsdb, xcursorgen, xdpr, xdpyinfo, xdriinfo, xev, xgamma, xhost, xinput, xkbbell, xkbcomp, xkbevd, xkbvleds, xkbwatch, xkill, xlsatoms, xlsclients, xmessage, xmodmap, xpr, xprop, xrandr, xrdb, xrefresh, xset, xsetroot, xvinfo, xwd, xwininfo, and xwud
Installed Libraries: None
Installed Directories: None

Short Descriptions

iceauth

is the ICE authority file utility

luit

provides locale and ISO 2022 support for Unicode terminals

mkfontdir

creates an index of X font files in a directory

mkfontscale

creates an index of scalable font files for X

sessreg

manages utmp/wtmp entries for non-init clients

setxkbmap

sets the keyboard using the X Keyboard Extension

smproxy

is the Session Manager Proxy

x11perf

is an X11 server performance test program

x11perfcomp

is an X11 server performance comparison program

xauth

is the X authority file utility

xbacklight

adjusts backlight brightness using RandR extension

xcmsdb

is the Device Color Characterization utility for the X Color Management System

xcursorgen

creates an X cursor file from a collection of PNG images

xdpr

dumps an X window directly to a printer

xdpyinfo

is a display information utility for X

xdriinfo

queries configuration information of DRI drivers

xev

prints contents of X events

xgamma

alters a monitor's gamma correction through the X server

xhost

is a server access control program for X

xinput

is a utility to configure and test X input devices

xkbbell

is an XKB utility program that raises a bell event

xkbcomp

compiles an XKB keyboard description

xkbevd

is the XKB event daemon

xkbvleds

shows the XKB status of keyboard LEDs

xkbwatch

monitors modifier keys and LEDs

xkill

kills a client by its X resource

xlsatoms

lists interned atoms defined on the server

xlsclients

lists client applications running on a display

xmessage

displays a message or query in a window

xmodmap

is a utility for modifying keymaps and pointer button mappings in X

xpr

prints an X window dump

xprop

is a property displayer for X

xrandr

is a primitive command line interface to RandR extension

xrdb

is the X server resource database utility

xrefresh

refreshes all or part of an X screen

xset

is the user preference utility for X

xsetroot

is the root window parameter setting utility for X

xvinfo

prints out X-Video extension adaptor information

xwd

dumps an image of an X window

xwininfo

is a window information utility for X

xwud

is an image displayer for X

Last updated on

xcursor-themes-1.0.6

Introduction to xcursor-themes

The xcursor-themes package contains the redglass and whiteglass animated cursor themes.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

xcursor-themes Dependencies

Required

Xorg Applications

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xcursor-themes

Installation of xcursor-themes

Install xcursor-themes by running the following commands:

./configure $XORG_CONFIG &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: None
Installed Directories: $XORG_PREFIX/share/icons/handhelds, $XORG_PREFIX/share/icons/redglass and $XORG_PREFIX/share/icons/whiteglass

Last updated on

Xorg Fonts

Introduction to Xorg Fonts

The Xorg font packages provide some scalable fonts and supporting packages for Xorg applications. Many people will want to install other TTF or OTF fonts in addition to, or instead of, these. Some are listed at the section called “TTF and OTF fonts”.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Xorg Fonts Dependencies

Required

xcursor-themes-1.0.6

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Xorg7Fonts

Downloading Xorg Fonts

First, create a list of files to be downloaded. This file will also be used to verify the integrity of the downloads when complete:

cat > font-7.md5 << "EOF"
3d6adb76fdd072db8c8fae41b40855e8  font-util-1.3.2.tar.bz2
bbae4f247b88ccde0e85ed6a403da22a  encodings-1.0.5.tar.bz2
0497de0176a0dfa5fac2b0552a4cf380  font-alias-1.0.4.tar.bz2
fcf24554c348df3c689b91596d7f9971  font-adobe-utopia-type1-1.0.4.tar.bz2
e8ca58ea0d3726b94fe9f2c17344be60  font-bh-ttf-1.0.3.tar.bz2
53ed9a42388b7ebb689bdfc374f96a22  font-bh-type1-1.0.3.tar.bz2
bfb2593d2102585f45daa960f43cb3c4  font-ibm-type1-1.0.3.tar.bz2
4ee18ab6c1edf636b8e75b73e6037371  font-misc-ethiopic-1.0.4.tar.bz2
3eeb3fb44690b477d510bbd8f86cf5aa  font-xfree86-type1-1.0.4.tar.bz2
EOF

To download the needed files using wget, use the following commands:

mkdir font &&
cd font &&
grep -v '^#' ../font-7.md5 | awk '{print $2}' | wget -i- -c \
    -B https://www.x.org/pub/individual/font/ &&
md5sum -c ../font-7.md5

Installation of Xorg Fonts

Note

When installing multiple packages in a script, the installation needs to be done as the root user. There are three general options that can be used to do this:

  1. Run the entire script as the root user (not recommended).

  2. Use the sudo command from the Sudo-1.9.9 package.

  3. Use su -c "command arguments" (quotes required) which will ask for the root password for every iteration of the loop.

One way to handle this situation is to create a short bash function that automatically selects the appropriate method. Once the command is set in the environment, it does not need to be set again.

as_root()
{
  if   [ $EUID = 0 ];        then $*
  elif [ -x /usr/bin/sudo ]; then sudo $*
  else                            su -c \\"$*\\"
  fi
}

export -f as_root

First, start a subshell that will exit on error:

bash -e

Install all of the packages by running the following commands:

for package in $(grep -v '^#' ../font-7.md5 | awk '{print $2}')
do
  packagedir=${package%.tar.bz2}
  tar -xf $package
  pushd $packagedir
    ./configure $XORG_CONFIG
    make
    as_root make install
  popd
  as_root rm -rf $packagedir
done

Finally, exit the shell that was started earlier:

exit

When all of the fonts have been installed, the system must be configured so that Fontconfig can find the TrueType fonts since they are outside of the default search path of /usr/share/fonts. Make symlinks to the Xorg TrueType font directories by running the following commands as the root user:

install -v -d -m755 /usr/share/fonts                               &&
ln -svfn $XORG_PREFIX/share/fonts/X11/OTF /usr/share/fonts/X11-OTF &&
ln -svfn $XORG_PREFIX/share/fonts/X11/TTF /usr/share/fonts/X11-TTF

Contents

Installed Programs: bdftruncate and ucs2any
Installed Libraries: None
Installed Directories: $XORG_PREFIX/share/fonts

Short Descriptions

bdftruncate

generates a truncated BDF font from an ISO 10646-1 encoded BDF font

ucs2any

generates BDF fonts in any encoding from an ISO 10646-1 encoded BDF font

Last updated on

XKeyboardConfig-2.35.1

Introduction to XKeyboardConfig

The XKeyboardConfig package contains the keyboard configuration database for the X Window System.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

XKeyboardConfig Dependencies

Required

Xorg Libraries

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xkeyboard-config

Installation of XKeyboardConfig

Install XKeyboardConfig by running the following commands:

sed -i -E 's/(ln -s)/\1f/' rules/meson.build &&

mkdir build &&
cd    build &&

meson --prefix=$XORG_PREFIX --buildtype=release .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Command Explanations

sed ... rules/meson.build: Make sure a symlink is created even if it already exists.

Contents

Installed Programs: None
Installed Libraries: None
Installed Directory: $XORG_PREFIX/share/X11/xkb

Last updated on

Xwayland-22.1.0

Introduction to Xwayland

The Xwayland package is an Xorg server running on top of the wayland server. It has been separated from the main Xorg server package. It allows running X clients inside a wayland session.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Xwayland Dependencies

Required

libxcvt-0.1.1, Pixman-0.40.0, wayland-protocols-1.25, and Xorg Fonts (only font-util)

Recommended
Optional

git-2.35.1 (to download packages needed for the tests), libgcrypt-1.10.0, Nettle-3.7.3, xmlto-0.0.28, Xorg Legacy Fonts (only bdftopcf, for building fonts required for the tests), rendercheck (for tests), and weston (for tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xwayland

Installation of Xwayland

Install xwayland by running the following commands:

sed -i '/install_man/,$d' meson.build &&

mkdir build &&
cd    build &&

meson --prefix=$XORG_PREFIX         \
      -Dxvfb=false                  \
      -Dxkb_output_dir=/var/lib/xkb \
      ..                            &&
ninja

Building the test framework needs some work. First, weston brings in several dependencies, but the number can be reduced by disabling unneeded features. The meson command for a stripped down build of weston is shown in Upstream continuous integration build.

Furthermore, an X server needs to be running during the build of xts. If not running the tests in a graphical environment, you'll need to enable Xvfb by removing the -Dxvfb=false above. The instructions below expect this has been done.

Running the tests involves downloading two other frameworks, in addition to the mentioned optional dependencies:

mkdir tools &&
pushd tools &&

git clone https://gitlab.freedesktop.org/mesa/piglit.git --depth 1 &&
cat > piglit/piglit.conf << EOF                                    &&
[xts]
path=$(pwd)/xts
EOF

git clone https://gitlab.freedesktop.org/xorg/test/xts --depth 1   &&

export DISPLAY=:22           &&
../hw/vfb/Xvfb $DISPLAY &
VFB_PID=$!                   &&
cd xts                       &&
CFLAGS=-fcommon ./autogen.sh &&
make                         &&
kill $VFB_PID                &&
unset DISPLAY VFB_PID        &&
popd

Then the tests can be run with:

XTEST_DIR=$(pwd)/tools/xts PIGLIT_DIR=$(pwd)/tools/piglit ninja test

Now, as the root user:

ninja install &&
mkdir -pv /etc/X11/xorg.conf.d &&
cat >> /etc/sysconfig/createfiles << "EOF"
/tmp/.X11-unix dir 1777 root root
EOF

Command Explanations

sed -i '/install_man/,$d' meson.build: Prevents installing a manual page for Xserver, which is not part of this package.

-Dxvfb=false: Prevents building the xvfb program, which is also installed by Xorg-Server-21.1.3. Remove this option if you do not plan to install the X server.

mkdir -pv /etc/X11/xorg.conf.d: This directory is needed to put configuration files for Xwayland. This command ensures that it exists, as some applications might use it without first creating it.

cat >> /etc/sysconfig/createfiles...: This command creates the /tmp/.X11-unix directory at startup, and ensures that the permissions and ownership are correct as required by applications using Xwayland.

Contents

Installed Program: Xwayland
Installed Library: None
Installed Directory: None

Short Descriptions

Xwayland

Allows X clients to run under wayland

Last updated on

Xorg-Server-21.1.3

Introduction to Xorg Server

The Xorg Server is the core of the X Window system.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Xorg Server Dependencies

Required

libxcvt-0.1.1, Pixman-0.40.0, Xorg Fonts (only font-util), and at runtime: xkeyboard-config-2.35.1

Recommended
Optional

acpid-2.0.33 (runtime), Doxygen-1.9.3 (to build API documentation), fop-2.7 (to build documentation), Nettle-3.7.3, libgcrypt-1.10.0, xcb-util-keysyms-0.4.0, xcb-util-image-0.4.0, xcb-util-renderutil-0.3.9, xcb-util-wm-0.4.1 (all four to build Xephyr), xmlto-0.0.28 (to build documentation), libunwind, rendercheck (for tests), and xorg-sgml-doctools (to build documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Xorg7Server

Installation of Xorg Server

Install the server by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=$XORG_PREFIX \
      -Dsuid_wrapper=true   \
      -Dxkb_output_dir=/var/lib/xkb &&
ninja

To test the results, issue: ninja test. You will need to run ldconfig as the root user first or some tests may fail.

Now as the root user:

ninja install &&
mkdir -pv /etc/X11/xorg.conf.d &&
cat >> /etc/sysconfig/createfiles << "EOF"
/tmp/.ICE-unix dir 1777 root root
/tmp/.X11-unix dir 1777 root root
EOF

Command Explanations

-Dsuid_wrapper=true: Builds the suid-root wrapper for legacy driver support on rootless xserver systems.

-Dsystemd_logind=false: This switch disables elogind integration, allowing Xorg Server to work without having the PAM module configured.

cat >> /etc/sysconfig/createfiles...: This command creates the /tmp/.ICE-unix and /tmp/.X11-unix directories at startup, and ensures that the permissions and ownership are correct as required by the server.

-Dxephyr=true: This option allows building Xephyr if its dependencies are met.

Contents

Installed Programs: gtf, X, Xnest, Xorg, Xvfb, and optionally Xephyr
Installed Libraries: several under $XORG_PREFIX/lib/xorg/modules/ including the modesetting_drv.so driver
Installed Directories: /etc/X11/xorg.conf.d, $XORG_PREFIX/include/xorg, $XORG_PREFIX/lib/xorg, and $XORG_PREFIX/share/X11/xorg.conf.d

Short Descriptions

gtf

calculates VESA GTF mode lines

X

is a symbolic link to Xorg

Xephyr

is a nested X server which supports modern X extensions

Xnest

is a nested X server

Xorg

is the X11R7 X Server

Xvfb

is the virtual framebuffer X server for X Version 11

modesetting_drv.so

provides a video driver for machines using Kernel Mode Setting (KMS). This will use glamor if that has been enabled and the hardware offers acceleration

Last updated on

Xorg Drivers

Introduction to Xorg Drivers

The Xorg Drivers page contains the instructions for building Xorg drivers that are necessary in order for Xorg Server to take advantage of the hardware that it is running on. At least one input and one video driver are required for Xorg Server to start.

On machines using KMS, the modesetting driver is provided by xorg-server and can be used instead of the video driver for the specific hardware, but with reduced performance. It can also be used (without hardware acceleration) in virtual machines running under qemu.

Note

If you are unsure which video hardware you have, you can use lspci from pciutils-3.7.0 to find out which video hardware you have and then look at the descriptions of the packages in order to find out which driver you need.

Note

In addition to the drivers listed below, there are several other drivers for very old hardware that may still be relevant. The latest versions of these drivers may be downloaded from https://www.x.org/archive/individual/driver. Instructions for building these now intermittently maintained drivers may be found in a prior version of BLFS: https://www.linuxfromscratch.org/blfs/view/7.6/x/x7driver.html

Hardware Video Acceleration

libevdev 1.12.0

Introduction to libevdev

The libevdev package contains common functions for Xorg input drivers.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
libevdev Dependencies
Optional

Doxygen-1.9.3 and Valgrind-3.18.1 (optional for tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libevdev

Kernel Configuration

Enable the following options in the kernel configuration and recompile the kernel if necessary:

Device Drivers  --->
  Input device support --->
    <*> Generic input layer (needed for keyboard, mouse, ...) [CONFIG_INPUT]
    <*>   Event interface                   [CONFIG_INPUT_EVDEV]
    [*]   Miscellaneous devices  --->       [CONFIG_INPUT_MISC]
      <*/m>    User level driver support    [CONFIG_INPUT_UINPUT]

The last item is not strictly required for libevdev. If it is compiled as a module, it is not loaded automatically. It is needed for full test coverage.

Installation of libevdev

Install libevdev by running the following commands:

./configure $XORG_CONFIG &&
make

The regression tests can be run as the root user with make check, in a graphical session. You need to have enabled the CONFIG_INPUT_UINPUT setting in the kernel for full test coverage. If it is enabled as a module, the module is named uinput and needs to be loaded before running the tests. Note that on some systems, the tests may cause a hard lockup and require a reboot. On laptops, the system will go into Sleep and need to be woken up to finish the test suites.

Now, as the root user:

make install

Contents

Installed Xorg Programs: libevdev-tweak-device, mouse-dpi-tool, and touchpad-edge-detector
Installed Xorg Library: libevdev.so
Installed Xorg Directory: $XORG_PREFIX/include/libevdev-1.0
Short Descriptions

libevdev-tweak-device

is a tool to change some kernel device properties

mouse-dpi-tool

is a tool to estimate the resolution of a mouse

touchpad-edge-detector

touchpad-edge-detector is a tool that reads the touchpad events from the kernel and calculates the minimum and maximum for the x and y coordinates, respectively

libevdev.so

is a library of Xorg driver input functions

Xorg Evdev Driver-2.10.6

Introduction to Xorg Evdev Driver

The Xorg Evdev Driver package contains a Generic Linux input driver for the Xorg X server. It handles keyboard, mouse, touchpads and wacom devices, though for touchpad and wacom advanced handling, additional drivers are required.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Xorg Evdev Driver Dependencies
Required

libevdev-1.12.0, mtdev-1.1.6, and Xorg-Server-21.1.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xorg-evdev-driver

Installation of Xorg Evdev Driver

Install Xorg Evdev Driver by running the following commands:

./configure $XORG_CONFIG &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Xorg Driver: evdev_drv.so
Short Descriptions

evdev_drv.so

is an Xorg input driver for Linux generic event devices

libinput-1.19.3

Introduction to libinput

libinput is a library that handles input devices for display servers and other applications that need to directly deal with input devices.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
libinput Dependencies
Required

libevdev-1.12.0 and mtdev-1.1.6

Optional

Valgrind-3.18.1 (to run the tests), Sphinx (required to build documentation), GTK+-3.24.31 (to build the GUI event viewer), libunwind (required for tests), libwacom-2.1.0, and PyParsing (for one non-root test)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libinput

kernel configuration for running the libinput testsuite

Although libinput works with the same kernel configuration used by libevdev-1.12.0, its extensive testsuite requires the presence of /dev/uinput (as well as both Valgrind-3.18.1 and libunwind).

If you wish to run the full tests, enable the following option in the kernel configuration and recompile the kernel if necessary:

Device Drivers --->
  Input device support --->
    Miscellaneous Devices --->
    <*/M>   User level driver support        [CONFIG_INPUT_UINPUT]

If you build this as a module, it needs to be inserted before the testsuite runs.

On an Xorg system you will also need to prevent the events generated during the testsuite from interfering with your desktop. Copy the file test/50-litest.conf into ${XORG_PREFIX}/share/X11/xorg.conf.d and restart X. For further information see libinput test suite.

Installation of libinput

Install libinput by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=$XORG_PREFIX \
      --buildtype=release   \
      -Ddebug-gui=false     \
      -Dtests=false         \
      -Dlibwacom=false      \
      ..                    &&
ninja

Note

If you want to run the full tests, remove -Dtests from the meson command above. Please read "kernel configuration for running the libinput testsuite" (above).

If you have enabled the full tests, you can run the main tests as the root user by executing: ninja test. A very large number of tests will be run, about 20 fail (at least on an Xorg system).

Now, as the root user:

ninja install

If you have passed -Ddocumentation=true to meson, you can install the generated documentation by running the following commands as the root user:

install -v -dm755      /usr/share/doc/libinput-1.19.3/html &&
cp -rv Documentation/* /usr/share/doc/libinput-1.19.3/html

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Ddebug-gui=false: This switch disables creation of a visual debug helper for libinput. Remove if you want it, and you have GTK+-3.24.31 installed.

-Dtests=false: This switch disables compilation of the main tests. Even with the tests defined as false, you can still run the first four minor tests, as a regular user, but one will be skipped if PyParsing is not installed.

-Dlibwacom=false: Remove this option if you have libwacom-2.1.0 installed, or if you are installing GNOME.

-Ddocumentation=true: This switch enables generation of the documentation. Add it if you want to generate the documentation. You must have Doxygen-1.9.3 and Graphviz-2.50.0 installed.

Contents

Installed Programs: libinput
Installed Libraries: libinput.so
Installed Directories: $XORG_PREFIX/libexec/libinput, /etc/libinput, /usr/share/libinput, and (optionally) /usr/share/doc/libinput-1.19.3

Short Descriptions

libinput

is a set of tools to interface with the libinput library

libinput.so

contains API functions for handling input devices

Xorg Libinput Driver-1.2.1

Introduction to Xorg Libinput Driver

The X.Org Libinput Driver is a thin wrapper around libinput and allows for libinput to be used for input devices in X. This driver can be used as as drop-in replacement for evdev and synaptics.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Xorg Libinput Driver Dependencies
Required

libinput-1.19.3 and Xorg-Server-21.1.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xorg-libinput-driver

Installation of Xorg Libinput Driver

Install Xorg Libinput Driver by running the following commands:

./configure $XORG_CONFIG &&
make

To test the results, issue make check.

Now, as the root user:

make install

Contents

Installed Xorg Driver: libinput_drv.so
Short Descriptions

libinput_drv.so

is an Xorg input driver for mouse, keyboard, touchpad, touchscreen, and tablet devices

Xorg Synaptics Driver-1.9.1

Introduction to Xorg Synaptics Driver

The Xorg Synaptics Driver package contains the X.Org Input Driver, support programs and SDK for Synaptics touchpads. Even though the evdev driver can handle touchpads very well, this driver is required if you want to use advanced features like multi tapping, scrolling with touchpad, turning the touchpad off while typing, etc.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Xorg Synaptics Driver Dependencies
Required

libevdev-1.12.0 and Xorg-Server-21.1.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xorg-synaptics-driver

Installation of Xorg Synaptics Driver

Install Xorg Synaptics Driver by running the following commands:

./configure $XORG_CONFIG &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: synclient and syndaemon
Installed Xorg Driver: synaptics_drv.so
Short Descriptions

synclient

is a command line utility used to query and modify Synaptics driver options

syndaemon

is a program that monitors keyboard activity and disables the touchpad when the keyboard is being used

synaptics_drv.so

is an Xorg input driver for touchpads

Xorg Wacom Driver-1.0.0

Introduction to Xorg Wacom Driver

The Xorg Wacom Driver package contains the X.Org X11 driver and SDK for Wacom and Wacom-like tablets. It is not required to use a Wacom tablet, the xf86-input-evdev driver can handle these devices without problems.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Xorg Wacom Drivers Dependencies
Required

Xorg-Server-21.1.3

Optional

Doxygen-1.9.3 and Graphviz-2.50.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xorg-wacom-driver

Kernel Configuration

To use a Wacom tablet with USB interface, enable the following options in your kernel configuration and recompile. Note that other configuration options could be required for tablet with a serial or bluetooth interface:

Device Drivers  --->
  HID support  --->
    -*- HID bus support                                      [CONFIG_HID]
         Special HID drivers --->
              <*/M> Wacom Intuos/Graphire tablet support (USB) [CONFIG_HID_WACOM]

Installation of Xorg Wacom Driver

Install Xorg Wacom Driver by running the following commands:

./configure $XORG_CONFIG --with-systemd-unit-dir=no &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Contents

Installed Programs: isdv4-serial-debugger, isdv4-serial-inputattach, and xsetwacom
Installed Xorg Driver: wacom_drv.so
Short Descriptions

xsetwacom

is a commandline utility used to query and modify wacom driver settings

wacom_drv.so

is an Xorg input driver for Wacom devices

Xorg AMDGPU Driver-21.0.0

Introduction to Xorg AMDGPU Driver

The Xorg AMDGPU Driver package contains the X.Org Video Driver for newer AMD Radeon video cards and newer AMD-CPUs with integrated graphics (APUs). This includes video cards starting with Volcanic Islands. It can also be used for Southern and Sea Islands if the experimental support was enabled in the kernel.

This package is known to build and work properly using an LFS-11.1 platform.

Note

For Direct Rendering to work, you need to enable the radeonsi Gallium driver at Mesa-21.3.6 build time. Also, all cards and newer APUs require Firmware to be available when the kernel driver is loaded. Firmware can be obtained from https://anduin.linuxfromscratch.org/BLFS/linux-firmware/. See the section called “Kernel Configuration for additional firmware” below for additional firmware.

Package Information
Xorg AMDGPU Driver Dependencies
Required

Xorg-Server-21.1.3 (must be built with glamor enabled)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xorg-amdgpu-driver

Kernel Configuration

Enable the following options in the kernel configuration and recompile the kernel if necessary:

Device Drivers  --->
  Graphics support --->
   <*> Direct Rendering Manager (XFree86 ... support) ---> [CONFIG_DRM]
   <*/M> AMD GPU                                           [CONFIG_DRM_AMDGPU]
    < /*> Enable amdgpu support for SI parts               [CONFIG_DRM_AMDGPU_SI]
    < /*> Enable amdgpu support for CIK parts              [CONFIG_DRM_AMDGPU_CIK]

The last two options enable experimental support for Southern and Sea Islands AMD GPUs so they can be used with this driver. Note that the support is marked experimental and disabled by default. Xorg ATI Driver-19.1.0 should be used for those GPUs.

Kernel Configuration for additional firmware

If you need to add firmware, install the file(s) and then point to them in the kernel configuration and recompile the kernel if necessary. To find out which firmware you need, consult the Decoder ring for engineering vs marketing names. Download any firmware for your card which is named like: <ENGINEERING_NAME>_rlc.bin, etc. Below is an example for Radeon R7 M340 GPU, which is codenamed Iceland/Topaz, along with a network card that also requires the firmware:

CONFIG_EXTRA_FIRMWARE="amdgpu/topaz_ce.bin amdgpu/topaz_k_smc.bin amdgpu/topaz_mc.bin
                       amdgpu/topaz_me.bin amdgpu/topaz_mec2.bin amdgpu/topaz_mec.bin
                       amdgpu/topaz_pfp.bin amdgpu/topaz_rlc.bin amdgpu/topaz_sdma1.bin
                       amdgpu/topaz_sdma.bin amdgpu/topaz_smc.bin rtl_nic/rtl8168e-3.fw"
CONFIG_EXTRA_FIRMWARE_DIR="/lib/firmware"

Note

CONFIG_EXTRA_FIRMWARE should all be on one line. It is shown above as multiple lines for presentation only.

Tip

You can check dmesg output after boot to see which firmware is missing.

Alternatively, if you change CONFIG_DRM_AMDGPU to '=m' in your linux kernel .config the firmware can be loaded automatically from /lib/firmware/amdgpu/ when it installs the module. This offers a tiny space saving, but also means that the screen will be blank for a longer time before the framebuffer appears. Distros take this approach because it is not practical to specify every possible firmware and the kernel would be excessively big.

Installation of Xorg AMDGPU Driver

Install Xorg AMDGPU Driver by running the following commands:

./configure $XORG_CONFIG &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Xorg Driver: amdgpu_drv.so
Short Descriptions

amdgpu_drv.so

is an Xorg video driver for latest AMD Radeon video cards

Xorg ATI Driver-19.1.0

Introduction to Xorg ATI Driver

The Xorg ATI Driver package contains the X.Org Video Driver for ATI Radeon video cards including all chipsets ranging from R100 to the "Volcanic Islands" chipsets.

This package is known to build and work properly using an LFS-11.1 platform.

Note

For Direct Rendering to work with newer Radeon Cards (R300 and later chipsets), you need to enable the r300, r600 and radeonsi Gallium drivers at Mesa-21.3.6 build time. Also, some cards require Firmware to be available when the kernel driver is loaded. Firmware can be obtained from https://anduin.linuxfromscratch.org/BLFS/linux-firmware/. See the section called “Kernel Configuration for additional firmware” below for additional firmware.

Package Information
Additional Downloads
Xorg ATI Driver Dependencies
Required

Xorg-Server-21.1.3 (recommended to be built with glamor enabled)

Note

Glamor is required for Southern, Sea or Volcanic Islands GPUs, and used by default in all other R600 or later radeon GPUs. To see which GPUs are in these categories, read the Decoder ring for engineering vs marketing names.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xorg-ati-driver

Kernel Configuration

Enable the following options in the kernel configuration and recompile the kernel if necessary:

Device Drivers  --->
  Graphics support --->
   <*> Direct Rendering Manager (XFree86 ... support) ---> [CONFIG_DRM]
   <*> ATI Radeon                                          [CONFIG_DRM_RADEON]

Kernel Configuration for additional firmware

If you need to add firmware, install the file(s) and then point to them in the kernel configuration and recompile the kernel if necessary. To find out which firmware you need, consult the Decoder ring for engineering vs marketing names. Download any firmware for your card which is named like: <ENGINEERING_NAME>_rlc.bin, etc. Note that for R600 and R700 family, generic R600_rlc.bin and R700_rlc.bin are necessary in addition to the model specific firmware, while for later generations you need the BTC_rlc.bin in addition to the model specific firmware. Below is an example for a Radeon HD6470 which is a "Northern Islands" GPU, plus an RTL network chip that also requests extra firmware:

CONFIG_EXTRA_FIRMWARE="radeon/BTC_rlc.bin radeon/CAICOS_mc.bin radeon/CAICOS_me.bin
radeon/CAICOS_pfp.bin radeon/CAICOS_smc.bin rtl_nic/rtl8168e-3.fw"
CONFIG_EXTRA_FIRMWARE_DIR="/lib/firmware"

Note

CONFIG_EXTRA_FIRMWARE should all be on one line. It is shown above as two lines for presentation only.

Tip

You can check dmesg output after boot to see which firmware is missing.

Alternatively, if you change CONFIG_DRM_RADEON to '=m' in your .config the firmware can be loaded automatically from /lib/firmware/radeon when it installs the module. This offers a tiny space saving, but also means that the screen will be blank for a longer time before the framebuffer appears. Distros take this approach because it is not practical to specify every possible firmware and the kernel would be excessively big.

Installation of Xorg ATI Driver

First, apply a patch including fixes for known performance regressions and future problems with Xorg-Server.

patch -Np1 -i ../xf86-video-ati-19.1.0-upstream_fixes-1.patch

Install Xorg ATI Driver by running the following commands:

./configure $XORG_CONFIG &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Xorg Drivers: ati_drv.so and radeon_drv.so
Short Descriptions

ati_drv.so

is a wrapper driver for ATI video cards that autodetects ATI video hardware and loads the radeon, mach64 or r128 driver depending on which video card is in use

radeon_drv.so

is an Xorg video driver for ATI Radeon based video cards

Xorg Fbdev Driver-0.5.0

Introduction to Xorg Fbdev Driver

The Xorg Fbdev Driver package contains the X.Org Video Driver for framebuffer devices. This driver is often used as fallback driver if the hardware specific and VESA drivers fail to load or are not present. If this driver is not installed, Xorg Server will print a warning on startup, but it can be safely ignored if hardware specific driver works well.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Xorg Fbdev Driver Dependencies
Required

Xorg-Server-21.1.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xorg-fbdev-driver

Installation of Xorg Fbdev Driver

Install Xorg Fbdev Driver by running the following commands:

./configure $XORG_CONFIG &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Xorg Driver: fbdev_drv.so
Short Descriptions

fbdev_drv.so

is an Xorg video driver for framebuffer devices

Xorg Intel Driver-20210222

Introduction to Xorg Intel Driver

The Xorg Intel Driver package contains the X.Org Video Driver for Intel integrated video chips including 8xx, 9xx, Gxx, Qxx, HD, Iris, and Iris Pro graphics processors.

This package is known to build and work properly using an LFS-11.1 platform.

Note

This driver is for Intel integrated GPU, and a development version is needed to work properly with the latest hardware. This version is now one year old and has some problems. The Kernel Modes Setting (KMS) driver shipped along with Xorg Server is said to give better results.

Package Information
Xorg Intel Driver Dependencies
Required

xcb-util-0.4.0 and Xorg-Server-21.1.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xorg-intel-driver

Kernel Configuration

Enable the following options in the kernel configuration. Recompile the kernel if necessary:

Device Drivers  --->
  Graphics support --->
   <*> Direct Rendering Manager (XFree86 ... support) ---> [CONFIG_DRM]
   <*> Intel 8xx/9xx/G3x/G4x/HD Graphics                   [CONFIG_DRM_I915]

Installation of Xorg Intel Driver

Install Xorg Intel Driver by running the following commands:

./autogen.sh $XORG_CONFIG     \
            --enable-kms-only \
            --enable-uxa      \
            --mandir=/usr/share/man &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&

mv -v /usr/share/man/man4/intel-virtual-output.4 \
      /usr/share/man/man1/intel-virtual-output.1 &&

sed -i '/\.TH/s/4/1/' /usr/share/man/man1/intel-virtual-output.1

Working around problems with the Intel driver

The SandyBridge New Acceleration (SNA) code is intended to replace the old UXA (UMA Acceleration Architecture), but it is a large body of code and may cause problems. However, the version of the code in the version control system listed above has been tested successfully with both SNA and UXA capabilities.

To work around this problem, as well as enabling support for UXA, it is necessary to force UXA to be used by creating a configuration file. If this problem applies to you, create the following file as the root user and modify it as needed:

cat >> /etc/X11/xorg.conf.d/20-intel.conf << "EOF"
Section   "Device"
        Identifier "Intel Graphics"
        Driver     "intel"
        #Option     "DRI" "2"            # DRI3 is default
        #Option     "AccelMethod"  "sna" # default
        #Option     "AccelMethod"  "uxa" # fallback
EndSection
EOF

Command Explanations

--enable-kms-only: This switch omits the UMS (User Mode Setting) code.

--enable-uxa: This switch allows the old UXA code to be compiled in addition to the default SNA.

Contents

Installed Program: intel-virtual-output
Installed Library: libIntelXvMC.so
Installed Xorg Driver: intel_drv.so
Short Descriptions

intel-virtual-output

is a utility to connect the integrated Intel GPU to discrete outputs on hybrid systems

intel_drv.so

is an Xorg video driver for Intel integrated graphics chipsets

Xorg Nouveau Driver-1.0.17

Introduction to Xorg Nouveau Driver

The Xorg Nouveau Driver package contains the X.Org Video Driver for NVidia Cards including RIVA TNT, RIVA TNT2, GeForce 256, QUADRO, GeForce2, QUADRO2, GeForce3, QUADRO DDC, nForce, nForce2, GeForce4, QUADRO4, GeForce FX, QUADRO FX, GeForce 6XXX and GeForce 7xxx chipsets.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Xorg Nouveau Drivers Dependencies
Required

Xorg-Server-21.1.3 (recommended to be built with glamor enabled)

Note

The new Maxwell and Pascal GPUs require Glamor to be built with the Xorg server.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xorg-nouveau-driver

Kernel Configuration

Enable the following options in the kernel configuration and recompile the kernel if necessary:

Device Drivers  --->
  Graphics support --->
   <*> Direct Rendering Manager (XFree86 ... support) ---> [CONFIG_DRM]
   <*> Nouveau (NVIDIA) cards                              [CONFIG_DRM_NOUVEAU]
      [*]   Support for backlight control                     [CONFIG_DRM_NOUVEAU_BACKLIGHT]

Installation of Xorg Nouveau Driver

Note

Please ensure that you have installed Mesa-21.3.6 with the nouveau fixes patch prior to continuing.

First, fix the Xorg Nouveau Driver to build with the latest Xorg Server:

grep -rl slave | xargs sed -i s/slave/secondary/

Install Xorg Nouveau Driver by running the following commands:

./configure $XORG_CONFIG &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Xorg Driver: nouveau_drv.so
Short Descriptions

nouveau_drv.so

is an Xorg video driver for nVidia video cards

Xorg VMware Driver-13.3.0

Introduction to Xorg VMware Driver

The Xorg VMware Driver package contains the X.Org Video Driver for VMware SVGA virtual video cards.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Xorg VMware Driver Dependencies
Required

Xorg-Server-21.1.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xorg-vmware-driver

Kernel Configuration

Enable the following options in the kernel configuration and recompile the kernel if necessary:

Device Drivers  --->
  Graphics support  --->
   <*> Direct Rendering Manager (XFree86 ... support) --->  [CONFIG_DRM]
   <*> DRM driver for VMware Virtual GPU                    [CONFIG_DRM_VMWGFX]
      [*]   Enable framebuffer console under vmwgfx by default [CONFIG_DRM_VMWGFX_FBCON]

Installation of Xorg VMware Driver

Install Xorg VMware Driver by running the following commands:

./configure $XORG_CONFIG &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Xorg Driver: vmware_drv.so
Short Descriptions

vmware_drv.so

is an Xorg video driver for VMware SVGA virtual video card

libva-2.13.0

Introduction to libva

The libva package contains a library which provides access to hardware accelerated video processing, using hardware to accelerate video processing in order to offload the central processing unit (CPU) to decode and encode compressed digital video. The VA API video decode/encode interface is platform and window system independent targeted at Direct Rendering Infrastructure (DRI) in the X Window System however it can potentially also be used with direct framebuffer and graphics sub-systems for video output. Accelerated processing includes support for video decoding, video encoding, subpicture blending, and rendering.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
Additional Downloads
libva Dependencies
Required

libdrm-2.4.110

Recommended
Optional

Doxygen-1.9.3, Wayland-1.20.0, and intel-gpu-tools

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libva

Installation of libva

Caution

If you are reinstalling this package, you will need to remove the older versions of the libraries. These are in the form of libva*.so.1 and any symbolic links pointing to them. In addition, any packages that use these files need to be rebuilt.

Install libva by running the following commands:

./configure $XORG_CONFIG &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Installation of intel-vaapi-driver

The intel-vaapi-driver is designed specifically for video cards based on an Intel GPU. Unpack the intel-vaapi tarball:

tar -xvf ../intel-vaapi-driver-2.4.1.tar.bz2 &&
cd intel-vaapi-driver-2.4.1

Install the driver by running the following commands:

./configure $XORG_CONFIG &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: libva-drm.so, libva-glx.so, libva.so, libva-wayland.so, and libva-x11.so
Installed Driver: i965_drv_video.so
Installed Directory: $XORG_PREFIX/include/va

Short Descriptions

libva.so

contains API functions which provide access to hardware accelerated video processing

libvdpau-1.4

Introduction to libvdpau

The libvdpau package contains a library which implements the VDPAU library.

VDPAU (Video Decode and Presentation API for Unix) is an open source library (libvdpau) and API originally designed by Nvidia for its GeForce 8 series and later GPU hardware targeted at the X Window System. This VDPAU API allows video programs to offload portions of the video decoding process and video post-processing to the GPU video-hardware.

Currently, the portions capable of being offloaded by VDPAU onto the GPU are motion compensation (mo comp), inverse discrete cosine transform (iDCT), VLD (variable-length decoding) and deblocking for MPEG-1, MPEG-2, MPEG-4 ASP (MPEG-4 Part 2), H.264/MPEG-4 AVC and VC-1, WMV3/WMV9 encoded videos. Which specific codecs of these that can be offloaded to the GPU depends on the version of the GPU hardware; specifically, to also decode MPEG-4 ASP (MPEG-4 Part 2), Xvid/OpenDivX (DivX 4), and DivX 5 formats, a GeForce 200M (2xxM) Series (the eleventh generation of Nvidia's GeForce graphics processing units) or newer GPU hardware is required.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
libvdpau Dependencies
Required

Xorg Libraries

Optional

Doxygen-1.9.3, Graphviz-2.50.0, and texlive-20210325 or install-tl-unx

Runtime Dependency

Mesa-21.3.6

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libvdpau

Installation of libvdpau

Install libvdpau by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=$XORG_PREFIX .. &&
ninja

To test the results, issue: ninja test. There is only one test for this package, dlclose, and it is known to fail on some systems.

Now, as the root user:

ninja install

If doxygen is present at build time place the documentation in a versioned directory as the root user:

[ -e $XORG_PREFIX/share/doc/libvdpau ] && mv -v $XORG_PREFIX/share/doc/libvdpau{,1.4}

Contents

Installed Programs: None
Installed Library: libvdpau.so
Installed Directories: $XORG_PREFIX/{include,lib}/vdpau

Short Descriptions

libvdpau.so

contains functions to offload portions of the video decoding process and video post-processing to the GPU video-hardware

libvdpau-va-gl-0.4.0

Introduction to libvdpau-va-gl

The libvdpau-va-gl package contains a library which implements the VDPAU library. Libvdpau_va_gl uses OpenGL under the hood to accelerate drawing and scaling and the VA-API (if available) to accelerate video decoding. For now VA-API is available on some Intel chips, and on some AMD video adapters with the help of the libvdpau driver.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information
libvdpau-va-gl Dependencies
Required

CMake-3.22.2, FFmpeg-4.4.1, libvdpau-1.4, and libva-2.13.0

Optional

Doxygen-1.9.3, Graphviz-2.50.0, and texlive-20210325 or install-tl-unx

Runtime Dependency

Mesa-21.3.6

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libvdpau

Installation of libvdpau-va-gl

Install libvdpau-va-gl by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=$XORG_PREFIX .. &&
make

To test the results, issue: make check. The tests must be run from an Xorg environment.

Now, as the root user:

make install

Configuration

To allow libvdpau to find libvdpau-va-gl, set an environment variable. As the root user:

echo "export VDPAU_DRIVER=va_gl" >> /etc/profile.d/xorg.sh

Contents

Installed Programs: None
Installed Library: libvdpau_va_gl.so
Installed Directories: None

Short Descriptions

libvdpau_va_gl.so

contains functions to implement the OpenGL backend to the VDPAU (Video Decode and Presentation API for Unix) API

Last updated on

twm-1.0.11

Introduction to twm

The twm package contains a very minimal window manager.

This package is not a part of the Xorg katamari and is provided only as a dependency to other packages or for testing the completed Xorg installation.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

twm Dependencies

Required

Xorg-Server-21.1.3

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/twm

Installation of twm

Install twm by running the following commands:

sed -i -e '/^rcdir =/s,^\(rcdir = \).*,\1/etc/X11/app-defaults,' src/Makefile.in &&
./configure $XORG_CONFIG &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

sed -i -e '/^rcdir =/s...: This command ensures the twm configuration file gets installed in the proper location.

Contents

Installed Programs: twm
Installed Libraries: None
Installed Directory: /etc/X11/app-defaults

Short Descriptions

twm

is the Tab Window Manager for the X Window System

Last updated on

xterm-370

Introduction to xterm

xterm is a terminal emulator for the X Window System.

This package is not a part of the Xorg katamari and is provided only as a dependency to other packages or for testing the completed Xorg installation.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

xterm Dependencies

Required

Xorg Applications

Required (at runtime)

A monospace TTF or OTF font such as Dejavu fonts

Optional

Emacs-27.2, PCRE-8.45 or pcre2-10.39, Valgrind-3.18.1 and man2html

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Xterm

Installation of xterm

Install xterm by running the following commands:

sed -i '/v0/{n;s/new:/new:kb=^?:/}' termcap &&
printf '\tkbs=\\177,\n' >> terminfo &&

TERMINFO=/usr/share/terminfo \
./configure $XORG_CONFIG     \
    --with-app-defaults=/etc/X11/app-defaults &&

make

This package does not come with a test suite.

Now, as the root user:

make install    &&
make install-ti &&

mkdir -pv /usr/share/applications &&
cp -v *.desktop /usr/share/applications/

Command Explanations

sed -i ... termcap, printf ... >> terminfo: These commands modify the terminal description so that the Backspace key is expected to send the character with ASCII code 127. This is done for consistency with the Linux console.

TERMINFO=/usr/share/terminfo: This ensures that the xterm terminfo files are installed to the system terminfo database.

--with-app-defaults=...: Sets the location for the app-defaults directory.

make install-ti: This command installs corrected terminfo description files for use with xterm.

Configuring xterm

There are two ways to configure xterm. You can add the X resource definitions to the user's ~/.Xresources file, or add them to the system-wide $XORG_PREFIX/share/X11/app-defaults/Xterm file.

In order for xterm to follow the locale settings in the environment, use TrueType fonts, and follow the Linux convention about the code sent by the Backspace key, add the following definitions as the root user:

cat >> /etc/X11/app-defaults/XTerm << "EOF"
*VT100*locale: true
*VT100*faceName: Monospace
*VT100*faceSize: 10
*backarrowKeyIsErase: true
*ptyInitialErase: true
EOF

Contents

Installed Programs: koi8rxterm, resize, uxterm, and xterm
Installed Libraries: None
Installed Directories: None

Short Descriptions

koi8rxterm

is a wrapper script to set up xterm with a KOI8-R locale

resize

prints a shell command for setting the TERM and TERMCAP environment variables to indicate the current size of xterm window

uxterm

is a wrapper script that modifies the current locale to use UTF-8 and starts xterm with the proper settings

xterm

is a terminal emulator for the X Window System

Last updated on

xclock-1.0.9

Introduction to xclock

The xclock package contains a simple clock application which is used in the default xinit configuration.

This package is not a part of the Xorg katamari and is provided only as a dependency to other packages or for testing the completed Xorg installation.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

xclock Dependencies

Required

Xorg Libraries

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xclock

Installation of xclock

Install xclock by running the following commands:

./configure $XORG_CONFIG &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: xclock
Installed Libraries: None
Installed Directory: None

Short Descriptions

xclock

is an analog/digital clock for X

Last updated on

xinit-1.4.1

Introduction to xinit

The xinit package contains a usable script to start the xserver.

This package is not a part of the Xorg katamari and is provided only as a dependency to other packages or for testing the completed Xorg installation.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

xinit Dependencies

Required

Xorg Libraries

Recommended (runtime only)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xinit

Installation of xinit

Install xinit by running the following commands:

./configure $XORG_CONFIG --with-xinitdir=/etc/X11/app-defaults &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&
ldconfig

Note

If starting Xorg from the command line, the default instructions above starts Xorg on the current virtual terminal. It may be convenient to see Xorg and associated application messages on the current virtual terminal, normally tty1, and start the graphical environment on the first available unused virtual terminal, normally tty7. To do this, set the suid bit on the Xorg application as the root user:

chmod u+s $XORG_PREFIX/libexec/Xorg

At this point you can start Xorg on virtual terminal 7 with startx <client arguments> -- vt7. Now you can toggle between tty1 and tty7 with the Ctrl-Alt-F1 and Ctrl-Alt-F7 key combinations.

To automatically start Xorg on the first available virtual terminal, modify the startx script as the root user with:

sed -i '/$serverargs $vtarg/ s/serverargs/: #&/' $XORG_PREFIX/bin/startx

After this change, the virtual terminal does not need to be specified on the startx command line.

Contents

Installed Programs: xinit and startx
Installed Libraries: None
Installed Directories: None

Short Descriptions

startx

initializes an X session

xinit

is the X Window System initializer

Last updated on

Xorg-7 Testing and Configuration

Testing Xorg

Note

Before starting Xorg for the first time, is is useful to rebuild the library cache by running ldconfig as the root user.

Note

Before starting Xorg for the first time, is is often needed to reboot the system to ensure all appropriate daemons are started and approprite security issues are properly set. As an alternative, logging out and logging back in may work, but as of this writing has not been tested.

Warning

If Xorg hangs for some reason (for example, lacking a proper input driver), the system may stop responding to any user input. As a precaution, you can enable a magic SysRq key before testing Xorg. As the root user, issue:

echo 4 > /proc/sys/kernel/sysrq

Then if Xorg hangs, it's possible to use Alt+SysRq+R to reset the keyboard mode. Now it should be able to use Ctrl+Alt+Fx (replace x with a VT number) to switch to another VT. If it works, login and kill Xorg using command line in the new VT.

To test the Xorg installation, issue startx. This command brings up a rudimentary window manager called twm with three xterm windows and one xclock window. The xterm window in the upper left is a login terminal and running exit from this terminal will exit the X Window session. The third xterm window may be obscured on your system by the other two xterms.

Note

When testing Xorg with the twm window manager, there will be several warnings in the Xorg log file, $HOME/.local/share/xorg/Xorg.0.log, about missing font files. In addition, there will be several warnings on the text mode terminal (usually tty1) about missing fonts. These warnings do not affect functionality, but can be removed if desired by installing the Xorg Legacy Fonts.

Generally, there is no specific configuration required for Xorg, but customization is possible. For details, see the section called “Setting up Xorg Devices” below.

Checking the Direct Rendering Infrastructure (DRI) Installation

DRI is a framework for allowing software to access graphics hardware in a safe and efficient manner. It is installed in X by default (using Mesa) if you have a supported video card.

To check if DRI drivers are installed properly, check the log file $HOME/.local/share/xorg/Xorg.0.log (or /var/log/Xorg.0.log if you have built Xorg-Server-21.1.3 with the suid bit) for statements such as:

(II) intel(0): direct rendering: DRI2 Enabled

or

(II) NOUVEAU(0): Loaded DRI module

Note

DRI configuration may differ if you are using alternate drivers, such as those from NVIDIA or AMD.

Another way to determine if DRI is working properly is to use one of the two optionally installed OpenGL demo programs in Mesa-21.3.6. From an X terminal, run glxinfo and look for the phrase:

name of display: :0
display: :0  screen: 0
direct rendering: Yes

If direct rendering is enabled, you can add verbosity by running LIBGL_DEBUG=verbose glxinfo. This will show the drivers, device nodes and files used by the DRI system.

To confirm that DRI2 hardware acceleration is working, you can (still in the X terminal) run the command glxinfo | egrep "(OpenGL vendor|OpenGL renderer|OpenGL version)". If that reports something other than Software Rasterizer then you have working acceleration for the user who ran the command.

If your hardware does not have any DRI2 driver available, it will use a Software Rasterizer for Direct Rendering. In such cases, you can use a new, LLVM-accelerated, Software Rasterizer called LLVMPipe. In order to build LLVMPipe just make sure that LLVM-13.0.1 is present at Mesa build time. Note that all decoding is done on the CPU instead of the GPU, so the display will run slower than with hardware acceleration. To check if you are using LLVMpipe, review the output of the glxinfo command above. An example of the output using the Software Rasterizer is shown below:

OpenGL vendor string: VMware, Inc.
OpenGL renderer string: Gallium 0.4 on llvmpipe (LLVM 3.5, 256 bits)
OpenGL version string: 3.0 Mesa 10.4.5

You can also force LLVMPipe by exporting the LIBGL_ALWAYS_SOFTWARE=1 environment variable when starting Xorg.

Again, if you have built the Mesa OpenGL demos, you can also run the test program glxgears. This program brings up a window with three gears turning. The X terminal will display how many frames were drawn every five seconds, so this will give a rough benchmark. The window is scalable, and the frames drawn per second is highly dependent on the size of the window. On some hardware, glxgears will run synchronized with the vertical refresh signal and the frame rate will be approximately the same as the monitor refresh rate.

Hybrid Graphics

Hybrid Graphics is still in experimental state for Linux. Xorg Developers have developed a technology called PRIME that can be used for switching between integrated and muxless discrete GPU at will. Automatic switching is not possible at the moment.

In order to use PRIME for GPU switching, make sure that you are using Linux Kernel 3.4 or later (recommended). You will need latest DRI and DDX drivers for your hardware and Xorg Server 1.13 or later.

Xorg Server should load both GPU drivers automaticaly. You can check that by running:

xrandr --listproviders

There should be two (or more) providers listed, for example:

Providers: number : 2
Provider 0: id: 0x7d cap: 0xb, Source Output, Sink Output, Sink Offload crtcs: 3 outputs: 4 associated providers: 1 name:Intel
Provider 1: id: 0x56 cap: 0xf, Source Output, Sink Output, Source Offload, Sink Offload crtcs: 6 outputs: 1 associated providers: 1 name:radeon

In order to be able to run a GLX application on a discrete GPU, you will need to run the following command, where <provider> is the more powerful discrete card, and <sink> is the card which has a display connected:

xrandr --setprovideroffloadsink <provider> <sink>

Note

With newer Xorg drivers, such as modesetting or intel, which are DRI3 capable, the above command is no longer necessary. It does no harm however.

Then, you will need to export the DRI_PRIME=1 environment variable each time you want the powerful GPU to be used. For example,

DRI_PRIME=1 glxinfo | egrep "(OpenGL vendor|OpenGL renderer|OpenGL version)"

will show OpenGL vendor, renderer and version for the discrete GPU.

If the last command reports same OpenGL renderer with and without DRI_PRIME=1, you will need to check your installation.

Setting up Xorg Devices

For most hardware configurations, modern Xorg will automatically get the server configuration correct without any user intervention. There are, however, some cases where auto-configuration will be incorrect. Following are some example manual configuration items that may be of use in these instances.

Setting up X Input Devices

For most input devices, no additional configuration will be necessary. This section is provided for informational purposes only.

A sample default XKB setup could look like the following (executed as the root user):

cat > /etc/X11/xorg.conf.d/xkb-defaults.conf << "EOF"
Section "InputClass"
    Identifier "XKB Defaults"
    MatchIsKeyboard "yes"
    Option "XkbLayout" "fr"
    Option "XkbOptions" "terminate:ctrl_alt_bksp"
EndSection
EOF

The XkbLayout line is an example for a French (AZERTY) keyboard. Change it to your keyboard model. That line is not needed for a QWERTY (US) keyboard.

Fine Tuning Display Settings

Again, with modern Xorg, little or no additional configuration is necessary. If you should need extra options passed to your video driver, for instance, you could use something like the following (again, executed as the root user):

cat > /etc/X11/xorg.conf.d/videocard-0.conf << "EOF"
Section "Device"
    Identifier  "Videocard0"
    Driver      "radeon"
    VendorName  "Videocard vendor"
    BoardName   "ATI Radeon 7500"
    Option      "NoAccel" "true"
EndSection
EOF

Another common setup is having multiple server layouts for use in different environments. Though the server will automatically detect the presence of another monitor, it may get the order incorrect:

cat > /etc/X11/xorg.conf.d/server-layout.conf << "EOF"
Section "ServerLayout"
    Identifier     "DefaultLayout"
    Screen      0  "Screen0" 0 0
    Screen      1  "Screen1" LeftOf "Screen0"
    Option         "Xinerama"
EndSection
EOF

Last updated on

Tuning Fontconfig

Overview of Fontconfig

If you only read text in English, and are happy with the common libre fonts listed on the next page, you may never need to worry about the details of how fontconfig works. But there are many things which can be altered if they do not suit your needs.

Although this page is long, it barely scratches the surface and you will be able to find many alternative views on the web (but please remember that some things have changed over the years, for example the autohinter is no longer the default). The aim here is to give you enough information to understand the changes you are making.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Fontconfig

The Xft Font Protocol

The Xft font protocol provides antialiased font rendering through freetype, and fonts are controlled from the client side using fontconfig (except for rxvt-unicode-9.30 which can use fonts listed in ~/.Xresources, and AbiWord-3.0.5 which only uses the specified font). The default search path is /usr/share/fonts and ~/.local/share/fonts although for the moment the old and deprecated location ~/.fonts still works. Fontconfig searches directories in its path recursively and maintains a cache of the font characteristics in each directory. If the cache appears to be out of date, it is ignored, and information is fetched from the fonts themselves (that can take a few seconds if you installed a lot of fonts).

If you've installed Xorg in any prefix other than /usr, any X fonts were not installed in a location known to Fontconfig. Symlinks were created from the OTF and TTF X font directories to /usr/share/fonts/X11-{OTF,TTF}. This allows Fontconfig to use the OpenType and TrueType fonts provided by X, although many people will prefer to use more modern fonts.

Fontconfig uses names to define fonts. Applications generally use generic font names such as "Monospace", "Sans" and "Serif". Fontconfig resolves these names to a font that has all characters that cover the orthography of the language indicated by the locale settings.

Useful Commands

The following commands may be helpful when working with fontconfig:

fc-list | less : show a list of all available fonts (/path/to/filename: Font Name:style). If you installed a font more than 30 seconds ago but it does not show, then it or one of its directories is not readable by your user.

fc-match 'Font Name' : will tell you which font will be used if the named font is requested. Typically you would use this to see what happens if a font you have not installed is requested, but you can also use it if the system is giving you a different font from what you expected (perhaps because fontconfig does not agree that the font supports your language).

fc-match -a 'Type' | less : will provide a list of all fonts which can be used for that type (Monospace, Sans, Serif). Note that in-extremis fontconfig will take a glyph from any available font, even if it is not of the specified type, and unless it knows about the font's type it will assume it is Sans.

If you wish to know which font will be used for a string of text (i.e. one or more glyphs, preceded by a space), paste the following command and replace the xyz by the text you care about:

FC_DEBUG=4 pango-view --font=monospace -t xyz | grep family : this requires Pango-1.50.4 and ImageMagick-7.1.0-25 - it will invoke display to show the text in a tiny window, and after closing that the last line of the output will show which font was chosen. This is particularly useful for CJK languages, and you can also pass a language, e.g. PANGO_LANGUAGE=en;ja (English, then assume Japanese) or just zh-cn (or other variants - 'zh' on its own is not valid).

The various files

The main files are in /etc/fonts/conf.d/, which was intended to be a directory populated by symlinks to some of the files in /usr/share/fontconfig/conf.avail/. But many people, and some packages, create the files directly. Each file name must be in the form of two digits, a dash, somename.conf and they are read in sequence.

By convention, the numbers are assigned as follows:

  • 00-09 extra font directories

  • 10-19 system rendering defaults (antialising etc)

  • 20-29 font rendering options

  • 30-39 family substitution

  • 40-49 map family to generic type

  • 50-59 load alternate config files

  • 60-69 generic aliases, map generic to family

  • 70-79 adjust which fonts are available

  • 80-89 match target scan (modify scanned patterns)

  • 90-99 font synthesis

You can also have a personal fonts.conf in $XDG_CONFIG_HOME which is ~/.config/fontconfig/.

The rules to choose a font

If the requested font is installed, and provided it contains the codepoints required for the current language (in the source, see the .orth files in the fc-lang/ directory), it will be used.

But if the document or page requested a font which is not installed (or, occasionally, does not contain all the required codepoints) the following rules come into play: First, 30-metric-aliases.conf is used to map aliases for some fonts with the same metrics (same size, etc). After that, an unknown font will be searched for in 45-latin.conf - if it is found it will be mapped as Serif or Monospace or Sans, otherwise it will be assumed to be Sans. Then 50-latin.conf provides ordered lists of the fallbacks - Dejavu fonts will be used if you installed them. Cyrillic and Greek appear to be treated in the same way. There are similar files with a 65- prefix for Persian and other non-latin writing systems. All of these files prefer commercial fonts if they are present, although modern libre fonts are often at least their equals.

Since fontconfig-2.12.5 there is also generic family matching for some emoji and math fonts, see {45,60}-generic.conf.

In the rare cases where a font does not contain all the expected codepoints, see 'Trial the First:' at I stared into the fontconfig for the long details.

Hinting and Anti-aliasing

It is possible to change how, or if, fonts are hinted. The following example file contains the default settings, but with comments. The settings are very much down to the user's preferences and to the choice of fonts, so a change which improves some pages may worsen others. The preferred location for this file is: ~/.config/fontconfig/fonts.conf

To try out different settings, you may need to exit from Xorg and then rerun startx so that all applications use the new settings. And if you use Gnome or KDE their desktops can override these changes. To explore the possibilities, create a file for your user:

mkdir -pv ~/.config/fontconfig &&
cat > ~/.config/fontconfig/fonts.conf << "EOF"
<?xml version='1.0'?>
<!DOCTYPE fontconfig SYSTEM 'fonts.dtd'>
<fontconfig>

  <match target="font" >
    <!-- autohint was the old automatic hinter when hinting was patent
    protected, so turn it off to ensure any hinting information in the font
    itself is used, this is the default -->
    <edit mode="assign" name="autohint">  <bool>false</bool></edit>

    <!-- hinting is enabled by default -->
    <edit mode="assign" name="hinting">   <bool>true</bool></edit>

    <!-- for the lcdfilter see http://www.spasche.net/files/lcdfiltering/ -->
    <edit mode="assign" name="lcdfilter"> <const>lcddefault</const></edit>

    <!-- options for hintstyle:
    hintfull: is supposed to give a crisp font that aligns well to the
    character-cell grid but at the cost of its proper shape.

    hintmedium: poorly documented, maybe a synonym for hintfull.
    hintslight is the default: - supposed to be more fuzzy but retains shape.

    hintnone: seems to turn hinting off.
    The variations are marginal and results vary with different fonts -->
    <edit mode="assign" name="hintstyle"> <const>hintslight</const></edit>

    <!-- antialiasing is on by default and really helps for faint characters
    and also for 'xft:' fonts used in rxvt-unicode -->
    <edit mode="assign" name="antialias"> <bool>true</bool></edit>

    <!-- subpixels are usually rgb, see
    http://www.lagom.nl/lcd-test/subpixel.php -->
    <edit mode="assign" name="rgba">      <const>rgb</const></edit>

    <!-- thanks to the Arch wiki for the lcd and subpixel links -->
  </match>

</fontconfig>
EOF

You will now need to edit the file in your preferred editor.

For more examples see the blfs-support thread which started at 2016-09/00128, particularly 2016-09/00137, and the original poster's preferred solution at 2016-09/00147. There are other examples in Fontconfig in the Arch wiki and Fontconfig in the Gentoo wiki.

Disabling Bitmap Fonts

In previous versions of BLFS, the ugly old Xorg bitmap fonts were installed. Now, many people will not need to install any of them. But if for some reason you have installed one or more bitmap fonts, you can prevent them being used by fontconfig by creating the following file as the root user :

cat > /etc/fonts/conf.d/70-no-bitmaps.conf << "EOF"
<?xml version='1.0'?>
<!DOCTYPE fontconfig SYSTEM 'fonts.dtd'>
<fontconfig>
<!-- Reject bitmap fonts -->
 <selectfont>
  <rejectfont>
   <pattern>
     <patelt name="scalable"><bool>false</bool></patelt>
   </pattern>
  </rejectfont>
 </selectfont>
</fontconfig>
EOF

Adding extra font directories

Normally, system fonts and user fonts are installed in directories beneath the locations specified in The Xft Font Protocol and there is no obvious reason to put them elsewhere. However, a full BLFS install of texlive-20210325 puts many fonts in /opt/texlive/2021/texmf-dist/fonts/ in the opentype/ and truetype/ subdirectories. Although pulling in all of these files may appear useful (it allows you to use them in non TeX programs), there are several problems with such an approach:

  1. There are hundreds of files, which makes selecting the font hard.

  2. Some of the files do odd things, such as displaying semaphore flags instead of ASCII letters, or mapping cyrillic codepoints to character forms appropriate to Old Church Slavonic instead of the expected current shapes: fine if that is what you need, but painful for normal use.

  3. Several fonts have multiple sizes and impenetrable short names, which both make selecting the correct font even harder.

  4. When a font is added to CTAN, it is accompanied by TeX packages to use it in the old engines (xelatex does not normally need this), and then the version is often frozen whilst the font is separately maintained. Some of these fonts such as Dejavu fonts are probably already installed on your BLFS system in a newer version, and if you have multiple versions of a font it is unclear which one will be used by fontconfig.

However, it is sometimes useful to look at these fonts in non-TeX applications, if only to see whether you wish to install a current version. If you have installed all of texlive, the following example will make one of the Arkandis Open Type fonts available to other applications, and all three of the ParaType TrueType fonts. Adjust or repeat the lines as desired, to either make all the opentype/ or truetypefonts available, or to select different font directories. As the root user:

cat > /etc/fonts/conf.d/09-texlive.conf << "EOF"
<?xml version='1.0'?>
<!DOCTYPE fontconfig SYSTEM 'fonts.dtd'>
<fontconfig>
  <dir>/opt/texlive/2021/texmf-dist/fonts/opentype/arkandis/berenisadf</dir>
  <dir>/opt/texlive/2021/texmf-dist/fonts/truetype/paratype</dir>
</fontconfig>
EOF

If you do this, remember to change all instances of the year in that file when you upgrade texlive to a later release.

Preferring certain fonts

There are many reasons why people may wish to have pages which specify a particular font use a different font, or prefer specific fonts in Monospace or Sans or Serif. As you will expect, there a number of different ways of achieving this.

Fontconfig user docs

Fontconfig installs user documentation that includes an example 'User configuration file' which among other things prefers WenQuanYi ZenHei (a Sans font) if a Serif font is requested for Chinese (this part might be anachronistic unless you have non-free Chinese fonts, because in 65-nonlatin.conf this font is already among the preferred fonts when Serif is specified for Chinese) and to prefer the modern VL Gothic font if a Sans font is specified on a Japanese page (otherwise a couple of other fonts would be preferred if they have been installed).

If you have installed the current version, the user documentation is available in html, PDF and text versions at /usr/share/doc/fontconfig-2.13.1/ : change the version if you installed a different one.

Prefer a specific font

As an example, if for some reason you wished to use the Nimbus Roman No9 L font wherever Times New Roman is referenced (it is metrically similar, and preferred for Times Roman, but the Serif font from Liberation fonts will be preferred for the Times New Roman font if installed), as an individual user you could install the font and then create the following file:

mkdir -pv ~/.config/fontconfig/conf.d &&
cat >  ~/.config/fontconfig/conf.d/35-prefer-nimbus-for-timesnew.conf << "EOF"
<?xml version='1.0'?>
<!DOCTYPE fontconfig SYSTEM 'fonts.dtd'>
<fontconfig>
<!-- prefer Nimbus Roman No9 L for Times New Roman as well as for Times,
 without this Tinos and Liberation Serif take precedence for Times New Roman
 before fontconfig falls back to whatever matches Times -->
    <alias binding="same">
        <family>Times New Roman</family>
        <accept>
            <family>Nimbus Roman No9 L</family>
        </accept>
    </alias>
</fontconfig>
EOF

This is something you would normally do in an individual user's settings, but the file in this case has been prefixed '35-' so that it could, if desired, be used system-wide in /etc/fonts/conf.d/.

Prefer chosen CJK fonts

The following example of a local configuration (i.e. one that applies for all users of the machine) does several things:

  1. If a Serif font is specified, it will prefer the UMing variants, so that in the zh-cn, zh-hk and zh-tw languages things should look good (also zh-sg which actually uses the same settings as zh-cn) without affecting Japanese.

  2. It prefers the Japanese IPAex fonts if they have been installed (although VL Gothic will take precedence for (Japanese) Sans if it has also been installed.

  3. Because WenQuanYi ZenHei covers Korean Hangul glyphs and is also preferred for Serif in 65-nonlatin.conf, if installed it will be used by default for Korean Serif. To get a proper Serif font, the UnBatang font is specified here - change that line if you installed a different Serif font from the choice of Korean fonts.

  4. The Monospace fonts are forced to the preferred Sans fonts. If the text is in Korean then WenQuanYi ZenHei will be used.

In a non-CJK locale, the result is that suitable fonts will be used for all variants of Chinese, Japanese and Hangul Korean. All other languages should already work if a font is present. As the root user:

cat > /etc/fonts/local.conf << "EOF"
<?xml version='1.0'?>
<!DOCTYPE fontconfig SYSTEM 'fonts.dtd'>
<fontconfig>
    <alias>
        <family>serif</family>
        <prefer>
            <family>AR PL UMing</family>
            <family>IPAexMincho</family>
            <!-- WenQuanYi is preferred as Serif in 65-nonlatin.conf,
            override that so a real Korean font can be used for Serif -->
            <family>UnBatang</family>
        </prefer>
    </alias>
    <alias>
         <family>sans-serif</family>
         <prefer>
             <family>WenQuanYi Zen Hei</family>
             <family>VL Gothic</family>
             <family>IPAexGothic</family>
         </prefer>
    </alias>
    <alias>
         <family>monospace</family>
         <prefer>
             <family>VL Gothic</family>
             <family>IPAexGothic</family>
             <family>WenQuanYi Zen Hei</family>
         </prefer>
    </alias>
</fontconfig>
EOF

Editing Old-style conf files

Some fonts, particularly Chinese fonts, ship with conf files which can be installed in /etc/fonts/conf.d. However, if you do that and then use a terminal to run any command which uses fontconfig you may see error messages such as :

Fontconfig warning: "/etc/fonts/conf.d/69-odofonts.conf", line 14: Having multiple <family> in <alias> isn't supported and may not work as expected.

In practice, these old rules do not work. For non-CJK users, fontconfig will usually do a good job without these rules. Their origin dates back to when CJK users needed handcrafted bitmaps to be legible at small sizes, and those looked ugly next to antialiased Latin glyphs - they preferred to use the same CJK font for the Latin glyphs. There is a side-effect of doing this : the (Serif) font is often also used for Sans, and in such a situation the (English) text in Gtk menus will use this font - compared to system fonts, as well as being serif it is both faint and rather small. That can make it uncomfortable to read.

Nevertheless, these old conf files can be fixed if you wish to use them. The following example is the first part of 64-arphic-uming.conf from UMing - there are a lot more similar items which also need changing :


   <match target="pattern">
       <test qual="any" name="lang" compare="contains">
           <string>zh-cn</string>
           <string>zh-sg</string>
       </test>
       <test qual="any" name="family">
           <string>serif</string>
       </test>
       <edit name="family" mode="prepend" binding="strong">
           <string>AR PL UMing CN</string>
       </edit>
    </match>

The process to correct this is straightforward but tedious - for every item which produces an error message, using your editor (as the root user) edit the installed file to repeat the whole block as many times as there are multiple variables, then reduce each example to have only one of them. You may wish to work on one error at a time, save the file after each fix, and from a separate term run a command such as fc-list 2>&1 | less to see that the fix worked. For the block above, the fixed version will be :


   <match target="pattern">
       <test qual="any" name="lang" compare="contains">
           <string>zh-cn</string>
       </test>
       <test qual="any" name="family">
           <string>serif</string>
       </test>
       <edit name="family" mode="prepend" binding="strong">
           <string>AR PL UMing CN</string>
       </edit>
    </match>
   <match target="pattern">
       <test qual="any" name="lang" compare="contains">
           <string>zh-sg</string>
       </test>
       <test qual="any" name="family">
           <string>serif</string>
       </test>
       <edit name="family" mode="prepend" binding="strong">
           <string>AR PL UMing CN</string>
       </edit>
    </match>

See Also

I stared into the fontconfig ...

The blog entries by Eevee are particularly useful if fontconfig does not think your chosen font supports your language, and for preferring some non-MS Japanese fonts when an ugly MS font is already installed.

Fontconfig in the Arch wiki

Arch has a lot of information in its wiki at font_configuration.

Fontconfig in the Gentoo wiki

Gentoo has some information in its wiki at Fontconfig although a lot of the details (what to enable, and Infinality) are specific to Gentoo.

Last updated on

TTF and OTF fonts

About TTF and OTF fonts

Originally, Xorg provided only bitmap fonts. Later, some scalable Type1 fonts were added, but the desktop world moved on to using TrueType and Open Type fonts. To support these, Xorg uses Xft, the X FreeType interface library.

These fonts can provide hints, which fontconfig uses to adjust them for maximum readability on computer monitors. On linux you should always prefer the hinted versions, if available (in general the latin, cyrillic and greek alphabets can use hints, most other writing systems do not use hinting).

A few fonts are provided as collections (TTC or OTC) where font data is shared between different fonts, thus saving disk space. Treat these in exactly the same way as individual TTF or OTF files.

If a font provides both TTF and OTF forms, prefer the OTF form in linux, it may provide more features for programs which know how to use them (such as xelatex).

For some scripts pango is required to render things correctly, either by selecting different glyph forms, or by combining glyphs - in both cases, according to the context. This applies particularly to arabic and indic scripts.

Standard scalable fonts that come with X provide very poor Unicode coverage. You may notice in applications that use Xft that some characters appear as a box with four binary digits inside. In this case, a font with the required glyphs has not been found. Other times, applications that don't use other font families by default and don't accept substitutions from Fontconfig will display blank lines when the default font doesn't cover the orthography of the user's language.

The fonts available to a program are those which were present when it was started, so if you add an extra font and wish to use it in a program which is currently running, then you will have to close and restart that program.

Some people are happy to have dozens, or even hundreds, of font files available, but if you ever wish to select a specific font in a desktop application (for example in a word processor) then scrolling through a lot of fonts to find the right one is slow and awkward - fewer is better. So, for some font packages you might decide to install only one of the fonts - but nevertheless install the different variants (italic, bold, etc) as these are all variations for the same font name.

In the past, everybody recommended running fc-cache as the root user after installing or removing fonts, but this is no-longer necessary on linux, fontconfig will do it automatically if needed and if its caches are more than 30 seconds old. But if you add a font and want to immediately use it then you can run that command (as a normal user).

There are several references below to CJK characters. This stands for Chinese, Japanese and Korean, although modern Korean is now almost all written using the phonetic Hangul glyphs (it used to sometimes use Hanja glyphs which are similar to Chinese and Japanese). Unicode decided to go for Han Unification and to map some Chinese and Japanese glyphs to the same codepoints. This was very unpopular in Japan, and the result is that different fonts will render some codepoints in quite different shapes. In addition, Simplified Chinese will sometimes use the same codepoint as Traditional Chinese but will show it differently, somewhat analogous to the different shapes used for the letters 'a' and 'g' in English (single-storey and two-storey), except that in a language context one will look "wrong" rather than just "different".

Unlike most other packages in this book, the BLFS editors do not monitor the versions of the fonts on this page - once a font is good enough for general use, the typical additions in a new version are minor (e.g. new currency symbols, or glyphs not for a modern language, such as emojis or playing cards). Therefore, none of these fonts show version or md5 information.

The list below will not provide complete Unicode coverage. Unicode is updated every year, and most additions are now for historic writing systems. For almost-complete coverage you can install Noto fonts (about 180 fonts when last checked) but that number of fonts makes it much less convenient to select a specific font in a document, and most people will regard many of them as a waste of space. We used to recommend the Unicode Font Guide, but that has not been updated since 2008 and many of its links are dead.

Rendered examples of most of these fonts, and many others, with details of what languages they cover, some examples of latin fonts with the same metrics (listed as "Substitute latin fonts") and various files of dummy text to compare fonts of similar types, can be found at this font comparison page. That site also covers other current writing systems.

Fonts are often supplied in zip files, requiring UnZip-6.0 to list and extract them, but even if the current release is a tarball you should still check to see if it will create a directory (scatterring the contents of a zipfile or tarball across the current directory can be very messy, and a few fonts create odd __MACOSX/ directories. In addition, many fonts are supplied with permissions which do not let 'other' read them - if a font is to be installed for system-wide use, any directories must be mode 755 and all the files mode 644, so change them if necessary. If you forget, the root user may be able to see a particular font in fc-list but a normal user will not.

As a font installation example, consider the installation of the Dejavu fonts. In this particular package, the TTF files are in a subdirectory. From the unpacked source directory, run the following commands as the root user:

install -v -d -m755 /usr/share/fonts/dejavu &&
install -v -m644 ttf/*.ttf /usr/share/fonts/dejavu &&
fc-cache -v /usr/share/fonts/dejavu

If you wish, you can also install any licenses or other documentation, either alongside the font or in a corresponding directory under /usr/share/doc/.

A few fonts ship with source as well as with the completed TTF or OTF file(s). Unless you intend to modify the font, and have the correct tools (sometimes FontForge-20201107, but often commercial tools), the source will provide no benefit, so do not install it. One or two fonts even ship with Web Open Font Format (WOFF) files - useful if you run a webserver and want to use that font on it, but not useful for desktops.

To provide greater Unicode coverage, you are recommended to install some of the following fonts, depending on what websites and languages you wish to read. The next part of this page details some fonts which cover at least latin alphabets, the final part deals with come CJK issues.

Note

You are strongly recommended to install the Dejavu fonts.

Caladea

Caladea (created as a Chrome OS extra font, hence the 'crosextrafonts' tarball name) is metrically compatible with MS Cambria and can be used if you have to edit a document which somebody started in Microsoft Office using Cambria and then return it to them.

Cantarell fonts

Cantarell fonts – The Cantarell typeface family provides a contemporary Humanist sans serif. It is particularly optimised for legibility at small sizes and is the preferred font family for the GNOME-3 user interface.

Please be aware that the current version includes a VF (Variable Font) file can provide all the individual fonts (also supplied) but breaks xelatex if it is found by fontconfig. The individual fonts work fine.

Carlito

Carlito (created as another Chrome OS extra font, again the 'crosextrafonts-' prefix in the tarball name) is metrically compatible with MS Calibri and can be used if you have to edit a document which somebody started in Microsoft Office using Calibri and then return it to them.

DejaVu fonts

DejaVu fonts – These fonts are an extension of, and replacement for, the Bitstream Vera fonts and provide Latin-based scripts with accents and punctuation such as "smart-quotes" and variant spacing characters, as well as Cyrillic, Greek, Arabic, Hebrew, Armenian, Georgian and some other glyphs. In the absence of the Bitstream Vera fonts (which had much less coverage), these are the default fallback fonts.

GNU FreeFont

GNU FreeFont – This set of fonts covers many non-CJK characters, in particular some of the variants of latin and cyrillic letters used in minority languages, but the glyphs are comparatively small (unlike DejaVu fonts which are comparatively large) and rather light weight ("less black" when black on white is used) which means that in some contexts such as terminals they are not visually pleasing, for example when most other glyphs are provided by another font. On the other hand, some fonts used primarily for printed output, and many CJK fonts, are also light weight.

Gelasio

Gelasio is metrically compatible with MS Georgia and fontconfig will use it if ever Georgia is requested but not installed.

Liberation fonts

The Liberation fonts provide libre substitutes for Arial, Courier New, and Times New Roman. Fontconfig will use them as substitutes for those fonts, and also for the similar Helvetica, Courier, Times Roman although for these latter it can prefer a different font (see the examples in the 'Substitutes' PDFs at zarniwhoop.uk).

Many people will find the Liberation fonts useful for pages where one of those fonts is requested.

Microsoft Core Fonts

The Microsoft Core fonts date from 2002. They were supplied with old versions of Microsoft Windows and were apparently made available for general use. You can extract them from the 'exe' files using bsd-tar from libarchive-3.6.0. Be sure to read the license before using them. At one time some of these fonts (particularly Arial, Times New Roman, and to a lesser extent Courier New) were widely specified on web pages. The full set contains Andale Mono, Arial, Arial Black, Comic Sans MS, Courier New, Georgia, Impact, Times New Roman, Trebuchet MS, Verdana and Webdings.

Please note that if you only want to use a font with the same metrics (character size, etc) as Arial, Courier New, or Times New Roman you can use the libre Liberation Fonts (above), and similarly you can replace Georgia with Gelasio.

Although many old posts recommend installing these fonts for better-looking output, there are more recent posts that these are ugly or 'broken'. One suggestion is that they do not support anti-aliasing.

The newer fonts which Microsoft made their defaults in later releases of MS Windows or MS Office (Calibri and Cambria) have never been freely available. But if you do not have them installed you can find metric equivalents (Carlito, Caladea) above.

Noto fonts

The Noto fonts ('No Tofu', i.e. avoiding boxes with dots [hex digits] when a glyph cannot be found) is a set of fonts which aim to cover every glyph in unicode, no matter how obscure. These fonts, or at least the Sans Serif fonts, are used by KF5 (initially only for gtk applications). If you want to cover historic languages, you can download all the fonts by clicking on the link at the top of that page.

People using languages written in Latin, Greek or Cyrillic alphabets need only install Noto Sans itself, and perhaps Noto Sans Symbols for currency symbols. For more details on the CJK fonts see Noto Sans CJK below. There are also separate fonts for every other current writing system, but these too will also require Noto Sans (or Noto Serif) and perhaps Noto Symbols.

However, you should be aware that fontconfig knows nothing about Noto fonts. The 'Noto Sans Something' fonts are each treated as separate fonts (and for Arabic there is not a specifically Sans name), so if you have other fonts installed then the choice of which font to use for missing glyphs where 'Noto Sans' is specified will be random, except that Sans fonts will be preferred over known Serif and Monospace fonts because Sans is the fallback for unknown fonts.

Oxygen fonts

When KDE Frameworks 5 was first released, it used the Oxygen fonts which were designed for integrated use with the KDE desktop. Those fonts are no-longer actively maintained, so KDE made a decision to switch to Noto fonts, but for the moment they are still required by 'startkde'.

Originally these fonts were only supplied as source, needing CMake-3.22.2 and FontForge-20201107 to create the TTF files. But for a while the source has also included the prepared TTF. The only unusual feature is that each TTF file is in its own subdirectory (oxygen-fonts/{*-?00}/) with the source in further subdirectories. You could just install the whole tarball if you prefer, although that will waste space.

Source Code Pro

This set of fonts from Adobe (seven different weights) includes what is now the preferred monospace font for those applications which use gsettings-desktop-schemas-41.0. The github release source-code-pro contains OTF (preferred) and TTF as well as the source and WOFF fonts.

To use this in terminals, you probably only want the Regular font.

There is also an older TTF version of this available from Google fonts but that has very limited coverage (adequate for most European languages using a latin alphabet).

CJK fonts:

As indicated earlier, usage of a combination of Chinese, Japanese and Korean can be tricky - each font only covers a subset of the available codepoints, the preferred shapes of the glyphs can differ between the languages, and many of the CJK fonts do not actually support modern Korean.

Also, by default fontconfig prefers Chinese to Japanese. Tuning that is covered at Prefer chosen CJK fonts.

Although Unicode has been extended to allow a very large number of CJK codepoints, those outside the Base Plane (greater than U+0xFFFF) are not commonly used in Mandarin (the normal form of written Chinese, whether Simplified (PRC) or Traditional (Taiwan)), or Japanese.

For Hong Kong, which uses Traditional Chinese and where Cantonese is the dominant language, the Hong Kong Supplementary Character Set was added to Unicode in 2005 and revised in 2009 (it is part of CJK Extension B and contains more than 1900 characters). Earlier fonts will not be able to support either Cantonese or use of these characters where local names are written in Mandarin. The UMing HK, Noto Sans CJK HK and WenQuanYi Zen Hei fonts all seem to cover Hong Kong usage (fontconfig disagrees about Noto Sans CJK HK).

The Han glyphs are double-width, other glyphs in the same font may be narrower. For their CJK content, all of these fonts can be regarded as monospaced (i.e. fixed width).

If all you wish to do is to be able to render CJK glyphs, installing WenQuanYi ZenHei may be a good place to start if you do not already have a preference.

Chinese fonts:

In Chinese, there are three font styles in common use: Sung (also known as Song or Ming) which is the most-common ornamented ("serif") form, Kai ("brush strokes") which is an earlier ornamented style that looks quite different, and modern Hei ("sans"). Unless you appreciate the differences, you probably do not want to install Kai fonts.

Noto Sans CJK

Noto Sans CJK – Sans-Serif sets of all CJK fonts in a ttc – as the link says, you can choose to install the TTC and cover all the languages in all weights in a 110MB file, or you can download subsets. There are also Monospace versions.

Opendesktop fonts

A copy of version 1.4.2 of the opendesktop-fonts is preserved at Arch. This was a later development of fireflysung which BLFS used to recommend, adding Kai and Mono fonts. The name of the Sung font remains 'AR PL New Sung' so they cannot both be installed together.

At one time there was a 1.6 release, and more recently some versions at github, which also included a Sans font (Odohei), but those have dropped off the web and it is unclear if there was a problem. Fontconfig does not know anything about the later fonts (AR PL New Kai, AR PL New Sung Mono) and will default to treating them as Sans.

UMing

UMing fonts – sets of Chinese Ming fonts (from Debian, use the '.orig' tarball) in a ttc which contain variations of Simplified and Traditional Chinese (Taiwanese, with second variant for different bopomofo, and Cantonese for Hong Kong). This ships with old-syntax files which you can install to /etc/fonts/conf.d/ but see Editing Old-Style conf files.

WenQuanYi Zen Hei

WenQuanYi Zen Hei provides a Sans-Serif font which covers all CJK scripts including Korean. Although it includes old-style conf files, these are not required: fontconfig will already treat these fonts (the 'sharp' contains bitmaps, the monospace appears not to be Mono in its ASCII part) as Sans, Serif, and Monospace. If all you wish to do is to be able to render Han and Korean text without worrying about the niceties of the shapes used, the main font from this package is a good font to use.

Japanese fonts:

In Japanese, Gothic fonts are Sans, Mincho are Serif. BLFS used to only mention the Kochi fonts, but those appear to now be the least-preferred of the Japanese fonts.

Apart from the fonts detailed below, also consider Noto Sans CJK.

IPAex fonts

The IPAex fonts are the current version of the IPA fonts. Click on 'English' at the link and then click on the Download icon to find IPAex Font Ver.003.01. Unfortunately, fontconfig only knows about the older IPAfonts and the forked IPA Mona font (which is not easily available and which apparently does not meet Debian's Free Software guidelines). Therefore if you install the IPAex fonts you may wish to make it known to fontconfig, see Prefer chosen CJK fonts for one possible way to do this.

Kochi fonts

The Kochi Substitute fonts were the first truly libre Japanese fonts (the earlier Kochi fonts were allegedly plagiarized from a commercial font).

VL Gothic

The VL Gothic font is a modern Japanese font in two variants with monotonic or proportional spacing for the non-Japanese characters.

Korean fonts:

In Korean, Batang or Myeongjo (the older name) are Serif, Dotum or Gothic are the main Sans fonts. BLFS previously recommended the Baekmuk fonts, but the Nanum and Un fonts are now preferred to Baekmuk by fontconfig because of user requests.

A convenient place to see examples of these and many other Korean fonts is Free Korean Fonts. Click on 'Gothic Fonts' or 'All Categories -> Myeongjo Fonts', then click on the font example to see more details including the License, and click on the link to download it. For Nanum, you will need to be able to read Korean to find the download link on the page you get to. For Un there are direct links and you can find the un-fonts-core tarball in the releases/ directory.

Alternatively, consider Noto Sans CJK (all of the variants cover Hangul) or WenQuanYi ZenHei.

Last updated on

Xorg Legacy

Introduction to Xorg Legacy

Xorg's ancestor (X11R1, in 1987) at first only provided bitmap fonts, with a tool (bdftopcf) to assist in their installation. With the introduction of xorg-server-1.19.0 and libXfont2 many people will not need them. There are still a few old packages which might require, or benefit from, these deprecated fonts and so the following packages are shown here.

Note

The font-adobe-100dpi package installs 100 dots per inch versions of Courier, Helvetica, New Century Schoolbook and Times fonts.

The remaining font packages here provide 75dpi versions of those fonts, and various miscellaneous fonts - mostly for legacy encodings. Those are primarily to silence warnings when testing Xorg. In previous versions of BLFS a lot more legacy fonts were installed.

Please consult the BLFS-7.10 book at https://www.linuxfromscratch.org/blfs/view/7.10/x/x7font.html if you wish to install any of those other fonts.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Xorg Legacy Dependencies

Required

xcursor-themes-1.0.6

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Xorg7Legacy

Downloading Xorg Legacy

First, create a list of files to be downloaded. This file will also be used to verify the integrity of the downloads when complete:

cat > legacy.dat << "EOF"
2a455d3c02390597feb9cefb3fe97a45 app/ bdftopcf-1.1.tar.bz2
1347c3031b74c9e91dc4dfa53b12f143 font/ font-adobe-100dpi-1.0.3.tar.bz2
6c9f26c92393c0756f3e8d614713495b font/ font-adobe-75dpi-1.0.3.tar.bz2
cb7b57d7800fd9e28ec35d85761ed278 font/ font-jis-misc-1.0.3.tar.bz2
0571bf77f8fab465a5454569d9989506 font/ font-daewoo-misc-1.0.3.tar.bz2
a2401caccbdcf5698e001784dbd43f1a font/ font-isas-misc-1.0.3.tar.bz2
c88eb44b3b903d79fb44b860a213e623 font/ font-misc-misc-1.1.2.tar.bz2
EOF

To download the needed files using wget, use the following commands:

mkdir legacy &&
cd    legacy &&
grep -v '^#' ../legacy.dat | awk '{print $2$3}' | wget -i- -c \
     -B https://www.x.org/pub/individual/ &&
grep -v '^#' ../legacy.dat | awk '{print $1 " " $3}' > ../legacy.md5 &&
md5sum -c ../legacy.md5

Installation of Xorg Legacy

Note

When installing multiple packages in a script, the installation needs to be done as the root user. There are three general options that can be used to do this:

  1. Run the entire script as the root user (not recommended).

  2. Use the sudo command from the Sudo-1.9.9 package.

  3. Use su -c "command arguments" (quotes required) which will ask for the root password for every iteration of the loop.

One way to handle this situation is to create a short bash function that automatically selects the appropriate method. Once the command is set in the environment, it does not need to be set again.

as_root()
{
  if   [ $EUID = 0 ];        then $*
  elif [ -x /usr/bin/sudo ]; then sudo $*
  else                            su -c \\"$*\\"
  fi
}

export -f as_root

First, start a subshell that will exit on error:

bash -e

Install all of the packages by running the following commands:

for package in $(grep -v '^#' ../legacy.md5 | awk '{print $2}')
do
  packagedir=${package%.tar.bz2}
  tar -xf $package
  pushd $packagedir
    ./configure $XORG_CONFIG
    make
    as_root make install
  popd
  rm -rf $packagedir
  as_root /sbin/ldconfig
done

Finally, exit the shell that was started earlier:

exit

Contents

Installed Programs: bdftopcf
Installed Libraries: None
Installed Directories: $XORG_PREFIX/share/fonts/100dpi, $XORG_PREFIX/share/fonts/75dpi, $XORG_PREFIX/share/fonts/misc

Short Descriptions

bdftopcf

converts an X font from Bitmap Distribution Format to Portable Compiled Format

Last updated on

Chapter 25. Graphical Environment Libraries

This chapter does not contain libraries that are required to run X. It does contain libraries that enhance X. In some cases the enhancement is as simple as font support. In others it is as complex as libraries that sit between X and applications that run on X whose purpose is to standardize the look and feel and inter-process communications for different applications. They also assist programmers by supplying common elements.

Amtk-5.2.0

Introduction to Amtk

The Amtk package contains a basic GTKUIManager replacement based on GAction.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Amtk Dependencies

Required

GTK+-3.24.31

Optional

GTK-Doc-1.33.2 (for documentation) and Valgrind-3.18.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/amtk

Installation of Amtk

Install Amtk by running the following commands:

./configure --prefix=/usr &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Libraries: libamtk-5.so
Installed Directories: /usr/include/amtk-5 and /usr/share/gtk-doc/html/amtk-5.0

Short Descriptions

libamtk-5.so

provides a basic GTKUIManager replacement API based on GAction

Last updated on

ATK-2.36.0

Introduction to ATK

ATK provides the set of accessibility interfaces that are implemented by other toolkits and applications. Using the ATK interfaces, accessibility tools have full access to view and control running applications.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

ATK Dependencies

Required

GLib-2.70.4

Recommended (Required if building GNOME)
Optional

GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/atk

Installation of ATK

Install ATK by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a testsuite.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: None
Installed Library: libatk-1.0.so
Installed Directories: /usr/include/atk-1.0

Short Descriptions

libatk-1.0.so

contains functions that are used by assistive technologies to interact with the desktop applications

Last updated on

Atkmm-2.28.2

Introduction to Atkmm

Atkmm is the official C++ interface for the ATK accessibility toolkit library.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Atkmm Dependencies

Required

ATK-2.36.0 and GLibmm-2.66.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/atkmm

Installation of Atkmm

Install Atkmm by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a testsuite.

Now, as the root user:

ninja install

Contents

Installed Programs: None
Installed Library: libatkmm-1.6.so
Installed Directories: /usr/{include,lib}/atkmm-1.6 and /usr/share/{devhelp/books/atkmm-1.6,doc/atkmm-2.28.2}

Short Descriptions

libatkmm-1.6.so

contains the ATK API classes

Last updated on

at-spi2-core-2.42.0

Introduction to At-Spi2 Core

The At-Spi2 Core package is a part of the GNOME Accessibility Project. It provides a Service Provider Interface for the Assistive Technologies available on the GNOME platform and a library against which applications can be linked.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

At-Spi2 Core Dependencies

Required

dbus-1.12.20, GLib-2.70.4, and Xorg Libraries

Optional (Required if building GNOME)

gobject-introspection-1.70.0

Optional

GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/at-spi2-core

Installation of At-Spi2 Core

Install At-Spi2 Core by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr       \
      --buildtype=release \
      -Dsystemd_user_dir=/tmp .. &&
ninja

A session bus address, normally available in an Xorg terminal, is necessary to run the tests. And, the test suite requires the glib schemas of the package to be installed already. To test the results, install the package first, then issue: ninja test. The memory test is known to timeout.

Now, as the root user:

ninja install &&
rm /tmp/at-spi-dbus-bus.service

Command Explanations

-Dsystemd_user_dir=/tmp: This flag puts the systemd unit file in /tmp where it will be removed. SysV, is unable to use this file.

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: None
Installed Library: libatspi.so
Installed Directories: /usr/include/at-spi-2.0, /usr/share/defaults/at-spi2, and /usr/share/gtk-doc/html/libatspi

Short Descriptions

libatspi.so

contains the At-Spi2 API functions

Last updated on

at-spi2-atk-2.38.0

Introduction to At-Spi2 Atk

The At-Spi2 Atk package contains a library that bridges ATK to At-Spi2 D-Bus service.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

At-Spi2 Atk Dependencies

Required

at-spi2-core-2.42.0 and ATK-2.36.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/at-spi2-atk

Installation of At-Spi2 Atk

Install At-Spi2 Atk by running the following commands:

mkdir build &&
cd build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test. An already active graphical session with bus address is necessary to run the tests.

Now, as the root user:

ninja install

Note

If you installed the package to your system using a DESTDIR method, /usr/share/glib-2.0/schemas/gschemas.compiled was not updated/created. Create (or update) the file using the following command as the root user:

glib-compile-schemas /usr/share/glib-2.0/schemas

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: None
Installed Libraries: libatk-bridge-2.0.so and /usr/lib/gtk-2.0/modules/libatk-bridge.so
Installed Directory: /usr/include/at-spi2-atk and /usr/lib/gnome-settings-daemon-3.0

Short Descriptions

libatk-bridge.so

is the Accessibility Toolkit GTK+ module

libatk-bridge-2.0.so

Contains the common functions used by GTK+ Accessibility Toolkit Bridge

Last updated on

Cairo-1.17.4

Introduction to Cairo

Cairo is a 2D graphics library with support for multiple output devices. Currently supported output targets include the X Window System, win32, image buffers, PostScript, PDF and SVG. Experimental backends include OpenGL, Quartz and XCB file output. Cairo is designed to produce consistent output on all output media while taking advantage of display hardware acceleration when available (e.g., through the X Render Extension). The Cairo API provides operations similar to the drawing operators of PostScript and PDF. Operations in Cairo include stroking and filling cubic Bézier splines, transforming and compositing translucent images, and antialiased text rendering. All drawing operations can be transformed by any affine transformation (scale, rotation, shear, etc.).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Cairo Dependencies

Required

libpng-1.6.37 and Pixman-0.40.0

Recommended
Optional

Cogl-1.22.8, ghostscript-9.55.0, GTK+-3.24.31 and GTK+-2.24.33, GTK-Doc-1.33.2, libdrm-2.4.110, librsvg-2.52.6, libxml2-2.9.13, LZO-2.10, Mesa-21.3.6, Poppler-22.02.0, Qt-5.15.2, Valgrind-3.18.1, DirectFB, jbig2dec, libspectre, Skia, and Qt4.

Note

There is a circular dependency between cairo and harfbuzz. If cairo is built before harfbuzz, it is necessary to rebuild cairo after harfbuzz in order to build pango.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/cairo

Installation of Cairo

Install Cairo by running the following commands:

./configure --prefix=/usr    \
            --disable-static \
            --enable-tee &&
make

This package does not have a working testsuite.

Now, as the root user:

make install

Command Explanations

--enable-tee: This switch enables the experimental tee surface backend which is required if using system-installed Cairo with Mozilla applications.

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-xlib-xcb: This switch enables several experimental Xlib/XCB functions used by some window managers.

--enable-gl: This switch enables Cairo's experimental OpenGL surface which is required for Wayland compositor and some other packages that are not part of BLFS.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to create and install the documentation.

Contents

Installed Programs: cairo-trace
Installed Libraries: libcairo.so, libcairo-gobject.so and libcairo-script-interpreter.so
Installed Directories: /usr/{include,lib,share/gtk-doc/html}/cairo

Short Descriptions

cairo-trace

generates a log of all calls made by an application to Cairo

libcairo.so

contains the 2D graphics functions required for rendering to the various output targets

libcairo-gobject.so

contains functions that integrate Cairo with Glib's GObject type system

libcairo-script-interpreter.so

contains the script interpreter functions for executing and manipulating Cairo execution traces

Last updated on

libcairomm-1.0 (cairomm-1.14.0)

Introduction to libcairomm-1.0

The libcairomm-1.0 package provides a C++ interface to Cairo.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libcairomm-1.0 Dependencies

Required

Cairo-1.17.4 and libsigc++-2.10.8

Recommended
Optional

Doxygen-1.9.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/cairomm-1.0

Installation of libcairomm-1.0

Install Cairomm-1.0 by running the following commands:

mkdir bld &&
cd    bld &&

meson --prefix=/usr       \
      --buildtype=release \
      -Dbuild-tests=true  \
      -Dboost-shared=true \
      ..                  &&
ninja

To run the test suite, run: ninja test.

Now, as the root user:

ninja install

Command Explanations

-Dbuild-tests=true: This switch is for building the unit tests. Remove if you have not installed Boost-1.78.0.

-Dboost-shared=true: This switch has the package use the shared version of boost libraries. It is required if you have not installed the boost static libraries, and you have passed -Dbuild-tests=true.

-Dbuild-documentation=true: This switch builds the html documentation if doxygen is installed.

Contents

Installed Programs: None
Installed Library: libcairomm-1.0.so
Installed Directories: /usr/{lib,include}/cairomm-1.0 and /usr/share/{devhelp/books,doc}/cairomm-1.0 (optional)

Short Descriptions

libcairomm-1.0.so

contains the Cairo API classes

Last updated on

Cogl-1.22.8

Introduction to Cogl

Cogl is a modern 3D graphics API with associated utility APIs designed to expose the features of 3D graphics hardware using a direct state access API design, as opposed to the state-machine style of OpenGL.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Cogl Dependencies

Required

Cairo-1.17.4, gdk-pixbuf-2.42.6, GLU-9.0.2, Mesa-21.3.6, Pango-1.50.4, and Wayland-1.20.0

Recommended
Optional

gst-plugins-base-1.20.0, GTK-Doc-1.33.2, SDL-1.2.15, and SDL2-2.0.20

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/cogl

Installation of Cogl

Install Cogl by running the following commands:

Note

This package may occasionally fail when building with multiple processors. See Using Multiple Processors for more information.

./configure --prefix=/usr  \
            --enable-gles1 \
            --enable-gles2 \
            --enable-{kms,wayland,xlib}-egl-platform \
            --enable-wayland-egl-server              &&
make

To test the results, issue: make check. The tests should be run from an X terminal on the hardware accelerated Xorg Server. A few tests will use all CPUs in parallel, regardless of parallellism settings.

Now, as the root user:

make install

Command Explanations

--enable-gles1: This switch enables support for OpenGL ES 1.1.

--enable-gles2: This switch enables support for OpenGL ES 2.0.

--enable-{kms,wayland,xlib}-egl-platform: These switches enable support for KMS, Wayland and Xlib EGL platforms. They are required for GNOME Wayland support.

--enable-wayland-egl-server: This switch enables Cogl's Wayland Server API which is required for GNOME Wayland support.

--enable-cogl-gst: This switch enables gstreamer support.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Libraries: libcogl-gles2.so, libcogl-pango.so, libcogl-path.so, and libcogl.so, and optional libraries libcogl-gst.so and /usr/lib/gstreamer-1.0/libgstcogl.so
Installed Directories: /usr/include/cogl and /usr/share/cogl

Short Descriptions

libcogl-gles2.so

is the OpenGL ES 2.0 integration library for Cogl

libcogl-pango.so

is the Pango integration library for Cogl

libcogl.so

is an object oriented GL/GLES Abstraction/Utility Layer library

Last updated on

Clutter-1.26.4

Introduction to Clutter

The Clutter package contains an open source software library used for creating fast, visually rich and animated graphical user interfaces.

This package is known to build and work properly using an LFS-11.1 platform.

Note

Anything built with this toolkit needs hardware 3D acceleration from the graphics driver at runtime. This is provided by Mesa (or by proprietary graphics drivers), but is not available for every graphics card nor for all virtual machines. You may wish to review Checking the DRI installation.

Package Information

Clutter Dependencies

Required

ATK-2.36.0, Cogl-1.22.8, and JSON-GLib-1.6.6

Recommended
Optional

GTK-Doc-1.33.2 and Tslib

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/clutter

Installation of Clutter

Install Clutter by running the following commands:

./configure --prefix=/usr               \
            --sysconfdir=/etc           \
            --enable-egl-backend        \
            --enable-evdev-input        \
            --enable-wayland-backend    \
            --enable-wayland-compositor &&
make

The test suite is not recommended because some tests may hang forever. If you want to test the results anyway, issue: make -j1 -k check. You must be in an xterm or similar, because it launches some windows.

Now, as the root user:

make install

Command Explanations

--enable-egl-backend: This switch enables the experimental EGL windowing backend.

--enable-evdev-input: This switch enables the experimental Evdev input backend which is required for GNOME Wayland support.

--enable-wayland-backend and --enable-wayland-compositor: These switches enable the experimental Wayland API in Clutter which is required for GNOME Wayland support.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Library: libclutter-1.0.so and libclutter-glx-1.0.so
Installed Directories: /usr/include/clutter-1.0 and /usr/share/gtk-doc/html/{cally,clutter}

Short Descriptions

libclutter-1.0.so

contains the Clutter API functions

Last updated on

clutter-gst-3.0.27

Introduction to Clutter Gst

The Clutter Gst package contains an integration library for using GStreamer with Clutter. Its purpose is to implement the ClutterMedia interface using GStreamer.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Clutter Gst Dependencies

Required

Clutter-1.26.4, gst-plugins-base-1.20.0, and libgudev-237

Recommended
Optional

GTK-Doc-1.33.2 and Cgc

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/clutter-gst

Installation of Clutter Gst

Install Clutter Gst by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a testsuite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Library: libclutter-gst-3.0.so and /usr/lib/gstreamer-1.0/libcluttergst3.so
Installed Directories: /usr/include/clutter-gst-3.0 and /usr/share/gtk-doc/html/clutter-gst-3.0

Short Descriptions

libclutter-gst-3.0.so

contains the Clutter Gst API functions

Last updated on

clutter-gtk-1.8.4

Introduction to Clutter Gtk

The Clutter Gtk package is a library providing facilities to integrate Clutter into GTK+ applications.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Clutter Gtk Dependencies

Required

Clutter-1.26.4 and GTK+-3.24.31

Recommended
Optional

GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/clutter-gtk

Installation of Clutter Gtk

Install Clutter Gtk by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Library: libclutter-gtk-1.0.so
Installed Directories: /usr/include/clutter-gtk-1.0 and /usr/share/gtk-doc/html/clutter-gtk-1.0

Short Descriptions

libclutter-gtk-1.0.so

contains the Clutter Gtk API functions

Last updated on

colord-gtk-0.3.0

Introduction to Colord GTK

The Colord GTK package contains GTK+ bindings for Colord.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Colord GTK Dependencies

Required

colord-1.4.6 and GTK+-3.24.31

Recommended
Optional

DocBook-utils-0.6.14 and GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/colord-gtk

Installation of Colord GTK

Warning

If building the documentation ninja -j1 must be used.

Install Colord GTK by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr       \
      --buildtype=release \
      -Dgtk2=true         \
      -Dgtk4=true         \
      -Dvapi=true         \
      -Ddocs=false        \
      -Dman=false ..      &&
ninja

To test the results, issue: ninja test. The tests need to be run from an X session, and may require a color profile for your primary display.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dvapi=true: This switch enables building of the Vala bindings. Remove this switch if you don't have Vala-0.54.7 installed.

-Dgtk2=true: This switch enables building the GTK+-2 bindings for colord.

-Dgtk4=true: This switch enables building the GTK-4 bindings for colord. Set this option to 'false' if you do not have GTK-4.6.1 installed.

-Ddocs=false: This switch disables building gtk-doc based documentation. Even if gtk-doc is installed, you will need the namespaced versions of the Docbook XSL stylesheets.

-Dman=false: This switch disables generating the manual pages for this package. Remove this switch if you have namespaced versions of the Docbook XSL stylesheets installed.

Contents

Installed Programs: cd-convert
Installed Libraries: libcolord-gtk.so, libcolord-gtk2.so, and libcolord-gtk4.so
Installed Directories: /usr/include/colord-1/colord-gtk and /usr/share/gtk-doc/html/colord-gtk

Short Descriptions

cd-convert

is a Color Manager Testing Tool

libcolord-gtk.so

contains the Colord GTK+ bindings

libcolord-gtk2.so

contains the Colord GTK+-2 bindings

libcolord-gtk4.so

contains the Colord GTK-4 bindings

Last updated on

FLTK-1.3.8

Introduction to FLTK

FLTK (pronounced "fulltick") is a cross-platform C++ GUI toolkit. FLTK provides modern GUI functionality and supports 3D graphics via OpenGL and its built-in GLUT emulation libraries used for creating graphical user interfaces for applications.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

FLTK Dependencies

Required

Xorg Libraries

Recommended
Optional

alsa-lib-1.2.6.1, desktop-file-utils-0.26, Doxygen-1.9.3, GLU-9.0.2, Mesa-21.3.6, and texlive-20210325 (or install-tl-unx)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/fltk

Installation of FLTK

Note

The tar extraction directory is fltk-1.3.8 and not fltk-1.3.8-source as indicated by the tarball name.

Install FLTK by running the following commands:

sed -i -e '/cat./d' documentation/Makefile       &&

./configure --prefix=/usr    \
            --enable-shared  &&
make

If you wish to create the API documentation, issue:

make -C documentation html

The tests for the package are interactive. To execute the tests, run test/unittests. In addition, there are 70 other executable test programs in the test directory that can be run individually.

Now, as the root user:

make docdir=/usr/share/doc/fltk-1.3.8 install

If desired, install some example games built as a part of the tests, extra documentation and example programs. As the root user:

make -C test          docdir=/usr/share/doc/fltk-1.3.8 install-linux &&
make -C documentation docdir=/usr/share/doc/fltk-1.3.8 install-linux

Command Explanations

sed ... documentation/Makefile: Avoid installing pages in /usr/share/man/cat*.

Contents

Installed Programs: blocks, checkers, fltk-config, fluid, and sudoku
Installed Libraries: libfltk.{a,so}, libfltk_forms.{a,so}, libfltk_gl.{a,so}, and libfltk_images.{a,so}
Installed Directories: /usr/include/FL and /usr/share/doc/fltk-1.3.8

Short Descriptions

blocks

is a FLTK-based block elimination game

checkers

is a FLTK-based version of the game of checkers

fltk-config

is a utility script that can be used to get information about the current version of FLTK that is installed on the system

fluid

is an interactive GUI designer for FLTK

sudoku

is an implementation of the popular Sudoku game

libfltk.so

contains functions that provide an API to implement graphical user interfaces

Last updated on

Freeglut-3.2.2

Introduction to Freeglut

Freeglut is intended to be a 100% compatible, completely opensourced clone of the GLUT library. GLUT is a window system independent toolkit for writing OpenGL programs, implementing a simple windowing API, which makes learning about and exploring OpenGL programming very easy.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Freeglut Dependencies

Required

CMake-3.22.2 and Mesa-21.3.6

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/freeglut

Installation of Freeglut

Install Freeglut by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr       \
      -DCMAKE_BUILD_TYPE=Release        \
      -DFREEGLUT_BUILD_DEMOS=OFF        \
      -DFREEGLUT_BUILD_STATIC_LIBS=OFF  \
      -Wno-dev .. &&

make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

-DFREEGLUT_BUILD_DEMOS=OFF: Disable building optional demo programs. Note that if you choose to build them, their installation must be done manually. The demo programs are limited and installation is not recommended.

-DFREEGLUT_BUILD_STATIC_LIBS=OFF: Do not build the static library.

Contents

Installed Programs: None
Installed Library: libglut.so
Installed Directories: None

Short Descriptions

libglut.so

contains functions that implement the OpenGL Utility Toolkit

Last updated on

gdk-pixbuf-2.42.6

Introduction to Gdk Pixbuf

The Gdk Pixbuf package is a toolkit for image loading and pixel buffer manipulation. It is used by GTK+ 2 and GTK+ 3 to load and manipulate images. In the past it was distributed as part of GTK+ 2 but it was split off into a separate package in preparation for the change to GTK+ 3.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Gdk Pixbuf Dependencies

Required

GLib-2.70.4, libjpeg-turbo-2.1.2, libpng-1.6.37, and shared-mime-info-2.1

Recommended
Optional (Required if building GNOME)

gobject-introspection-1.70.0

Optional

gi-docgen (to generate documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gdk-pixbuf

Installation of Gdk Pixbuf

Install Gdk Pixbuf by running the following commands:

mkdir build &&
cd build &&

meson --prefix=/usr --buildtype=release --wrap-mode=nofallback .. &&
ninja

To test the results, issue: ninja test. The tests make a heavy use of disk.

Now, as the root user:

ninja install

Note

If you installed the package on to your system using a DESTDIR method, an important file was not installed and should be copied and/or generated. Generate it using the following command as the root user:

gdk-pixbuf-query-loaders --update-cache

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

--wrap-mode=nofallback: This switch prevents meson from using subproject fallbacks for any dependency declarations in the build files, stopping it downloading any optional dependency which is not installed on the system.

Contents

Installed Programs: gdk-pixbuf-csource, gdk-pixbuf-pixdata, gdk-pixbuf-query-loaders, and gdk-pixbuf-thumbnailer
Installed Libraries: libgdk_pixbuf-2.0.so
Installed Directories: /usr/{include,lib}/gdk-pixbuf-2.0, /usr/libexec/installed-tests/gdk-pixbuf, /usr/share/installed-tests/gdk-pixbuf, /usr/share/gtk-doc/html/gdk-pixbuf, and /usr/share/thumbnailers

Short Descriptions

gdk-pixbuf-csource

is a small utility that generates C code containing images, used for compiling images directly into programs

gdk-pixbuf-pixdata

is a tool used to convert GdkPixbuf to GdkPixdata

gdk-pixbuf-query-loaders

collects information about loadable modules for Gdk Pixbuf and writes it to the default cache file location, or to stdout

gdk-pixbuf-thumbnailer

creates thumbnails of pictures for use in other applications

libgdk_pixbuf-2.0.so

contains functions used to load and render images

Last updated on

gdk-pixbuf-xlib-2.40.2

Introduction to gdk-pixbuf-xlib

The gdk-pixbuf-xlib package provides a deprecated Xlib interface to gdk-pixbuf, which is needed for some applications which have not been ported to use the new interfaces yet.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

gdk-pixbuf-xlib Dependencies

Required

gdk-pixbuf-2.42.6 and Xorg Libraries

Optional

GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gdk-pixbuf-xlib

Installation of gdk-pixbuf-xlib

Install gdk-pixbuf-xlib by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Command Explanations

-Dgtk_doc=true: Use this option if GTK-Doc-1.33.2 is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Libraries: libgdk_pixbuf_xlib-2.0.so
Installed Directories: /usr/include/gdk-pixbuf-2.0/gdk-pixbuf-xlib

Short Descriptions

libgdk_pixbuf_xlib-2.0.so

provides a Xlib interface to gdk-pixbuf

Last updated on

GDL-3.40.0

Introduction to GDL

The GDL package provides a library that is useful for docking objects in GTK+ applications.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GDL Dependencies

Required

GTK+-3.24.31

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gdl

Installation of GDL

Install GDL by running the following commands:

./configure --prefix=/usr --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Libraries: libgdl-3.so
Installed Directories: /usr/include/libgdl-3.0 and /usr/share/gtk-doc/html/gdl-3.0

Short Descriptions

libgdl-3.so

contains functions that allow for docking objects in GTK+ applications

Last updated on

GLEW-2.2.0

Introduction to GLEW

GLEW is the OpenGL Extension Wrangler Library.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

glew Dependencies

Required

Mesa-21.3.6

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/GLEW

Installation of GLEW

Install GLEW by running the following commands:

sed -i 's%lib64%lib%g' config/Makefile.linux &&
sed -i -e '/glew.lib.static:/d' \
       -e '/0644 .*STATIC/d'    \
       -e 's/glew.lib.static//' Makefile     &&
make

This package does not come with a test suite.

Now, as the root user:

make install.all

Command Explanations

sed -i 's%lib64%lib%g' ...: This ensures that the library is installed in /usr/lib.

sed -i -e '/glew.lib.static:/d' ...: This suppresses the static library.

make install.all: This installs the programs as well as the library.

Contents

Installed Programs: glewinfo and visualinfo
Installed Library: libGLEW.so
Installed Directory: /usr/include/GL

Short Descriptions

glewinfo

provides information about the supported extensions

visualinfo

is an extended version of glxinfo

libGLEW.so

provides functions to access OpenGL extensions

Last updated on

GLU-9.0.2

Introduction to GLU

This package provides the Mesa OpenGL Utility library.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GLU Dependencies

Required

Mesa-21.3.6

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/glu

Installation of GLU

Install GLU by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=$XORG_PREFIX -Dgl_provider=gl --buildtype=release .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install &&
rm -vf /usr/lib/libGLU.a

Contents

Installed Programs: None
Installed Library: libGLU.so
Installed Directories: None

Short Descriptions

libGLU.so

is the Mesa OpenGL Utility library

Last updated on

GOffice-0.10.51

Introduction to GOffice

The GOffice package contains a library of GLib/GTK document centric objects and utilities. This is useful for performing common operations for document centric applications that are conceptually simple, but complex to implement fully. Some of the operations provided by the GOffice library include support for plugins, load/save routines for application documents and undo/redo functions.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GOffice Dependencies

Required

GTK+-3.24.31, libgsf-1.14.48, librsvg-2.52.6, libxslt-1.1.35, and Which-2.21

Optional

gobject-introspection-1.70.0, ghostscript-9.55.0, gsettings-desktop-schemas-41.0, GTK-Doc-1.33.2, Lasem, and libspectre

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/goffice010

Installation of GOffice

Install GOffice by running the following commands:

./configure --prefix=/usr &&
make

If you wish to run the tests, issue: make check.

Now, as the root user:

make install

Command Explanations

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Libraries: libgoffice-0.10.so
Installed Directories: /usr/include/libgoffice-0.10, /usr/{lib,share}/goffice, and /usr/share/gtk-doc/html/goffice-0.10

Short Descriptions

libgoffice-0.10.so

contains API functions to provide support for document centric objects and utilities

Last updated on

Grantlee-5.2.0

Introduction to grantlee

Grantlee is a set of free software libraries written using the Qt framework. Currently two libraries are shipped with Grantlee: Grantlee Templates and Grantlee TextDocument. The goal of Grantlee Templates is to make it easier for application developers to separate the structure of documents from the data they contain, opening the door for theming.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Grantlee Dependencies

Required

CMake-3.22.2 and Qt-5.15.2

Optional

Doxygen-1.9.3 (for documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/grantlee

Installation of Grantlee

Install Grantlee by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_BUILD_TYPE=Release  \
      .. &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: none
Installed Libraries: libGrantlee_Templates.so and libGrantlee_TextDocument.so
Installed Directories: /usr/lib/cmake/Grantlee5, /usr/lib/grantlee/5.2, and /usr/include/grantlee

Short Descriptions

libGrantlee_Templates.so

contains common documentation templates for separating documents from their structure

libGrantlee_TextDocument.so

contains functions that allow separating the content of text documents from their structure.

Last updated on

Graphene-1.10.6

Introduction to Graphene

The Graphene package provides a thin layer of types for graphics libraries.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Graphene Dependencies

Required

GLib-2.70.4 and gobject-introspection-1.70.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/graphene

Installation of Graphene

Install Graphene by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dgtk_doc=true: Use this switch if you have GTK-Doc-1.33.2 installed and wish to generate the API documentation.

Contents

Installed Programs: None
Installed Libraries: libgraphene-1.0.so
Installed Directories: /usr/include/graphene-1.0, /usr/lib/graphene-1.0, /usr/{libexec,share}/installed-tests/graphene-1.0

Short Descriptions

libgraphene-1.0.so

contains functions that provide a thin layer of types for graphics libraries

Last updated on

GTK+-2.24.33

Introduction to GTK+ 2

The GTK+ 2 package contains libraries used for creating graphical user interfaces for applications.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GTK+ 2 Dependencies

Required

ATK-2.36.0, gdk-pixbuf-2.42.6 and Pango-1.50.4

Recommended
Optional

Cups-2.4.1, DocBook-utils-0.6.14, gnome-themes-extra-3.28 (runtime, for Adwaita and HighContrast themes), gobject-introspection-1.70.0 and GTK-Doc-1.33.2

Note

If gobject-introspection-1.70.0 was installed after ATK-2.36.0, gdk-pixbuf-2.42.6, and/or Pango-1.50.4, those packages will have to be rebuilt before this package can be built.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gtk+2

Installation of GTK+ 2

Install GTK+ 2 by running the following commands:

sed -e 's#l \(gtk-.*\).sgml#& -o \1#' \
    -i docs/{faq,tutorial}/Makefile.in      &&

./configure --prefix=/usr --sysconfdir=/etc &&

make

To test the results, issue: make -k check. Note that you must run the tests from a session with X Window Display capability (i.e., not a text-based terminal/console) as the tests attempt to open an X window, and the tests can take an excessively long time. Using an X Window, the tests should take less than 0.1 SBU. One test, aliasfilescheck.sh, is known to fail.

Now, as the root user:

make install

Note

If you installed the package on to your system using a DESTDIR method, an important file was not installed and must be copied and/or generated. Generate it using the following command as the root user:

gtk-query-immodules-2.0 --update-cache

Command Explanations

sed -i 's#l \(gtk-.*\).sgml#& -o \1#' docs/{faq,tutorial}/Makefile.in: If you have DocBook-utils-0.6.14 installed (specifically, if configure finds db2html) then it will try to use it to rebuild some of its HTML documentation and fail due to bugs in some of the Makefiles. This sed fixes the Makefiles.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Configuring GTK+ 2

Config Files

~/.gtkrc-2.0, /etc/gtk-2.0/gtkrc, and /usr/share/gtk-2.0/gtkrc

Configuration Information

GTK+ 2 themes change the way a GTK+ 2 application looks. A GTK+ 2 icon theme can be used to change the icons that appear on the application's toolbar. If you have installed a GTK+ 2 theme (such as gnome-themes-extra-3.28 or GTK Engines-2.20.2), or a GTK+ icon theme (such as adwaita-icon-theme-41.0) you can set your preferences in ~/.gtkrc-2.0:

cat > ~/.gtkrc-2.0 << "EOF"
include "/usr/share/themes/Glider/gtk-2.0/gtkrc"
gtk-icon-theme-name = "hicolor"
EOF

There are many more themes available at Gnome-Look.org and other places.

Once you've settled on themes you like, you can (as the root user) make them the default system wide:

cat > /etc/gtk-2.0/gtkrc << "EOF"
include "/usr/share/themes/Clearlooks/gtk-2.0/gtkrc"
gtk-icon-theme-name = "elementary"
EOF

LXAppearance-0.6.3 is a GTK+ 2 application that can help you choose the themes you like.

Contents

Installed Programs: gtk-builder-convert, gtk-demo, gtk-query-immodules-2.0, and gtk-update-icon-cache
Installed Libraries: libgailutil.so, libgdk-x11-2.0.so, and libgtk-x11-2.0.so
Installed Directories: /etc/gtk-2.0, /usr/include/{gail-1.0,gtk-2.0,gtk-unix-print-2.0}, /usr/lib/gtk-2.0, /usr/share/doc/gtk+-2.24.33, /usr/share/gtk-2.0, /usr/share/gtk-doc/html/{gail-libgail-util,gdk2,gtk2}, and /usr/share/themes/{Default,Emacs,Raleigh}

Short Descriptions

gtk-builder-convert

converts glade files into XML files which can be loaded with GtkBuilder

gtk-demo

demonstrates GTK+ 2 functionality and provides code for the examples

gtk-query-immodules-2.0

collects information about loadable input method modules for GTK+ 2 and writes it to standard output

gtk-update-icon-cache

creates mmap()able cache files for icon themes. Starting with gtk+-2.24.24, add the flag --include-image-data to this command, if you wish previous behavior, with image data in the cache

libgdk-x11-2.0.so

contains functions that act as a wrapper around the low-level drawing and windowing functions provided by the underlying graphics system

libgtk-x11-2.0.so

contains functions that provide an API to implement graphical user interfaces

Last updated on

GTK+-3.24.31

Introduction to GTK+ 3

The GTK+ 3 package contains libraries used for creating graphical user interfaces for applications.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GTK+ 3 Dependencies

Required

at-spi2-atk-2.38.0, gdk-pixbuf-2.42.6, libepoxy-1.5.9, and Pango-1.50.4

Recommended
Recommended (Required if building GNOME)
Optional

colord-1.4.6, Cups-2.4.1, DocBook-utils-0.6.14, GTK-Doc-1.33.2, PyAtSpi2-2.38.2 (for tests), and PAPI

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gtk3

Installation of GTK+ 3

Install GTK+ 3 by running the following commands:

./configure --prefix=/usr              \
            --sysconfdir=/etc          \
            --enable-broadway-backend  \
            --enable-x11-backend       \
            --enable-wayland-backend   &&
make

Some tests fail if /usr/share/glib-2.0/schemas/gschemas.compiled is not found. If you wish to run the test suite, create (or update) the file using the following command as the root user: glib-compile-schemas /usr/share/glib-2.0/schemas.

To test the results you need a graphical session, then issue make check. Several tests associated with scrolledwindow are known to fail.

Now, as the root user:

make install

Note

If you installed the package on to your system using a c DESTDIR method, an important file was not installed and must be copied and/or generated. Generate it using the following command as the root user:

gtk-query-immodules-3.0 --update-cache

Note

If you installed the package to your system using a DESTDIR method, /usr/share/glib-2.0/schemas/gschemas.compiled was not updated/created. Create (or update) the file using the following command as the root user:

glib-compile-schemas /usr/share/glib-2.0/schemas

Command Explanations

--enable-broadway-backend: This switch enables the HTML5 GTK backend.

--enable-x11-backend: This switch enables the X11 GDK backend.

--enable-wayland-backend: This switch enables the Wayland GDK backend. Replace with --disable-wayland-backend if you do not have Wayland-1.20.0 and wayland-protocols-1.25 or you do not wish to build GNOME with Wayland support. Other changes may be needed to allow the build to complete without the wayland backend enabled. Note that a previous installation of gtk+3 built with wayland will interfere with installation without wayland. If this is desired, remove /usr/lib/libgtk-3* before installation.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Configuring GTK+ 3

Config Files

~/.config/gtk-3.0/settings.ini and /etc/gtk-3.0/settings.ini

Configuration Information

GTK+ 3 themes change the way a GTK+ 3 application looks. An icon theme can be used to change the icons that appear on the application's toolbar. If you have installed a GTK+ 3 theme (e.g. the Adwaita theme built in GTK+ 3), an icon theme (such as oxygen-icons5-5.91.0) and/or a font (Dejavu fonts), you can set your preferences in ~/.config/gtk-3.0/settings.ini, or the default system wide configuration file (as the root user), in /etc/gtk-3.0/settings.ini. For the local user an example is:

mkdir -vp ~/.config/gtk-3.0
cat > ~/.config/gtk-3.0/settings.ini << "EOF"
[Settings]
gtk-theme-name = Adwaita
gtk-icon-theme-name = oxygen
gtk-font-name = DejaVu Sans 12
gtk-cursor-theme-size = 18
gtk-toolbar-style = GTK_TOOLBAR_BOTH_HORIZ
gtk-xft-antialias = 1
gtk-xft-hinting = 1
gtk-xft-hintstyle = hintslight
gtk-xft-rgba = rgb
gtk-cursor-theme-name = Adwaita
EOF

There are many settings keys, some with default values. You can find them at Settings: GTK+ 3 Reference Manual. There are many more themes available at https://www.gnome-look.org/browse/ and other places.

As part of GTK+-3.0's redesign, the scroll bar buttons are no longer visible on the scrollbar in many applications. If this functionality is desired, modify the gtk.css file and restore them using the following command:

cat > ~/.config/gtk-3.0/gtk.css << "EOF"
*  {
   -GtkScrollbar-has-backward-stepper: 1;
   -GtkScrollbar-has-forward-stepper: 1;
}
EOF

Contents

Installed Programs: broadwayd, gtk3-demo, gtk3-demo-application, gtk3-icon-browser, gtk3-widget-factory, gtk-builder-tool, gtk-encode-symbolic-svg, gtk-launch, gtk-query-immodules-3.0, gtk-query-settings, and gtk-update-icon-cache
Installed Libraries: libgailutil-3.so, libgdk-3.so, and libgtk-3.so
Installed Directories: /etc/gtk-3.0, /usr/include/{gail,gtk}-3.0, /usr/{lib,share}/gtk-3.0, /usr/share/gtk-doc/html/{gail-libgail-util,gdk,gtk}3, and /usr/share/themes/{Default,Emacs}/gtk-3.0

Short Descriptions

broadwayd

provides support for displaying GTK+ 3 applications in a web browser, using HTML5 and web sockets

gtk3-demo

is a simple program that demonstrates some of the tasks that can be done with GTK+ 3

gtk3-demo-application

is a simple GTK+ 3 application

gtk3-icon-browser

is a utility to explore the icons in the current icon theme. It shows icons in various sizes, their symbolic variants where available, as well as a description of the icon and its context

gtk3-widget-factory

is a program to view GTK+ 3 themes and widgets

gtk-builder-tool

performs various operations on GtkBuilder .ui files

gtk-encode-symbolic-svg

converts symbolic SVG icons into specially prepared PNG files. GTK+ 3 can load and recolor these PNGs, just like original SVGs, but loading them is much faster

gtk-launch

launches an application using the given name. The name should match the application desktop file name, as residing in /usr/share/applications, with or without the '.desktop' suffix

gtk-query-immodules-3.0

collects information about loadable input method modules for GTK+ 3 and writes it to the default cache file location, or to standard output

gtk-query-settings

provides a complete listing of all settings related to GTK+ 3

gtk-update-icon-cache

is an icon theme caching utility that creates mmap()able cache files for icon themes

libgailutil-3.so

contains functions that implement the accessibility interfaces defined by the GNOME Accessibility Toolkit

libgdk-3.so

contains functions that act as a wrapper around the low-level drawing and windowing functions provided by the underlying graphics system

libgtk-3.so

contains functions that provide an API to implement graphical user interfaces

Last updated on

GTK-4.6.1

Introduction to GTK 4

The GTK 4 package contains libraries used for creating graphical user interfaces for applications.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GTK 4 Dependencies

Required

FriBidi-1.0.11, gdk-pixbuf-2.42.6, graphene-1.10.6, ISO Codes-4.9.0, libepoxy-1.5.9, libxkbcommon-1.4.0, Pango-1.50.4, PyGObject-3.42.0, and wayland-protocols-1.25

Recommended
Recommended (Required if building GNOME)
Optional

colord-1.4.6, Cups-2.4.1, FFmpeg-4.4.1 (built with libvpx-1.11.0), GTK-Doc-1.33.2, Highlight-4.1 (runtime, only used by gtk4-demo for syntax highlighting of demo source code), sassc-3.6.2, Tracker-3.2.1, gi-docgen, libcloudproviders, and vulkan

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gtk4

Installation of GTK 4

Install GTK 4 by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release -Dbroadway-backend=true .. &&
ninja

To run the tests, issue: meson test --setup x11. If you are in a Wayland session, replace x11 with wayland. A few tests may fail.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dbroadway-backend=true: This switch enables the HTML5 GDK backend.

-Dcloudproviders=enabled: Use this switch if you have libcloudproviders installed and wish to enable support for cloud providers in a file chooser window.

-Dsysprof=enabled: Use this switch if you have sysprof-3.42.1 installed and wish to enable tracing support for GTK4-based applications.

-Dtracker=enabled: Use this switch if you have Tracker-3.2.1 installed and wish to use search functionality when running a file chooser.

-Dcolord=enabled: Use this switch if you have colord-1.4.6 installed and wish to use colord with the CUPS printing backend.

-Dgtk_doc=true: Use this switch if you have GTK-Doc-1.33.2 installed and wish to generate the API reference documentation.

Configuring GTK 4

Config Files

~/.config/gtk-4.0/settings.ini and /usr/share/gtk-4.0/settings.ini

Configuration Information

GTK 4 themes change the way a GTK 4 application looks. An icon theme can be used to change the icons that appear on the application's toolbar. If you have installed a GTK 4 theme (e.g. the Adwaita theme built in GTK 4), an icon theme (such as oxygen-icons5-5.91.0) and/or a font (Dejavu fonts), you can set your preferences in ~/.config/gtk-4.0/settings.ini, or the default system-wide configuration file (as the root user), in /usr/share/gtk-4.0/settings.ini. For the local user, an example is:

mkdir -pv ~/.config/gtk-4.0
cat > ~/.config/gtk-4.0/settings.ini << "EOF"
[Settings]
gtk-theme-name = Adwaita
gtk-icon-theme-name = oxygen
gtk-font-name = DejaVu Sans 12
gtk-cursor-theme-size = 18
gtk-xft-antialias = 1
gtk-xft-hinting = 1
gtk-xft-hintstyle = hintslight
gtk-xft-rgba = rgb
gtk-cursor-theme-name = Adwaita
EOF

There are many settings keys, some with default values. You can find them at Settings: GTK 4 Reference Manual.

Contents

Installed Programs: gtk4-broadwayd, gtk4-builder-tool, gtk4-demo, gtk4-demo-application, gtk4-encode-symbolic-svg, gtk4-icon-browser, gtk4-launch, gtk4-print-editor, gtk4-query-settings, gtk4-update-icon-cache, and gtk4-widget-factory
Installed Libraries: libgtk-4.so
Installed Directories: /usr/include/gtk-4.0, /usr/lib/gtk-4.0, and /usr/share/gtk-4.0

Short Descriptions

gtk4-broadwayd

provides support for displaying GTK 4 applications in a web browser using HTML5 and web sockets

gtk4-builder-tool

performs various operations on GtkBuilder .ui files

gtk4-demo

is a simple program that demonstrates some of the tasks that can be done with GTK 4

gtk4-demo-application

is a simple GTK 4 application which is useful for testing

gtk4-encode-symbolic-svg

converts symbolic SVG icons into special PNG files. GTK 4 can load and recolor these PNGs, just like original SVGs, but loading them is much faster

gtk4-icon-browser

is a utility to explore the icons in the current icon theme. It shows icons in various sizes, their symbolic variants when available, as well as a description of the icon and its context

gtk4-launch

launches an application using the given name. The name should match the application .desktop file name (as seen in /usr/share/applications), with or without the '.desktop' extension

gtk4-print-editor

is a simple program to demonstrate printing using GTK 4 applications

gtk4-query-settings

provides a complete listing of all settings related to GTK 4

gtk4-update-icon-cache

is an icon theme caching utility that creates mmap()able cache files for icon themes

gtk4-widget-factory

is a program to view GTK 4 themes and widgets

libgtk-4.so

contains functions that provide an API to implement graphical user interfaces

Last updated on

GTK Engines-2.20.2

Introduction to GTK Engines

The GTK Engines package contains eight themes/engines and two additional engines for GTK2.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GTK Engines Dependencies

Required

GTK+-2.24.33

Optional

Lua-5.4.4 and Which-2.21 (required for test suite)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gtk-engines

Installation of GTK Engines

Install GTK Engines by running the following commands:

./configure --prefix=/usr &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--enable-lua --with-system-lua: Use these switches if you installed Lua and want to build Lua theming engine.

Contents

Installed Programs: None
Installed Libraries: libclearlooks.so, libcrux-engine.so, libglide.so, libhcengine.so, libindustrial.so, libmist.so, libredmond95.so and libthinice.so (GTK-2 engines libraries)
Installed Directories: /usr/lib/gtk-2.0/2.10.0/engines, /usr/share/gtk-engines, /usr/share/themes/Clearlooks, /usr/share/themes/Crux, /usr/share/themes/Industrial, /usr/share/themes/Mist, /usr/share/themes/Redmond and /usr/share/themes/ThinIce
Installed Themes: Clearlooks, Crux, Industrial, Mist, Redmond and ThinIce

Short Descriptions

engine libraries

are manager systems for specific themes

Last updated on

Gtkmm-2.24.5

Introduction to Gtkmm

The Gtkmm package provides a C++ interface to GTK+ 2. It can be installed alongside Gtkmm-3.24.5 (the GTK+ 3 version) with no namespace conflicts.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Gtkmm Dependencies

Required

Atkmm-2.28.2, GTK+-2.24.33 and Pangomm-2.46.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gtkmm2

Installation of Gtkmm

First, fix the documents directory name:

sed -e '/^libdocdir =/ s/$(book_name)/gtkmm-2.24.5/' \
    -i docs/Makefile.in

Install Gtkmm by running the following commands:

./configure --prefix=/usr &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: libgdkmm-2.4.so and libgtkmm-2.4.so
Installed Directories: /usr/include/gdkmm-2.4, /usr/include/gtkmm-2.4, /usr/lib/gdkmm-2.4, /usr/lib/gtkmm-2.4, and /usr/share/{devhelp/books/gtkmm-2.4,doc/gtkmm-2.24.5}

Short Descriptions

libgdkmm-2.4.so

contains the GDK API classes

libgtkmm-2.4.so

contains the GTK+ API classes

Last updated on

Gtkmm-3.24.5

Introduction to Gtkmm

The Gtkmm package provides a C++ interface to GTK+ 3.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Gtkmm Dependencies

Required

Atkmm-2.28.2, GTK+-3.24.31, and Pangomm-2.46.2

Optional

Doxygen-1.9.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gtkmm3

Installation of Gtkmm

Install Gtkmm by running the following commands:

mkdir gtkmm3-build &&
cd    gtkmm3-build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test. Note that you must be in a graphical environment, as the tests try to open some windows.

Now, as the root user:

ninja install

If you have built the documentation (see Command Explanations below) it was installed to /usr/share/doc/gtkmm-3.0. For consistency, move it to a versioned directory as the root user:

mv -v /usr/share/doc/gtkmm-3.0 /usr/share/doc/gtkmm-3.24.5

Command Explanations

-Dbuild-documentation=true: If you have installed Doxygen-1.9.3 this define will build and install the documentation.

Contents

Installed Programs: None
Installed Libraries: libgdkmm-3.0.so and libgtkmm-3.0.so
Installed Directories: /usr/include/gdkmm-3.0, /usr/include/gtkmm-3.0, /usr/lib/gdkmm-3.0, /usr/lib/gtkmm-3.0, and optionally /usr/share/{devhelp/books/gtkmm-3.0,doc/gtkmm-3.24.5}

Short Descriptions

libgdkmm-3.0.so

contains the GDK API classes

libgtkmm-3.0.so

contains the GTK+ 3 API classes

Last updated on

gtk-vnc-1.3.0

Introduction to Gtk VNC

The Gtk VNC package contains a VNC viewer widget for GTK+. It is built using coroutines allowing it to be completely asynchronous while remaining single threaded.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Gtk VNC Dependencies

Required

GnuTLS-3.7.3, GTK+-3.24.31, and libgcrypt-1.10.0

Recommended
Optional

Cyrus SASL-2.1.27 and PulseAudio-15.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gtk-vnc

Installation of Gtk VNC

Install Gtk VNC by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a testsuite.

Now, as the root user:

ninja install

Command Explanations

-Dwith-vala=false: This switch disables building of the Vala bindings. Add this if you decide to build gtk-vnc without vala installed.

Contents

Installed Program: gvnccapture
Installed Libraries: libgtk-vnc-2.0.so, libgvnc-1.0.so and libgvncpulse-1.0.so
Installed Directories: /usr/include/gtk-vnc-2.0, /usr/include/gvnc-1.0 and /usr/include/gvncpulse-1.0

Short Descriptions

gvnccapture

is used to capture image from VNC server

libgtk-vnc-2.0.so

contains the GTK+ 3 bindings for Gtk VNC

libgvnc-1.0.so

contains the GObject bindings for Gtk VNC

libgvncpulse-1.0.so

is the PulseAudio bridge for Gtk VNC

Last updated on

gtksourceview-3.24.11

Introduction to GtkSourceView

The GtkSourceView package contains libraries used for extending the GTK+ text functions to include syntax highlighting.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GtkSourceView Dependencies

Required

GTK+-3.24.31

Recommended
Optional

Vala-0.54.7, Valgrind-3.18.1, GTK-Doc-1.33.2, itstool-2.0.7, fop-2.7 (or dblatex), and Glade

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gtksourceview

Installation of GtkSourceView

Install GtkSourceView by running the following commands:

./configure --prefix=/usr &&
make

To test the results, issue make check. The tests need to be run in a graphical environment.

Now, as the root user:

make install

Command Explanations

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Library: libgtksourceview-3.0.so
Installed Directories: /usr/{include,share,share/gtk-doc/html}/gtksourceview-3.0

Short Descriptions

libgtksourceview-3.0.so

contains function extensions for the GtkTextView widget

Last updated on

gtksourceview4-4.8.2

Introduction to GtkSourceView

The GtkSourceView package contains libraries used for extending the GTK+ text functions to include syntax highlighting.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GtkSourceView Dependencies

Required

GTK+-3.24.31

Recommended
Optional

Vala-0.54.7, Valgrind-3.18.1, GTK-Doc-1.33.2, itstool-2.0.7, fop-2.7 (or dblatex), and Glade

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gtksourceview4

Installation of GtkSourceView

Install GtkSourceView by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue ninja test. The tests need to be run in a graphical environment.

Now, as the root user:

ninja install

Command Explanations

-Dgtk_doc=true: This option is normally used if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Library: libgtksourceview-4.so
Installed Directories: /usr/{include,share,share/gtk-doc/html}/gtksourceview-4

Short Descriptions

libgtksourceview-4.so

contains function extensions for the GtkTextView widget

Last updated on

gtksourceview5-5.2.0

Introduction to GtkSourceView

The GtkSourceView package contains a library used for extending the GTK text functions to include syntax highlighting.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GtkSourceView Dependencies

Required

GTK-4.6.1 and pcre2-10.39

Recommended
Optional

GTK-Doc-1.33.2, sysprof-3.42.1, Vala-0.54.7, and Valgrind-3.18.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gtksourceview5

Installation of GtkSourceView

Install GtkSourceView by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

-Dgtk_doc=true: Use this switch if you have GTK-Doc-1.33.2 installed and wish to generate the API documentation.

-Dsysprof=true: Use this switch if you have sysprof-3.42.1 installed and wish to build with sysprof profiler support.

Contents

Installed Programs: None
Installed Libraries: libgtksourceview-5.so
Installed Directories: /usr/include/gtksourceview-5 and /usr/share/gtksourceview-5

Short Descriptions

libgtksourceview-5.so

contains function extensions for the GtkTextView widget

Last updated on

imlib2-1.8.0

Introduction to imlib2

imlib2 is a graphics library for fast file loading, saving, rendering and manipulation.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

imlib2 Dependencies

Required

Xorg Libraries

Recommended
Optional

libpng-1.6.37, libjpeg-turbo-2.1.2, libtiff-4.3.0, and libid3tag

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/imlib2

Installation of imlib2

Install imlib2 by running the following commands:

./configure --prefix=/usr --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&
install -v -m755 -d                        /usr/share/doc/imlib2-1.8.0 &&
install -v -m644    doc/{*.gif,index.html} /usr/share/doc/imlib2-1.8.0

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: imlib2_bumpmap, imlib2_colorspace, imlib2-config, imlib2_conv, imlib2_grab, imlib2_poly, imlib2_show, imlib2_test, and imlib2_view
Installed Libraries: libImlib2.so and various filters and image loader modules.
Installed Directories: /usr/lib/imlib2, /usr/share/doc/imlib2-1.8.0, and /usr/share/imlib2

Short Descriptions

imlib2_bumpmap

is to test the imlib2 bumpmap function

imlib2_colorspace

is to test the imlib2 colorspace function

imlib2-config

is a script used to obtain imlib2 building informations

imlib2_poly

is to test the imlib2 poly function

imlib2_conv

converts images between formats

imlib2_grab

takes screenshots

imlib2_show

is an imlib2 program test

imlib2_test

is an imlib2 program test

imlib2_view

diplays images files

libImlib2.so

provides the functions for programs to handle various image data formats

Last updated on

keybinder-0.3.1

Introduction to keybinder

The keybinder package contains a utility library registering global X keyboard shortcuts.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

keybinder Dependencies

Required

GTK+-2.24.33

Recommended
Optional

GTK-Doc-1.33.2 and Lua-5.4.4 (currently broken because an older lua version is required)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/keybinder

Installation of keybinder

Install keybinder by running the following commands:

./configure --prefix=/usr --disable-lua &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-lua: Use this switch to disable Lua-5.4.4 bindings (currently broken, because older lua version is required).

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Library: libkeybinder.so and /usr/lib/python2.7/site-packages/keybinder/_keybinder.so
Installed Directories: /usr/lib/python2.7/site-packages/keybinder and /usr/share/gtk-doc/html/keybinder

Short Descriptions

libkeybinder.so

is the library that registers global X keyboard shortcuts

Last updated on

keybinder-3.0-0.3.2

Introduction to keybinder-3.0

The keybinder-3.0 package contains a utility library registering global X keyboard shortcuts for GTK+-3.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

keybinder-3.0 Dependencies

Required

GTK+-3.24.31

Recommended
Optional

GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/keybinder-3.0

Installation of keybinder-3.0

Install keybinder-3.0 by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Library: libkeybinder-3.0.so
Installed Directories: /usr/include/keybinder-3.0 and /usr/share/gtk-doc/html/keybinder-3.0

Short Descriptions

libkeybinder-3.0.so

is the library that registers global X keyboard shortcuts

Last updated on

libdazzle-3.42.0

Introduction to libdazzle

libdazzle is a companion library to GObject and GTK+ that adds APIs for special graphical effects.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libdazzle Dependencies

Required

GTK+-3.24.31

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libdazzle

Installation of libdazzle

Install libdazzle by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Program: dazzle-list-counters
Installed Library: libdazzle-1.0.so
Installed Directory: /usr/include/libdazzle-1.0

Short Descriptions

dazzle-list-counters

lists counters that are in use by a process

libdazzle-1.0.so

contains API functions for graphical effects

Last updated on

Libhandy-1.4.0

Introduction to libhandy

The libhandy package provides additional GTK UI widgets for use in developing user interfaces.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libhandy Dependencies

Required

GTK+-3.24.31

Recommended
Optional

GTK-Doc-1.33.2 and Glade

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libhandy1

Installation of libhandy

Install libhandy by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test. The tests must be run from a graphical session.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dgtk_doc=true: Use this option if you have GTK-Doc-1.33.2 installed and wish to install the documentation.

Contents

Installed Programs: handy-1-demo
Installed Libraries: libhandy-1.so
Installed Directories: /usr/include/libhandy-1

Short Descriptions

handy-1-demo

provides an example of how to use the libhandy library

libhandy-1.so

provides additional GTK widgets for use in creating user interfaces

Last updated on

libdrm-2.4.110

Introduction to libdrm

libdrm provides a user space library for accessing the DRM, direct rendering manager, on operating systems that support the ioctl interface. libdrm is a low-level library, typically used by graphics drivers such as the Mesa DRI drivers, the X drivers, libva and similar projects.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libdrm Dependencies

Recommended
Optional

Cairo-1.17.4 (for tests), CMake-3.22.2 (could be used to find dependencies without pkgconfig files), docbook-xml-4.5, docbook-xsl-1.79.2, docutils-0.18.1, and libxslt-1.1.35 (to build manual pages), libatomic_ops-7.6.12 (required by architectures without native atomic operations), Valgrind-3.18.1, and CUNIT (for AMDGPU tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libdrm

Installation of libdrm

Install libdrm by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=$XORG_PREFIX \
      --buildtype=release   \
      -Dudev=true           \
      -Dvalgrind=false      &&
ninja

To check the results, issue ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dudev=true: This parameter enables support for using Udev instead of mknod.

-Dvalgrind=false: This parameter disables building libdrm with valgrind support. This fixes building sysprof and other packages that use libdrm. Change this parameter to "true" if you need support for valgrind.

Contents

Installed Programs: None
Installed Libraries: libdrm_amdgpu.so, libdrm_intel.so, libdrm_nouveau.so, libdrm_radeon.so, libdrm.so, and libkms.so
Installed Directories: /usr/include/libdrm, /usr/include/libkms, and /usr/share/libdrm

Short Descriptions

libdrm_amdgpu.so

contains the AMDGPU specific Direct Rendering Manager functions

libdrm_intel.so

contains the Intel specific Direct Rendering Manager functions

libdrm_nouveau.so

contains the open source nVidia (Nouveau) specific Direct Rendering Manager functions

libdrm_radeon.so

contains the AMD Radeon specific Direct Rendering Manager functions

libdrm.so

contains the Direct Rendering Manager API functions

libkms.so

contains API functions for kernel mode setting abstraction

Last updated on

libepoxy-1.5.9

Introduction to libepoxy

libepoxy is a library for handling OpenGL function pointer management.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libepoxy Dependencies

Required

Mesa-21.3.6

Optional

Doxygen-1.9.3 (for documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libepoxy

Installation of libepoxy

Install libepoxy by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Ddocs=true: If you have Doxygen-1.9.3 installed, add this option to generate additional documentation.

Contents

Installed Programs: None
Installed Libraries: libepoxy.so
Installed Directories: /usr/include/epoxy

Short Descriptions

libepoxy.so

contains API functions for handling OpenGL function pointer management

Last updated on

libglade-2.6.4

Introduction to libglade

The libglade package contains libglade libraries. These are useful for loading Glade interface files in a program at runtime.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libglade Dependencies

Required

libxml2-2.9.13 and GTK+-2.24.33

Optional

Python-2.7.18 and GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libglade

Installation of libglade

Install libglade by running the following commands:

sed -i '/DG_DISABLE_DEPRECATED/d' glade/Makefile.in &&
./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check. One of the tests, test-convert, is known to fail.

Now, as the root user:

make install

Command Explanations

sed -i '/DG_DISABLE_DEPRECATED/d': Some of the glib functions that libglade uses were declared deprecated in glib-2.30. This sed removes the G_DISABLE_DEPRECATED CFLAG.

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Program: libglade-convert (requires python)
Installed Library: libglade-2.0.so
Installed Directories: /usr/{include/libglade-2.0/glade,share/{gtk-doc/html/libglade, xml/libglade}}

Short Descriptions

libglade-convert

is used to convert old Glade interface files to Glade-2.0 standards

libglade-2.0.so

contains the functions necessary to load Glade interface files

Last updated on

libnotify-0.7.9

Introduction to libnotify

The libnotify library is used to send desktop notifications to a notification daemon, as defined in the Desktop Notifications spec. These notifications can be used to inform the user about an event or display some form of information without getting in the user's way.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libnotify Dependencies

Required

GTK+-3.24.31

Optional (Required if building GNOME)

gobject-introspection-1.70.0

Optional

GTK-Doc-1.33.2 and xmlto-0.0.28

Required (runtime)

notification-daemon-3.20.0 or xfce4-notifyd-0.6.3

Note

GNOME Shell and KDE KWin provide their own notification daemons.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libnotify

Installation of libnotify

Install libnotify by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr       \
      --buildtype=release \
      -Dgtk_doc=false     \
      -Dman=false .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install &&
mv -v /usr/share/doc/libnotify{,-0.7.9}

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dgtk_doc=false: Remove this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Program: notify-send
Installed Library: libnotify.so
Installed Directories: /usr/include/libnotify and /usr/share/gtk-doc/html/libnotify

Short Descriptions

notify-send

is a command used to send notifications

libnotify.so

contains the libnotify API functions

Last updated on

libxklavier-5.4

Introduction to libxklavier

The libxklavier package contains a utility library for X keyboard.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libxklavier Dependencies

Required

GLib-2.70.4, ISO Codes-4.9.0, libxml2-2.9.13 and Xorg Libraries

Recommended
Optional

GTK-Doc-1.33.2 and Vala-0.54.7

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libxklavier

Installation of libxklavier

Install libxklavier by running the following commands:

./configure --prefix=/usr --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: This parameter is normally used if GTK-Doc is installed and you wish to rebuild and install the API documentation. It is broken for this package due to the use of a long deprecated gtk-doc program that is no longer available.

Contents

Installed Programs: None
Installed Library: libxklavier.so
Installed Directories: /usr/include/libxklavier and /usr/share/gtk-doc/html/libxklavier

Short Descriptions

libxklavier.so

contains XKB utility functions

Last updated on

Pango-1.50.4

Introduction to Pango

Pango is a library for laying out and rendering text, with an emphasis on internationalization. It can be used anywhere that text layout is needed, though most of the work on Pango so far has been done in the context of the GTK+ widget toolkit.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Pango Dependencies

Required

Fontconfig-2.13.1 (must be built with FreeType-2.11.1 using HarfBuzz-3.4.0), FriBidi-1.0.11, and GLib-2.70.4

Recommended
Optional

Cantarell fonts (for tests), sysprof-3.42.1, gi-docgen (to generate documentation), help2man, and libthai

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pango

Installation of Pango

Install Pango by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release --wrap-mode=nofallback .. &&
ninja

To test the results, issue: ninja test. Two tests, test-font and test-layout are known to fail.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dintrospection=false: Use this switch if you do not want to use gobject-introspection-1.70.0.

--wrap-mode=nofallback: This switch prevents meson from using subproject fallbacks for any dependency declarations in the build files, stopping it downloading any optional dependency which is not installed on the system.

Configuring Pango

Config Files

/etc/pango/pangorc, ~/.pangorc and the file specified in the environment variable PANGO_RC_FILE

Contents

Installed Programs: pango-list, pango-segmentation, and pango-view
Installed Libraries: libpango-1.0.so, libpangocairo-1.0.so, libpangoft2-1.0.so, and libpangoxft-1.0.so
Installed Directories: /usr/include/pango-1.0

Short Descriptions

pango-list

displays a list of fonts that Pango can use that are currently installed on the system

pango-segmentation

shows text segmentation as determined by Pango.

pango-view

renders a given text file through Pango for viewing purposes

libpango-1.0.so

contains low level layout rendering routines, a high level driver for laying out entire blocks of text, and routines to assist in editing internationalized text

Last updated on

Pangomm-2.46.2

Introduction to Pangomm

The Pangomm package provides a C++ interface to Pango.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Pangomm Dependencies

Required

libcairomm-1.14.0, GLibmm-2.66.2 and Pango-1.50.4

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pangomm

Installation of Pangomm

Install Pangomm by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Contents

Installed Programs: None
Installed Library: libpangomm-1.4.so
Installed Directories: /usr/include/pangomm-1.4, /usr/lib/pangomm-1.4, and /usr/share/{devhelp/books/pangomm-1.4,doc/pangomm-2.46.2}

Short Descriptions

libpangomm-1.4.so

contains the Pango API classes

Last updated on

Qt-5.15.2

Introduction to Qt5

Qt5 is a cross-platform application framework that is widely used for developing application software with a graphical user interface (GUI) (in which cases Qt5 is classified as a widget toolkit), and also used for developing non-GUI programs such as command-line tools and consoles for servers. One of the major users of Qt is KDE Frameworks 5 (KF5).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Qt5 Dependencies

Required

Xorg Libraries

Recommended
Optional

BlueZ-5.63 (for sdpscanner, and at runtime for QtConnectivity module), ibus-1.5.25, libinput-1.19.3, MariaDB-10.6.7 or MySQL, pciutils-3.7.0, PostgreSQL-14.2, PulseAudio-15.0, SDL2-2.0.20, unixODBC-2.3.9, assimp, Flite, Firebird, FreeTDS, libproxy, OpenAL, speech-dispatcher, tslib, and Vulkan

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/qt5

Setting the installation prefix

Installing in /opt/qt5

The BLFS editors recommend installing Qt5 in a directory other than /usr, ie /opt/qt5. To do this, set the following environment variable:

export QT5PREFIX=/opt/qt5

Tip

Sometimes, the installation paths are hardcoded into installed files. This is the reason why /opt/qt5 is used as installation prefix instead of /opt/qt-5.15.2. To create a versioned Qt5 directory after the installation is complete, you may rename the directory and create a symlink:

mkdir -pv /opt/qt-5.15.2
ln -sfnv qt-5.15.2 /opt/qt5

Later on, you may want to install other versions of Qt5. To do that, just remove the symlink and use /opt/qt5 as the prefix again. Which version of Qt5 you use depends only on where the symlink points.

Note

If qca-2.3.4 has been installed and you are reinstalling or updating this package, then qca will need to be reinstalled.

Installation of Qt5

Warning

If Qt5 is being reinstalled into the same directory as an existing instance, run the commands done by root, such as make install, from a console or non-Qt5 based window manager. It overwrites Qt5 libraries that should not be in use during the install process.

Caution

If you did not install some of the recommended dependencies, examine ./configure --help output to check how to disable them or use internal versions bundled in the source tarball.

Note

The build time and space required for the full Qt5 is quite long. The instructions below do not build the tutorials and examples. Removing the -nomake line will create a complete build.

Note

The BLFS editors do not recommend installing Qt5 into the /usr hierarchy because it becomes difficult to find components and to update to a new version. If you do want to install Qt5 in /usr, the directories need to be specified explicitly. In this case, set QT5PREFIX=/usr and add the following to the configure arguments below:

            -archdatadir    /usr/lib/qt5                \
            -bindir         /usr/bin                    \
            -plugindir      /usr/lib/qt5/plugins        \
            -importdir      /usr/lib/qt5/imports        \
            -headerdir      /usr/include/qt5            \
            -datadir        /usr/share/qt5              \
            -docdir         /usr/share/doc/qt5          \
            -translationdir /usr/share/qt5/translations \
            -examplesdir    /usr/share/doc/qt5/examples

First apply a patch to pull in the fixes curated by kde for those modules which are required by packages mentioned in this book:

patch -Np1 -i ../qt-everywhere-src-5.15.2-kf5.15-2.patch

Install Qt5 by running the following commands:

./configure -prefix $QT5PREFIX                        \
            -sysconfdir /etc/xdg                      \
            -confirm-license                          \
            -opensource                               \
            -dbus-linked                              \
            -openssl-linked                           \
            -system-harfbuzz                          \
            -system-sqlite                            \
            -nomake examples                          \
            -no-rpath                                 \
            -syslog                                   \
            -skip qtwebengine                         &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Remove references to the build directory from installed library dependency (prl) files by running the following command as the root user:

find $QT5PREFIX/ -name \*.prl \
   -exec sed -i -e '/^QMAKE_PRL_BUILD_DIR/d' {} \;

Install images and create the menu entries for installed applications. The QT5BINDIR variable is used here to point to the directory for the executable programs. If you have changed the bindir above, QT5BINDIR will need to be adjusted below. Be sure that the QT5BINDIR variable is defined in root's environment and as the root user:

QT5BINDIR=$QT5PREFIX/bin

install -v -dm755 /usr/share/pixmaps/                  &&

install -v -Dm644 qttools/src/assistant/assistant/images/assistant-128.png \
                  /usr/share/pixmaps/assistant-qt5.png &&

install -v -Dm644 qttools/src/designer/src/designer/images/designer.png \
                  /usr/share/pixmaps/designer-qt5.png  &&

install -v -Dm644 qttools/src/linguist/linguist/images/icons/linguist-128-32.png \
                  /usr/share/pixmaps/linguist-qt5.png  &&

install -v -Dm644 qttools/src/qdbus/qdbusviewer/images/qdbusviewer-128.png \
                  /usr/share/pixmaps/qdbusviewer-qt5.png &&

install -dm755 /usr/share/applications &&

cat > /usr/share/applications/assistant-qt5.desktop << EOF
[Desktop Entry]
Name=Qt5 Assistant
Comment=Shows Qt5 documentation and examples
Exec=$QT5BINDIR/assistant
Icon=assistant-qt5.png
Terminal=false
Encoding=UTF-8
Type=Application
Categories=Qt;Development;Documentation;
EOF

cat > /usr/share/applications/designer-qt5.desktop << EOF
[Desktop Entry]
Name=Qt5 Designer
GenericName=Interface Designer
Comment=Design GUIs for Qt5 applications
Exec=$QT5BINDIR/designer
Icon=designer-qt5.png
MimeType=application/x-designer;
Terminal=false
Encoding=UTF-8
Type=Application
Categories=Qt;Development;
EOF

cat > /usr/share/applications/linguist-qt5.desktop << EOF
[Desktop Entry]
Name=Qt5 Linguist
Comment=Add translations to Qt5 applications
Exec=$QT5BINDIR/linguist
Icon=linguist-qt5.png
MimeType=text/vnd.trolltech.linguist;application/x-linguist;
Terminal=false
Encoding=UTF-8
Type=Application
Categories=Qt;Development;
EOF

cat > /usr/share/applications/qdbusviewer-qt5.desktop << EOF
[Desktop Entry]
Name=Qt5 QDbusViewer
GenericName=D-Bus Debugger
Comment=Debug D-Bus applications
Exec=$QT5BINDIR/qdbusviewer
Icon=qdbusviewer-qt5.png
Terminal=false
Encoding=UTF-8
Type=Application
Categories=Qt;Development;Debugger;
EOF

Some packages such as VLC-3.0.16 look for certain executables with a -qt5 suffix. Run the following command as the root user to create the necessary symlinks:

for file in moc uic rcc qmake lconvert lrelease lupdate; do
  ln -sfrvn $QT5BINDIR/$file /usr/bin/$file-qt5
done

Command Explanations

sed ...: Allows using Python 3 instead of Python 2. This command destroys the build for QtWebEngine, so do not use it if you remove the -skip qtwebengine switch.

-confirm-license: Accept license without prompting user during configuration.

-opensource: Install the opensource version of Qt.

-nomake examples: This switch disables building of the example programs included in the source tarball. Remove it if you want to build them.

-system-sqlite: This switch enables use of the system version of SQLite.

-dbus-linked -openssl-linked: These switches enable explicit linking of the D-Bus and OpenSSL libraries into Qt5 libraries instead of dlopen()-ing them.

-syslog: This switch allows to send Qt messages to the syslog logging system.

-skip qtwebengine: This switch disables building the QtWebEngine. The BLFS editors have chosen to build qtwebengine-5.15.8 separately.

-system-harfbuzz: This switch enables use of the system version of Harfbuzz.

Configuring Qt5

If you installed Qt5 in /usr

If you installed Qt5 in /usr, create an environment variable needed by certain packages. As the root user:

cat > /etc/profile.d/qt5.sh << "EOF"
# Begin /etc/profile.d/qt5.sh

QT5DIR=/usr
export QT5DIR
pathappend $QT5DIR/bin

# End /etc/profile.d/qt5.sh
EOF

If Sudo-1.9.9 is installed, QT5DIR should be available to the super user as well. Execute the following commands as the root user:

cat > /etc/sudoers.d/qt << "EOF"
Defaults env_keep += QT5DIR
EOF
If you did not install Qt5 in /usr

If you installed Qt5 in a location other than /usr, you need to update the following configuration files so that Qt5 is correctly found by other packages and system processes.

As the root user, update the /etc/ld.so.conf file and the dynamic linker's run-time cache file:

cat >> /etc/ld.so.conf << EOF
# Begin Qt addition

/opt/qt5/lib

# End Qt addition
EOF

ldconfig

As the root user, create the /etc/profile.d/qt5.sh file:

cat > /etc/profile.d/qt5.sh << "EOF"
# Begin /etc/profile.d/qt5.sh

QT5DIR=/opt/qt5

pathappend $QT5DIR/bin           PATH
pathappend $QT5DIR/lib/pkgconfig PKG_CONFIG_PATH

export QT5DIR

# End /etc/profile.d/qt5.sh
EOF

Contents

Installed Programs: assistant, balsam, canbusutil, designer, fixqt4headers.pl, lconvert, linguist, lprodump, lrelease, lrelease-pro, lupdate, lupdate-pro, meshdebug, moc, pixeltool, qcollectiongenerator, qdbus, qdbuscpp2xml, qdbusviewer, qdbusxml2cpp, qdistancefieldgenerator, qdoc, qgltf, qhelpgenerator, qlalr, qmake, qml, qmlcachegen, qmleasing, qmlformat, qmlimportscanner, qmllint, qmlmin, qmlplugindump, qmlpreview, qmlprofiler, qmlscene, qmltestrunner, qscxmlc, qtattributionscanner, qtdiag, qtpaths, qtplugininfo, qtwaylandscanner, qvkgen, rcc, repc, sdpscanner, syncqt.pl, tracegen, uic, xmlpatterns, and xmlpatternsvalidator
Installed Libraries: libQt53DAnimation.so, libQt53DCore.so, libQt53DExtras.so, libQt53DInput.so, libQt53DLogic.so, libQt53DQuick.so, libQt53DQuickAnimation.so, libQt53DQuickExtras.so, libQt53DQuickInput.so, libQt53DQuickRender.so, libQt53DQuickScene2D.so, libQt53DRender.so, libQt5AccessibilitySupport.a, libQt5Bluetooth.so, libQt5Bodymovin.so, libQt5Bootstrap.a, libQt5Charts.so, libQt5Concurrent.so, libQt5Core.so, libQt5DataVisualization.so, libQt5DBus.so, libQt5DesignerComponents.so, libQt5Designer.so, libQt5DeviceDiscoverySupport.a, libQt5EdidSupport.a, libQt5EglFSDeviceIntegration.so, libQt5EglFsKmsSupport.so, libQt5EglSupport.a, libQt5EventDispatcherSupport.a, libQt5FbSupport.a, libQt5FontDatabaseSupport.a, libQt5Gamepad.so, libQt5GlxSupport.a, libQt5Gui.so,libQt5Help.so, libQt5InputSupport.a, libQt5KmsSupport.a, libQt5LinuxAccessibilitySupport.a, libQt5Location.so, libQt5Multimedia.so, libQt5MultimediaGstTools.so, libQt5MultimediaQuick.so, libQt5MultimediaWidgets.so, libQt5Network.so, libQt5NetworkAuth.so, libQt5Nfc.so, libQt5OpenGLExtensions.a, libQt5OpenGL.so, libQt5PacketProtocol.a, libQt5PlatformCompositorSupport.a, libQt5Positioning.so, libQt5PositioningQuick.so, libQt5PrintSupport.so, libQt5Purchasing.so, libQt5Qml.so, libQt5QmlDebug.a, libQt5QmlDevTools.a, libQt5QmlModels.so, libQt5QmlWorkerScript.so, libQt5Quick.so, libQt5Quick3D.so, libQt5Quick3DAssetImport.so, libQt5Quick3DRender.so, libQt5Quick3DRuntimeRender.so, libQt5Quick3DUtils.so, libQt5QuickControls2.so, libQt5QuickParticles.so, libQt5QuickShapes.so, libQt5QuickTemplates2.so, libQt5QuickTest.so, libQt5QuickWidgets.so, libQt5RemoteObjects.so, libQt5Script.so, libQt5ScriptTools.so, libQt5Scxml.so, libQt5Sensors.so, libQt5SerialBus.so, libQt5SerialPort.so, libQt5ServiceSupport.a, libQt5Sql.so, libQt5Svg.so, libQt5Test.so, libQt5TextToSpeech.so, libQt5ThemeSupport.a, libQt5UiTools.a, libQt5VirtualKeyboard.so, libQt5WaylandClient.so, libQt5WaylandCompositor.so, libQt5WebChannel.so, libQt5WebSockets.so, libQt5WebView.so, libQt5Widgets.so, libQt5X11Extras.so, libQt5XcbQpa.so, libQt5XkbCommonSupport.a, libQt5Xml.so, libQt5XmlPatterns.so, and several plugins under /opt/qt5/{plugins,qml}
Installed Directories: /usr/include/qt5, /usr/lib/qt5, /usr/share/doc/qt5, and /usr/share/qt5 OR /opt/qt5 and /opt/qt-5.15.2

Short Descriptions

assistant

is a tool for presenting on-line documentation

balsam

is a tool to convert 3D scenes from various creation tools to QML format, for use by the new QtQuick 3D library

canbustil

is a tool to deal with arbitrary CAN bus frames. A Controller Area Network (CAN) is a vehicle bus standard designed to allow microcontrollers and devices to communicate with each other in applications without a host computer

designer

is a full-fledged GUI builder. It includes powerful features such as preview mode, automatic widget layout, support for custom widgets, and an advanced property editor

fixqt4headers.pl

is a script to replace all Qt 4 style includes with Qt 5 includes

lconvert

is part of Qt5's Linguist tool chain. It can be used as a standalone tool to convert and filter translation data files

linguist

provides support for translating applications into local languages

lrelease

is a simple command line tool. It reads XML-based translation file in TS format and produces message files used by the application

lrelease-pro

extracts project information from qmake projects and passes it to lrelease

lupdate

finds the translatable strings in the specified source, header and Qt Designer interface files, and stores the extracted messages in translation files to be processed by lrelease

lupdate-pro

reads a Qt project file, an passes the collected information to lupdate

meshdebug

displays information about qtquick-3d mesh files

moc

generates Qt meta object support code

pixeltool

is a desktop magnifier and as you move your mouse around the screen it will show the magnified contents in its window

qcollectiongenerator

processes and converts Qt help files

qdbuscpp2xml

takes a C++ source file and generates a D-Bus XML definition of the interface

qdbus

lists available services, object paths, methods, signals, and properties of objects on a bus

qdbusviewer

is a graphical D-Bus browser

qdbusxml2cpp

is a tool that can be used to parse interface descriptions and produce static code representing those interfaces,

qdistancefieldgenerator

allows a font cache to be pregenerated for Text.QtRendering to speed up an application's startup if the user interface has a lot of text, or multiple fonts, or a large amount of distinct characters, e.g. in CJK writing systems

qdoc

is a tool used by Qt Developers to generate documentation for software projects

qgltf

imports a a variety of 3D model formats and exports into fast-to-load, optimized glTF assets embedded into Qt resource files

qhelpgenerator

is a tool used to generate a Qt compressed help file

qlalr

is a tool used to generate code from grammar specifications

qmake

uses information stored in project files to determine what should go in the makefiles it generates

qml

executes a QML file

qmlcachegen

supports the creation of cache files at build time

qmleasing

is a tool used to define the easing curves using an interactive curve editor

qmlformat

formats QML files according to the QML coding conventions

qmlimportscanner

is a tool used to import QML files from a directory

qmllint

is a syntax checker for QML files

qmlmin

removes comments and layout characters from a QML file

qmlplugindump

is a tool to create a qmltypes file

qmlpreview

is a tool used to analyze QML applications

qmlprofiler

is a tool which watches QML and JavaScript files on disk and updates the application live with any changes

qmlscene

is a utility that loads and displays QML documents even before the application is complete

qmltestrunner

is a tool used to make tests

qscxml

converts an input.scxml file to a header and cpp file

qtattributionsscanner

processes qt_attribution.json files in Qt sources

qtdiag

is a tool for reporting diagnostic information about Qt and its environment

qtpaths

is a tool to query Qt path information

qtplugininfo

dumps meta-data about Qt plugins in JSON format

qtwaylandscanner

converts Wayland specfiles to C++ headers and code needed for QtWayland

qvkgen

converts Vulkan specfiles to C++ headers and code

rcc

is a resource compiler used in conjunction with designer

repc

is the Replica Compiler, which generates QObject header files based on an API definition file

sdpscanner

performs a Session Description Protocol scan on a remote device, using the SDP server represented by the local Bluetooth device

syncqt.pl

is a script to create the forwarding headers in the include directories. It is an internal development tool

tracegen

is a trace generator for LTTng or ETW

uic

is a Qt user interface compiler

xmlpatterns

provides support for XPath, XQuery, XSLT, and XML Schema validation

xmlpatternsvalidator

is a tool used to validate XML documents

Last updated on

QtWebEngine-5.15.8

Introduction to QtWebEngine

QtWebEngine integrates chromium's web capabilities into Qt. It ships with its own copy of ninja which it uses for the build if it cannot find a system copy, and various copies of libraries from ffmpeg, icu, libvpx, and zlib (including libminizip) which have been forked by the chromium developers.

This package and browsers using it may be useful if you need to use a website designed for google chrome, or chromium, browsers.

Warning

QtWebEngine uses a forked copy of chromium, and is therefore vulnerable to many issues found there. The Qt developers have always preferred to make releases at the same time as the rest of Qt (rather than adding emergency fixes), but with stable versions getting released after the current development version. Now that they are keen to move to Qt6, the 5.15.3 and later Qt-5.15 releases are initially only available to paying customers. QtWebEngine is something of an exception because of its LGPL licence, but getting the git sources (with the forked chromium submodule) to a position where they will successfully build on a current BLFS system can take a lot of effort and therefore updates to the book may be delayed.

It seems likely that future 5.15-series versions will also be released long after the chromium vulnerabilities are known, but fixes for QtWebEngine can be found in git and the editors take the view that known vulnerabilities in browsers should be fixed.

The tarball linked to below was created from the 5.15 git branch and the 87-branch of the chromium submodule (which is forked from chromium). See the GIT-VERSIONS file in the tarball (after applying any patches) for details of the latest commits.

This package is known to build and work properly using an LFS-11.1 platform.

Warning

By default, ninja will use all online CPUs +2 (if at least 4 exist), even if they are not available to the current task because the build terminal has been restricted with 'taskset'. In BLFS, this package takes more time to build than than any other. In one example, the build of this package crashed at about the 90 percent point due to an out of memory problem on a system with 24 cores and 32 GB of memory.

To work around this, see the Command Explanations below.

Note

If you are upgrading and have installed a newer version of ICU-70.1 since you last installed Qt-5.15.2, you will need to reinstall Qt5 before upgrading, otherwise the final link of this package will fail with a warning that the version of icu libraries needed by libQt5Core.so may conflict with the version used for this package.

Unusually, the shipped GN build system (used to create the Ninja files) requires a static libstdc++.a although the installed libraries correctly use the shared version. If that static library is not present, the build will fail quite quickly. Please note that if you try to build webengine as part of Qt and the static library is not available, that build will either complete without installing webengine, or else fail during the install (both variants were observed in 5.12.0).

Package Information

Additional Downloads

qtwebengine Dependencies

Required

nodejs-16.14.0, nss-3.75, pciutils-3.7.0, Python-2.7.18, and Qt-5.15.2

Recommended

Note

If these packages are not installed, the build process will compile and install its own (perhaps older) version, with the side effect of increasing build and installed disk space and build time.

Optional

libevent-2.1.12, MIT Kerberos V5-1.19.2, pipewire-0.3.47, Poppler-22.02.0, jsoncpp, libsrtp, snappy

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/qtwebengine

Installation of qtwebengine

Note

Unlike version 5.15.2, the chromium-derived build system now needs python to be available and to be python2. In BLFS-10.1 the creation of the python symlink was removed as a step towards eventually getting rid of python2 (other old packages which need python2 usually work by invoking python2). If you are still using an earlier version of BLFS where /usr/bin/python exists, you can skip the commands to create the symlink, and to later remove it.

First, as the root user, create the python symlink:

ln -svf /usr/bin/python{2,}

Apply apply a patch to fix several issues that can prevent the build working:

patch -Np1 -i ../qtwebengine-5.15.8-build_fixes-1.patch

Although the build_fixes patch has ensured that git is not invoked during the build, the build system has labyrinthine rules of byzantine complexity, and in particular trying to build without two .git directories will lead to it eventually falling into unexpected and unbuildable code which references a private header that has not been created. Avoid this by creating the required directories:

mkdir -pv .git src/3rdparty/chromium/.git

Because this version of qtwebengine is aimed at a later release than the current public releases, change it to build for qt-5.15.2 using a sed:

sed -e '/^MODULE_VERSION/s/5.*/5.15.2/' -i .qmake.conf

Now, ensure that the local headers are available when not building as part of the complete Qt-5.15.2:

find -type f -name "*.pr[io]" |
  xargs sed -i -e 's|INCLUDEPATH += |&$$QTWEBENGINE_ROOT/include |'

Next, allow the pulseaudio library to be linked at build time, instead of run time. This also prevents an issue with newer pulseaudio:

sed -e '/link_pulseaudio/s/false/true/' \
    -i src/3rdparty/chromium/media/media_options.gni

Finally, fix a change in the build system which allows its developers to pass e.g. -j20 to make (for quick tests of some areas) but breaks the build with LFS's use of the NINJAJOBS environment variable:

sed -i 's/NINJAJOBS/NINJA_JOBS/' src/core/gn_run.pro

Install qtwebengine by running the following commands:

mkdir build &&
cd    build &&
qmake .. -- -system-ffmpeg -webengine-icu &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Remove references to the build directory from installed library dependency (prl) files by running the following commands as the root user:

find $QT5DIR/ -name \*.prl \
   -exec sed -i -e '/^QMAKE_PRL_BUILD_DIR/d' {} \;

Finally, as the root user, remove the python symlink:

rm -v /usr/bin/python

Command Explanations

qmake: This will build the included copy of ninja if it is not already installed and use it to configure the build.

-- -system-ffmpeg -webengine-icu: If any options are passed to qmake they must come after '--' which must follow '..' that points to the main directory. The options here cause it to use system ffmpeg and system icu. If built as part of full Qt5, the system icu is automatically used (only) by Qt5Core if it is available, but unless this option is used webengine will always use its shipped copy of icu, adding time and space to the build.

-webengine-jumbo-build 0: If this is added to the qmake command it will cause the 'Jumbo Build Merge Limit' to be reported as 'no' instead of 8. That turns off the jumbo build. Some distros do that to get a smaller build on some architectures such as MIPS. On x86_64 it might save a little space in the build, but the build time will increase by a very large amount.

-webengine-kerberos: Add this if you have installed MIT Kerberos V5-1.19.2 and wish to connect from a browser using QtWebEngine to a webserver which requires you to connect via kerberos.

NINJAJOBS=4 make: If you patched system ninja in LFS to recognize the NINJAJOBS environment variable, this command will run system ninja with the specified number of jobs (i.e. 4). There are several reasons why you might want to use options like this this:

  • Building on a subset of CPUs allows measuring the build time for a smaller number of processors, and/or running other CPU-intensive tasks at the same time. For an editor on a machine with a lot of CPUs, trying to measure the build time for a 4-CPU machine, NINJAJOBS=4 make will give a reasonable approximation (there is a short period where N+2 python2 and node jobs run).

  • On a machine with only 4 CPUs online, the default of scheduling N+2 jobs for qtwebengine is slower by between 3% and 7%, probably because of the size of the C++ files and their many includes and templates. Therefore, if in doubt set NINJAJOBS to the number of CPUs.

  • Reducing the number of cores being used on long running, CPU intensive packages may alleviate heat problems.

  • Reducing the number of cores will prevent potential out-of-memory problems on systems that do not have enough memory (or swap) when all cores are active. A suggested approach is to limit the number of cores to about one core for each 1.5 GB of combined RAM and swap space.

Configuring QtWebEngine

Configuration Information

If you are upgrading from an older minor version of this application, for some webpages to load you may need to clear the browser caches, e.g. for falkon they will be found in ~/.cache/falkon/. You will need to do this if the browser starts to render the page and then changes to a blank tab with a message that something went wrong, and a button to Retry. Even after removing the old caches, you may need to retry a few times for each affected tab.

If a browser using this package fails to run and when run from a term it reports 'Trace/breakpoint trap' that is probably a kernel configuration issue - there is no need to rebuild QtWebEngine, see the next section, recompile the kernel and reboot to the new kernel.

Kernel Configuration

This package does not require any of the optional kernel namespace items, but if User namespace is enabled PID namespace must also be enabled. In that case enable the following options in the kernel configuration and recompile the kernel if necessary:

General setup --->
  -*- Namespaces support --->
    [ ]     User namespace                    [CONFIG_USER_NS]
    [*]     PID namespace                     [CONFIG_PID_NS]

Contents

Installed Programs: qtwebengine_convert_dict and QtWebEngineProcess (in $QT5DIR/libexec)
Installed Libraries: libQt5Pdf.so, libQt5PdfWidgets.so, libQt5WebEngineCore.so, libQt5WebEngine.so, and libQt5WebEngineWidgets.so
Installed Directories: $QT5DIR/include/QtPdf, $QT5DIR/include/QtPdfWidgets, $QT5DIR/include/QtWebEngine, $QT5DIR/include/QtWebEngineCore, $QT5DIR/include/QtWebEngineWidgets, $QT5DIR/qml/QtWebEngine, and $QT5DIR/translations/qtwebengine_locales

Short Descriptions

qtwebengine_convert_dict

converts hunspell dictionaries (.dic) to chromium format (.bdic)

QtWebEngineProcess

is a libexec program which runs a zygote process (one that listens for spawn requests from a master process and will fork itself in response)

libQtWebEngine.so

provides QML types for rendering web content within a QML application

libQtWebEngineCore.so

provides public API shared by both QtWebEngine and QtWebEngineWidgets

libQtWebEngineWidgets.so

provides a web browser engine as well as C++ classes to render and interact with web content

Last updated on

startup-notification-0.12

Introduction to startup-notification

The startup-notification package contains startup-notification libraries. These are useful for building a consistent manner to notify the user through the cursor that the application is loading.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

startup-notification Dependencies

Required

Xorg Libraries and xcb-util-0.4.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/startup-notification

Installation of startup-notification

Install startup-notification by running the following commands:

./configure --prefix=/usr --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&
install -v -m644 -D doc/startup-notification.txt \
    /usr/share/doc/startup-notification-0.12/startup-notification.txt

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Library: libstartup-notification-1.so
Installed Directories: /usr/include/startup-notification-1.0 and /usr/share/doc/startup-notification-0.12

Short Descriptions

libstartup-notification-1.so

provides the functions to assist applications in communicating with the cursor system to provide feedback to the user that the application is loading

Last updated on

Tepl-6.00.0

Introduction to Tepl

The Tepl package contains a library that eases the development of GtkSourceView-based text editors and IDEs.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Tepl Dependencies

Required

amtk-5.2.0, gtksourceview4-4.8.2, ICU-70.1, and uchardet-0.0.7

Optional

GTK-Doc-1.33.2 (for documentation) and Valgrind-3.18.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/tepl

Installation of Tepl

Install Tepl by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

-Dgtk_doc=true: Use this option if GTK-Doc is installed and you wish to build and install the API documentation.

Contents

Installed Programs: None
Installed Libraries: libtepl-6.so
Installed Directories: /usr/include/tepl-6 and /usr/share/gtk-doc/html/tepl-6.0

Short Descriptions

libtepl-5.so

contains convenience functions for GtkSourceView4-based programs

Last updated on

WebKitGTK-2.34.6

Introduction to WebKitGTK

The WebKitGTK package is a port of the portable web rendering engine WebKit to the GTK+ 3 and GTK+ 2 platforms.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://webkitgtk.org/releases/webkitgtk-2.34.6.tar.xz

  • Download MD5 sum: a5eeedd02f5b4bba8bd891b92dc743d4

  • Download size: 23 MB

  • Estimated disk space required: 933 MB (130 MB installed)

  • Estimated build time: 37 SBU (using parallelism=4, estimated 107 SBU using one core)

WebKitGTK Dependencies

Required

Cairo-1.17.4, CMake-3.22.2, gst-plugins-base-1.20.0, gst-plugins-bad-1.20.0, GTK+-3.24.31, ICU-70.1, Little CMS-2.13.1, libgudev-237, libsecret-0.20.5, libsoup-2.74.2, libtasn1-4.18.0, libwebp-1.2.2, Mesa-21.3.6, OpenJPEG-2.4.0, Ruby-3.1.0, SQLite-3.37.2, Which-2.21, and wpebackend-fdo-1.12.0

Recommended
Optional

bubblewrap-0.5.0, GTK-Doc-1.33.2, GTK-4.6.1, HarfBuzz-3.4.0, Wayland-1.20.0, WOFF2-1.0.2, ccache, Hyphen, libavif, libmanette, and xdg-dbus-proxy

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/webkitgtk

Installation of WebKitGTK

Installation of WebKitGTK

Install WebKitGTK by running the following commands:

mkdir -vp build &&
cd        build &&

cmake -DCMAKE_BUILD_TYPE=Release  \
      -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_SKIP_RPATH=ON       \
      -DPORT=GTK                  \
      -DLIB_INSTALL_DIR=/usr/lib  \
      -DUSE_LIBHYPHEN=OFF         \
      -DENABLE_GAMEPAD=OFF        \
      -DENABLE_MINIBROWSER=ON     \
      -DUSE_WOFF2=OFF             \
      -DUSE_SOUP2=ON              \
      -DUSE_WPE_RENDERER=ON       \
      -DUSE_SYSTEMD=OFF           \
      -DENABLE_BUBBLEWRAP_SANDBOX=OFF \
      -Wno-dev -G Ninja ..        &&
ninja

This package does not have a working testsuite. However, there is a usable basic graphical web browser in the build directory, build/bin/MiniBrowser. If launching it fails, there is a problem with the build.

Now, as the root user:

ninja install &&

install -vdm755 /usr/share/gtk-doc/html/webkit{2,dom}gtk-4.0 &&
install -vm644  ../Documentation/webkit2gtk-4.0/html/*   \
                /usr/share/gtk-doc/html/webkit2gtk-4.0       &&
install -vm644  ../Documentation/webkitdomgtk-4.0/html/* \
                /usr/share/gtk-doc/html/webkitdomgtk-4.0

Command Explanations

-DUSE_LIBHYPHEN=OFF: This switch disables the default automatic hyphenation implementation. You need to install Hyphen if you wish to enable it (replacing OFF with ON or just removing the switch).

-DENABLE_GAMEPAD=OFF: This switch disables gamepad support. Remove this switch if you have libmanette installed and wish to enable it.

-DENABLE_MINIBROWSER=ON: This switch enables compiling and installing the MiniBrowser.

-DUSE_WPE_RENDERER=ON: This switch uses the WPE renderer, which is recommended by upstream.

-DENABLE_BUBBLEWRAP_SANDBOX=OFF: Remove this switch if the optional packages bubblewrap-0.5.0 and xdg-dbus-proxy are installed.

-DUSE_SYSTEMD=OFF: This switch disables using the systemd journal for logging errors and debugging information since it is not available on SysV systems.

-DUSE_LIBNOTIFY=OFF: Use this switch if you do not have libnotify installed.

-DUSE_SYSTEM_MALLOC=ON: This switch enables building against the system installed malloc.

-DENABLE_GEOLOCATION=OFF: Use this switch if you don't want to install GeoClue-2.6.0.

-DENABLE_GTKDOC=ON: Use this switch if GTK-Doc-1.33.2 is installed and you wish to rebuild and install the API documentation.

-DUSE_WOFF2=ON: Use this switch if the optional package WOFF2-1.0.2 is installed. This adds additional support for fonts.

Contents

Installed Program: WebKitWebDriver
Installed Libraries: libjavascriptcoregtk-4.0.so and libwebkit2gtk-4.0.so
Installed Directories: /usr/include/webkitgtk-4.0, /usr/lib{,exec}/webkit2gtk-4.0, and /usr/share/gtk-doc/html/webkit{2,dom}gtk-4.0

Short Descriptions

WebKitWebDriver

allows debugging and automation of web pages and browsers

libjavascriptcoregtk-4.0.so

contains core JavaScript API functions used by jsc and libwebkit2gtk-4.0

libwebkit2gtk-4.0.so

contains the WebKit2 API functions

Last updated on

Chapter 26. Display Managers

Display Managers are graphical programs used for starting the graphical display (currently, the X server) and providing a login capability for a Window Manager or Desktop Environment.

There are many Display Managers available. Some of the more well known include: GDM, KDM (deprecated), LightDM, LXDM, Slim, and SDDM.

Among the Desktop Environments available for Linux you find: Enlightenment, GNOME, KDE, LXDE, LXQt, and XFce.

Choosing a Display Manager or Desktop Environment is highly subjective. The choice depends on the look and feel of the packages, the resources (memory and disk space) required, and the utilities included.

In this chapter, the installation instructions of some Display Managers are presented. Later in the book, you will find other ones, which are provided as part of some Desktop Environments.

lightdm-1.30.0

Introduction to Lightdm

The lightdm package contains a lightweight display manager based upon GTK.

This package is known to build and work properly using an LFS-11.1 platform.

Lightdm Package Information

Additional download

Note

The greeter is a program to present a graphical login screen. There are several alternative greeters, but the gtk+ package is the reference implementation. For a list of other greeters, see https://en.wikipedia.org/wiki/LightDM.

Lightdm Dependencies

Required

Exo-4.16.3 (for the greeter), libgcrypt-1.10.0, itstool-2.0.7, and Linux-PAM-1.5.2

Recommended
Optional

AccountsService-22.07.5 (run time), at-spi2-core-2.42.0, GTK-Doc-1.33.2, Qt-5.15.2, libido, and libindicator

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lightdm

Installation of Lightdm

First, create a dedicated user and group to take control of the lightdm daemon after it is started. Issue the following commands as the root user:

groupadd -g 65 lightdm       &&
useradd  -c "Lightdm Daemon" \
         -d /var/lib/lightdm \
         -u 65 -g lightdm    \
         -s /bin/false lightdm

Then change the Linux-PAM configuration files so that elogind is used:

sed -i s/systemd/elogind/ data/pam/*

Install lightdm by running the following commands:

./configure                          \
       --prefix=/usr                 \
       --libexecdir=/usr/lib/lightdm \
       --localstatedir=/var          \
       --sbindir=/usr/bin            \
       --sysconfdir=/etc             \
       --disable-static              \
       --disable-tests               \
       --with-greeter-user=lightdm   \
       --with-greeter-session=lightdm-gtk-greeter \
       --docdir=/usr/share/doc/lightdm-1.30.0 &&
make

This package does not come with a test suite.

Now, as the root user:

make install                                                  &&
cp tests/src/lightdm-session /usr/bin                         &&
sed -i '1 s/sh/bash --login/' /usr/bin/lightdm-session        &&
rm -rf /etc/init                                              &&
install -v -dm755 -o lightdm -g lightdm /var/lib/lightdm      &&
install -v -dm755 -o lightdm -g lightdm /var/lib/lightdm-data &&
install -v -dm755 -o lightdm -g lightdm /var/cache/lightdm    &&
install -v -dm770 -o lightdm -g lightdm /var/log/lightdm

Now build the greeter:

tar -xf ../lightdm-gtk-greeter-2.0.8.tar.gz &&
cd lightdm-gtk-greeter-2.0.8 &&

./configure                      \
   --prefix=/usr                 \
   --libexecdir=/usr/lib/lightdm \
   --sbindir=/usr/bin            \
   --sysconfdir=/etc             \
   --with-libxklavier            \
   --enable-kill-on-sigterm      \
   --disable-libido              \
   --disable-libindicator        \
   --disable-static              \
   --disable-maintainer-mode     \
   --docdir=/usr/share/doc/lightdm-gtk-greeter-2.0.8 &&

make

Now, as the root user:

make install

Note

If you installed Xorg in /opt, you will need to create a symbolic link so lightdm can find the Xorg server. As the root user:

ln -sf /opt/xorg/bin/Xorg /usr/bin/X

Command Explanations

sed ... /usr/bin/lightdm-session: This command ensures that the initial login via the greeter sources /etc/profile and ~/.bash_profile. Without this, commands that depend on different environment variables may not work as expected.

Configuring lightdm

Config Files

/etc/lightdm/{lightdm,users,keys}.conf

Boot Script

To start lightdm automatically when the system is switched to runlevel 5, install the /etc/rc.d/init.d/xdm script and the /etc/sysconfig/xdm configuration file included in the blfs-bootscripts-20210826 package and adjust /etc/inittab by running as the root user:

make install-lightdm

Starting lightdm

The lightdm greeter can be started from the command line as the root user:

telinit 5

Alternatively the runlevel can be permanently set to 5, starting the lightdm greeter screen automatically, by modifying /etc/inittab. As the root user:

cp -v /etc/inittab{,-orig} &&
sed -i '/initdefault/ s/3/5/' /etc/inittab

Available Sessions

The greeter offers a list of available sessions, depending on the Window Managers and Desktop Environments installed. The list includes sessions which have a corresponding .desktop file installed under /usr/share/xsessions. Most of the Window Managers and Desktop Environments automatically provide those files, but if necessary, you may include a custom one.

Contents

Installed Programs: dm-tool, lightdm, and lightdm-gtk-greeter
Installed Libraries: liblightdm-gobject-1.so
Installed Directories: /etc/lightdm, /etc/apparmor.d, /usr/lib/lightdm, /usr/include/lightdm-gobject-1, /usr/share/help/C/lightdm /usr/share/gtk-doc/html/lightdm-gobject-1, /usr/share/doc/lightdm-gtk-greeter-2.0.8, /var/lib/lightdm, /var/lib/lightdm-data, /var/cache/lightdm, and /var/log/lightdm

Short Descriptions

lightdm

is a display and login manager

lightdm-gtk-greeter

is an auxiliary process that displays the greeter, a graphical user interface that performs user authentication and initiates the selected window manager or display environment

Last updated on

lxdm-0.5.3

Introduction to LXDM

The LXDM is a lightweight Display Manager for the LXDE desktop. It can also be used as an alternative to other Display Managers such as GNOME's GDM or LightDM.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

LXDM Dependencies

Required

GTK+-2.24.33, ISO Codes-4.9.0, and librsvg-2.52.6 (runtime, for default theme background)

Recommended
Optional

GTK+-3.24.31

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lxdm

Installation of LXDM

First, some fixes.

cat > pam/lxdm << "EOF"
# Begin /etc/pam.d/lxdm

auth     requisite      pam_nologin.so
auth     required       pam_env.so
auth     required       pam_succeed_if.so uid >= 1000 quiet
auth     include        system-auth

account  include        system-account

password include        system-password

session  required       pam_limits.so
session  include        system-session

# End /etc/pam.d/lxdm
EOF

sed -i 's:sysconfig/i18n:profile.d/i18n.sh:g' data/lxdm.in &&
sed -i 's:/etc/xprofile:/etc/profile:g' data/Xsession &&
sed -e 's/^bg/#&/'        \
    -e '/reset=1/ s/# //' \
    -e 's/logou$/logout/' \
    -e "/arg=/a arg=$XORG_PREFIX/bin/X" \
    -i data/lxdm.conf.in

Install LXDM by running the following commands:

./configure --prefix=/usr     \
            --sysconfdir=/etc \
            --with-pam        \
            --with-systemdsystemunitdir=no &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

cat > pam/lxdm << "EOF" ...: Replace default /etc/pam.d/lxdm by another one appropriate for BLFS.

sed -i ... data/lxdm.conf.in: Modifications in the default configuration: (1) fix the background to the default one; (2) restart X when session is close; (3) typo; and (4) include XORG_PREFIX, which may be different from /usr.

sed -i ... data/Xsession: Source /etc/profile, instead of other file, according to BLFS standard.

sed -i ... data/lxdm.in: Fix greeter's locale for BLFS specification.

--with-pam: This parameter enables use of pam authentication.

--with-systemdsystemunitdir=no: BLFS does not support systemd.

Configuring LXDM

Config Files

/etc/lxdm/lxdm.conf

Boot Script

To start lxdm automatically when the system is switched to runlevel 5, install the /etc/rc.d/init.d/xdm script and the /etc/sysconfig/xdm configuration file included in the blfs-bootscripts-20210826 package and adjust /etc/inittab by running as the root user:

make install-lxdm

Configuration Information

The LXDM daemon configuration file (/etc/lxdm/lxdm.conf) specifies options that include numlock on/off, background image (bg), session, etc. You can set a default session by uncommenting the line: session=/usr/bin/startlxde and replacing startlxde with your session of choice. For GNOME session=/usr/bin/gnome-session. For OPENBOX session=/usr/bin/openbox-session and for XFCE session=/usr/bin/startxfce4.

It is also possible to set the preferred session on a per-user basis by editing the ~/.dmrc file for each user and adding:

[Desktop]
        Session=xfce

You can replace the default dummy face in the greeting screen by another image representing your user. For that, copy or symlink the desired image to your home directory with the name .face.

Starting lxdm

The lxdm greeter can be started from the command line as the root user:

telinit 5

Alternatively the runlevel can be permanently set to 5, starting the lxdm greeter screen automatically, by modifying /etc/inittab. As the root user:

cp -v /etc/inittab{,-orig} &&
sed -i '/initdefault/ s/3/5/' /etc/inittab

Note

One important script, executed after login is /etc/lxdm/Xsession which we have fixed to fit BLFS specifications.

Contents

Installed Programs: lxdm, lxdm-binary and lxdm-config
Installed Libraries: None
Installed Directories: /etc/lxdm and /usr/share/lxdm

Short Descriptions

lxdm

is a script to execute lxdm-binary

lxdm-binary

is the actual Display Manager; needs to be executed with option -d to daemonize

lxdm-config

is a graphical customizing program

Last updated on

Chapter 27. Window Managers

Window Managers and Desktop Environments are the primary user interfaces into the X Window System. A window manager is a program that controls the appearance of windows and provides the means by which the user can interact with them. A Desktop Environment provides a more complete interface to the operating system, and provides a range of integrated utilities and applications.

There are many Window Managers available. Some of the more well known ones include fvwm2, Window Maker, AfterStep, Enlightenment, Sawfish, and Blackbox.

The Desktop Environments available for Linux are GNOME, KDE, and XFce.

Choosing a Window Manager or Desktop Environment is highly subjective. The choice depends on the look and feel of the packages, the resources (RAM, disk space) required, and the utilities included. One web site that provides a very good summary of what is available, screenshots, and their respective features is Window Managers for X .

In this chapter, the installation instructions of several Window Managers and one lightweight Desktop Environment are presented. Later in the book, both KDE and GNOME have their own sections.

Fluxbox-1.3.7

Introduction to Fluxbox

The Fluxbox package contains a window manager.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Fluxbox Dependencies

Required

a graphical environment

Optional

dbus-1.12.20 (runtime), FriBidi-1.0.11, and imlib2-1.8.0 (if you wish to use other image formats in addition to XPM)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/fluxbox

Installation of Fluxbox

First, fix a build failure when building with gcc-11.1:

sed -i '/text_prop.value > 0/s/>/!=/' util/fluxbox-remote.cc

Install Fluxbox by running the following commands:

./configure --prefix=/usr &&
make

This package does not have a working testsuite.

Now, as the root user:

make install

Configuring Fluxbox

Config Files

~/.fluxbox/init, ~/.fluxbox/keys, and ~/.fluxbox/menu

Configuration Information

If Fluxbox is the only Window Manager you want to use, you can start it with an .xinitrc file in your home folder. Be sure to backup your current .xinitrc before proceeding.

echo startfluxbox > ~/.xinitrc

Or alternatively, if you use a login manager like GDM-41.3 or lightdm-1.30.0, and would like to be able to choose Fluxbox at the login prompt, create a fluxbox.desktop file. As root:

mkdir -pv /usr/share/xsessions &&
cat > /usr/share/xsessions/fluxbox.desktop << "EOF"
[Desktop Entry]
Encoding=UTF-8
Name=Fluxbox
Comment=This session logs you into Fluxbox
Exec=startfluxbox
Type=Application
EOF

If you didn't install GDM-41.3 or lightdm-1.30.0 in /usr, then change that command to fit the prefix you chose.

Now create the Fluxbox configuration files:

mkdir -v ~/.fluxbox &&
cp -v /usr/share/fluxbox/init ~/.fluxbox/init &&
cp -v /usr/share/fluxbox/keys ~/.fluxbox/keys

To generate the application menu, first you may wish to run fluxbox-generate_menu -h, in order to choose any <user_options>, then issue:

cd ~/.fluxbox &&
fluxbox-generate_menu <user_options>

Alternately, copy a pregenerated menu:

cp -v /usr/share/fluxbox/menu ~/.fluxbox/menu

Menu items are added by editing ~/.fluxbox/menu. The syntax is explained on the fluxbox man page.

If you want to use an image as your desktop background, copy the theme you like into ~/.fluxbox. Then add a line to make it use the correct image. In the following command, change <theme> for the name of the theme you want and change </path/to/nice/image.ext> to point to the actual image you want to use, where ext must be xpm, if imlib2-1.8.0 is not installed to allow other image formats.

cp -r /usr/share/fluxbox/styles/<theme> ~/.fluxbox/theme &&

sed -i 's,\(session.styleFile:\).*,\1 ~/.fluxbox/theme,' ~/.fluxbox/init &&

[ -f ~/.fluxbox/theme ] &&
echo "background.pixmap: </path/to/nice/image.ext>" >> ~/.fluxbox/theme ||
[ -d ~/.fluxbox/theme ] &&
echo "background.pixmap: </path/to/nice/image.ext>" >> ~/.fluxbox/theme/theme.cfg

In some locales the font specified in the theme may not contain the needed characters. This results in menus with blank items. You can fix this by editing ~/.fluxbox/theme with a text editor and altering it so that it names a suitable font.

Contents

Installed Programs: fluxbox, fbsetbg, fbsetroot, fluxbox-generate_menu, startfluxbox, fbrun, fluxbox-remote, and fluxbox-update_configs
Installed Libraries: None
Installed Directories: /usr/share/fluxbox and ~/.fluxbox

Short Descriptions

fluxbox

is a window manager for X11 based on Blackbox 0.61.0

fbsetbg

is a utility that sets the background image. It requires one of the following at runtime: Esetroot, wmsetbg, feh, hsetroot, chbg, display, qiv, xv, xsri, xli, or xsetbg. It also requires which if Esetroot is found

fbsetroot

is a utility to change root window appearance based on the Blackbox application bsetroot

fluxbox-generate_menu

is a utility that generates a menu by scanning your PATH

startfluxbox

is a session startup script that allows for command executions prior to fluxbox starting

fbrun

displays a run dialog window

fluxbox-remote

provides command line access to key commands for Fluxbox

fluxbox-update_configs

use to manage config files (reload, update, test)

Last updated on

IceWM-2.9.5

Introduction to IceWM

IceWM is a window manager with the goals of speed, simplicity, and not getting in the user's way.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

IceWM Dependencies

Required

CMake-3.22.2, a graphical environment, and gdk-pixbuf-xlib-2.40.2

Optional

asciidoc-10.1.1 (for regenerating the HTML documentation), FriBidi-1.0.11 (for languages written right to left), imlib2-1.8.0, librsvg-2.52.6, libao-1.2.0, libsndfile-1.0.31, and alsa-lib-1.2.6.1 (for the experimental icesound program)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/icewm

Installation of IceWM

Install IceWM by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_BUILD_TYPE=Release  \
      -DCFGDIR=/etc               \
      -DENABLE_LTO=ON             \
      -DCONFIG_GDK_PIXBUF_XLIB=ON \
      -DCONFIG_IMLIB2=OFF         \
      -DDOCDIR=/usr/share/doc/icewm-2.9.5  \
      .. &&
make

This package does not have a working testsuite.

Now, as the root user:

make install

Command Explanations

-DENABLE_LTO=ON: This option enables Link Time Optimization and is required for this package.

Configuring IceWM

Config Files

~/.icewm/keys, ~/.icewm/menu, and ~/.icewm/preferences, and ~/.icewm/toolbar, and ~/.icewm/winoptions. The default versions are installed in /usr/share/icewm/ and will be used if you have not copied them to ~/.icewm.

Configuration Information

If IceWM is the only Window Manager you want to use, you can start it with an .xinitrc file in your home folder. Be sure to backup your current .xinitrc before proceeding.

echo icewm-session > ~/.xinitrc

Now create the IceWM configuration files:

mkdir -pv ~/.icewm                                      &&
cp -v /usr/share/icewm/keys ~/.icewm/keys               &&
cp -v /usr/share/icewm/menu ~/.icewm/menu               &&
cp -v /usr/share/icewm/preferences ~/.icewm/preferences &&
cp -v /usr/share/icewm/toolbar ~/.icewm/toolbar         &&
cp -v /usr/share/icewm/winoptions ~/.icewm/winoptions

You can now edit these files to meet your requirements. In particular, review the preferences file. You can use Logout -> Restart-IceWM on the main menu to load your changed preferences, but changes to the background only take effect when IceWM is started.

At this point you can either modify the traditional menu files to suit your requirements, or use the newer icewm-menu-fdo described later.

The syntax of the menus is explained in the help files, which you can access by running help from the menu, but some of the detail is out of date and the default selections in the menus (a few old applications on the main menu, everything else on the Programs menu) will benefit from being updated to meet your needs. The following examples are provided to encourage you to think about how you wish to organise your menus. Please note the following:

  • If a program listed in the menu has not been installed, it will not appear when the menu is displayed. Similarly, if the program exists but the specified icon does not, no icon will be displayed in the menu.

  • The icons can be either .xpm or .png files, and there is no need to specify the extension. If the icon is located in the "library" (/usr/share/icewm/icons) there is no need to specify the path.

  • Most programs are in sub-menus, and the main menu will always append entries for windows, help, settings, logout at the bottom.

  • An icon for firefox was copied to the library directory and given a meaningful name. The icon for xine is xine.xpm which was installed to a pixmap directory.

  • The default toolbar is not altered.

If you wish to use this traditional method, there are more examples in previous releases of this book (e.g. BLFS-7.8).

Alternatively, you can create a menu which conforms to the FDO Desktop Menu Specifications, where programs can be found because they have a .desktop file in the XDG_DATA_HOME or XDG_DATA_DIR directories. Unlike most windowmanagers, icewm does not search for programs when the menu is invoked, so if you take this route you will need to rerun the following command after installing or removing programs:

icewm-menu-fdo >~/.icewm/menu

If you wish to put icons on your desktop, you will need to install a program such as Rox-Filer-2.11 which provides a pinboard. If you do that you will no longer be able to access the menu by right-clicking on the desktop, you will have to use the IceWM button. To ensure that the rox pinboard is running, the following commands will put it in the startup file:

cat > ~/.icewm/startup << "EOF"
rox -p Default &
EOF &&
chmod +x ~/.icewm/startup

Tip

There are a number of keyboard shortcuts in IceWM:

  • Ctrl + Alt + FN : go to ttyN.

  • Ctrl + Alt + N : go to desktop number N

  • Ctrl + Alt + Space : open a box on the taskbar where you can key in the name of an application and run it.

Contents

Installed Programs: icehelp, icesh, icesound, icewm, icewm-menu-fdo, icewm-menu-xrandr, icewm-session, icewm-set-gnomewm, icewmbg, and icewmhint
Installed Libraries: None
Installed Directories: /usr/share/doc/icewm-2.9.5, /usr/share/icewm and ~/.icewm

Short Descriptions

icehelp

is used to display the html manual

icesh

is a command-line window manager which can be used in ~/.icewm/startup

icesound

plays audio files on GUI events raised by IceWM

icewm

is the window manager

icewm-menu-fdo

can create a file in a format suitable for an IceWM menu, which lists those programs currently installed in a layout conforming to the FDO Desktop Menu Specifications

icewm-menu-xrandr

is a helper program used to manage multi-screen configurations

icewm-session

runs icewmbg, icewm, icewmtray, startup, shutdown (i.e. startup and shutdown scripts are run if installed)

icewm-set-gnomewm

is a script to set the GNOME window manager to icewm using gconftool

icewmbg

is used to set the background, according to the various DesktopBackground settings in the preferences

icewmhint

is used internally to provide hints to the user

icewmtray

provides the tray

Last updated on

openbox-3.6.1

Introduction to openbox

Openbox is a highly configurable desktop window manager with extensive standards support. It allows you to control almost every aspect of how you interact with your desktop.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Openbox Dependencies

Required

a graphical environment and Pango-1.50.4 (compiled with support for libXft)

Optional

dbus-1.12.20 (runtime), imlib2-1.8.0 (to enable icons in the right click menu), ImageMagick-7.1.0-25 (to show desktop backgrounds as seen in the Configuration Information section below), PyXDG-0.27, startup-notification-0.12, and librsvg-2.52.6

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/openbox

Installation of Openbox

Note

If XORG_PREFIX is not /usr, tell gcc about it:

export LIBRARY_PATH=$XORG_PREFIX/lib

If you only installed the Python 3 PyXDG module convert one of the scripts to Python 3:

2to3-3.10 -w data/autostart/openbox-xdg-autostart &&
sed 's/python/python3/' -i data/autostart/openbox-xdg-autostart

Install Openbox by running the following commands:

./configure --prefix=/usr     \
            --sysconfdir=/etc \
            --disable-static  \
            --docdir=/usr/share/doc/openbox-3.6.1 &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--sysconfdir=/etc: This option puts Openbox's configuration files in /etc/xdg/openbox instead of /usr/etc/xdg/openbox.

--docdir=/usr/share/doc/openbox-3.6.1: this puts a few files in a versioned directory in /usr/share/doc.

--disable-static: This switch prevents installation of static versions of the libraries.

Configuring Openbox

Config Files

/etc/xdg/openbox/autostart, /etc/xdg/openbox/menu.xml, /etc/xdg/openbox/rc.xml, ~/.config/openbox/autostart, ~/.config/openbox/menu.xml and ~/.config/openbox/rc.xml

Configuration Information

Openbox's right click menu can be used to launch programs. The menu itself is configured with 2 files, /etc/xdg/openbox/menu.xml and ~/.config/openbox/menu.xml. To make changes to the menu, copy /etc/xdg/openbox/menu.xml to ~/.config/openbox/menu.xml and edit it:

cp -rf /etc/xdg/openbox ~/.config

~/.config/openbox/menu.xml can be edited with a text editor or you can install Obmenu (requires pyxml and PyGTK-2.24.0).

To have icons in your right click menu requires installing imlib2-1.8.0 before you install Openbox. To set an icon for an entry in the menu edit ~/.config/openbox/menu.xml and add an icon to the <item> tag like this:

                <item label="Mplayer" icon="/usr/share/pixmaps/mplayer.png">

Many other aspects of Openbox's behaviour are configured with ~/.config/openbox/rc.xml such as what keybindings are used to launch programs or which mouse button launches the main menu.

Details of the theme that Openbox applies to window decorations are configured in ~/.config/openbox/rc.xml. You can get a list of the available themes with the command:

ls -d /usr/share/themes/*/openbox-3 | sed 's#.*es/##;s#/o.*##'

Starting Openbox

To automatically start openbox when you start Xorg:

echo openbox > ~/.xinitrc

If you want to set a background image to your desktop you can use display and launch it from ~/.xinitrc just before openbox:

cat > ~/.xinitrc << "EOF"
display -backdrop -window root /path/to/beautiful/picture.jpeg
exec openbox
EOF

Or if you like a bit of variety, put a selection of images in a folder (in this example, the directory ~/.config/backgrounds) and choose one at random each time you xinit:

cat > ~/.xinitrc << "EOF"
# make an array which lists the pictures:
picture_list=(~/.config/backgrounds/*)
# create a random integer between 0 and the number of pictures:
random_number=$(( ${RANDOM} % ${#picture_list[@]} ))
# display the chosen picture:
display -backdrop -window root "${picture_list[${random_number}]}"
exec openbox
EOF

If you like to have the numlock key set when you start Xorg, install Numlockx and add that to your xinitrc. Another useful application is dbus-1.12.20:

cat > ~/.xinitrc << "EOF"
. /etc/profile
picture_list=(~/.config/backgrounds/*)
random_number=$(( ${RANDOM} % ${#picture_list[*]} ))
display -backdrop -window root "${picture_list[${random_number}]}"
numlockx
eval $(dbus-launch --auto-syntax --exit-with-session)
lxpanel &
exec openbox
EOF

Contents

Installed Programs: gdm-control, gnome-panel-control, obxprop, openbox, openbox-gnome-session, openbox-kde-session and openbox-session
Installed Libraries: libobrender.so and libobt.so
Installed Directories: /etc/xdg/openbox, /usr/include/openbox, /usr/share/doc/openbox-3.6.1 and /usr/share/themes.

Short Descriptions

gdm-control

is a command line tool to send signals to GDM

gnome-panel-control

is a command line utility to invoke the Gnome Panel run dialog/menu

obxprop

is a tool for displaying the properties on an x window. It has a similar functionality to xprop, but allows you to see UTF-8 strings as text

openbox

is a standards compliant, highly configurable, window manager

openbox-gnome-session

is a script to launch an Gnome session with Openbox as your window manager from your ~/.xinitrc

openbox-kde-session

is a script to launch an KDE session with Openbox as your window manager from your ~/.xinitrc

openbox-session

is a script to launch an Openbox session from your ~/.xinitrc

libobrender.so

contains the functions used by Openbox for theme rendering

libobt.so

is the Openbox toolkit library

Last updated on

sawfish-1.13.0

Introduction to sawfish

The sawfish package contains a window manager. This is useful for organizing and displaying windows where all window decorations are configurable and all user-interface policy is controlled through the extension language.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

sawfish Dependencies

Required

gdk-pixbuf-xlib-2.40.2, rep-gtk-0.90.8.3, and Which-2.21

Optional

libnsl-2.0.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/sawfish

Installation of sawfish

Install sawfish by running the following commands:

./configure --prefix=/usr --with-pango  &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Configuring sawfish

Configuration Information

Be sure to backup your current .xinitrc before proceeding.

cat >> ~/.xinitrc << "EOF"
exec sawfish
EOF

Optionally, you can use a Display Manager, such as lxdm-0.5.3.

From the developers: The default menu binding is somewhat obscure; you must middle-click on the background to bring up the menus. (If you have a two-button mouse, try clicking both buttons simultaneously). You can find this at sawfish's FAQ.

Contents

Installed Programs: sawfish, sawfish-about, sawfish-client, sawfish-config, sawfish-kde4-session, sawfish-kde5-session, sawfish-lumina-session, sawfish-mate-session, and sawfish-xfce-session
Installed Libraries: Several internal modules under /usr/lib/sawfish tree
Installed Directory: /usr/include/sawfish, /usr/lib/sawfish, /usr/lib/rep/sawfish, and /usr/share/sawfish

Short Descriptions

sawfish

is the extensible window manager using a Lisp-based scripting language

sawfish-about

is the sawfish about window

sawfish-client

allows you to connect to a window manager process and evaluate arbitrary Lisp forms

sawfish-config

is the sawfish configuration manager

sawfish-kde4-session

is a script to run KDE4 using sawfish

sawfish-kde5-session

is a script to run Plasma 5 using sawfish

sawfish-mate-session

is a script to run mate using sawfish

sawfish-lumina-session

is a script to run Lumina using sawfish

sawfish-xfce-session

is a script to run xfce using sawfish

Last updated on

Chapter 28. Icons

Window Managers and Desktop Environments can use icons from different sources. Generally icons are installed in /usr/share/icons and are independent of distribution.

adwaita-icon-theme-41.0

Introduction to Adwaita Icon Theme

The Adwaita Icon Theme package contains an icon theme for Gtk+ 3 applications.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Adwaita Icon Theme Dependencies

Optional

git-2.35.1, GTK+-2.24.33 or GTK+-3.24.31 (if present, librsvg-2.52.6 is also required, and gtk-update-icon-cache and gtk-encode-symbolic-svg are run after installing), Inkscape-1.1.2 and Icon Tools

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/adwaita-icon-theme

Installation of Adwaita Icon Theme

Install Adwaita Icon Theme by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Library: None
Installed Directory: /usr/share/icons/Adwaita

Last updated on

breeze-icons-5.91.0

Introduction to Breeze Icons

The Breeze Icons package contains the default icons for KDE Plasma 5 applications, but it can be used for other window environments.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Breeze Icons Dependencies

Required

extra-cmake-modules-5.91.0 and Qt-5.15.2

Optional

KDE Frameworks-5.91.0, libxml2-2.9.13, and lxml-4.7.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/breeze-icons

Installation of Breeze Icons

Install Breeze Icons by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DBUILD_TESTING=OFF         \
      -Wno-dev ..

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

-DBUILD_TESTING=OFF: This parameter disables building the testing framework, which requires some modules from KDE Frameworks-5.91.0.

Contents

Installed Programs: None
Installed Library: None
Installed Directory: /usr/share/icons/breeze{,-dark}

Last updated on

gnome-icon-theme-3.12.0

Introduction to GNOME Icon Theme

The GNOME Icon Theme package contains an assortment of non-scalable icons of different sizes and themes.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Icon Theme Dependencies

Required

GTK+-3.24.31 or GTK+-2.24.33, hicolor-icon-theme-0.17, and icon-naming-utils-0.8.90

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-icon-theme

Installation of GNOME Icon Theme

Install GNOME Icon Theme by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: None
Installed Directory: /usr/share/icons/gnome

Last updated on

gnome-icon-theme-extras-3.12.0

Introduction to GNOME Icon Theme Extras

The GNOME Icon Theme Extras package contains extra icons for the GNOME Desktop.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Icon Theme Extras Dependencies

Required

gnome-icon-theme-3.12.0

Optional

git-2.35.1 and Inkscape-1.1.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-icon-theme-extras

Installation of GNOME Icon Theme Extras

Install GNOME Icon Theme Extras by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Last updated on

gnome-icon-theme-symbolic-3.12.0

Introduction to GNOME Icon Theme Symbolic

The GNOME Icon Theme Symbolic package contains symbolic icons for the default GNOME icon theme.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Icon Theme Symbolic Dependencies

Required

gnome-icon-theme-3.12.0

Optional

git-2.35.1 and Inkscape-1.1.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-icon-theme-symbolic

Installation of GNOME Icon Theme Symbolic

Install GNOME Icon Theme Symbolic by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: None
Installed Directories: /usr/share/icons/gnome/scalable

Last updated on

gnome-themes-extra-3.28

Introduction to GNOME Themes Extra

The GNOME Themes Extra package, formerly known as GNOME Themes Standard, contains various components of the default GNOME theme.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Themes Extra Dependencies

Required

GTK+-2.24.33 or GTK+-3.24.31 with librsvg-2.52.6 or both

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-themes-extra

Installation of GNOME Themes Extra

Install GNOME Themes Extra by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-gtk2-engine: This switch disables the GTK+-2 theming engine.

--disable-gtk3-engine: This switch disables the GTK+-3 theming engine.

Contents

Installed Programs: None
Installed Library: libadwaita.so
Installed Directories: /usr/lib/gtk-2.0/2.10.0/engines, /usr/share/icons/HighContrast, /usr/share/themes/Adwaita, /usr/share/themes/Adwaita-dark, and /usr/share/themes/HighContrast

Short Descriptions

libadwaita.so

is the Adwaita GTK+-2 engine theme

Last updated on

hicolor-icon-theme-0.17

Introduction to hicolor-icon-theme

The hicolor-icon-theme package contains a default fallback theme for implementations of the icon theme specification.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/hicolor-icon-theme

Installation of hicolor-icon-theme

Install hicolor-icon-theme by running the following commands:

./configure --prefix=/usr

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: None
Installed Directory: /usr/share/icons/hicolor

Short Descriptions

/usr/share/icons/hicolor/*

contains icon definitions used as defaults

Last updated on

icon-naming-utils-0.8.90

Introduction to icon-naming-utils

The icon-naming-utils package contains a Perl script used for maintaining backwards compatibility with current desktop icon themes, while migrating to the names specified in the Icon Naming Specification.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

icon-naming-utils Dependencies

Required

XML-Simple-2.25

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/icon-naming-utils

Installation of icon-naming-utils

Install icon-naming-utils by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: icon-name-mapping
Installed Libraries: None
Installed Directories: /usr/share/dtds and /usr/share/icon-naming-utils

Short Descriptions

icon-name-mapping

is a Perl script used for maintaining backwards compatibility with current desktop icon themes, while migrating to the names specified in the Icon Naming Specification

Last updated on

lxde-icon-theme-0.5.1

Introduction to LXDE Icon Theme

The LXDE Icon Theme package contains nuoveXT 2.2 Icon Theme for LXDE.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

LXDE Icon Theme Dependencies

Optional

GTK+-2.24.33 or GTK+-3.24.31 (for gtk-update-icon-cache command)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lxde-icon-theme

Installation of LXDE Icon Theme

Install LXDE Icon Theme by running the following commands:

./configure --prefix=/usr

This package does not come with a test suite.

Now, as the root user:

make install

If you have installed one of the optional dependencies, run the following command as the root user:

gtk-update-icon-cache -qf /usr/share/icons/nuoveXT2

Contents

Installed Programs: None
Installed Libraries: None
Installed Directory: /usr/share/icons/nuoveXT2

Last updated on

oxygen-icons5-5.91.0

Introduction to oxygen-icons5

The oxygen icons 5 theme is a photo-realistic icon style, with a high standard of graphics quality.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

oxygen-icons5 Dependencies

Required

extra-cmake-modules-5.91.0 and Qt-5.15.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/oxygen-icons5

Installation of oxygen-icons5

First, enable scalable icons:

sed -i '/( oxygen/ s/)/scalable )/' CMakeLists.txt

Install oxygen-icons5 by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr -Wno-dev ..

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: none
Installed Libraries: none
Installed Directory: /usr/share/icons/oxygen

Last updated on

Part VII. KDE

KDE is a comprehensive desktop environment with a huge number of applications written for it and a huge amount of users. It is based on the Qt framework.

For more information visit the official KDE project site at http://www.kde.org/.

Chapter 29. Introduction to KDE

KDE Preliminaries

KDE is a comprehensive desktop environment with a huge number of applications written for it and a huge amount of users. It is based on the Qt framework.

The KDE5 system has two main blocks: the libraries, called KDE Frameworks 5 or KF5, which can be used in other environments, and the desktop environment called KDE Plasma 5. Most of the applications written by the KDE team only use KF5, and do not need the plasma environment.

For more information visit the official KDE project site at http://www.kde.org/.

Last updated on

extra-cmake-modules-5.91.0

Introduction to Extra Cmake Modules

The Extra Cmake Modules package contains extra CMake modules used by KDE Frameworks 5 and other packages.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Extra Cmake Modules Dependencies

Required

CMake-3.22.2

Optional

PyQt (experimental support for building KDE Python bindings), and Sphinx (for building documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/extra-cmake-modules

Installation of Extra Cmake Modules

Install Extra Cmake Modules by running the following commands:

sed -i '/"lib64"/s/64//' kde-modules/KDEInstallDirsCommon.cmake &&

sed -e '/PACKAGE_INIT/i set(SAVE_PACKAGE_PREFIX_DIR "${PACKAGE_PREFIX_DIR}")' \
    -e '/^include/a set(PACKAGE_PREFIX_DIR "${SAVE_PACKAGE_PREFIX_DIR}")' \
    -i ECMConfig.cmake.in &&

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr .. &&
make

This package does not come with a test suite.

Note

Unlike other KF5 packages, this module is installed in /usr because it can be used by some non-KF5 packages.

Now, as the root user:

make install

Command Explanations

sed ... Modules/KDEInstallDirs.cmake: This command disables applications using cmake from attempting to install files in a lib64 sub-directory.

sed ... ECMConfig.cmake.in: This command protects the global cmake variable PACKAGE_PREFIX_DIR from being changed when checking ECM presence: since we install ECM into /usr, the check would set that variable to /usr, while most KDE packages expect it to be set to /opt/kf5 and would fail to build if it is set to something else.

Contents

Installed Programs: None
Installed Libraries: None
Installed Directories: /usr/share/ECM and /usr/share/doc/ECM (if documentation was built)

Last updated on

Phonon-4.11.1

Introduction to Phonon

Phonon is the multimedia API for KDE. It replaces the old aRts package. Phonon needs either the GStreamer or VLC backend.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Phonon Dependencies

Required

CMake-3.22.2, extra-cmake-modules-5.91.0, GLib-2.70.4, and Qt-5.15.2

At least one of phonon-backend-gstreamer-4.10.0 or phonon-backend-vlc-0.11.3 needs to be installed afterwards for multimedia operation in KDE.

Optional

PulseAudio-15.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/phonon

Installation of Phonon

Install Phonon by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_BUILD_TYPE=Release  \
      .. &&
make

Now, as the root user:

make install

Command Explanations

-DCMAKE_BUILD_TYPE=Release: This switch is used to apply higher level of the compiler optimizations.

Contents

Installed Programs: phononsettings
Installed Libraries: libphonon4qt5.so and libphonon4qt5experimental.so
Installed Directories: /usr/include/phonon4qt5, /usr/lib/cmake/phonon4qt5, and /usr/share/phonon4qt5

Last updated on

Phonon-backend-gstreamer-4.10.0

Introduction to the Phonon-backend-gstreamer

This package provides a Phonon backend which utilizes the GStreamer media framework.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Phonon-backend-gstreamer Dependencies

Required

gstreamer-1.20.0, libxml2-2.9.13, and phonon-4.11.1

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/phonon-backend-gstreamer

Installation of Phonon-backend-gstreamer

Install Phonon-backend-gstreamer by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr    \
      -DCMAKE_BUILD_TYPE=Release     \
      .. &&
make

Now, as the root user:

make install

Command Explanations

-DCMAKE_BUILD_TYPE=Release: This switch is used to apply higher level of compiler optimizations.

Contents

Installed Programs: none
Installed Libraries: phonon_gstreamer.so
Installed Directories: /usr/lib/qt5/plugins/phonon4qt5_backend

Last updated on

Phonon-backend-vlc-0.11.3

Introduction to the Phonon-backend-vlc

This package provides a Phonon backend which utilizes the VLC media framework.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Phonon-backend-vlc Dependencies

Required

phonon-4.11.1 and VLC-3.0.16

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/phonon-backend-vlc

Installation of Phonon-backend-vlc

Install Phonon-backend-vlc by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_BUILD_TYPE=Release  \
      .. &&
make

Now, as the root user:

make install

Command Explanations

-DCMAKE_BUILD_TYPE=Release: This switch is used to apply higher level of compiler optimizations.

Contents

Installed Program: none
Installed Libraries: phonon_vlc.so
Installed Directory: /usr/lib/qt5/plugins/phonon4qt5_backend

Last updated on

Polkit-Qt-0.114.0

Introduction to Polkit-Qt

Polkit-Qt provides an API to PolicyKit in the Qt environment.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Polkit-Qt Dependencies

Required

CMake-3.22.2, Polkit-0.120, and Qt-5.15.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/polkit-qt

Installation of Polkit-Qt

Install Polkit-Qt by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_BUILD_TYPE=Release  \
      -Wno-dev .. &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

-DCMAKE_BUILD_TYPE=Release: This switch is used to apply higher level of the compiler optimizations.

Contents

Installed Programs: none
Installed Libraries: libpolkit-qt5-agent-1.so, libpolkit-qt5-core-1.so, and libpolkit-qt5-gui-1.so
Installed Directories: /usr/include/polkit-qt5-1 and /usr/lib/cmake/PolkitQt5-1

Last updated on

libdbusmenu-qt-0.9.3+16.04.20160218

Introduction to libdbusmenu-qt

This library provides a Qt implementation of the DBusMenu specification that exposes menus via DBus.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libdbusmenu-qt Dependencies

Required

Qt-5.15.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libdbusmenu-qt

Installation of libdbusmenu-qt

Install libdbusmenu-qt by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_BUILD_TYPE=Release  \
      -DWITH_DOC=OFF              \
      -Wno-dev .. &&
make

This packages does not come with a working test suite.

Now, as the root user:

make install

Command Explanations

-DCMAKE_BUILD_TYPE=Release: This switch is used to build without debugging symbols and apply a higher level of compiler optimizations.

-DWITH_DOC=OFF: This option is set to avoid trying to build the API documentation which requires obsolete Qt4.

Contents

Installed Programs: None
Installed Library: libdbusmenu-qt5.so
Installed Directory: /usr/lib/cmake/dbusmenu-qt5 and /usr/include/dbusmenu-qt5

Last updated on

Plasma-wayland-protocols-1.6.0

Introduction to the Plasma-wayland-protocols

This package provides a custom set of protocol definitions for KDE.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Plasma-wayland-protocols Dependencies

Required

extra-cmake-modules-5.91.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/plasma-wayland-protocols

Installation of Plasma-wayland-protocols

Install Plasma-wayland-protocols by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr ..

Now, as the root user:

make install

Contents

Installed Programs: none
Installed Libraries: none
Installed Directories: /usr/share/plasma-wayland-protocols and /usr/lib/cmake/PlasmaWaylandProtocols

Last updated on

Chapter 30. KDE Frameworks 5

KDE Frameworks 5 Pre-installation Configuration

KF5 can be installed in /usr or /opt/kf5. The BLFS editors recommend the latter in the BLFS environment.

Installing in /usr

One option is to install KDE Frameworks 5 into the /usr hierarchy. This creates a simpler setup but makes it more difficult to try multiple versions of KDE Frameworks.

export KF5_PREFIX=/usr

It is a good idea to add the following variables to your system or personal profiles:

cat >> /etc/profile.d/qt5.sh << "EOF"
# Begin kf5 extension for /etc/profile.d/qt5.sh

pathappend /usr/lib/qt5/plugins    QT_PLUGIN_PATH
pathappend $QT5DIR/lib/plugins     QT_PLUGIN_PATH

pathappend /usr/lib/qt5/qml        QML2_IMPORT_PATH
pathappend $QT5DIR/lib/qml         QML2_IMPORT_PATH

# End extension for /etc/profile.d/qt5.sh
EOF

cat > /etc/profile.d/kf5.sh << "EOF"
# Begin /etc/profile.d/kf5.sh

export KF5_PREFIX=/usr

# End /etc/profile.d/kf5.sh
EOF

Note

If qt5 was installed in /usr, the $QT5DIR/lib/ portions of the above paths may need to be changed to $QT5DIR/lib/qt5/.

Additionally, if Sudo-1.9.9 is installed, these variables should be available to the super user. Execute the following commands as the root user:

cat >> /etc/sudoers.d/qt << "EOF"
Defaults env_keep += QT_PLUGIN_PATH
Defaults env_keep += QML2_IMPORT_PATH
EOF

cat >> /etc/sudoers.d/kde << "EOF"
Defaults env_keep += KF5_PREFIX
EOF

Installing in /opt

A method of building multiple versions installs KDE Frameworks 5 in the /opt hierarchy:

export KF5_PREFIX=/opt/kf5

If you are not installing KDE Frameworks 5 in /usr, you will need to make some additional configuration changes. Best practice is to add those to your system or personal profile:

cat > /etc/profile.d/kf5.sh << "EOF"
# Begin /etc/profile.d/kf5.sh

export KF5_PREFIX=/opt/kf5

pathappend $KF5_PREFIX/bin              PATH
pathappend $KF5_PREFIX/lib/pkgconfig    PKG_CONFIG_PATH

pathappend $KF5_PREFIX/etc/xdg          XDG_CONFIG_DIRS
pathappend $KF5_PREFIX/share            XDG_DATA_DIRS

pathappend $KF5_PREFIX/lib/plugins      QT_PLUGIN_PATH
pathappend $KF5_PREFIX/lib/plugins/kcms QT_PLUGIN_PATH

pathappend $KF5_PREFIX/lib/qml          QML2_IMPORT_PATH

pathappend $KF5_PREFIX/lib/python3.10/site-packages PYTHONPATH

pathappend $KF5_PREFIX/share/man        MANPATH
# End /etc/profile.d/kf5.sh
EOF

cat >> /etc/profile.d/qt5.sh << "EOF"
# Begin Qt5 changes for KF5

pathappend $QT5DIR/plugins             QT_PLUGIN_PATH
pathappend $QT5DIR/qml                 QML2_IMPORT_PATH

# End Qt5 changes for KF5
EOF

Expand your /etc/ld.so.conf file:

cat >> /etc/ld.so.conf << "EOF"
# Begin KF5 addition

/opt/kf5/lib

# End KF5 addition
EOF

Several KDE Frameworks 5 and Plasma 5 packages install files into D-Bus and Polkit directories. When installing KDE Frameworks 5 in a location other than /usr, D-Bus and Polkit need to be able to find these files. The easiest way to achieve this is to create the following symlinks (as the root user):

install -v -dm755           $KF5_PREFIX/{etc,share} &&
ln -sfv /etc/dbus-1         $KF5_PREFIX/etc         &&
ln -sfv /usr/share/dbus-1   $KF5_PREFIX/share       &&
ln -sfv /usr/share/polkit-1 $KF5_PREFIX/share

Some packages may also install icons from the "hicolor" icon set. Since that icon set is used by many packages, it is a good idea to create a symlink to the one in /usr/share to avoid having multiple installations of hicolor-icon-theme-0.17. Run the following commands as the root user:

install -v -dm755                $KF5_PREFIX/share/icons &&
ln -sfv /usr/share/icons/hicolor $KF5_PREFIX/share/icons

Tip

Sometimes, the installation paths are hardcoded into installed files. This is the reason why /opt/kf5 is used as installation prefix instead of /opt/kf5-5.91.0. After installing KDE Frameworks, you may rename the directory and create a symlink:

mv /opt/kf5{,-5.91.0}
ln -sfv kf5-5.91.0 /opt/kf5

Later on, you may want to install other versions of KDE Frameworks 5. To do that, just remove the symlink and use /opt/kf5 as the prefix again. Which version of KDE Frameworks 5 you use depends only on where the symlink points. No other reconfiguration will be needed.

Last updated on

Building KDE Frameworks 5 (KF5)

KDE Frameworks 5 is a collection of libraries based on top of Qt5 and QML derived from the monolithic KDE 4 libraries. They can be used independent of the KDE Display Environment (Plasma 5).

This package is known to build and work properly using an LFS-11.1 platform.

The instructions below build all of the KDE Frameworks packages in one step by using a bash script.

Package Information

KF5 Dependencies

Required

Boost-1.78.0, extra-cmake-modules-5.91.0, docbook-xml-4.5, docbook-xsl-1.79.2, giflib-5.2.1, libepoxy-1.5.9, libgcrypt-1.10.0, libical-3.0.14, libjpeg-turbo-2.1.2, libpng-1.6.37, libxslt-1.1.35, lmdb-0.9.29, qrencode-4.1.1, phonon-4.11.1, plasma-wayland-protocols-1.6.0, shared-mime-info-2.1, URI-5.10, and Wget-1.21.2 (required to download the packages)

Recommended
Optional

BlueZ-5.63 (needed to build Bluez-Qt), ModemManager-1.18.6 (needed to build ModemManager-Qt), Datamatrix (deemed recommended for Prison by upstream)

Runtime dependency for FrameworkIntegration

Oxygen fonts and Noto fonts

Additional recommended dependencies for kapidox
Other python modules needed by kapidox

requests, doxyqml, doxypypy, urllib3, idna, charset-normalizer, and certifi (all will be automatically installed at build time if not present on the system)

Additional image formats support in KImageFormats

JasPer-2.0.33 and OpenEXR

Optional dependencies for KIO

MIT Kerberos V5-1.19.2

Optional dependencies for Solid

UDisks-2.9.4, UPower-0.99.13 and media-player-info (runtime)

Optional dependency for KWallet

GPGME-1.17.0, built with C++ bindings (which is the default).

Optional dictionary backends for Sonnet

Hspell and Hunspell

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/kf5

Downloading KDE Frameworks

The easiest way to get the KDE Frameworks packages is to use a single wget to fetch them all at once:

url=https://download.kde.org/stable/frameworks/5.91/
wget -r -nH -nd -A '*.xz' -np $url

The options used here are:
  -r            recurse through child directories
  -nH           disable generation of host-prefixed directories
  -nd           do not create a hierarchy of directories
  -A '*.xz'     just get the *.xz files
  -np           don't get parent directories

Setting Package Order

The order of building files is important due to internal dependencies. Create the list of files in the proper order as follows:

cat > frameworks-5.91.0.md5 << "EOF"
5d9784ee2bd02ca0764c6bd1d8589dff  attica-5.91.0.tar.xz
#65a71fbf53cda26166fa315c496f16ca  extra-cmake-modules-5.91.0.tar.xz
f2a6670f535225cee132b0862af157ad  kapidox-5.91.0.tar.xz
c1bd7b16fd4b488f38d008574871e7a6  karchive-5.91.0.tar.xz
643759d7e8b7edafcd96fe57a31f65ba  kcodecs-5.91.0.tar.xz
503fb86945377cc4e6824526083a03c2  kconfig-5.91.0.tar.xz
4d39a971050164eca9cfd17267fbd49d  kcoreaddons-5.91.0.tar.xz
df8c55668581077a980ac34b97533a6a  kdbusaddons-5.91.0.tar.xz
4a39910f9fffa41bf636108046d11a62  kdnssd-5.91.0.tar.xz
d35d659076a7e693f534b075e977938c  kguiaddons-5.91.0.tar.xz
8def96f2eecd9351350f749344bfb6e7  ki18n-5.91.0.tar.xz
0277a06b454a12cb9081238acc20d9ff  kidletime-5.91.0.tar.xz
54ad4bf2891c9b83b368efd5e5ed0320  kimageformats-5.91.0.tar.xz
40cc3a14e1c2b30d0daf1a09946886cf  kitemmodels-5.91.0.tar.xz
7fccfc2d2f03620933623e2a92fb31d5  kitemviews-5.91.0.tar.xz
46fdbec50f3947966d25cbaa69abd727  kplotting-5.91.0.tar.xz
53ef80abdb614eb4b3db80299a648303  kwidgetsaddons-5.91.0.tar.xz
3741a8dd1af123a48f8f622c5000457f  kwindowsystem-5.91.0.tar.xz
022818490366c1c84b099855135882b3  networkmanager-qt-5.91.0.tar.xz
59f5148ddc67455188c81d570167147f  solid-5.91.0.tar.xz
ca8498069ae692512a7a884492898db9  sonnet-5.91.0.tar.xz
de397b8183b1c0827f0a541aa5d5f770  threadweaver-5.91.0.tar.xz
9771c45d5646210509a1f336f080db8a  kauth-5.91.0.tar.xz
e4ad9f872cddaa3deef16fcc202e8b53  kcompletion-5.91.0.tar.xz
f8444d0caacd92799fc9d869331899bb  kcrash-5.91.0.tar.xz
f49f6f134a370add0e901aae468c2164  kdoctools-5.91.0.tar.xz
77c52f14f2e49ff18d030c7284308389  kpty-5.91.0.tar.xz
37338dd3c41623cdf4e305966d497a49  kunitconversion-5.91.0.tar.xz
c29c3835fc89c0004c5d9586efdca8ee  kconfigwidgets-5.91.0.tar.xz
b45f86503ff166a69a7cd2fc2f3fdca2  kservice-5.91.0.tar.xz
da8b36e6c834f7181983fba73828ee42  kglobalaccel-5.91.0.tar.xz
6e72bd9c68eba7a05c735e4b17238ec9  kpackage-5.91.0.tar.xz
cf6a45110d6f7a5b3e74d133262c65a8  kdesu-5.91.0.tar.xz
f0872d10bc2caaf7eb3add7ce9e6546c  kemoticons-5.91.0.tar.xz
49df446c1150b92021c42e1d0ca70cc2  kiconthemes-5.91.0.tar.xz
eca731f12d135cc92d53cc95f9598d24  kjobwidgets-5.91.0.tar.xz
392da2d1e13bdfbbe9f799f8b6ffd216  knotifications-5.91.0.tar.xz
f67fa515f50c11fcb376d26f2197a4d8  ktextwidgets-5.91.0.tar.xz
6331ab56636c38cf9ca59ac3f43e4aa3  kxmlgui-5.91.0.tar.xz
4d76d18f66b841a5198d9e5449478bba  kbookmarks-5.91.0.tar.xz
890904a43d90486126cdc08ca32aabb4  kwallet-5.91.0.tar.xz
a272d2e425e1bcda33151c89d68b806b  kded-5.91.0.tar.xz
b1ce633d68b986a917cf81132927e574  kio-5.91.0.tar.xz
bd47095a50a31c273f48e5b0a0178f02  kdeclarative-5.91.0.tar.xz
393d52ba4883d61dd9b1f06df04b2f27  kcmutils-5.91.0.tar.xz
c0c4e2f09fea4440da5c1777cc3605b3  kirigami2-5.91.0.tar.xz
1fb3cce028aefdd1db4d613b300d7edf  syndication-5.91.0.tar.xz
140700c804ef89f06024524c8a51daa5  knewstuff-5.91.0.tar.xz
d6e68519c97992610722b0a68c563a34  frameworkintegration-5.91.0.tar.xz
aa0a82faf3749e707565bc0172ced5d3  kinit-5.91.0.tar.xz
fe2d0dbf070991d7ae51779db4fa8fd2  kparts-5.91.0.tar.xz
9f80142ffe37b515b34dc0889126fe65  kactivities-5.91.0.tar.xz
#27062fb86be35c87443e680721e8fa56  kdewebkit-5.91.0.tar.xz
d8c472435f2e7025e73cadc57d822bf0  syntax-highlighting-5.91.0.tar.xz
a6bfff981c61753c508cc5c45543cb58  ktexteditor-5.91.0.tar.xz
f8c2992823438e3800e5fa814194e178  kdesignerplugin-5.91.0.tar.xz
ceb9a445c9c074cd922c929454dfcf05  kwayland-5.91.0.tar.xz
0e8698ea83e84bfc6709f378a32b6ba3  plasma-framework-5.91.0.tar.xz
#996e0521066cf5c5cf73a23b5d24acc6  modemmanager-qt-5.91.0.tar.xz
aced764828de66a63eeb9c1226a2a36c  kpeople-5.91.0.tar.xz
e952784913e584b0764eaa8b277d7394  kxmlrpcclient-5.91.0.tar.xz
6603e4e589a0701526b620f6cbb76b49  bluez-qt-5.91.0.tar.xz
1e6fe97a90bf20bb5443f730426dd163  kfilemetadata-5.91.0.tar.xz
07e81669af7cec4d3ed04fa237aef72c  baloo-5.91.0.tar.xz
#864c1dde4188c17b02dac7fb71dd8695  breeze-icons-5.91.0.tar.xz
#e5608a99e4bc7a3320ad047feec69bb4  oxygen-icons5-5.91.0.tar.xz
645b3974745de2cfc3a12096088cb3fd  kactivities-stats-5.91.0.tar.xz
a2c3256fcb5784405328a306aecfd034  krunner-5.91.0.tar.xz
76b4b3595295fda99eedf9cd39ea9187  prison-5.91.0.tar.xz
baaec24cc963ca6667336b55a2b4f6c7  qqc2-desktop-style-5.91.0.tar.xz
e9f719f8b00c9339db2a85cc26218d85  kjs-5.91.0.tar.xz
c366867d52842fa7b720dafb5fb76b40  kdelibs4support-5.91.0.tar.xz
68ef440aa83a691f35210db7124d163f  khtml-5.91.0.tar.xz
18f7d38c4bf120c256dda9445119a08c  kjsembed-5.91.0.tar.xz
0cda6ca0293714bb966a3b500d2ecee1  kmediaplayer-5.91.0.tar.xz
38c919168a2156b1ee8028059e42f07c  kross-5.91.0.tar.xz
fbdffe1ebe8b4b64df7860ec551e7b96  kholidays-5.91.0.tar.xz
dbf82286cc4bd94226c1f587ae97ecf2  purpose-5.91.0.tar.xz
f93809564a2a94b69eede7d7b3c6b0de  kcalendarcore-5.91.0.tar.xz
7864dea3081e33463aa477359bf426de  kcontacts-5.91.0.tar.xz
4e66810dd1a30dc3cf9ba4704cf1fb0c  kquickcharts-5.91.0.tar.xz
d89c0336fb388a584210cb26f746b171  knotifyconfig-5.91.0.tar.xz
3dc723d9345877a478980f3892c144c6  kdav-5.91.0.tar.xz
EOF

In the above list, notice that some files have been commented out with a hash (#) character. The extra-cmake-modules entry has been commented out because it was built earlier in the Introduction to KDE. The icon packages are covered separately at breeze-icons-5.91.0 and oxygen-icons5-5.91.0. The modemmanager-qt package may be built if its optional dependency has been installed. The kdewebkit may be built if the external package QtWebkit has been built.

Installation of KDE Frameworks

Note

When installing multiple packages in a script, the installation needs to be done as the root user. There are three general options that can be used to do this:

  1. Run the entire script as the root user (not recommended).

  2. Use the sudo command from the Sudo-1.9.9 package.

  3. Use su -c "command arguments" (quotes required) which will ask for the root password for every iteration of the loop.

One way to handle this situation is to create a short bash function that automatically selects the appropriate method. Once the command is set in the environment, it does not need to be set again.

as_root()
{
  if   [ $EUID = 0 ];        then $*
  elif [ -x /usr/bin/sudo ]; then sudo $*
  else                            su -c \\"$*\\"
  fi
}

export -f as_root

Caution

If installing in /opt and there is an existing /opt/kf5 either as a regular directory or a symbolic link, it should be reinitialized (as root):

mv -v /opt/kf5 /opt/kf5.old                         &&
install -v -dm755           $KF5_PREFIX/{etc,share} &&
ln -sfv /etc/dbus-1         $KF5_PREFIX/etc         &&
ln -sfv /usr/share/dbus-1   $KF5_PREFIX/share       &&
ln -sfv /usr/share/polkit-1 $KF5_PREFIX/share

First, start a subshell that will exit on error:

bash -e

Install all of the packages by running the following commands:

while read -r line; do

    # Get the file name, ignoring comments and blank lines
    if $(echo $line | grep -E -q '^ *$|^#' ); then continue; fi
    file=$(echo $line | cut -d" " -f2)

    pkg=$(echo $file|sed 's|^.*/||')          # Remove directory
    packagedir=$(echo $pkg|sed 's|\.tar.*||') # Package directory

    name=$(echo $pkg|sed 's|-5.*$||') # Isolate package name

    tar -xf $file
    pushd $packagedir

      mkdir build
      cd    build

      cmake -DCMAKE_INSTALL_PREFIX=$KF5_PREFIX \
            -DCMAKE_PREFIX_PATH=$QT5DIR        \
            -DCMAKE_BUILD_TYPE=Release         \
            -DBUILD_TESTING=OFF                \
            -Wno-dev ..
      make
      as_root make install
    popd

  as_root rm -rf $packagedir
  as_root /sbin/ldconfig

done < frameworks-5.91.0.md5

exit

Note

Any modules that have been omitted can be installed later by using the same mkdir build; cd build; cmake; make; make install procedure as above.

Useless systemd units have been installed in $KF5_PREFIX/lib. Remove them now (as root):

rm -rf $KF5_PREFIX/lib/systemd

Sometimes the installation paths are hardcoded into installed files. If the installed directory is not /usr, rename the directory and create a symlink:

mv -v /opt/kf5 /opt/kf5-5.91.0
ln -sfvn kf5-5.91.0 /opt/kf5

Command Explanations

-DCMAKE_PREFIX_PATH=$QT5DIR: This switch is used to allow cmake to find the proper Qt libraries.

-DCMAKE_BUILD_TYPE=Release: This switch is used to apply higher level of the compiler optimizations.

-DBUILD_TESTING=OFF: This switch is used to prevent building test programs and libraries that are of no use to an end user.

Contents

Installed Programs: balooctl, baloo_file, baloo_file_extractor, baloosearch, balooshow, checkXML5, depdiagram-generate, depdiagram-generate-all, depdiagram-prepare, desktoptojson, gentrigrams, kactivities-cli, kapidox_generate, kate-syntax-highlighter, kbuildsycoca5, kcookiejar5, kdebugdialog5, kded5, kdeinit5, kdeinit5_shutdown, kdeinit5_wrapper, kf5-config, kf5kross, kgendesignerplugin, kglobalaccel5, kiconfinder5, kjs5, kjscmd5, kjsconsole, knewstuff-dialog, kpackagelauncherqml, kpackagetool5, kquitapp5, kreadconfig5, kshell5, ktelnetservice5, ktrash5, kwalletd5, kwallet-query, kwrapper5, kwriteconfig5, meinproc5, parsetrigrams, plasmapkg2, preparetips5, protocoltojson, and solid-hardware5
Installed Libraries: libkdeinit5_klauncher.so, libKF5Activities.so, libKF5ActivitiesStats.so, libKF5Archive.so, libKF5Attica.so, libKF5AuthCore.so, libKF5Auth.so, libKF5Baloo.so, libKF5BluezQt.so, libKF5Bookmarks.so, libKF5CalendarCore.so, libKF5CalendarEvents.so, libKF5Codecs.so, libKF5Completion.so, libKF5ConfigCore.so, libKF5ConfigGui.so, libKF5ConfigWidgets.so, libKF5Contacts.so, libKF5CoreAddons.so, libKF5Crash.so, libKF5DAV.so, libKF5DBusAddons.so, libKF5Declarative.so, libKF5DNSSD.so, libKF5DocTools.so, libKF5Emoticons.so, libKF5FileMetaData.so, libKF5GlobalAccel.so, libKF5GuiAddons.so, libKF5Holidays.so, libKF5I18n.so, libKF5IconThemes.so, libKF5IdleTime.so, libKF5ItemModels.so, libKF5ItemViews.so, libKF5JobWidgets.so, libKF5JSApi.so, libKF5JsEmbed.so, libKF5JS.so, libKF5KCMUtils.so, libKF5KDELibs4Support.so, libKF5KHtml.so, libKF5KIOCore.so, libKF5KIOFileWidgets.so, libKF5KIOGui.so, libKF5KIONTLM.so, libKF5KIOWidgets.so, libKF5Kirigami2.so, libKF5KrossCore.so, libKF5KrossUi.so, libKF5MediaPlayer.so, libKF5NetworkManagerQt.so, libKF5NewStuffCore.so, libKF5NewStuff.so, libKF5Notifications.so, libKF5NotifyConfig.so, libKF5Package.so, libKF5Parts.so, libKF5PeopleBackend.so, libKF5People.so, libKF5PeopleWidgets.so, libKF5PlasmaQuick.so, libKF5Plasma.so, libKF5Plotting.so, libKF5Prison.so, libKF5Pty.so, libKF5Purpose.so, libKF5PurposeWidgets.so, libKF5QuickAddons.so, libKF5Runner.so, libKF5Service.so, libKF5Solid.so, libKF5SonnetCore.so, libKF5SonnetUi.so, libKF5Style.so, libKF5Su.so, libKF5SyntaxHighlighting.so, libKF5TextEditor.so, libKF5TextWidgets.so, libKF5ThreadWeaver.so, libKF5UnitConversion.so, libKF5Wallet.so, libKF5WaylandClient.so, libKF5WaylandServer.so, libKF5WidgetsAddons.so, libKF5WindowSystem.so, libKF5XmlGui.so, libKF5XmlRpcClient.so, and libkwalletbackend5.so
Installed Directories: /opt/kf5 (symlink to /opt/kf5-5.91.0) if installing in /opt

Short Descriptions

checkXML5

is a tool to check for syntax errors in KDE DocBook XML files

depdiagram-generate

is a tool to generate a dependency diagram

depdiagram-generate-all

is a tool to generate a dependency diagram for all frameworks at once

depdiagram-prepare

is a tool to prepare dot files

desktoptojson

is a tool to convert a .desktop file to a .json file

kbuildsycoca5

rebuilds the KService desktop file system configuration cache

kcookiejar5

is a command line interface to the HTTP cookie store used by KDE, a D-BUS service to store/retrieve/clean cookies

kded5

consolidates several small services in one process

kdeinit5

is a process launcher somewhat similar to the famous init used for booting UNIX

kf5-config

is a command line program used to retrieve information about KDE installation or user paths

kf5kross

executes kross scripts written in KDE Javascript, Python, Ruby, Java and Falcon

kgendesignerplugin

generates widget plugins for Qt(TM) Designer

kglobalaccel5

is a daemon use to register the key bindings and for getting notified when the action triggered

kjs5

is KDE ECMAScript/JavaScript engine

kjscmd5

is a tool for launching KJSEmbed scripts from the command line

kjsconsole

is a console for kjs5

kpackagelauncherqml

is a commandline tool for launching kpackage QML application

kpackagetool5

is a command line kpackage tool

kreadconfig5

is a command line tool to retrieve values from KDE configuration files

kshell5

start applications via kdeinit

ktelnetservice5

is a telnet service

ktrash5

is a helper program to handle the KDE trash can

kwalletd5

is the wallet manager daemon

kwriteconfig5

is a command line tool to write values in KDE configuration files

meinproc5

converts DocBook files to HTML

plasmapkg2

is a tool to install, list, remove Plasma packages

preparetips5

is a script to extract the text from a tips file

solid-hardware5

is a command line tool to investigate available devices

Last updated on

Chapter 31. KDE Frameworks 5 Based Applications

Ark-21.12.2

Introduction to Ark

The Ark package is a KF5 archive tool. It is a graphical front end to tar and similar tools.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Ark Dependencies

Required

KDE Frameworks-5.91.0 and libarchive-3.6.0

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/ark5

Installation of Ark

Install Ark by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=$KF5_PREFIX \
      -DCMAKE_BUILD_TYPE=Release         \
      -DBUILD_TESTING=OFF                \
      -Wno-dev .. &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: ark
Installed Libraries: libkerfuffle.so
Installed Directories: $KF5_PREFIX/lib/plugins/kerfuffle, $KF5_PREFIX/share/doc/HTML/*/ark, and $KF5_PREFIX/share/kxmlgui5/ark

Short Descriptions

ark

is a KF5-based Archive Manager

Last updated on

Kdenlive-21.12.2

Introduction to Kdenlive

The Kdenlive package is a KF5 based video editor.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Kdenlive Dependencies

Required

KDE Frameworks-5.91.0, mlt-7.4.0, and v4l-utils-1.22.1 (runtime)

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/kdenlive5

Installation of Kdenlive

Install Kdenlive by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=$KF5_PREFIX \
      -DCMAKE_BUILD_TYPE=Release         \
      -DBUILD_TESTING=OFF                \
      -Wno-dev .. &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: kdenlive and kdenlive_render
Installed Libraries: mltpreview.so
Installed Directories: $KF5_PREFIX/share/doc/HTML/*/kdenlive, $KF5_PREFIX/share/kdenlive, and $KF5_PREFIX/share/kxmlgui5/kdenlive

Short Descriptions

kdenlive

is an open source non-linear video editor which supports a large number of formats

kdenlive_render

is a render program for kdenlive

Last updated on

KMix-21.12.2

Introduction to KMix

The KMix package contains a KF5 based Sound Mixer application.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

KMix Dependencies

Required

KDE Frameworks-5.91.0

Recommended
Optional

libcanberra-0.30 and PulseAudio-15.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/kmix5

Installation of KMix

Install KMix by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=$KF5_PREFIX \
      -DCMAKE_BUILD_TYPE=Release         \
      -DBUILD_TESTING=OFF                \
      -Wno-dev .. &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: kmix, kmixctrl, and kmixremote
Installed Libraries: libkmixcore.so
Installed Directories: $KF5_PREFIX/share/kmix, $KF5_PREFIX/share/kxmlgui5/kmix, and $KF5_PREFIX/share/doc/HTML/*/kmix

Short Descriptions

kmix

is a mini audio mixer for kde

kmixctrl

is used to save or restore the settings of kmix

kmixremote

is a utility to mute, get and set volume levels

Last updated on

kio-extras-21.12.2

Introduction to kio-extras

The kio-extras package contains additional components to increase the functionality of the KDE resource and network access abstractions.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

kio-extras Dependencies

Required

kdsoap-2.0.0 and KDE Frameworks-5.91.0

Optional

libtirpc-1.3.2, Samba-4.15.5, and taglib-1.12

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/kio-extras

Installation of kio-extras

Install kio-extras by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=$KF5_PREFIX \
      -DCMAKE_BUILD_TYPE=Release         \
      -DBUILD_TESTING=OFF                \
      -Wno-dev .. &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: libkioarchive.so and 32 plugins
Installed Directories: None

Khelpcenter-21.12.2

Introduction to Khelpcenter

Khelpcenter is an application to show KDE Applications' documentation.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Khelpcenter Dependencies

Required

grantlee-5.2.0, KDE Frameworks-5.91.0, libxml2-2.9.13, and xapian-1.4.19

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/khelpcenter

Installation of Khelpcenter

Install khelpcenter by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=$KF5_PREFIX \
      -DCMAKE_BUILD_TYPE=Release         \
      -DBUILD_TESTING=OFF                \
      -Wno-dev .. &&
make

This package does not come with a test suite.

Now, as the root user:

make install  &&

mv -v $KF5_PREFIX/share/kde4/services/khelpcenter.desktop /usr/share/applications/ &&
rm -rv $KF5_PREFIX/share/kde4

Contents

Installed Program: khelpcenter
Installed Libraries: libkdeinit5_khelpcenter.so
Installed Directories: $KF5_PREFIX/share/khelpcenter, $KF5_PREFIX/share/kxmlgui5/khelpcenter, and $KF5_PREFIX/share/doc/HTML/*/{khelpcenter,fundamentals,onlinehelp}

Short Descriptions

khelpcenter

is the help viewer for KDE applications

Last updated on

Konsole-21.12.2

Introduction to Konsole

The Konsole package is a KF5 based terminal emulator.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Konsole Dependencies

Required

KDE Frameworks-5.91.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/konsole5

Installation of Konsole

Note

In non-plasma environments, the konsole scrollbar and its handle do not show up well. If desired, apply the optional patch to the package:

patch -Np1 -i ../konsole-21.12.2-scrollbar-1.patch

The patch makes the scrollbar light gray with a small white border. The handle is dark gray. If desired, the colors may be changed to taste by editing the patch.

Install Konsole by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=$KF5_PREFIX \
      -DCMAKE_BUILD_TYPE=Release         \
      -DBUILD_TESTING=OFF                \
      -Wno-dev .. &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: konsole and konsoleprofile
Installed Libraries: libkdeinit5_konsole.so and libkonsoleprivate.so
Installed Directories: $KF5_PREFIX/share/doc/HTML/*/konsole, $KF5_PREFIX/share/konsole, and $KF5_PREFIX/share/kxmlgui5/konsole

Short Descriptions

konsole

is an X terminal emulation which provides a command-line interface

konsoleprofile

is a command-line tool to change the current tab's profile options

Last updated on

libkexiv2-21.12.2

Introduction to libkexiv2

Libkexiv2 is a KDE wrapper around the Exiv2 library for manipulating image metadata.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libkexiv2 Dependencies

Required

KDE Frameworks-5.91.0 and Exiv2-0.27.5

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libkexiv2

Installation of libkexiv2

Install libkexiv2 by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=$KF5_PREFIX \
      -DCMAKE_BUILD_TYPE=Release         \
      -DBUILD_TESTING=OFF                \
      -Wno-dev .. &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Library: libKF5KExiv2.so
Installed Directories: $KF5_PREFIX/include/KF5/KExiv2 and $KF5_PREFIX/lib/cmake/KF5KExiv2

Last updated on

Okular-21.12.2

Introduction to Okular

Okular is a document viewer for KDE. It can view documents of many types including PDF, PostScript, TIFF, Microsoft CHM, DjVu, DVI, XPS and ePub.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Okular Dependencies

Required

KDE Frameworks-5.91.0

Recommended
Optional

qca-2.3.4, DjVuLibre, kpimtextedit, libspectre (for PostScript support), libchm, libepub, and Mobipocket

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/okular5

Installation of Okular

Install Okular by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=$KF5_PREFIX \
      -DCMAKE_BUILD_TYPE=Release         \
      -DBUILD_TESTING=OFF                \
      -Wno-dev .. &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Program: okular
Installed Library: libOkular5Core.so
Installed Directories: $KF5_PREFIX/include/okular, $KF5_PREFIX/lib/cmake/Okular5, $KF5_PREFIX/lib/plugins/okular, $KF5_PREFIX/share/kxmlgui5/okular, $KF5_PREFIX/share/okular, $KF5_PREFIX/share/doc/HTML/*/okular, and

Short Descriptions

okular

is a document viewer

Last updated on

libkdcraw-21.12.2

Introduction to libkdcraw

Libkdcraw is a KDE wrapper around the libraw-0.20.2 library for manipulating image metadata.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libkdcraw Dependencies

Required

KDE Frameworks-5.91.0 and libraw-0.20.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libkdcraw

Installation of libkdcraw

Install libkdcraw by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=$KF5_PREFIX \
      -DCMAKE_BUILD_TYPE=Release         \
      -DBUILD_TESTING=OFF                \
      -Wno-dev .. &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Library: libKF5KDcraw.so
Installed Directories: $KF5_PREFIX/include/KF5/KDCRAW and $KF5_PREFIX/lib/cmake/KF5KDcraw

Last updated on

Gwenview-21.12.2

Introduction to Gwenview

Gwenview is a fast and easy-to-use image viewer for KDE.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Gwenview Dependencies

Required

Exiv2-0.27.5, KDE Frameworks-5.91.0, and Little CMS-2.13.1

Recommended
Optional

KF5Kipi

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gwenview

Installation of Gwenview

Install Gwenview by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=$KF5_PREFIX \
      -DCMAKE_BUILD_TYPE=Release         \
      -DBUILD_TESTING=OFF                \
      -Wno-dev .. &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Program: gwenview and gwenview_importer
Installed Libraries: libgwenviewlib.so and gvpart.so
Installed Directories: $KF5_PREFIX/share/{kxmlgui5/gvpart,gwenview,doc/HTML/*/gwenview}

Short Descriptions

gwenview

is the KDE image viewer

gwenview_importer

is a Photo importer

Last updated on

libkcddb-21.12.2

Introduction to libkcddb

The libkcddb package contains a library used to retrieve audio CD meta data from the internet.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libkcddb Dependencies

Required

KDE Frameworks-5.91.0 and libmusicbrainz-5.1.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libkcddb

Installation of libkcddb

Install libkcddb by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=$KF5_PREFIX \
      -DCMAKE_BUILD_TYPE=Release         \
      -DBUILD_TESTING=OFF                \
      -Wno-dev ..                        &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: libKF5Cddb.so and kcm_cddb.so
Installed Directories: $KF5_PREFIX/include/KF5/KCddb and $KF5_PREFIX/lib/cmake/KF5Cddb $KF5_PREFIX/share/doc/HTML/*/kcontrol

Short Descriptions

libkcddb.so

contains functions used to retrieve audio CD meta data from the internet

Last updated on

k3b-21.12.2

Introduction to K3b

The K3b package contains a KF5-based graphical interface to the Cdrtools and dvd+rw-tools CD/DVD manipulation tools. It also combines the capabilities of many other multimedia packages into one central interface to provide a simple-to-operate application that can be used to handle many of your CD/DVD recording and formatting requirements. It is used for creating audio, data, video and mixed-mode CDs as well as copying, ripping and burning CDs and DVDs.

Though k3b can be used to copy almost any DVD to similar medium, it does not provide a way to copy, or reproduce a double-layer DVD onto single-layer medium. Of course, there is not a program anywhere on any platform that can make an exact duplicate of a double-layer DVD onto a single-layer disk, there are programs on some platforms that can compress the data on a double-layer DVD to fit on a single-layer DVD producing a duplicate, but compressed, image. If you need to copy the contents of a double-layer DVD to single-layer medium, you may want to look at the RMLCopyDVD package.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

K3b Dependencies

Required

KDE Frameworks-5.91.0, libkcddb-21.12.2, libsamplerate-0.2.2, and shared-mime-info-2.1

The CD/DVD drive is detected at run time using UDisks-2.9.4, which must therefore be installed before running k3b.

Recommended
Optional

FLAC-1.3.3, LAME-3.100, libmad-0.15.1b, libsndfile-1.0.31, libvorbis-1.3.7, libmusicbrainz-2.1.5, and Musepack (libmpcdec)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/k3b

Installation of K3b

Install K3b by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=$KF5_PREFIX \
      -DCMAKE_BUILD_TYPE=Release         \
      -DBUILD_TESTING=OFF                \
      -Wno-dev ..                        &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: k3b
Installed Libraries: libk3bdevice.so, libk3blib.so, and numerous plugin modules for the installed dependencies
Installed Directories: $KF5_PREFIX/share/{,kxmlgui5/}k3b and $KF5_PREFIX/share/doc/HTML/*/k3b

Short Descriptions

k3b

is the graphical CD/DVD program

Last updated on

Further KDE5 packages

This section did not provide instructions for all of the available packages in the KDE5 Software Compilation. The included packages were selected based on what most people would want to use on a standard desktop computer.

For a full list of available packages, have a look on the KDE5 servers at https://download.kde.org/stable/release-service/21.12.2/src.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Further_KDE_Packages

Some additional packages worth mentioning are:

  • Juk: A lightweight music player.

  • Dragon: A video player.

  • Kcalc: A scientific calculator.

  • Kwalletmanager: A credentials management application.

  • Marble: A global map program.

  • A variety (about 40) of KDE games including: kpat, kfourinline, and kmines.

Note

Some packages will require additional dependencies. To determine what dependencies are needed, run from the top of the source tree:

cmake -Wno-dev -L .

Most of these packages can be built with the standard KDE5 instructions:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=$KF5_PREFIX \
      -DCMAKE_BUILD_TYPE=Release         \
      -DBUILD_TESTING=OFF                \
      -Wno-dev .. &&
make

And as the root user:

make install

Last updated on

Chapter 32. KDE Plasma 5

KDE Plasma 5 is a desktop environment built using KDE Frameworks 5 and QML which runs on top of a fully hardware accelerated graphics stack using Qt5, QtQuick 2 and an OpenGL(-ES) scenegraph.

No additional configuration is needed before building the KDE Plasma 5 because it uses the same configuration that KDE Frameworks 5 uses.

Building Plasma 5

KDE Plasma 5 is a collection of packages based on top of KDE Frameworks 5 and QML. They implement the KDE Display Environment (Plasma 5).

This package is known to build and work properly using an LFS-11.1 platform.

The instructions below build all of the Plasma 5 packages in one step by using a bash script.

Package Information

Plasma 5 Dependencies

Required

GTK+-2.24.33, GTK+-3.24.31, KDE Frameworks-5.91.0, libpwquality-1.4.4, libqalculate-4.0.0, libxkbcommon-1.4.0, Mesa-21.3.6 built with Wayland-1.20.0, NetworkManager-1.34.0, pipewire-0.3.47, PulseAudio-15.0, qca-2.3.4, sassc-3.6.2, taglib-1.12, and xcb-util-cursor-0.1.3

Recommended
Recommended (runtime)
Optional

GLU-9.0.2, ibus-1.5.25, qtwebengine-5.15.8, Xorg Synaptics Driver-1.9.1, appstream-qt, KDevPlatform, libgps, libhybris, libraw1394, mockcpp, packagekit-qt, Qalculate, Qapt, SCIM, and socat (for pam_kwallet)

Note

Only two plasma packages optionally use qtwebengine-5.15.8: libksysguard and kdeplasma-addons. If QtWebEngine is installed later, only those two packages have to be rebuilt. This allows to provide a more complete display in the system monitor application.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/kf5

Downloading KDE Plasma5

The easiest way to get the KDE Plasma5 packages is to use a single wget to fetch them all at once:

url=https://download.kde.org/stable/plasma/5.24.0/
wget -r -nH -nd -A '*.xz' -np $url

The options used here are:
  -r            recurse through child directories
  -nH           disable generation of host-prefixed directories
  -nd           do not create a hierarchy of directories
  -A '*.xz'     just get the *.xz files
  -np           don't get parent directories

Setting Package Order

The order of building files is important due to internal dependencies. Create the list of files in the proper order as follows:

cat > plasma-5.24.0.md5 << "EOF"
d5a143b93d183e46d2d9eecb65ca32d6  kdecoration-5.24.0.tar.xz
25328009546df7703a45a51c27befc76  libkscreen-5.24.0.tar.xz
3869c4c0c3acc7fcb2a210aac6480249  libksysguard-5.24.0.tar.xz
3065e58dd9832b419e68b38921a97c24  breeze-5.24.0.tar.xz
6fad933f0ee6f852ae58d906444b9595  breeze-gtk-5.24.0.tar.xz
7eae43606459dd0a288d5c081d9a6a2a  layer-shell-qt-5.24.0.tar.xz
127f90c5e77d404949446813baf7d61a  kscreenlocker-5.24.0.tar.xz
626ae567af6b34bb3f8a0ffc18093e95  oxygen-5.24.0.tar.xz
f9a542276e05b3b4cb9fbd32c541a552  kinfocenter-5.24.0.tar.xz
cad3dc7c0b9ca2faa9f8d25b4b2d857d  kwayland-server-5.24.0.tar.xz
a401b80ab133740bb9c006cdf0eaedbf  kwin-5.24.0.tar.xz
56e20e9dd1767457613592c1edece60b  plasma-workspace-5.24.0.tar.xz
c8aa0ccd5cf5b428e16a25410f8ac33f  plasma-disks-5.24.0.tar.xz
6b7e9f27503c829924048bf65a0c4763  bluedevil-5.24.0.tar.xz
5dcd7cb3e9401942b1307ec65dcf7ea5  kde-gtk-config-5.24.0.tar.xz
5a289a97f76a416a9ac6a62dc8fe733a  khotkeys-5.24.0.tar.xz
a7485966e66b63f50eddbcbc4790832c  kmenuedit-5.24.0.tar.xz
507d12a9237fded95bbd1532e4a7b66b  kscreen-5.24.0.tar.xz
4c2f698253f260a955ed1867d1ec9007  kwallet-pam-5.24.0.tar.xz
1e5ff352ea3b039b112efe37677eff45  kwayland-integration-5.24.0.tar.xz
4f3d56f758541d046ad69e842fccac7b  kwrited-5.24.0.tar.xz
5e1d46d9bf8d0a03694903e83d070e3f  milou-5.24.0.tar.xz
b6e7be0be859d21947284e233d6e2931  plasma-nm-5.24.0.tar.xz
d99ceab1dd9986122690a4b24d50b114  plasma-pa-5.24.0.tar.xz
bad6e9079ac8ad192b8375242e5b1121  plasma-workspace-wallpapers-5.24.0.tar.xz
eacdd3ef241f27d7ae68abce49d47a45  polkit-kde-agent-1-5.24.0.tar.xz
8b1299077c31395e2f04b28d94d1ca06  powerdevil-5.24.0.tar.xz
8c07b6d13e9ed8965abb38f0c3bdfdbf  plasma-desktop-5.24.0.tar.xz
0f52913bec0b9ae5fe7c39b7eb7c0822  kdeplasma-addons-5.24.0.tar.xz
3dfd5a918fe12eaec8cf3fc291c69bfb  kgamma5-5.24.0.tar.xz
63bd9da2abdbffb38f7b89d4d1e6e52b  ksshaskpass-5.24.0.tar.xz
#e4353dc4d36d9ed54d25df4e2538ef04  plasma-sdk-5.24.0.tar.xz
9f4568cf9b1ace13f082bb38f45f0079  sddm-kcm-5.24.0.tar.xz
1759fb71e190f0fd506e98f68d1df938  discover-5.24.0.tar.xz
#89000e84cca76de236e576c922979352  breeze-grub-5.24.0.tar.xz
#5f34ae758eab4fc8343e2fad5b7afbfb  breeze-plymouth-5.24.0.tar.xz
f2485f5a857898ae47c256ae8d9b4893  kactivitymanagerd-5.24.0.tar.xz
050d04b18ce5f00fb7dfef31000d88b6  plasma-integration-5.24.0.tar.xz
1eab4ed3b88ef3a712223afc4c116a7d  plasma-tests-5.24.0.tar.xz
#8b19cc2d7929cf988a44606a3eba7644  plymouth-kcm-5.24.0.tar.xz
9aafa58faea1bd7f90776f6e63d3866a  xdg-desktop-portal-kde-5.24.0.tar.xz
fe87c0f534cbefe3955faecfe5fcfc4d  drkonqi-5.24.0.tar.xz
c6f224eb9eb6f87e0af1464d7a933d09  plasma-vault-5.24.0.tar.xz
d3c42b17d180af6ddf9821abd6f36d7e  plasma-browser-integration-5.24.0.tar.xz
a7157d0f6a12d2da890643b30bb02967  kde-cli-tools-5.24.0.tar.xz
3c7a50b0eb124cb6d1886cc89a0de5e8  systemsettings-5.24.0.tar.xz
e6346ea04baa5c25e706145777a193dc  plasma-thunderbolt-5.24.0.tar.xz
#e4daa179a4bce0f03f4988186dfe3e31  plasma-nano-5.24.0.tar.xz
#3e0e67f2a798b51025cb97a750fc1dea  plasma-phone-components-5.24.0.tar.xz
#3e0e67f2a798b51025cb97a750fc1dea  plasma-mobile-5.24.0.tar.xz
2c43882de9c657073aed4df2c01eeac4  plasma-firewall-5.24.0.tar.xz
886d89f75a6ba9324586154816a9bcef  plasma-systemmonitor-5.24.0.tar.xz
61903525c0e1585cb00e1b7c7c690145  qqc2-breeze-style-5.24.0.tar.xz
f1e7a6af9a0862cc8812426e4d040be6  ksystemstats-5.24.0.tar.xz
EOF

Note

The breeze-grub, breeze-plymouth, and plymouth-kcm packages above are all for customized support of Plymouth which is designed to be run within an initial ram disk during boot (see the section called “About initramfs”). The plasma-sdk package is optional and used for software development. The plasma-nano package is used for embedded systems and plasma-phone-components provides phone functionality for Plasma.

Installation of Plasma5

Note

When installing multiple packages in a script, the installation needs to be done as the root user. There are three general options that can be used to do this:

  1. Run the entire script as the root user (not recommended).

  2. Use the sudo command from the Sudo-1.9.9 package.

  3. Use su -c "command arguments" (quotes required) which will ask for the root password for every iteration of the loop.

One way to handle this situation is to create a short bash function that automatically selects the appropriate method. Once the command is set in the environment, it does not need to be set again.

as_root()
{
  if   [ $EUID = 0 ];        then $*
  elif [ -x /usr/bin/sudo ]; then sudo $*
  else                            su -c \\"$*\\"
  fi
}

export -f as_root

First, start a subshell that will exit on error:

bash -e

Install all of the packages by running the following commands:

while read -r line; do

    # Get the file name, ignoring comments and blank lines
    if $(echo $line | grep -E -q '^ *$|^#' ); then continue; fi
    file=$(echo $line | cut -d" " -f2)

    pkg=$(echo $file|sed 's|^.*/||')          # Remove directory
    packagedir=$(echo $pkg|sed 's|\.tar.*||') # Package directory

    tar -xf $file
    pushd $packagedir

       mkdir build
       cd    build

       cmake -DCMAKE_INSTALL_PREFIX=$KF5_PREFIX \
             -DCMAKE_BUILD_TYPE=Release         \
             -DBUILD_TESTING=OFF                \
             -Wno-dev ..  &&

        make
        as_root make install
    popd


    as_root rm -rf $packagedir
    as_root /sbin/ldconfig

done < plasma-5.24.0.md5

exit

If you did not set $KF5_PREFIX to /usr, create symlinks to allow display managers to find Plasma:

as_root install -dvm 755 /usr/share/xsessions              &&
cd /usr/share/xsessions/                                   &&
[ -e plasma.desktop ]                                      ||
as_root ln -sfv $KF5_PREFIX/share/xsessions/plasma.desktop &&
as_root install -dvm 755 /usr/share/wayland-sessions       &&
cd /usr/share/wayland-sessions/                            &&
[ -e plasmawayland.desktop ]                               ||
as_root ln -sfv $KF5_PREFIX/share/wayland-sessions/plasmawayland.desktop

Useless systemd units have been installed in $KF5_PREFIX/lib. Remove them now (as root):

rm -rf $KF5_PREFIX/lib/systemd

Configuring Plasma

Linux PAM Configuration

If you built Plasma with the recommended Linux PAM support, create necessary configuration files by running the following commands as the root user:

cat > /etc/pam.d/kde << "EOF"
# Begin /etc/pam.d/kde

auth     requisite      pam_nologin.so
auth     required       pam_env.so

auth     required       pam_succeed_if.so uid >= 1000 quiet
auth     include        system-auth

account  include        system-account
password include        system-password
session  include        system-session

# End /etc/pam.d/kde
EOF

cat > /etc/pam.d/kde-np << "EOF"
# Begin /etc/pam.d/kde-np

auth     requisite      pam_nologin.so
auth     required       pam_env.so

auth     required       pam_succeed_if.so uid >= 1000 quiet
auth     required       pam_permit.so

account  include        system-account
password include        system-password
session  include        system-session

# End /etc/pam.d/kde-np
EOF

cat > /etc/pam.d/kscreensaver << "EOF"
# Begin /etc/pam.d/kscreensaver

auth    include system-auth
account include system-account

# End /etc/pam.d/kscreensaver
EOF

Starting Plasma5

You can start Plasma5 from runlevel 3, using xinit-1.4.1, or from runlevel 5, using a Display Manager, such as lightdm-1.30.0.

To start Plasma 5 using xinit-1.4.1, run the following commands:

cat > ~/.xinitrc << "EOF"
dbus-launch --exit-with-session $KF5_PREFIX/bin/startplasma-x11
EOF

startx

The X session starts on the first unused virtual terminal, normally vt7. You can switch to another vtn simultaneously pressing the keys Ctrl-Alt-Fn (n=1, 2, ...). To switch back to the X session, normally started at vt7, use Ctrl-Alt-F7. The vt where the command startx was executed will display many messages, including X starting messages, applications automatically started with the session, and eventually, some warning and error messages. You may prefer to redirect those messages to a log file, which not only will keep the initial vt uncluttered, but can also be used for debugging purposes. This can be done starting X with:

startx &> ~/x-session-errors

When shutting down or rebooting, the shutdown messages appear on the vt where X was running. If you wish to see those messages, simultaneously press keys Alt-F7 (assuming that X was running on vt7).

Contents

Installed Programs: There are too many plasma programs (63 in /opt/kf5/bin) to list separately here.
Installed Libraries: There are too many plasma libraries (40 in /opt/kf5/lib) to list separately here.
Installed Directories: There are too many plasma directories (over 1000 in /opt/kf5) to list separately here.

Last updated on

Part VIII. GNOME

Chapter 33. GNOME Libraries and Desktop

The objective of this section is to build a GNOME desktop.

Libraries

Last updated on

Gcr-3.40.0

Introduction to Gcr

The Gcr package contains libraries used for displaying certificates and accessing key stores. It also provides the viewer for crypto files on the GNOME Desktop.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Gcr Dependencies

Required

GLib-2.70.4, libgcrypt-1.10.0, and p11-kit-0.24.1

Recommended
Optional

GTK-Doc-1.33.2 and Valgrind-3.18.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gcr

Installation of Gcr

First apply a fix for building with newer versions of meson:

find . -name meson.build | xargs sed -i /packages.\*deps/d

Install Gcr by running the following commands:

sed -i 's:"/desktop:"/org:' schema/*.xml &&

sed -e '208 s/@BASENAME@/gcr-viewer.desktop/'   \
    -e '231 s/@BASENAME@/gcr-prompter.desktop/' \
    -i ui/meson.build                           &&

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release -Dgtk_doc=false .. &&
ninja

To test the results, issue: ninja test. The tests must be run from an X Terminal or similar.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

sed ... schema/*.xml: This command fixes a deprecated entry in the schema template.

sed ... ui/meson.build: This command fixes a problem when building with meson-0.59.0.

-Dgtk=false: Use this switch if you haven't installed GTK+-3.24.31. Note that gcr-viewer will not be installed if this is passed to meson.

-Dgtk_doc=true: Use this switch if you wish to generate the API reference documentation. Note that you must have GTK-Doc installed.

Contents

Installed Program: gcr-viewer
Installed Libraries: libgck-1.so, libgcr-base-3.so and libgcr-ui-3.so
Installed Directories: /usr/include/gck-1, /usr/include/gcr-3, and /usr/share/gtk-doc/html/{gcr,gck}

Short Descriptions

gcr-viewer

is used to view certificates and key files

libgck-1.so

contains GObject bindings for PKCS#11

Last updated on

gsettings-desktop-schemas-41.0

Introduction to GSettings Desktop Schemas

The GSettings Desktop Schemas package contains a collection of GSettings schemas for settings shared by various components of a GNOME Desktop.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GSettings Desktop Schemas Dependencies

Required

GLib-2.70.4 and gobject-introspection-1.70.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gsettings-desktop-schemas

Installation of GSettings Desktop Schemas

Install GSettings Desktop Schemas by running the following commands:

sed -i -r 's:"(/system):"/org/gnome\1:g' schemas/*.in &&

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Note

If you installed the package to your system using a DESTDIR method, /usr/share/glib-2.0/schemas/gschemas.compiled was not updated/created. Create (or update) the file using the following command as the root user:

glib-compile-schemas /usr/share/glib-2.0/schemas

Command Explanations

sed ... schemas/*.in: This command fixes some deprecated entries in the schema templates.

Contents

Installed Programs: None
Installed Libraries: None
Installed Directory: /usr/include/gsettings-desktop-schemas and /usr/share/GConf/gsettings

Last updated on

libsecret-0.20.5

Introduction to libsecret

The libsecret package contains a GObject based library for accessing the Secret Service API.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libsecret Dependencies

Required

GLib-2.70.4

Recommended
Optional

GTK-Doc-1.33.2 and docbook-xml-4.5, docbook-xsl-1.79.2, libxslt-1.1.35 (to build manual pages), and Valgrind-3.18.1 (can be used in tests)

Optional (Required for the testsuite)

D-Bus Python-1.2.18, Gjs-1.70.1, PyGObject-3.42.0 (Python 3 module), and tpm2-tss

Runtime Dependency

gnome-keyring-40.0

Note

Any package requiring libsecret expects GNOME Keyring to be present at runtime.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libsecret

Installation of libsecret

Install libsecret by running the following commands:

mkdir bld &&
cd bld &&

meson --prefix=/usr --buildtype=release -Dgtk_doc=false .. &&
ninja

Now, as the root user:

ninja install

To test the results, issue: ninja test, after the package is installed. The test suite should be run from a local GUI session started with dbus-launch.

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dgtk_doc=false: Remove this if you have GTK-Doc-1.33.2 installed and want to rebuild the documentation with it.

-Dmanpage=false: Use this switch if you have not installed libxslt-1.1.35 and DocBook packages.

-Dgcrypt=false: Use this switch if you have not installed the recommended dependency of libgcrypt-1.10.0.

Contents

Installed Program: secret-tool
Installed Library: libsecret-1.so
Installed Directories: /usr/include/libsecret-1 and /usr/share/gtk-doc/html/libsecret-1

Short Descriptions

secret-tool

is a command line tool that can be used to store and retrieve passwords

libsecret-1.so

contains the libsecret API functions

Last updated on

rest-0.8.1

Introduction to rest

The rest package contains a library that was designed to make it easier to access web services that claim to be "RESTful". It includes convenience wrappers for libsoup and libxml to ease remote use of the RESTful API.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

rest Dependencies

Required

make-ca-1.10 and libsoup-2.74.2

Recommended
Optional

GTK-Doc-1.33.2 and LCOV

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/rest

Installation of rest

Install rest by running the following commands:

./configure --prefix=/usr &&
make

To test the results, issue: make check. The flickr test will fail due to Public API changes on their site. The OAuth tests will fail because the website that it uses to test connectivity via OAuth no longer exists.

Now, as the root user:

make install

Command Explanations

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Libraries: librest-0.7.so and librest-extras-0.7.so
Installed Directories: /usr/include/rest-0.7 and /usr/share/gtk-doc/html/rest-0.7

Short Descriptions

librest-0.7.so

contains the RESTful Web API Query functions

librest-extras-0.7.so

contains extra RESTful Web API Query functions

Last updated on

totem-pl-parser-3.26.6

Introduction to Totem PL Parser

The Totem PL Parser package contains a simple GObject-based library used to parse multiple playlist formats.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Totem PL Parser Dependencies

Required

libsoup-2.74.2

Recommended
Optional

CMake-3.22.2, GTK-Doc-1.33.2, Gvfs-1.48.1 (for some tests), LCOV, and libquvi >= 0.9.1 and libquvi-scripts - if they are installed, then lua-socket (git) is necessary for the tests

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/totem-pl-parser

Installation of Totem PL Parser

Install Totem PL Parser by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: None
Installed Libraries: libtotem-plparser-mini.so and libtotem-plparser.so
Installed Directories: /usr/include/totem-pl-parser and /usr/share/gtk-doc/html/totem-pl-parser

Short Descriptions

libtotem-plparser.so

is the Totem Playlist Parser library

libtotem-plparser-mini.so

is the Totem Playlist Parser library, mini version

Last updated on

VTE-0.66.2

Introduction to VTE

The VTE package contains a termcap file implementation for terminal emulators.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

VTE Dependencies

Required

GTK+-3.24.31, libxml2-2.9.13, and pcre2-10.39

Recommended
Optional

FriBidi-1.0.11 and GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/vte

Installation of VTE

Install VTE by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr       \
      --buildtype=release \
      -Dfribidi=false     \
      -D_systemd=false .. &&
ninja

To test the results, issue ninja test.

Now, as the root user:

ninja install &&
rm -v /etc/profile.d/vte.*

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

rm -v /etc/profile.d/vte.*: This command removes two files installed in /etc/profile.d that have no use on a LFS system.

-Dfribidi=false: Omit this switch if you want to enable bidirectional capabilities.

-Dgnutls=false: Add this switch if you do not want to enable GnuTLS support.

-Dvapi=false: Add this switch if you do not want to enable vala bindings.

-Ddocs=true: Add this switch if wish to build the documentation.

Contents

Installed Program: vte-2.91
Installed Library: libvte-2.91.so
Installed Directories: /usr/include/vte-2.91 and (optional) /usr/share/gtk-doc/html/vte-2.91

Short Descriptions

vte-2.91

is a test application for the VTE libraries

libvte-2.91.so

is a library which implements a terminal emulator widget for GTK+ 3

Last updated on

yelp-xsl-41.1

Introduction to Yelp XSL

The Yelp XSL package contains XSL stylesheets that are used by the Yelp help browser to format Docbook and Mallard documents.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Yelp XSL Dependencies

Required

libxslt-1.1.35 and itstool-2.0.7

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/yelp-xsl

Installation of Yelp XSL

Install Yelp XSL by running the following commands:

./configure --prefix=/usr

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: None
Installed Directory: /usr/share/yelp-xsl

Last updated on

GConf-3.2.6

Introduction to GConf

The GConf package contains a configuration database system used by many GNOME applications.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GConf Dependencies

Required

dbus-glib-0.112 and libxml2-2.9.13

Recommended
Optional

OpenLDAP-2.6.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gconf

Installation of GConf

Install GConf by running the following commands:

./configure --prefix=/usr \
            --sysconfdir=/etc \
            --disable-orbit \
            --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&
ln -s gconf.xml.defaults /etc/gconf/gconf.xml.system

Command Explanations

--disable-orbit: This switch is required if ORBit2 is not installed. ORBit2 is a deprecated package.

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: gconf-merge-tree, gconftool-2, gsettings-data-convert and gsettings-schema-convert
Installed Libraries: libgconf-2.so and libgsettingsgconfbackend.so (GIO Module installed in /usr/lib/gio/modules)
Installed Directories: /etc/gconf, /usr/include/gconf, /usr/lib/GConf, /usr/share/gtk-doc/html/gconf and /usr/share/sgml/gconf

Short Descriptions

gconf-merge-tree

merges an XML filesystem hierarchy

gconftool-2

is a command line tool used for manipulating the GConf database

gsettings-data-convert

reads values out of the users GConf database and stores them in GSettings

gsettings-schemas-convert

converts between GConf and GSettings schema file formats

libgconf-2.so

provides the functions necessary to maintain the configuration database

Last updated on

geocode-glib-3.26.2

Introduction to Geocode GLib

The Geocode GLib is a convenience library for the Yahoo! Place Finder APIs. The Place Finder web service allows to do geocoding (finding longitude and latitude from an address), and reverse geocoding (finding an address from coordinates).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Geocode GLib Dependencies

Required

JSON-GLib-1.6.6 and libsoup-2.74.2

Recommended
Optional

GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/geocode-glib

Installation of Geocode GLib

Install Geocode GLib by running the following commands:

mkdir build                                   &&
cd    build                                   &&
meson --prefix /usr --buildtype=release -Denable-gtk-doc=false .. &&
ninja

To test the results, issue: LANG=C ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Denable-gtk-doc=false: Allow this package to be built without GTK-Doc. Remove this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Library: libgeocode-glib.so
Installed Directories: /usr/include/geocode-glib-1.0, /usr/libexec/installed-tests/geocode-glib, /usr/share/icons/gnome/scalable/places, and /usr/share/gtk-doc/html/geocode-glib

Short Descriptions

libgeocode-glib.so

contains the Geocode GLib API functions

Last updated on

Gjs-1.70.1

Introduction to Gjs

Gjs is a set of Javascript bindings for GNOME.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Gjs Dependencies

Required

Cairo-1.17.4, dbus-1.12.20, gobject-introspection-1.70.0, and js78-78.15.0

Recommended (required for GNOME)
Optional

sysprof-3.42.1, Valgrind-3.18.1 (for tests), DTrace, LCOV, and Systemtap

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gjs

Installation of Gjs

Install Gjs by running the following commands:

mkdir gjs-build &&
cd    gjs-build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test. The GTK and Cairo tests will fail if not running in an Xorg session. The gjs:JS / Gtk4 test is known to exit with an ERROR on some systems.

Now, as the root user:

ninja install &&
ln -sfv gjs-console /usr/bin/gjs

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: gjs (symlink) and gjs-console
Installed Library: libgjs.so
Installed Directories: /usr/include/gjs-1.0, /usr/lib/gjs, /usr/libexec/installed-tests/gjs, /usr/share/gjs-1.0, and /usr/share/installed-tests/gjs

Short Descriptions

gjs-console

contains a console to run JavaScript commands

libgjs.so

contains the GNOME JavaScript bindings

Last updated on

gnome-autoar-0.4.3

Introduction to gnome-autoar

The gnome-autoar package provides a framework for automatic archive extraction, compression, and management.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

gnome-autoar Dependencies

Required

libarchive-3.6.0 and GTK+-3.24.31

Recommended
Optional

GTK-Doc-1.33.2 (for building documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-autoar

Installation of gnome-autoar

Install gnome-autoar by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release -Dvapi=true -Dtests=true &&
ninja

To test the results, issue: ninja test

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dgtk_doc=true: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Libraries: libgnome-autoar-0.so and libgnome-autoar-gtk-0.so
Installed Directories: /usr/include/gnome-autoar-0 and /usr/share/gtk-doc/html/gnome-autoar

Short Descriptions

libgnome-autoar-0.so

provides API functions for automatic archive management

libgnome-autoar-gtk-0.so

provides GTK+ widgets to aid in automatic archive management

Last updated on

gnome-desktop-41.3

Introduction to GNOME Desktop

The GNOME Desktop package contains a library that provides an API shared by several applications on the GNOME Desktop.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Desktop Dependencies

Required

gsettings-desktop-schemas-41.0, GTK+-3.24.31, ISO Codes-4.9.0, itstool-2.0.7, libseccomp-2.5.3, libxml2-2.9.13, and xkeyboard-config-2.35.1

Recommended
Optional

GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-desktop

Installation of GNOME Desktop

Install GNOME Desktop by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr                 \
      --buildtype=release           \
      -Dgnome_distributor="BLFS" .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dgnome_distributor="Some Name": Use this parameter to supply a custom name in the Distributor: field of the GNOME About display window.

-Dgtk_doc=true: Use this parameter if you wish to build the API documentation.

-Dinstalled_tests=true: Use this parameter you wish to enable the installed tests.

Contents

Installed Programs: None
Installed Library: libgnome-desktop-3.so
Installed Directories: /usr/include/gnome-desktop-3.0, /usr/libexec/gnome-desktop-debug, /usr/share/gnome, /usr/share/gtk-doc/html/gnome-desktop3, and /usr/share/help/*/{fdl,gpl,lgpl}

Short Descriptions

libgnome-desktop-3.so

contains functions shared by several GNOME applications

Last updated on

gnome-menus-3.36.0

Introduction to GNOME Menus

The GNOME Menus package contains an implementation of the draft Desktop Menu Specification from freedesktop.org. It also contains the GNOME menu layout configuration files and .directory files.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Menus Dependencies

Required

GLib-2.70.4

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-menus

Installation of GNOME Menus

Install GNOME Menus by running the following commands:

./configure --prefix=/usr \
            --sysconfdir=/etc \
            --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Libraries: libgnome-menu-3.so
Installed Directories: /etc/xdg/menus, /usr/include/gnome-menus-3.0, and /usr/share/desktop-directories

Short Descriptions

libgnome-menu-3.so

contains functions required to support GNOME's implementation of the Desktop Menu Specification

Last updated on

gnome-video-effects-0.5.0

Introduction to GNOME Video Effects

The GNOME Video Effects package contains a collection of GStreamer effects.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-video-effects

Installation of GNOME Video Effects

Install GNOME Video Effects by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a testsuite.

Now, as the root user:

ninja install

Contents

Installed Programs: None
Installed Libraries: None
Installed Directory: /usr/share/gnome-video-effects

Last updated on

gnome-online-accounts-3.40.1

Introduction to GNOME Online Accounts

The GNOME Online Accounts package contains a framework used to access the user's online accounts.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Online Accounts Dependencies

Required

Gcr-3.40.0, JSON-GLib-1.6.6, rest-0.8.1, Vala-0.54.7, and WebKitGTK-2.34.6

Recommended
Optional

GTK-Doc-1.33.2, MIT Kerberos V5-1.19.2, and Valgrind-3.18.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-online-accounts

Installation of GNOME Online Accounts

Note

The Google API Key and OAuth tokens below are specific to LFS. If using these instructions for another distro, or if you intend to distribute binary copies of the software using these instructions, please obtain your own keys following the instructions located at http://www.chromium.org/developers/how-tos/api-keys.

Install GNOME Online Accounts by running the following commands:

./configure --prefix=/usr \
            --disable-static \
            --with-google-client-secret=5ntt6GbbkjnTVXx-MSxbmx5e \
            --with-google-client-id=595013732528-llk8trb03f0ldpqq6nprjp1s79596646.apps.googleusercontent.com &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--with-google-client-*: These switches use the BLFS OAuth ID and secret for Google services.

--enable-kerberos: Use this switch if you have installed MIT Kerberos V5-1.19.2 and wish to use it with GNOME Online Accounts.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: goa-daemon and goa-identity-service (library executables)
Installed Libraries: libgoa-1.0.so and libgoa-backend-1.0.so
Installed Directories: /usr/include/goa-1.0, /usr/lib/goa-1.0, and /usr/share/gtk-doc/html/goa

Short Descriptions

goa-daemon

is the GNOME Online Accounts Daemon

libgoa-1.0.so

contains the GNOME Online Accounts API functions

libgoa-backend-1.0.so

contains functions used by GNOME Online Accounts backends

Last updated on

Grilo-0.3.14

Introduction to Grilo

Grilo is a framework focused on making media discovery and browsing easy for applications and application developers.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Grilo Dependencies

Required

GLib-2.70.4 and libxml2-2.9.13

Recommended
Optional

Avahi-0.8, DocBook-utils-0.6.14, liboauth-1.0.3, and GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/grilo

Installation of Grilo

Install Grilo by running the following commands:

mkdir build &&
cd    build    &&

meson --prefix=/usr       \
      --buildtype=release \
      -Denable-gtk-doc=false .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Denable-gtk-doc=false: This option disables generating documentation. If you have GTK-Doc-1.33.2 installed and wish to generate documentation, remove this option.

Contents

Installed Programs: grilo-test-ui-0.3, grl-inspect-0.3 and grl-launch-0.3
Installed Libraries: libgrilo-0.3.so, libgrlnet-0.3.so and libgrlpls-0.3.so
Installed Directories: /usr/include/grilo-0.3

Short Descriptions

grilo-test-ui-0.3

is a simple playground application that you can use to test the framework and its plugins

grl-inspect-0.3

is a tool that prints out information on available Grilo sources

grl-launch-0.3

is a tool to run Grilo operations from command line

libgrilo.so

provides the Grilo framework

libgrlnet.so

provides Grilo networking helpers for plug-ins

libgrlpls.so

provides playlist handling functions

Last updated on

libchamplain-0.12.20

Introduction to libchamplain

The libchamplain package contains a Clutter-based widget that is used to display rich and interactive maps.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libchamplain Dependencies

Required

clutter-gtk-1.8.4, GTK+-3.24.31, libsoup-2.74.2, and SQLite-3.37.2

Recommended
Optional

GTK-Doc-1.33.2 and libmemphis

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libchamplain

Installation of libchamplain

Install libchamplain by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: None
Installed Libraries: libchamplain-0.12.so and libchamplain-gtk-0.12.so
Installed Directories: /usr/include/champlain-0.12 and /usr/share/gtk-doc/html/champlain-0.12

Short Descriptions

libchamplain-0.12.so

contains the libchamplain API functions

libchamplain-gtk-0.12.so

contains the libchamplain GTK+ bindings

Last updated on

libgdata-0.18.1

Introduction to libgdata

The libgdata package is a GLib-based library for accessing online service APIs using the GData protocol, most notably, Google's services. It provides APIs to access the common Google services and has full asynchronous support.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libgdata Dependencies

Required

libsoup-2.74.2, gnome-online-accounts-3.40.1, GTK+-3.24.31, JSON-GLib-1.6.6, and Vala-0.54.7

Recommended
Optional

GTK-Doc-1.33.2 (for documentation), liboauth-1.0.3 (for OAuth v1 support), and uhttpmock-0.5.3 (required for tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libgdata

Installation of libgdata

Install libgdata by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr                 \
      --buildtype=release           \
      -Dgtk_doc=false               \
      -Dalways_build_tests=false .. &&
ninja

If you wish to run the test suite, make sure uhttpmock-0.5.3 is installed and remove -Dalways_build_tests=false in the meson command line. To test the results, issue: ninja test. Note that the tests need network access.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dgtk_doc=false: Remove this if you have GTK-Doc-1.33.2 installed and want to rebuild the documentation with it.

-Doauth1=enabled: Use this option if you wish to build in support for OAuth v1. Note that you must have liboauth-1.0.3 installed in order to enable this option.

Contents

Installed Programs: None
Installed Libraries: libgdata.so
Installed Directories: /usr/include/libgdata and /usr/share/gtk-doc/html/gdata

Short Descriptions

libgdata.so

contains the libgdata API functions

Last updated on

libgee-0.20.5

Introduction to libgee

The libgee package is a collection library providing GObject based interfaces and classes for commonly used data structures.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libgee Dependencies

Required

GLib-2.70.4

Recommended
Optional

Vala-0.54.7 (with Valadoc) and LCOV

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libgee

Installation of libgee

Install libgee by running the following commands:

./configure --prefix=/usr &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Library: libgee-0.8.so
Installed Directory: /usr/include/gee-0.8

Short Descriptions

libgee-0.8.so

contains the libgee API functions

Last updated on

libgtop-2.40.0

Introduction to libgtop

The libgtop package contains the GNOME top libraries.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libgtop Dependencies

Required

GLib-2.70.4 and Xorg Libraries

Recommended
Optional

GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libgtop

Installation of libgtop

Install libgtop by running the following commands:

./configure --prefix=/usr --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: libgtop_daemon2 and libgtop_server2
Installed Library: libgtop-2.0.so
Installed Directories: /usr/include/libgtop-2.0 and /usr/share/gtk-doc/html/libgtop

Short Descriptions

libgtop-2.0.so

contains functions that allow access to system performance data

Last updated on

libgweather-40.0

Introduction to libgweather

The libgweather package is a library used to access weather information from online services for numerous locations.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libgweather Dependencies

Required

geocode-glib-3.26.2, GTK+-3.24.31, and libsoup-2.74.2

Recommended
Optional

GTK-Doc-1.33.2, Glade, and pylint

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libgweather

Installation of libgweather

Install libgweather by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: LANG=C ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dgtk_doc=true: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Libraries: libgweather-3.so
Installed Directories: /usr/lib/libgweather, /usr/include/libgweather-3.0, /usr/share/gtk-doc/html/libgweather-3.0 and /usr/share/libgweather

Short Descriptions

libgweather-3.so

contains functions that allow the retrieval of weather information

Last updated on

libpeas-1.30.0

Introduction to libpeas

libpeas is a GObject based plugins engine, and is targeted at giving every application the chance to assume its own extensibility.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libpeas Dependencies

Required

gobject-introspection-1.70.0 and GTK+-3.24.31

Recommended
Optional

GTK-Doc-1.33.2, Glade, embed, LGI (for LUA bindings, built with LUA-5.1), with either luajit or LUA-5.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libpeas

Installation of libpeas

Install libpeas by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test. An active graphical session with bus address is necessary to run the tests.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dvapi=true: Add this switch if you wish to generate vapi (vala) data.

-Ddemos=false: Add this switch if you do not wish to build the demo programs.

-Dgtk_doc=true: Add this switch if wish to build the reference manual.

Contents

Installed Program: peas-demo
Installed Libraries: libpeas-1.0.so and libpeas-gtk-1.0.so
Installed Directories: /usr/include/libpeas-1.0, /usr/lib/libpeas-1.0, /usr/lib/peas-demo and /usr/share/gtk-doc/html/libpeas

Short Descriptions

peas-demo

is the Peas demo program

libpeas-1.0.so

contains the libpeas API functions

libpeas-gtk-1.0.so

contains the libpeas GTK+ widgets

Last updated on

libwnck-40.1

Introduction to libwnck

The libwnck package contains the Window Navigator Construction Kit.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libwnck Dependencies

Required

GTK+-3.24.31

Recommended
Optional

GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libwnck

Installation of libwnck

Install libwnck by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dgtk_doc=true: Use this option to build the API reference manual.

Contents

Installed Program: wnckprop and wnck-urgency-monitor
Installed Library: libwnck-3.so
Installed Directories: /usr/include/libwnck-3.0 and /usr/share/gtk-doc/html/libwnck-3.0

Short Descriptions

wnckprop

is used to print or modify the properties of a screen/workspace/window, or to interact with it

libwnck-3.so

contains functions for writing pagers and task lists

Last updated on

evolution-data-server-3.42.4

Introduction to Evolution Data Server

The Evolution Data Server package provides a unified backend for programs that work with contacts, tasks, and calendar information. It was originally developed for Evolution (hence the name), but is now used by other packages as well.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Evolution Data Server Dependencies

Required

Gcr-3.40.0, libical-3.0.14, libsecret-0.20.5, nss-3.75, and SQLite-3.37.2.

Recommended
Recommended (Runtime)
Optional

Berkeley DB-5.3.28, GTK-Doc-1.33.2, MIT Kerberos V5-1.19.2, a MTA (that provides a sendmail command), OpenLDAP-2.6.1, and libphonenumber

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/evolution-data-server

Installation of Evolution Data Server

Install Evolution Data Server by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr   \
      -DSYSCONF_INSTALL_DIR=/etc    \
      -DENABLE_VALA_BINDINGS=ON     \
      -DENABLE_INSTALLED_TESTS=ON   \
      -DENABLE_GOOGLE=ON            \
      -DWITH_OPENLDAP=OFF           \
      -DWITH_KRB5=OFF               \
      -DENABLE_INTROSPECTION=ON     \
      -DENABLE_GTK_DOC=OFF          \
      -DWITH_LIBDB=OFF              \
      -DWITH_SYSTEMDUSERUNITDIR=no  \
      .. &&
make

To test the results, issue: make test.

Now, as the root user:

make install

Command Explanations

-DENABLE_GOOGLE=ON: This switch enables access to google services via libgdata-0.18.1 and also enables the Google Authentication option.

-DENABLE_VALA_BINDINGS=ON: This switch enables building the Vala bindings. Remove if you don't have Vala-0.54.7 installed.

-DENABLE_GTK_DOC=OFF: This switch disables building the API documentation. It is broken for this package due to the use of a long deprecated gtk-doc program that is no longer available.

-DWITH_LIBDB=OFF: This switch allows building this package without Berkeley DB-5.3.28. This package only uses Berkeley DB-5.3.28 to import data from very outdated releases. SQLite-3.37.2 is used for normal operation.

-DWITH_SYSTEMDUSERUNITDIR=no: This switch disables installing the systemd units, which are not used for a Sysv build.

Note

To enable many of the optional dependencies, review the information from cmake -L CMakeLists.txt for the necessary parameters you must pass to the cmake command.

Contents

Installed Programs: None
Installed Libraries: libcamel-1.2.so, libebackend-1.2.so, libebook-1.2.so, libebook-contacts-1.2.so, libecal-2.0.so, libedata-book-1.2.so, libedata-cal-2.0.so, libedataserver-1.2.so, libedataserverui-1.2.so, and libetestserverutils.so
Installed Directories: /usr/include/evolution-data-server, /usr/lib{,exec}/evolution-data-server, /usr/share/installed-tests/evolution-data-server, and /usr/share/pixmaps/evolution-data-server

Short Descriptions

libcamel-1.2.so

is the Evolution MIME message handling library

libebackend-1.2.so

is the utility library for Evolution Data Server Backends

libebook-1.2.so

is the client library for Evolution address books

libebook-contacts-1.2.so

is the client library for Evolution contacts

libecal-1.2.so

is the client library for Evolution calendars

libedata-book-1.2.so

is the backend library for Evolution address books

libedata-cal-1.2.so

is the backend library for Evolution calendars

libedataserver-1.2.so

is the utility library for Evolution Data Server

libedataserverui-3.0.so

is the GUI utility library for Evolution Data Server

libetestserverutils.so

is the server test utility library for Evolution Data Server

Last updated on

Folks-0.15.4

Introduction to Folks

Folks is a library that aggregates people from multiple sources (e.g, Telepathy connection managers and Evolution Data Server, Facebook, etc.) to create metacontacts.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Folks Dependencies

Required

evolution-data-server-3.42.4, gobject-introspection-1.70.0, libgee-0.20.5, dbusmock-0.25.0, and telepathy-glib-0.24.2

Recommended
Optional

libsocialweb and Zeitgeist

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/folks

Installation of Folks

Install Folks by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue ninja test from a local X session started with dbus-launch. A few tests may time out.

Now, as the root user:

ninja install

Command Explanations

-Ddocs=true: This switch enables documentation generation.

Contents

Installed Programs: folks-import and folks-inspect
Installed Libraries: libfolks-dummy.so, libfolks-eds.so, libfolks.so, and libfolks-telepathy.so
Installed Directories: /usr/include/folks and /usr/lib/folks

Short Descriptions

folks-import

is used to import meta-contact information to libfolks

folks-inspect

is used to inspect meta-contact information in libfolks

libfolks-eds.so

contains Evolution specific implementations of the libfolks classes

libfolks.so

contains the Folks API functions

libfolks-telepathy.so

contains Telepathy specific implementations of the libfolks classes

Last updated on

gfbgraph-0.2.5

Introduction to gfbgraph

The gfbgraph package contains a GObject wrapper for the Facebook Graph API.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

gfbgraph Dependencies

Required

gnome-online-accounts-3.40.1 and rest-0.8.1

Recommended
Optional

GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gfbgraph

Installation of gfbgraph

Install gfbgraph by running the following commands:

./configure --prefix=/usr --disable-static &&
make

This package does not have a working testsuite.

Now, as the root user:

make libgfbgraphdocdir=/usr/share/doc/gfbgraph-0.2.5 install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Libraries: libgfbgraph-0.2.so
Installed Directories: /usr/include/gfbgraph-0.2, /usr/share/doc/gfbgraph-0.2.5, and /usr/share/gtk-doc/html/gfbgraph-0.2

Short Descriptions

libgfbgraph-0.2.so

is a GObject wrapper for the Facebook Graph API

Last updated on

Tracker-3.2.1

Introduction to Tracker

Tracker is the file indexing and search provider used in the GNOME desktop environment.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Tracker Dependencies

Required

JSON-GLib-1.6.6, libseccomp-2.5.3, libsoup-2.74.2, and Vala-0.54.7

Recommended
Optional

asciidoc-10.1.1, GTK-Doc-1.33.2, bash-completion, and libstemmer

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/tracker3

Installation of Tracker

Install Tracker by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr      \
      --buildtype=release \
      -Ddocs=false       \
      -Dman=false        \
      -Dsystemd_user_services=false .. &&
ninja

To test the results, issue: ninja test. The tests should be run from a graphical session.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Ddocs=false: This switch prevents the build process from generating API documentation. Omit this switch if you have GTK-Doc-1.33.2 installed and wish to generate and install the API documentation.

-Dman=false: This switch prevents the build process from generating man pages. Omit this switch if you have asciidoc-10.1.1 installed and wish to generate and install the man pages.

-Dsystemd_user_services=false: This switch prevents the build process from installing systemd user services since they are useless on SysV systems.

Contents

Installed Programs: tracker3
Installed Library: libtracker-sparql-3.0.so
Installed Directories: /usr/{include,lib}/tracker-3.0, /usr/libexec/tracker3, /usr/share/tracker3, and /usr/share/gtk-doc/html/{libtracker-sparql,ontology}-3

Short Descriptions

tracker3

is a control program for the indexer

libtracker-sparql-3.0.so

contains resource management and database functions

Last updated on

Tracker-miners-3.2.1

Introduction to Tracker-miners

The Tracker-miners package contains a set of data extractors for Tracker.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Tracker-miners Dependencies

Required

gst-plugins-base-1.20.0, Tracker-3.2.1, Exempi-2.6.1, and gexiv2-0.14.0

Recommended
Optional

asciidoc-10.1.1, CMake-3.22.2, DConf-0.40.0, libgsf-1.14.48, libseccomp-2.5.3, taglib-1.12, totem-pl-parser-3.26.6, UPower-0.99.13, libcue, libitpcdata, libosinfo, and gupnp

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/tracker-miners

Installation of Tracker-miners

Install Tracker-miners by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr                 \
      --buildtype=release           \
      -Dsystemd_user_services=false \
      -Dman=false .. &&
ninja

To test the results, as the root user, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dman=false: This switch prevents the build process from generating man pages. Omit this switch if you have asciidoc-10.1.1 installed and wish to generate and install the man pages.

-Dsystemd_user_services=false: This switch prevents the build process from installing systemd units since they are useless on SysV systems.

-Dseccomp=false: This option disables the seccomp system call filter. On some architectures, such as i686 and ARM, the functions that tracker-miners uses are not guarded properly, and tracker-miners will get killed with a SIGSYS as a result.

-Dminer_rss=false: Use this option if you have not installed the recommended dependency libgrss.

Contents

Installed Programs: None
Installed Libraries: Several modules under /usr/lib/tracker-miners-3.0
Installed Directories: /usr/lib/tracker-miners-3.0, /usr/libexec/tracker3, and /usr/share/tracker3-miners

Last updated on

GSound-1.0.3

Introduction to GSound

The gsound package contains a small library for playing system sounds.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

gsound Dependencies

Required

libcanberra-0.30

Recommended
Optional

GTK-Doc-1.33.2 (for generating documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gsound

Installation of GSound

Install gsound by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: gsound-play
Installed Libraries: libgsound.so
Installed Directories: /usr/share/gtk-doc/html/gsound

Short Descriptions

gsound-play

plays system sounds through the libgsound interface

libgsound.so

contains API functions for playing system sounds

Last updated on

GNOME Desktop Components

Last updated on

DConf-0.40.0 / DConf-Editor-3.38.3

Introduction to DConf

The DConf package contains a low-level configuration system. Its main purpose is to provide a backend to GSettings on platforms that don't already have configuration storage systems.

The DConf-Editor, as the name suggests, is a graphical editor for the DConf database. Installation is optional, because gsettings from GLib-2.70.4 provides similar functionality on the commandline.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

DConf Dependencies

Required

dbus-1.12.20, GLib-2.70.4, GTK+-3.24.31 (for the editor), and libxml2-2.9.13 (for the editor)

Recommended
Optional

GTK-Doc-1.33.2 and bash-completion

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/dconf

Installation of DConf

First, prevent unnecessary systemd units from being installed:

sed -i 's/install_dir: systemd_userunitdir,//' service/meson.build

Install DConf by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release -Dbash_completion=false .. &&
ninja

To test the results, issue: ninja test

As the root user:

ninja install

Now, optionally install the editor:

cd ..              &&
tar -xf ../dconf-editor-3.38.3.tar.xz &&
cd dconf-editor-3.38.3                &&

sed -e '/  desktop,/d' \
    -e '/  appdata,/d' \
    -i editor/meson.build &&

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

As the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dgtk_doc=true: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

sed -e '/  desktop,/d' ...: This fixes a failure to build with newer versions of meson.

Contents

Installed Programs: dconf and dconf-editor
Installed Libraries: libdconf.so, and libdconfsettings.so (GIO Module installed in /usr/lib/gio/modules)
Installed Directories: /usr/{include,share/gtk-doc/html}/dconf

Short Descriptions

dconf

is a simple tool for manipulating the DConf database

dconf-editor

is a graphical program for editing the DConf database

libdconf.so

contains the DConf client API functions

Last updated on

gnome-backgrounds-41.0

Introduction to GNOME Backgrounds

The GNOME Backgrounds package contains a collection of graphics files which can be used as backgrounds in the GNOME Desktop environment. Additionally, the package creates the proper framework and directory structure so that you can add your own files to the collection.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-backgrounds

Installation of GNOME Backgrounds

Install GNOME Backgrounds by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Contents

Installed Programs: None
Installed Libraries: None
Installed Directories: /usr/share/backgrounds/gnome and /usr/share/gnome-background-properties

Short Descriptions

GNOME Backgrounds

are background images for the GNOME Desktop

Last updated on

Gvfs-1.48.1

Introduction to Gvfs

The Gvfs package is a userspace virtual filesystem designed to work with the I/O abstractions of GLib's GIO library.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Gvfs Dependencies

Required

dbus-1.12.20, GLib-2.70.4, libusb-1.0.25, libsecret-0.20.5 and libsoup-2.74.2

Recommended
Optional

Apache-2.4.52, Avahi-0.8, BlueZ-5.63, dbus-glib-0.112, Fuse-3.10.5, gnome-online-accounts-3.40.1, GTK-Doc-1.33.2, libarchive-3.6.0, libgcrypt-1.10.0, libxml2-2.9.13, libxslt-1.1.35, OpenSSH-8.8p1, Samba-4.15.5, libbluray, libgphoto2, libimobiledevice, libmtp, libnfs, and Twisted

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gvfs

Installation of Gvfs

First, apply a fix to build with newer versions of meson:

sed -i '/policy,/d' daemon/meson.build

Install Gvfs by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr       \
      --buildtype=release \
      -Dfuse=false        \
      -Dgphoto2=false     \
      -Dafc=false         \
      -Dbluray=false      \
      -Dnfs=false         \
      -Dmtp=false         \
      -Dsmb=false         \
      -Dtmpfilesdir=no    \
      -Ddnssd=false       \
      -Dgoa=false         \
      -Dgoogle=false      \
      -Dsystemduserunitdir=no .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Note

If you installed the package to your system using a DESTDIR method, /usr/share/glib-2.0/schemas/gschemas.compiled was not updated/created. Create (or update) the file using the following command as the root user:

glib-compile-schemas /usr/share/glib-2.0/schemas

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-D<option>=false: These switches are required if the corresponding optional dependency is not installed. Remove those where you have installed the corresponding application and wish to use it with Gvfs. The dnssd option requires avahi and both goa/google require GNOME Online Accounts.

-Dtmpfilesdir=no -Dsystemduserunitdir=no: These switches provide systemd directory locations. Setting them to no disables the dependency on systemd and logind.

-Dcdda=false: This switch is required if libcdio is not installed. The cdda backend is useless on machines without a CDROM/DVD drive.

Contents

Installed Programs: None
Installed Library: libgvfscommon.so, libgvfsdaemon.so and some under /usr/lib/gio/modules/
Installed Directories: /usr/include/gvfs-client and /usr/{lib,share}/gvfs

Short Descriptions

libgvfscommon.so

contains the common API functions used in Gvfs programs

Last updated on

gexiv2-0.14.0

Introduction to gexiv2

gexiv2 is a GObject-based wrapper around the Exiv2 library.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

gexiv2 Dependencies

Required

Exiv2-0.27.5

Recommended
Optional

GTK-Doc-1.33.2 (for documentation) and Python-2.7.18 (for the Python2 module)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gexiv2

Installation of gexiv2

Install gexiv2 by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, run ninja test.

As the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: None
Installed Libraries: libgexiv2.so
Installed Directories: /usr/include/gexiv2

Last updated on

Nautilus-41.2

Introduction to Nautilus

The Nautilus package contains the GNOME file manager.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Nautilus Dependencies

Required

bubblewrap-0.5.0, gexiv2-0.14.0, gnome-autoar-0.4.3, gnome-desktop-41.3, libhandy-1.4.0, libnotify-0.7.9, libseccomp-2.5.3, and tracker-miners-3.2.1

Recommended
Optional

GTK-Doc-1.33.2

Recommended (Runtime)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/nautilus

Installation of Nautilus

Fix an issue building Nautilus with libportal-0.5 or later:

sed "/dependency/s@'libportal'@'libportal-gtk3'@" -i meson.build
sed "/portal-gtk3/s@portal/@portal-gtk3/@" -i src/nautilus-files-view.c

Install Nautilus by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr       \
      --buildtype=release \
      -Dselinux=false     \
      -Dpackagekit=false  \
      .. &&

ninja

To test the results, issue: ninja test. The tests need to be run in a graphical environment.

Now, as the root user:

ninja install

Note

If you installed the package to your system using a DESTDIR method, /usr/share/glib-2.0/schemas/gschemas.compiled was not updated/created. Create (or update) the file using the following command as the root user:

glib-compile-schemas /usr/share/glib-2.0/schemas

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dselinux=false: This switch disables the use of selinux which isn't supported by BLFS.

-Dpackagekit=false: This switch disables the use of PackageKit which isn't suitable for BLFS.

-Dlibportal=false: Use this switch if you do not have libportal-0.5 installed.

Contents

Installed Programs: nautilus and nautilus-autorun-software
Installed Library: libnautilus-extension.so
Installed Directories: /usr/{include,lib,share}/nautilus, /usr/share/gnome-shell/search-providers, and /usr/share/gtk-doc/html/libnautilus-extension (optional)

Short Descriptions

nautilus

is the GNOME file manager

libnautilus-extension.so

supplies the functions needed by the file manager extensions

Last updated on

Zenity-3.32.0

Introduction to Zenity

Zenity is a rewrite of gdialog, the GNOME port of dialog which allows you to display GTK+ dialog boxes from the command line and shell scripts.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Zenity Dependencies

Required

GTK+-3.24.31 and itstool-2.0.7

Recommended
Optional

WebKitGTK-2.34.6

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/zenity

Installation of Zenity

Install Zenity by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: gdialog and zenity
Installed Libraries: None
Installed Directories: /usr/share/help/*/zenity and /usr/share/zenity

Short Descriptions

gdialog

is a Perl wrapper script which can be used with legacy scripts

zenity

is a program that will display GTK+ dialogs, and return the user's input

Last updated on

gnome-bluetooth-3.34.5

Introduction to GNOME Bluetooth

The GNOME Bluetooth package contains tools for managing and manipulating Bluetooth devices using the GNOME Desktop.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Bluetooth Dependencies

Required

GTK+-3.24.31, itstool-2.0.7, libcanberra-0.30, and libnotify-0.7.9

Recommended
Optional

GTK-Doc-1.33.2 and dbusmock-0.25.0

Runtime Dependencies

BlueZ-5.63 and elogind-246.10

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-bluetooth

Installation of GNOME Bluetooth

First, fix building with newer versions of meson

sed -i "/  desktop,/d" sendto/meson.build

Install GNOME Bluetooth by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: bluetooth-sendto
Installed Libraries: libgnome-bluetooth.so
Installed Directories: /usr/include/gnome-bluetooth and /usr/share/gnome-bluetooth

Short Descriptions

bluetooth-sendto

is a GTK+ application for transferring files over Bluetooth

libgnome-bluetooth.so

contains the GNOME Bluetooth API functions

Last updated on

gnome-keyring-40.0

Introduction to GNOME Keyring

The GNOME Keyring package contains a daemon that keeps passwords and other secrets for users.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Keyring Dependencies

Required

dbus-1.12.20 and Gcr-3.40.0

Recommended
Optional

LCOV, libcap-ng, GnuPG-2.2.34, and Valgrind-3.18.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-keyring

Installation of GNOME Keyring

Install GNOME Keyring by running the following commands:

sed -i 's:"/desktop:"/org:' schema/*.xml &&

./configure --prefix=/usr     \
            --sysconfdir=/etc &&
make

A session bus address is necessary to run the tests. To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

sed ... schema/*.xml: This command fixes a deprecated entry in the schema template.

Contents

Installed Programs: gnome-keyring (symlink), gnome-keyring-3, and gnome-keyring-daemon
Installed Libraries: gnome-keyring-pkcs11.so (PKCS#11 module) and pam_gnome_keyring.so (PAM module)
Installed Directory: /usr/lib/gnome-keyring and /usr/share/xdg-desktop-portal

Short Descriptions

gnome-keyring-daemon

is a session daemon that keeps passwords for users

Last updated on

gnome-settings-daemon-41.0

Introduction to GNOME Settings Daemon

The GNOME Settings Daemon is responsible for setting various parameters of a GNOME Session and the applications that run under it.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Settings Daemon Dependencies

Required

alsa-lib-1.2.6.1, colord-1.4.6, Fontconfig-2.13.1, Gcr-3.40.0, GeoClue-2.6.0, geocode-glib-3.26.2, gnome-desktop-41.3, Little CMS-2.13.1, libcanberra-0.30, libgweather-40.0, libnotify-0.7.9, libwacom-2.1.0, PulseAudio-15.0, elogind-246.10, and UPower-0.99.13

Recommended

Note

Recommended dependencies are not strictly required for this package to build and function, but you may not get expected results at runtime if you don't install them.

Recommended (Runtime)
Optional

gnome-session-41.3, Mutter-41.4, dbusmock-0.25.0, and umockdev-0.17.6

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-settings-daemon

Installation of GNOME Settings Daemon

First, fix building with recent versions of meson:

sed "/  policy,/d" -i plugins/{power,wacom}/meson.build

Next, fix libelogind detection for tests:

sed -e 's/libsystemd/libelogind/' \
    -i plugins/power/test.py

Next, fix backlight functionality in gnome-control-center:

sed -e 's/(backlight->logind_proxy)/(0)/' \
    -i plugins/power/gsd-backlight.c

Install GNOME Settings Daemon by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release -Dsystemd=false .. &&
ninja

To check the results, execute: ninja test. Note that you must have python-dbusmock installed in order for the tests to complete successfully. Some tests may fail depending on the init system in use.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: None
Installed Libraries: libgsd.so
Installed Directories: /etc/xdg/Xwayland-session.d, /usr/include/gnome-settings-daemon-41, /usr/lib/gnome-settings-daemon-41, and /usr/share/gnome-settings-daemon

Last updated on

gnome-control-center-41.4

Introduction to GNOME Control Center

The GNOME Control Center package contains the GNOME settings manager.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Control Center Dependencies

Required

AccountsService-22.07.5, clutter-gtk-1.8.4, colord-gtk-0.3.0, gnome-online-accounts-3.40.1, gnome-settings-daemon-41.0, Grilo-0.3.14, gsound-1.0.3, libgtop-2.40.0, libpwquality-1.4.4, MIT Kerberos V5-1.19.2, shared-mime-info-2.1, and UDisks-2.9.4

Recommended
Optional

dbusmock-0.25.0 (for tests)

Recommended (Runtime)
Optional Runtime Dependencies

cups-pk-helper-0.2.6 (Printers panel), gnome-color-manager-3.36.0 (Color panel), gnome-shell-41.4 (Applications panel), and sound-theme-freedesktop-0.8 (Additional Sound Effects in Sound panel)

Note

Recommended dependencies are not strictly required for this package to build and function, but you may not get expected results at runtime if you don't install them.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-control-center

Installation of GNOME Control Center

Install GNOME Control Center by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test. Note that you must have python-dbusmock module installed in order for the tests to complete successfully.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dcheese=false: Use this switch if you have not installed recommended dependency Cheese.

-Dibus=false: Use this switch if you have not installed recommended dependency IBus.

Contents

Installed Programs: gnome-control-center
Installed Libraries: None
Installed Directories: /usr/share/gnome-control-center, /usr/share/pixmaps/faces, and /usr/share/sounds/gnome

Short Descriptions

gnome-control-center

is a graphical user interface used to configure various aspects of GNOME

Last updated on

Mutter-41.4

Introduction to Mutter

Mutter is the window manager for GNOME. It is not invoked directly, but from GNOME Session (on a machine with a hardware accelerated video driver).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Mutter Dependencies

Required

gnome-settings-daemon-41.0, graphene-1.10.6, libxcvt-0.1.1, libxkbcommon-1.4.0, pipewire-0.3.47, and Zenity-3.32.0

Recommended
Recommended (Required to build the Wayland compositor)
Recommended (Runtime)
Optional

Xorg-Server-21.1.3 (for X11 sessions)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/mutter

Installation of Mutter

Install Mutter by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release -Dtests=false .. &&
ninja

The test suite for this package does not work on systems using glibc-2.35 and later.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dtests=false: Prevents building the tests, and removes a hard requirement on catchsegv or xvfb-run.

-Dprofiler=false: Use this option if Sysprof is not installed, and you don't want meson to download Sysprof source code.

Contents

Installed Programs: mutter
Installed Libraries: libmutter-9.so
Installed Directories: /usr/{lib,include,libexec/installed-tests,share/{installed-tests}}/mutter-9

Short Descriptions

mutter

is a Clutter based compositing GTK+ Window Manager

libmutter-9.so

contains the Mutter API functions

Last updated on

gnome-shell-41.4

Introduction to GNOME Shell

The GNOME Shell is the core user interface of the GNOME Desktop environment.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Shell Dependencies

Required

evolution-data-server-3.42.4, Gjs-1.70.1, gnome-autoar-0.4.3, gnome-control-center-41.4, GTK-4.6.1, Mutter-41.4, sassc-3.6.2, startup-notification-0.12, and elogind-246.10

Recommended
Recommended (Runtime)
Optional

GTK-Doc-1.33.2 and bash-completion

Runtime Dependencies

adwaita-icon-theme-41.0, DConf-0.40.0, GDM-41.3, gnome-backgrounds-41.0, gnome-menus-3.36.0, and telepathy-mission-control-5.16.6

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-shell

Installation of GNOME Shell

First, fix a bug in the meson build process exposed by recent versions of meson:

sed -i '/i18n.merge_file/s/(.*/(/' $(find -name meson.build)

Install GNOME Shell by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr       \
      --buildtype=release \
      -Dsystemd=false     \
      -Dtests=false       \
      .. &&
ninja

To test the results, you need to remove the -Dtests=false switch, and to have Mutter-41.4 compiled with tests too. Issue: ninja test. You must be running an X session to run the tests. Some will fail if GDM-41.3 is not installed.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

patch ...: This patch fixes a bug when trying to start an xwayland application on non systemd.

-Dsystemd=false: Prevents installing systemd files, which are not needed in this version of BLFS.

-Dtests=false: Remove this switch if you want to build the tests. But then meson will fail if Mutter-41.4 tests are not installed.

-Dextensions=false: This option disables building the gnome-extensions CLI tool. Using this option removes the need for asciidoc-10.1.1.

Contents

Installed Programs: gnome-extensions, gnome-extensions-app, gnome-shell, gnome-shell-extension-prefs, gnome-shell-extension-tool, and gnome-shell-perf-tool
Installed Libraries: None
Installed Directories: /usr/lib/gnome-shell, /usr/share/gnome-shell, /usr/share/gtk-doc/html/{shell,st}, and /usr/share/xdg-desktop-portal/

Short Descriptions

gnome-shell

provides the core user interface functions for the GNOME 3 Desktop

Last updated on

gnome-shell-extensions-41.2

Introduction to GNOME Shell Extensions

The GNOME Shell Extensions package contains a collection of extensions providing additional and optional functionality to the GNOME Shell.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Shell Extensions Dependencies

Required

libgtop-2.40.0

Optional

sassc-3.6.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-shell-extensions

Installation of GNOME Shell Extensions

Install GNOME Shell Extensions by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr .. 

This package does not come with a test suite.

Now, as the root user:

ninja install

Contents

Installed Programs: None
Installed Libraries: None
Installed Directories: /usr/share/gnome-shell/extensions

Last updated on

gnome-session-41.3

Introduction to GNOME Session

The GNOME Session package contains the GNOME session manager.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Session Dependencies

Required

dbus-glib-0.112, elogind-246.10, gnome-desktop-41.3, JSON-GLib-1.6.6, Mesa-21.3.6, and UPower-0.99.13

Optional

xmlto-0.0.28, and libxslt-1.1.35 with docbook-xml-4.5 and docbook-xsl-1.79.2 (to build the documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-session

Installation of GNOME Session

When running GNOME under Wayland-1.20.0, environment settings are not imported for the user using the system profile. The Wayland developers are currently undecided on a standard method to provide system environment settings for user sessions. To work around this limitation, execute the following command to make gnome-session use a login shell:

sed 's@/bin/sh@/bin/sh -l@' -i gnome-session/gnome-session.in

Adapt meson.build so that gnome-session can build without systemd:

sed -i "/  systemd_dep/,+3d;/if enable_systemd/a \    systemd_userunitdir = '/tmp\'" meson.build

Install GNOME Session by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr           \
      --buildtype=release     \
      -Dsystemd_journal=false \
      .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Move the documentation to a versioned directory:

mv -v /usr/share/doc/gnome-session{,-41.3}

Now, as the root user, remove systemd units that are useless on SysV systems:

rm -rv /tmp/{*.d,*.target,*.service}

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: gnome-session, gnome-session-custom-session, gnome-session-inhibit, and gnome-session-quit
Installed Libraries: None
Installed Directories: /usr/share/doc/gnome-session-41.3 and /usr/share/gnome-session

Short Descriptions

gnome-session

is used to start up the GNOME Desktop environment

gnome-session-inhibit

is used to inhibit certain GNOME Session functionality while executing the given command

gnome-session-quit

is used to end the GNOME Session

Last updated on

GDM-41.3

Introduction to GDM

GDM is a system service that is responsible for providing graphical logins and managing local and remote displays.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GDM Dependencies

Required

AccountsService-22.07.5, GTK+-3.24.31, ISO Codes-4.9.0, itstool-2.0.7, libcanberra-0.30, libdaemon-0.14, and Linux-PAM-1.5.2

Optional

keyutils-1.6.1

Runtime Dependencies

gnome-session-41.3, gnome-shell-41.4, and elogind-246.10

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gdm

Installation of GDM

It is recommended to have a dedicated user and group to take control of the gdm daemon after it is started. Issue the following commands as the root user:

groupadd -g 21 gdm &&
useradd -c "GDM Daemon Owner" -d /var/lib/gdm -u 21 \
        -g gdm -s /bin/false gdm &&
passwd -ql gdm

First, adapt GDM to build without systemd present:

sed -i -r '/(^| )systemd_dep/d' meson.build

Install GDM by running the following commands:

sed -e 's@systemd@elogind@'                                \
    -e '/elogind/isession  required       pam_loginuid.so' \
    -i data/pam-lfs/gdm-launch-environment.pam &&

mkdir build &&
cd    build &&

meson --prefix=/usr               \
      --buildtype=release         \
      -Dgdm-xsession=true         \
      -Dsystemd-journal=false     \
      -Dsystemdsystemunitdir=/tmp \
      -Dsystemduserunitdir=/tmp   .. &&
ninja

This package does not come with a usable test suite.

Now, as the root user:

ninja install &&
rm -rv /tmp/*.{service,target.d}

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dinitial-vt=7: Use this switch to make GDM start on VT7 instead of the first free VT.

-Ddefault-pam-config=lfs: Use this switch if you did not create the /etc/lfs-release file or distribution auto detection will fail and you will be unable to use GDM.

-Dgdm-xsession=true: This enables the installation of the GDM Xsession file.

Configuring GDM

Config Files

/etc/gdm/custom.conf

Configuration Information

The GDM daemon is configured using the /etc/gdm/custom.conf file. Default values are stored in GSettings in the gdm.schemas file. It is recommended that end-users modify the /etc/gdm/custom.conf file because the schemas file may be overwritten when the user updates their system to have a newer version of GDM.

Boot Script

To start gdm automatically when the system is switched to runlevel 5, install the /etc/rc.d/init.d/xdm script and the /etc/sysconfig/xdm configuration file included in the blfs-bootscripts-20210826 package and adjust /etc/inittab by running as the root user:

make install-gdm

In order to permanently set the default runlevel to 5, starting the gdm greeter screen automatically, you can modify /etc/inittab. As the root user:

sed /initdefault/s/3/5/ -i /etc/inittab

Contents

Installed Programs: gdm, gdmflexiserver, and gdm-screenshot
Installed Libraries: libgdm.so and pam_gdm.so (PAM Module)
Installed Directories: /etc/gdm, /usr/include/gdm, /usr/share/gdm, /usr/share/help/*/gdm, /var/cache/gdm, /var/lib/gdm, /var/log/gdm, and /var/run/gdm

Short Descriptions

gdm

is a login prompt for GNOME

gdm-screenshot

is a screenshot tool for GDM

Last updated on

gnome-user-docs-41.2

Introduction to GNOME User Docs

The GNOME User Docs package contains documentation for GNOME.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME User Docs Dependencies

Required

itstool-2.0.7 and libxml2-2.9.13

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-user-docs

Installation of GNOME User Docs

Install GNOME User Docs by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: None
Installed Directories: /usr/share/help/*/gnome-help and /usr/share/help/*/system-admin-guide

Last updated on

Yelp-41.2

Introduction to Yelp

The Yelp package contains a help browser used for viewing help files.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Yelp Dependencies

Required

gsettings-desktop-schemas-41.0, WebKitGTK-2.34.6 and yelp-xsl-41.1

Recommended
Optional

GTK-Doc-1.33.2

Note

The Yelp package is not required for a functional GNOME Desktop. Note, however, that without Yelp you will not be able to view the built-in Help provided by core GNOME and many of the support applications.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/yelp

Installation of Yelp

Install Yelp by running the following commands:

./configure --prefix=/usr --disable-static --with-webkit2gtk-4-0 &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Still as the root user, ensure that /usr/share/applications/mimeinfo.cache will be updated and therefore the help in gnome applications will work.

update-desktop-database

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Program: gnome-help (symlink) and yelp
Installed Library: libyelp.so
Installed Directories: /usr/{include,share/gtk-doc/html}/libyelp and /usr/{lib,share}/yelp

Short Descriptions

yelp

is the GNOME Help Browser

libyelp.so

contains the Yelp API functions

Last updated on

Chapter 34. GNOME Applications

These packages are desktop applications and assorted utilities from the GNOME project. Feel free to install them on an as needed or as desired basis.

Baobab-41.0

Introduction to Baobab

The Baobab package contains a graphical directory tree analyzer.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Baobab Dependencies

Required

adwaita-icon-theme-41.0, GTK+-3.24.31, itstool-2.0.7, libhandy-1.4.0, and Vala-0.54.7

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/baobab

Installation of Baobab

Install Baobab by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Contents

Installed Program: baobab
Installed Libraries: None
Installed Directories: /usr/share/help/*/baobab

Short Descriptions

baobab

is a graphical tool used to analyze disk usage

Last updated on

Brasero-3.12.3

Introduction to Brasero

Brasero is an application used to burn CD/DVD on the GNOME Desktop. It is designed to be as simple as possible and has some unique features that enable users to create their discs easily and quickly.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Brasero Dependencies

Required

gst-plugins-base-1.20.0, itstool-2.0.7, libcanberra-0.30, and libnotify-0.7.9

Recommended
Optional

GTK-Doc-1.33.2

Recommended (Runtime)
Optional (Runtime)

Cdrdao-1.2.4, libdvdcss-1.4.3, Cdrtools-3.02a09, and VCDImager

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/brasero

Installation of Brasero

Install Brasero by running the following commands:

./configure --prefix=/usr                \
            --enable-compile-warnings=no \
            --enable-cxx-warnings=no     &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--enable-*-warnings=no: These switches fix build problems under GCC-6.x compilers.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: brasero
Installed Libraries: libbrasero-{burn,media,utils}3.so, and /usr/lib/nautilus/extensions-3.0/libnautilus-brasero-extension.so
Installed Directories: /usr/include/brasero3, /usr/lib/brasero3, /usr/share/brasero, /usr/share/gtk-doc/html/libbrasero-{burn,media}, and /usr/share/help/*/brasero

Short Descriptions

brasero

is a simple and easy to use CD/DVD burning application for the GNOME Desktop

libbrasero-burn3.so

contains the Burning API functions

libbrasero-media3.so

contains the Media API functions

libbrasero-utils3.so

contains the Brasero API functions

Last updated on

Cheese-41.1

Introduction to Cheese

Cheese is used to take photos and videos with fun graphical effects.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Cheese Dependencies

Required

clutter-gst-3.0.27, clutter-gtk-1.8.4, gnome-desktop-41.3, gst-plugins-bad-1.20.0, gst-plugins-good-1.20.0 (built with v4l-utils-1.22.1), libcanberra-0.30, and libgudev-237

Recommended
Optional

GTK-Doc-1.33.2, libxslt-1.1.35, appstream-glib, LCOV , and Nautilus SendTo

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/cheese

Kernel Configuration

Depending on your camera, enable the appropriate options and recompile the kernel if necessary:

Device Drivers  --->
  Multimedia support --->
    <*> Autoselect ancillary drivers (tuners, sensors, i2c, spi, frontends) [CONFIG_MEDIA_SUBDRV_AUTOSELECT]
    Media device types --->
      <*> Cameras/video grabbers support  [CONFIG_MEDIA_CAMERA_SUPPORT]
    Media drivers --->
      <*> Media USB Adapters  --->         [CONFIG_MEDIA_USB_SUPPORT]
                  Select device(s) as needed

Installation of Cheese

Install Cheese by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release -Dgtk_doc=false .. &&
ninja

This package does not have a working testsuite.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dgtk_doc=false: This switch prevents the build system from generating and installing the API documentation. Omit this switch if you have GTK-Doc-1.33.2 installed and wish to generate and install the API documentation. Building the documentation is broken due to an incompatibility with gtk-doc.

Contents

Installed Program: cheese
Installed Library: libcheese.so and libcheese-gtk.so
Installed Directories: /usr/{include,share/gtk-doc/html,share/help/*}/cheese

Short Descriptions

cheese

is a webcam tool with graphical effects

libcheese.so

contains the Cheese API functions

libcheese-gtk.so

contains the Cheese GTK+ widgets

Last updated on

EOG-41.1

Introduction to EOG

EOG is an application used for viewing and cataloging image files on the GNOME Desktop. It also has basic editing capabilities.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

EOG Dependencies

Required

adwaita-icon-theme-41.0, Exempi-2.6.1, gnome-desktop-41.3, itstool-2.0.7, libjpeg-turbo-2.1.2, libpeas-1.30.0, and shared-mime-info-2.1

Recommended
Optional

GTK-Doc-1.33.2 and libportal-0.5

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/eog

Installation of EOG

Fix an issue building EOG with libportal-0.5 or later:

sed "/dependency/s@'libportal'@'libportal-gtk3'@" -i meson.build
sed "/portal-gtk3/s@portal/@portal-gtk3/@" -i src/eog-util.c

Install EOG by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release -Dlibportal=false .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Still as the root user, rebuild the cache database of MIME types handled by desktop files so Nautilus-41.2 will be able to open image files with EOG.

update-desktop-database

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dlibportal=false: This parameter disables building EOG with support for flatpak portals. Remove this parameter if you have libportal-0.5 installed and wish to have support for flatpak portals.

-Dgtk_doc=true: Use this option if GTK-Doc-1.33.2 is installed and you wish to rebuild and install the API documentation.

Contents

Installed Program: eog
Installed Library: libeog.so
Installed Directories: /usr/include/eog-3.0 and /usr/{lib,share,share/gtk-doc/html,share/help/*}/eog

Short Descriptions

eog

is a fast and functional image viewer as well as an image cataloging program. It has basic editing capabilities

Last updated on

Evince-41.3

Introduction to Evince

Evince is a document viewer for multiple document formats. It supports PDF, Postscript, DjVu, TIFF and DVI. It is useful for viewing documents of various types using one simple application instead of the multiple document viewers that once existed on the GNOME Desktop.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Evince Dependencies

Required

adwaita-icon-theme-41.0, gsettings-desktop-schemas-41.0, GTK+-3.24.31, itstool-2.0.7, libhandy-1.4.0, libxml2-2.9.13, and OpenJPEG-2.4.0

Recommended
Optional

Cups-2.4.1 (to enable printing if support is built into GTK+ 3), gnome-desktop-41.3, gspell-1.8.4, gst-plugins-base-1.20.0, GTK-Doc-1.33.2, libgxps-0.3.2, libtiff-4.3.0, texlive-20210325 (or install-tl-unx), DjVuLibre, libspectre, Synctex, and t1lib

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/evince

Installation of Evince

First, make sure that meson can find TeXLive if it is installed. This has no effect on systems without TeXLive installed.

export CPPFLAGS="-I/opt/texlive/2021/include" &&
export LDFLAGS="$LDFLAGS -L/opt/texlive/2021/lib"

Next, fix building with newer versions of meson:

find . -name meson.build | xargs sed -i '/merge_file/{n;d}'

Install Evince by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr       \
      --buildtype=release \
      -Dgtk_doc=false     \
      -Dsystemduserunitdir=no .. &&
ninja

This package does not have a working testsuite.

Now, as the root user:

ninja install

Note

If you installed the package to your system using a DESTDIR method, /usr/share/glib-2.0/schemas/gschemas.compiled was not updated/created. Create (or update) the file using the following command as the root user:

glib-compile-schemas /usr/share/glib-2.0/schemas

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

CPPFLAGS="..." LDFLAGS="$LDFLAGS ...": If TeXLive has been installed in /opt/texlive/2021 the configure script will find libkpathsea.so and enable the DVI backend, but without this addition the compile will fail because it cannot find the required headers. Adding this to a system where TeXLive has not been installed does not break the build.

-Dgtk_doc=false: This switch disables generating the gtk-doc API reference documentation. If you have GTK-Doc-1.33.2 installed and wish to generate the API reference documentation, remove this switch.

-Dgspell=false: This switch turns off support for the spell checking plugin.

-Dintrospection=false: Use this option if you don't have gobject-introspection-1.70.0 installed and don't wish to have introspection support built into Evince.

-Dnautilus=false: This switch disables building the Nautilus Plugin. Use this switch if Nautilus is not installed.

-Dkeyring=false: This switch disables the use of libsecret. Use this switch if libsecret is not installed.

-Dps=enabled: Use this switch if libspectre is installed and you want to view PostScript files with Evince.

Contents

Installed Programs: evince, evince-previewer, and evince-thumbnailer
Installed Libraries: libevdocument3.so, libevview3.so, and /usr/lib/nautilus/extensions-3.0/libevince-properties-page.so
Installed Directories: /usr/{include,lib,share}/evince, /usr/share/gtk-doc/html/{evince,libevdocument-3.0,libevview-3.0}, and /usr/share/help/*/evince

Short Descriptions

evince

is a multiple format document viewer

evince-previewer

is an application that implements the printing previewer

evince-thumbnailer

is a simple program used to create thumbnail images of supported documents

Last updated on

Evolution-3.42.4

Introduction to Evolution

The Evolution package contains an integrated mail, calendar and address book suite designed for the GNOME environment.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Evolution Dependencies

Required

adwaita-icon-theme-41.0, evolution-data-server-3.42.4, gnome-autoar-0.4.3, itstool-2.0.7, libgdata-0.18.1, shared-mime-info-2.1, and WebKitGTK-2.34.6

Recommended
Optional

clutter-gtk-1.8.4, GeoClue-2.6.0, geocode-glib-3.26.2, and libchamplain-0.12.20 (Contact Maps plugin), GTK-Doc-1.33.2, Glade, libpst, libunity, libytnef

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/evolution

Installation of Evolution

Install Evolution by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DSYSCONF_INSTALL_DIR=/etc  \
      -DENABLE_INSTALLED_TESTS=ON \
      -DENABLE_PST_IMPORT=OFF     \
      -DENABLE_YTNEF=OFF          \
      -DENABLE_CONTACT_MAPS=OFF   \
      -G Ninja .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Command Explanations

-DENABLE_YTNEF=OFF: This switch is used to disable the yTNEF library usage because libytnef is not part of BLFS.

-DENABLE_PST_IMPORT=OFF: This switch is used to disable the pst-import plugin because libpst is not part of BLFS.

-DENABLE_CONTACT_MAPS=ON: Use this switch if you have installed the necessary dependencies and wish to build the Contact Maps plugin.

-DWITH_OPENLDAP=OFF: Use this switch if you have not installed OpenLDAP-2.6.1.

Contents

Installed Programs: evolution
Installed Libraries: libeabutil.so, libeabwidgets.so, libecontacteditor.so, libecontactlisteditor.so, libecontactprint.so, libemail-engine.so, libessmime.so, libevolution-addressbook-importers.so, libevolution-calendar-importers.so, libevolution-calendar.so, libevolution-mail-composer.so, libevolution-mail-formatter.so, libevolution-mail-importers.so, libevolution-mail.so, libevolution-shell.so, libevolution-smime.so, libevolution-util.so, libgnomecanvas.so, and several modules and plugins in /usr/lib/evolution/{modules,plugins,web-extensions}
Installed Directories: /usr/include/evolution, /usr/lib/evolution, /usr/libexec/evolution, /usr/share/evolution, /usr/share/installed-tests/evolution, /usr/share/help/*/evolution, and optionally /usr/share/gtk-doc/html/{evolution-mail-composer,evolution-mail-engine}, /usr/share/gtk-doc/html/{evolution-mail-formatter,evolution-shell}, and /usr/share/gtk-doc/html/evolution-util

Short Descriptions

evolution

is an email, calendar and address book suite for the GNOME Desktop

Last updated on

File-Roller-3.40.0

Introduction to File Roller

File Roller is an archive manager for GNOME with support for tar, bzip2, gzip, zip, jar, compress, lzop, zstd, and many other archive formats.

This package is known to build and work properly using an LFS-11.1 platform.

Note

File Roller is only a graphical interface to archiving utilities such as tar and zip.

Package Information

File Roller Dependencies

Required

GTK+-3.24.31 and itstool-2.0.7

Recommended
Optional (Runtime)

UnRar-6.1.4, UnZip-6.0, and Zip-3.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/file-roller

Installation of File Roller

Install File Roller by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release -Dpackagekit=false .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install &&
chmod -v 0755 /usr/libexec/file-roller/isoinfo.sh

Note

If you installed the package to your system using a DESTDIR method, /usr/share/glib-2.0/schemas/gschemas.compiled was not updated/created. Create (or update) the file using the following command as the root user:

glib-compile-schemas /usr/share/glib-2.0/schemas

Note

This package installs icon files into the /usr/share/icons/hicolor hierarchy and desktop files into the /usr/share/applications hierarchy. You can improve system performance and memory usage by updating /usr/share/icons/hicolor/index.theme and /usr/share/applications/mimeinfo.cache. To perform the update you must have GTK+-2.24.33 or GTK+-3.24.31 installed (for the icon cache) and desktop-file-utils-0.26 (for the desktop cache) and issue the following commands as the root user:

gtk-update-icon-cache -qtf /usr/share/icons/hicolor &&
update-desktop-database -q

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dpackagekit=false: This switch disables the use of PackageKit which isn't suitable for BLFS.

Contents

Installed Program: file-roller
Installed Libraries: libnautilus-fileroller.so
Installed Directories: /usr/{libexec,share{,/help/*}}/file-roller

Short Descriptions

file-roller

is an archive manager for GNOME

Last updated on

gnome-calculator-41.1

Introduction to GNOME Calculator

GNOME Calculator is a powerful graphical calculator with financial, logical and scientific modes. It uses a multiple precision package to do its arithmetic to give a high degree of accuracy.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Calculator Dependencies

Required

GTK+-3.24.31, gtksourceview4-4.8.2, itstool-2.0.7, libgee-0.20.5, libhandy-1.4.0, and libsoup-2.74.2

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-calculator

Installation of GNOME Calculator

Install GNOME Calculator by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Contents

Installed Programs: gcalccmd and gnome-calculator
Installed Library: libgcalc-2.so and libgci-1.so
Installed Directories: /usr/include/gcalc-2, /usr/include/gci-2, /usr/share/devhelp/books/{GCalc-2,GCi-1}, and /usr/share/help/*/gnome-calculator

Short Descriptions

gnome-calculator

is the official calculator of the GNOME Desktop

gcalccmd

is a command line version of gnome-calculator

Last updated on

gnome-color-manager-3.36.0

Introduction to GNOME Color Manager

GNOME Color Manager is a session framework for the GNOME desktop environment that makes it easy to manage, install and generate color profiles.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Color Manager Dependencies

Required

colord-1.4.6, GTK+-3.24.31, itstool-2.0.7, Little CMS-2.13.1, libcanberra-0.30, and libexif-0.6.24

Recommended
Optional

appstream-glib and DocBook-utils-0.6.14 (currently causes build to fail)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-color-manager

Installation of GNOME Color Manager

If DocBook-utils-0.6.14 is installed, disable installation of the man pages to avoid a build failure:

sed /subdir\(\'man/d -i meson.build

Install GNOME Color Manager by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test. The tests must be run from an X session.

Now, as the root user:

ninja install

Contents

Installed Programs: gcm-import, gcm-inspect, gcm-picker, and gcm-viewer
Installed Libraries: None
Installed Directories: /usr/share/gnome-color-manager and /usr/share/help/*/gnome-color-manager

Short Descriptions

gcm-import

allows you to import ICC profiles supplied by vendors

gcm-inspect

allows you to inspect your session color-management settings

gcm-picker

allows you to pick spot colors for use by an attached colorimeter

gcm-viewer

allows you to view properties of ICC profiles

Last updated on

gnome-disk-utility-41.0

Introduction to GNOME Disk Utility

The GNOME Disk Utility package provides applications used for dealing with storage devices.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Disk Utility Dependencies

Required

gnome-settings-daemon-41.0, itstool-2.0.7, libdvdread-6.1.2, libhandy-1.4.0, libpwquality-1.4.4, libsecret-0.20.5, and UDisks-2.9.4

Optional

appstream-glib

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-disk-utility

Installation of GNOME Disk Utility

First, fix building with newer versions of meson:

sed -i '/merge_file/{n;d}' data/meson.build

Install GNOME Disk Utility by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Contents

Installed Programs: gnome-disk-image-mounter and gnome-disks
Installed Libraries: None
Installed Directories: None

Short Descriptions

gnome-disk-image-mounter

is used to set up disk images

gnome-disks

is used to inspect, format, partition and configure disks and block devices

Last updated on

gnome-maps-41.4

Introduction to GNOME Maps

GNOME Maps is a map application for GNOME.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Maps Dependencies

Required

clutter-gtk-1.8.4, desktop-file-utils-0.26, Folks-0.15.4, GeoClue-2.6.0, geocode-glib-3.26.2, gfbgraph-0.2.5, Gjs-1.70.1, libchamplain-0.12.20, libgee-0.20.5, libhandy-1.4.0, and rest-0.8.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-maps

Installation of GNOME Maps

Install GNOME Maps by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Contents

Installed Programs: gnome-maps
Installed Libraries: libgnome-maps.so
Installed Directories: /usr/lib/gnome-maps and /usr/share/gnome-maps

Short Descriptions

gnome-maps

is a map application for GNOME

Last updated on

gnome-nettool-3.8.1

Introduction to GNOME Nettool

The GNOME Nettool package is a network information tool which provides GUI interface for some of the most common command line network tools.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

GNOME Nettool Dependencies

Required

GTK+-3.24.31, itstool-2.0.7, and libgtop-2.40.0

Runtime Dependencies

BIND Utilities-9.18.0, Nmap-7.92, Net-tools-2.10, Traceroute-2.1.0, and Whois-5.4.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-nettool

Installation of GNOME Nettool

First, adapt GNOME Nettool to changes in the ping, ping6, and netstat utilities:

patch -Np1 -i ../gnome-nettool-3.8.1-ping_and_netstat_fixes-1.patch

Install GNOME Nettool by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Program: gnome-nettool
Installed Libraries: None
Installed Directories: /usr/share/gnome-nettool and /usr/share/help/*/gnome-nettool

Short Descriptions

gnome-nettool

is a network information tool

Last updated on

gnome-power-manager-3.32.0

Introduction to GNOME Power Manager

The GNOME Power Manager package contains a tool used to report on power management on the system.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Power Manager Dependencies

Required

GTK+-3.24.31 and UPower-0.99.13

Optional

DocBook-utils-0.6.14 and appstream-glib

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-power-manager

Installation of GNOME Power Manager

Install GNOME Power Manager by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr  --buildtype=release .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Contents

Installed Programs: gnome-power-statistics
Installed Libraries: None
Installed Directories: None

Short Descriptions

gnome-power-statistics

is used to visualize the power consumption of laptop hardware

Last updated on

gnome-screenshot-41.0

Introduction to GNOME Screenshot

The GNOME Screenshot is a utility used for taking screenshots of the entire screen, a window or a user-defined area of the screen, with optional beautifying border effects.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Screenshot Dependencies

Required

GTK+-3.24.31, libcanberra-0.30 (Compiled with GTK+3 support), and libhandy-1.4.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-screenshot

Installation of GNOME Screenshot

First, fix building with newer versions of meson:

sed -i '/merge_file/{n;d}' data/meson.build

Install GNOME Screenshot by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Note

In order to best run GNOME Screenshot from the command line, the -i option needs to be specified.

Contents

Installed Program: gnome-screenshot
Installed Libraries: None
Installed Directories: None

Short Descriptions

gnome-screenshot

is used to capture the screen, a window, or a user-defined area and save the snapshot image to a file

Last updated on

gnome-system-monitor-41.0

Introduction to GNOME System Monitor

The GNOME System Monitor package contains GNOME's replacement for gtop.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME System Monitor Dependencies

Required

adwaita-icon-theme-41.0, Gtkmm-3.24.5, itstool-2.0.7, libgtop-2.40.0, and librsvg-2.52.6

Optional

desktop-file-utils-0.26 and appstream-glib

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-system-monitor

Installation of GNOME System Monitor

Install GNOME System Monitor by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr -Dsystemd=false --buildtype=release .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Command Explanations

-Dsystemd=false: This switch ensures that gnome-system-monitor does NOT use the systemd process monitoring framework. Use this option if you are on a SysV system.

Contents

Installed Program: gnome-system-monitor
Installed Libraries: None
Installed Directories: /usr/{libexec,share,share/help/*}/gnome-system-monitor

Short Descriptions

gnome-system-monitor

is used to display the process tree and hardware meters

Last updated on

gnome-terminal-3.42.2

Introduction to GNOME Terminal

The GNOME Terminal package contains the terminal emulator for GNOME Desktop.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Terminal Dependencies

Required

DConf-0.40.0, gsettings-desktop-schemas-41.0, itstool-2.0.7, pcre2-10.39, and VTE-0.66.2

Recommended
Optional

desktop-file-utils-0.26, and appstream-glib

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-terminal

Installation of GNOME Terminal

First, fix building with newer versions of meson:

sed -i '/merge_file/{n;d}' data/meson.build

Next, fix some deprecated schema entries:

sed -i -r 's:"(/system):"/org/gnome\1:g' src/external.gschema.xml

Install GNOME Terminal by running the following commands:

mkdir build &&
cd   build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install &&
rm -v /usr/lib/systemd/user/gnome-terminal-server.service

Note

To run GNOME Terminal, the environment variable LANG must be set to a UTF-8 locale prior to starting the graphical environment.

Command Explanations

-Dsearch_provider=false: This switch disables the search gnome-shell provider. Use this option if you do not have gnome-shell installed.

-Dnautilus_extension=false: This switch disables a dependency on the nautilus file manager. Use this option if you do not have Nautilus installed.

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Program: gnome-terminal
Installed Libraries: /usr/lib/nautilus/extensions-3.0/libterminal-nautilus.so (Nautilus Extension)
Installed Directories: /usr/{lib,share/help/*}/gnome-terminal

Short Descriptions

gnome-terminal

is the GNOME Terminal Emulator

Last updated on

gnome-tweaks-40.0

Introduction to GNOME Tweaks

GNOME Tweaks is a simple program used to tweak advanced GNOME settings.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Tweaks Dependencies

Required

GTK+-3.24.31, gsettings-desktop-schemas-41.0, libhandy-1.4.0, PyGObject-3.42.0, and sound-theme-freedesktop-0.8

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-tweaks

Installation of GNOME Tweaks

First, if you are upgrading from gnome-tweaks-3.34.x, remove some incompatible files as the root user:

rm -rf /usr/lib/python3.10/site-packages/gtweak

Next, fix building with newer versions of meson:

sed -i '/merge_file/s/(.*/(/' data/meson.build

Install GNOME Tweaks by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: gnome-tweaks
Installed Libraries: None
Installed Directories: /usr/lib/python3.10/site-packages/gtweak and /usr/share/gnome-tweaks

Short Descriptions

gnome-tweaks

is used to tweak advanced GNOME settings

Last updated on

gnome-weather-41.0

Introduction to GNOME Weather

GNOME Weather is a small application that allows you to monitor the current weather conditions for your city, or anywhere in the world, and to access updated forecasts provided by various internet services.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GNOME Weather Dependencies

Required

Gjs-1.70.1, libgweather-40.0, and libhandy-1.4.0

Optional

appstream-glib

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnome-weather

Installation of GNOME Weather

First, fix building with newer versions of meson:

sed -i '/merge_file/{n;d}' data/meson.build

Install GNOME Weather by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: gnome-weather
Installed Libraries: None
Installed Directories: /usr/share/org.gnome.Weather

Short Descriptions

gnome-weather

is a small application that allows you to monitor the current weather conditions anywhere in the world

Last updated on

Gucharmap-14.0.2

Introduction to Gucharmap

Gucharmap is a Unicode character map and font viewer. It allows you to browse through all the available Unicode characters and categories for the installed fonts, and to examine their detailed properties. It is an easy way to find the character you might only know by its Unicode name or code point.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Unicode Character Database files

Gucharmap Dependencies

Required

desktop-file-utils-0.26, gsettings-desktop-schemas-41.0, GTK+-3.24.31, itstool-2.0.7, pcre2-10.39, and UnZip-6.0

Recommended
Optional

appstream-glib and GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gucharmap

Installation of Gucharmap

Install Gucharmap by running the following commands:

mkdir build                   &&
cd    build                   &&
mkdir ucd                     &&
pushd ucd                     &&
  unzip ../../../UCD.zip      &&
  cp -v ../../../Unihan.zip . &&
popd                          &&

meson --prefix=/usr         \
      --strip               \
      --buildtype=release   \
      -Ducd_path=./ucd      \
      -Ddocs=false ..       &&
ninja

This package does not have a testsuite.

Now, as the root user:

rm  -fv /usr/share/glib-2.0/schemas/org.gnome.Charmap.enums.xml &&
ninja install

Command Explanations

--strip: Although the package defaults to a release build without debug information, without this switch there will be some debug information in the binaries.

-Ducd_path=./ucd: This points to where the extracted main Unicode data files, and the zipped Unihan archive can be found.

rm -fv /usr/share/glib-2.0/schemas/org.gnome.Charmap.enums.xml: Old versions of this package installed an obsolete file that prevents the program from running, as if the main schema has not been installed. Forcibly removing works even if the old file is not present.

-Ddocs=false: This allows the package to build even if gtk-doc has not been installed. Remove this if you have installed that and wish to build the documentation.

-Dgir=false: Use this if you have not installed gobject-introspection-1.70.0.

-Dvapi=false: Use this if you have not installed Vala-0.54.7.

Contents

Installed Program: gucharmap
Installed Library: libgucharmap_2_90.so
Installed Directories: /usr/include/gucharmap-2.90

Short Descriptions

gucharmap

is a Unicode character map and font viewer

libgucharmap_2_90.so

contains the Gucharmap API functions

Last updated on

Seahorse-41.0

Introduction to Seahorse

Seahorse is a graphical interface for managing and using encryption keys. Currently it supports PGP keys (using GPG/GPGME) and SSH keys.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Seahorse Dependencies

Required

Gcr-3.40.0, GnuPG-2.2.34, GPGME-1.17.0, itstool-2.0.7, libhandy-1.4.0, libpwquality-1.4.4 and libsecret-0.20.5

Recommended
Optional

Avahi-0.8

Runtime Dependency

gnome-keyring-40.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/seahorse

Installation of Seahorse

Install Seahorse by running the following commands:

sed -i -r 's:"(/apps):"/org/gnome\1:' data/*.xml &&

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

sed ... data/*.xml: This command fixes some deprecated entries in the schema templates.

-Dldap-support=false: Add this switch if you have not installed openldap.

Contents

Installed Program: seahorse
Installed Libraries: None
Installed Directories: /usr/{libexec,share,share/help/*}/seahorse

Short Descriptions

seahorse

is the graphical interface for managing and using encryption keys

Last updated on

Vinagre-3.22.0

Introduction to Vinagre

Vinagre is a VNC client for the GNOME Desktop.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Vinagre Dependencies

Required

gtk-vnc-1.3.0, itstool-2.0.7, and libsecret-0.20.5

Recommended
Optional

Avahi-0.8, appstream-glib, FreeRDP (For connecting to Windows desktops), and Spice-GTK

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/vinagre

Installation of Vinagre

First fix an issue exposed by GCC-10:

sed -e '/_VinagreVnc/i gboolean scaling_command_line;' \
    -i plugins/vnc/vinagre-vnc-connection.c &&
sed -e '/scaling_/s/^/extern /' \
    -i plugins/vnc/vinagre-vnc-connection.h

Install Vinagre by running the following commands:

./configure --prefix=/usr \
            --enable-compile-warnings=minimum &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--enable-compile-warnings=minimum: This switch disables compiler warnings that can cause the build to fail when built under GCC6.

Contents

Installed Programs: vinagre
Installed Libraries: None
Installed Directories: /usr/share/help/*/vinagre and /usr/share/vinagre

Short Descriptions

vinagre

is a remote desktop viewer for the GNOME Desktop

Last updated on

Part IX. Xfce

Chapter 35. Xfce Desktop

Xfce is a desktop environment that aims to be fast and low on system resources, while still being visually appealing and user friendly.

Xfce embodies the traditional UNIX philosophy of modularity and re-usability. It consists of a number of components that provide the full functionality one can expect of a modern desktop environment. They are packaged separately and you can pick among the available packages to create the optimal personal working environment.

Build Xfce core packages in the order presented in the book for the easiest resolution of dependencies.

libxfce4util-4.16.0

Introduction to libxfce4util

The libxfce4util package is a basic utility library for the Xfce desktop environment.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libxfce4util Dependencies

Required

GLib-2.70.4 and gobject-introspection-1.70.0

Recommended
Optional

GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libxfce4util

Installation of libxfce4util

Install libxfce4util by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Program: xfce4-kiosk-query
Installed Library: libxfce4util.so
Installed Directories: /usr/include/xfce4 and /usr/share/gtk-doc/html/libxfce4util

Short Descriptions

xfce4-kiosk-query

Queries the given capabilities of <module> for the current user and reports whether the user has the capabilities or not. This tool is mainly meant for system administrators to test their Kiosk setup

libxfce4util.so

contains basic utility functions for the Xfce desktop environment

Last updated on

Xfconf-4.16.0

Introduction to Xfconf

Xfconf is the configuration storage system for Xfce.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Xfconf Dependencies

Required

libxfce4util-4.16.0

Optional

GTK-Doc-1.33.2 and Vala-0.54.7

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xfconf

Installation of Xfconf

Install Xfconf by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Program: xfconf-query
Installed Library: libxfconf-0.so
Installed Directories: /usr/include/xfce4/xfconf-0, /usr/lib/xfce4/xfconf, and /usr/share/gtk-doc/html/xfconf

Short Descriptions

xfconf-query

is a commandline utility to view or change any setting stored in Xfconf

libxfconf-0.so

contains basic functions for Xfce configuration

Last updated on

libxfce4ui-4.16.1

Introduction to libxfce4ui

The libxfce4ui package contains GTK+ 2 widgets that are used by other Xfce applications.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libxfce4ui Dependencies

Required

GTK+-3.24.31 and Xfconf-4.16.0

Recommended
Optional

GTK-Doc-1.33.2, gobject-introspection-1.70.0, libgtop-2.40.0, libgudev-237, and Glade

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libxfce4ui

Installation of libxfce4ui

Install libxfce4ui by running the following commands:

./configure --prefix=/usr --sysconfdir=/etc &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: None
Installed Libraries: libxfce4kbd-private-{2,3}.so and libxfce4ui-{1,2}.so
Installed Directories: /etc/xdg/xfce4, /usr/include/xfce4/libxfce4kbd-private-2, /usr/include/xfce4/libxfce4ui-{1,2}, and /usr/share/gtk-doc/html/libxfce4ui

Short Descriptions

libxfce4kbd-private-2.so

is a private Xfce library for sharing code between Xfwm4 and Xfce4 Settings

libxfce4ui-1.so

contains widgets that are used by other Xfce applications

Last updated on

Exo-4.16.3

Introduction to Exo

Exo is a support library used in the Xfce desktop. It also has some helper applications that are used throughout Xfce.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Exo Dependencies

Required

GTK+-3.24.31, libxfce4ui-4.16.1, and libxfce4util-4.16.0

Optional

GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/exo

Installation of Exo

Install Exo by running the following commands:

./configure --prefix=/usr --sysconfdir=/etc &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: exo-desktop-item-edit and exo-open
Installed Libraries: libexo-2.so
Installed Directories: /usr/include/exo-2 and /usr/share/gtk-doc/html/exo-2

Short Descriptions

exo-desktop-item-edit

is a command line utility to create or edit icons on the desktop

exo-open

is a command line frontend to the Xfce Preferred Applications framework. It can either be used to open a list of urls with the default URL handler or launch the preferred application for a certain category

libexo-2.so

contains additional widgets, a framework for editable toolbars, light-weight session management support and functions to automatically synchronise object properties (based on GObject Binding Properties)

Last updated on

Garcon-4.16.1

Introduction to Garcon

The Garcon package contains a freedesktop.org compliant menu implementation based on GLib and GIO.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Garcon Dependencies

Required

libxfce4ui-4.16.1 and GTK+-3.24.31

Optional

gobject-introspection-1.70.0 and GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/garcon

Installation of Garcon

Install Garcon by running the following commands:

./configure --prefix=/usr --sysconfdir=/etc &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Library: libgarcon-1.so and libgarcon-gtk3-1.so
Installed Directory: /usr/include/garcon-1, /usr/include/garcon-gtk3-1, and /usr/share/gtk-doc/html/garcon

Short Descriptions

libgarcon-1.so

contains functions that provide a freedesktop.org compliant menu implementation based on GLib and GIO

Last updated on

thunar-4.16.10

Introduction to thunar

Thunar is the Xfce file manager, a GTK+ 3 GUI to organise the files on your computer.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Thunar Dependencies

Required

Exo-4.16.3

Required (Runtime)

hicolor-icon-theme-0.17

Recommended
Optional

GTK-Doc-1.33.2 (for documentation), Gvfs-1.48.1 (for remote browsing and automounting), libexif-0.6.24 and tumbler-4.16.0 (runtime)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/thunar

Installation of Thunar

First prevent the installation of an unneeded systemd file:

sed -i 's/\tinstall-systemd_userDATA/\t/' Makefile.in

Install Thunar by running the following commands:

./configure --prefix=/usr \
            --sysconfdir=/etc \
            --docdir=/usr/share/doc/thunar-4.16.10 &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: Thunar (symlink to thunar), thunar, and thunar-settings
Installed Library: libthunarx-3.so
Installed Directories: /etc/xdg/Thunar, /usr/include/thunarx-3, /usr/lib/Thunar, /usr/lib/thunarx-3, /usr/share/Thunar, /usr/share/doc/thunar-4.16.10, and /usr/share/gtk-doc/html/thunarx

Short Descriptions

thunar

is the Xfce file manager

thunar-settings

is a shell script that launches a dialog box to allow you to alter the behaviour of Thunar

libthunarx-3.so

contains the Thunar extension library which permits adding new features to the Thunar file manager

Last updated on

thunar-volman-4.16.0

Introduction to the Thunar Volume Manager

The Thunar Volume Manager is an extension for the Thunar file manager, which enables automatic management of removable drives and media.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Thunar Volume Manager Dependencies

Required

Exo-4.16.3 and libgudev-237

Recommended
Recommended Runtime Dependencies

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/thunar-volman

Installation of the Thunar Volume Manager

Install the Thunar Volume Manager by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: thunar-volman and thunar-volman-settings
Installed Libraries: None
Installed Directories: None

Short Descriptions

thunar-volman

is the Thunar Volume Manager, a command line utility to automatically mount or unmount removable media

thunar-volman-settings

is a small GTK+ 3 application for changing Thunar Volume Manager settings

Last updated on

tumbler-4.16.0

Introduction to tumbler

The Tumbler package contains a D-Bus thumbnailing service based on the thumbnail management D-Bus specification. This is useful for generating thumbnail images of files.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Tumbler Dependencies

Required

GLib-2.70.4

Optional

cURL-7.81.0, FreeType-2.11.1, gdk-pixbuf-2.42.6, gst-plugins-base-1.20.0, GTK-Doc-1.33.2, libjpeg-turbo-2.1.2, libgsf-1.14.48, libpng-1.6.37, Poppler-22.02.0, FFmpegThumbnailer, libgepub, and libopenraw

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/tumbler

Installation of Tumbler

Install Tumbler by running the following commands:

./configure --prefix=/usr --sysconfdir=/etc &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: tumblerd
Installed Library: libtumbler-1.so and several under /usr/lib/tumbler-1/plugins/
Installed Directories: /etc/xdg/tumbler, /usr/include/tumbler-1, /usr/lib/tumbler-1 and /usr/share/gtk-doc/html/tumbler

Short Descriptions

tumblerd

is a D-Bus service for applications such as Thunar and Ristretto to use thumbnail images

libtumbler-1.so

contains functions that the Tumbler daemon uses to create thumbnail images

Last updated on

xfce4-appfinder-4.16.1

Introduction to Xfce4 Appfinder

Xfce4 Appfinder is a tool to find and launch installed applications by searching the .desktop files installed on your system.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Xfce4 Appfinder Dependencies

Required

Garcon-4.16.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xfce4-appfinder

Installation of Xfce4 Appfinder

Install Xfce4 Appfinder by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: xfce4-appfinder and xfrun4 (symlink)
Installed Libraries: None
Installed Directories: None

Short Descriptions

xfce4-appfinder

Is a GTK+ 3 application that enables you to quickly search through the .desktop files installed on your system looking for an application

Last updated on

xfce4-panel-4.16.3

Introduction to Xfce4 Panel

The Xfce4 Panel package contains the Xfce4 Panel.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Xfce4 Panel Dependencies

Required

Cairo-1.17.4, Exo-4.16.3, Garcon-4.16.1, and libwnck-40.1

Optional

GTK-Doc-1.33.2 and libdbusmenu

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xfce4-panel

Installation of Xfce4 Panel

Install Xfce4 Panel by running the following commands:

./configure --prefix=/usr --sysconfdir=/etc &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: xfce4-panel, xfce4-popup-applicationsmenu, xfce4-popup-directorymenu, and xfce4-popup-windowmenu
Installed Library: libxfce4panel-2.0.so
Installed Directories: /etc/xdg/xfce4/panel, /usr/include/xfce4/libxfce4panel-1.0, /usr/lib/xfce4/panel, /usr/share/gtk-doc/html/libxfce4panel-1.0 and /usr/share/xfce4/panel

Short Descriptions

xfce4-panel

is the Xfce panel

xfce4-popup-applicationsmenu

is a shell script that uses D-Bus and Xfce Panel to display a popup menu of the installed applications

xfce4-popup-directorymenu

is a shell script that uses D-Bus and Xfce Panel to display a popup menu of your home folder and its subdirectories

xfce4-popup-windowmenu

is a shell script that uses DBus to display the Xfwm4 a popup menu

libxfce4panel-2.0.so

contains the Xfce Panel API functions

Last updated on

xfce4-power-manager-4.16.0

Introduction to Xfce4 Power Manager

The Xfce4 Power Manager is a power manager for the Xfce desktop, Xfce power manager manages the power sources on the computer and the devices that can be controlled to reduce their power consumption (such as LCD brightness level, monitor sleep, CPU frequency scaling). In addition, Xfce4 Power Manager provides a set of freedesktop-compliant DBus interfaces to inform other applications about current power level so that they can adjust their power consumption.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Xfce4 Power Manager Dependencies

Required

libnotify-0.7.9, UPower-0.99.13, and xfce4-panel-4.16.3

Optional

NetworkManager-1.34.0 and Polkit-0.120

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xfce4-power-manager

Installation of Xfce4 Power Manager

Install Xfce4 Power Manager by running the following commands:

./configure --prefix=/usr --sysconfdir=/etc &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: xfce4-power-manager, xfce4-power-manager-settings, xfce4-pm-helper, and xfpm-power-backlight-helper
Installed Libraries: libxfce4powermanager.so
Installed Directories: None

Short Descriptions

xfce4-pm-helper

is a helper program for the suspend and hibernate functions of xfce4-power-manager

xfce4-power-manager

is the Xfce Power Manager

xfce4-power-manager-settings

is a utility that comes with the Xfce Power Manager to access/change its configuration

xfpm-power-backlight-helper

is a command line utility to get or set the brightness of your screen

Last updated on

xfce4-settings-4.16.2

Introduction to Xfce4 Settings

The Xfce4 Settings package contains a collection of programs that are useful for adjusting your Xfce preferences.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Xfce4 Settings Dependencies

Required

Exo-4.16.3 and Garcon-4.16.1

Required (Runtime)

gnome-icon-theme-3.12.0 or lxde-icon-theme-0.5.1

Recommended
Optional

colord-1.4.6, libinput-1.19.3, and UPower-0.99.13

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xfce4-settings

Installation of Xfce4 Settings

Install Xfce4 Settings by running the following commands:

./configure --prefix=/usr --sysconfdir=/etc &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--enable-sound-settings: Use this switch to enable sound settings in GUI.

--enable-pluggable-dialogs: Use this switch to enable support for embedded settings dialogs.

Contents

Installed Programs: xfce4-accessibility-settings, xfce4-appearance-settings, xfce4-color-settings, xfce4-display-settings, xfce4-find-cursor, xfce4-keyboard-settings, xfce4-mime-helper, xfce4-mime-settings, xfce4-mouse-settings, xfce4-settings-editor, xfce4-settings-manager and xfsettingsd
Installed Libraries: None
Installed Directories: None

Short Descriptions

xfce4-accessibility-settings

is a GTK+ 3 GUI to allow you to change some of your keyboard and mouse preferences

xfce4-appearance-settings

is a GTK+ 3 GUI to allow you to change some of your theme, icon and font preferences

xfce4-display-settings

is a GTK+ 3 GUI to allow you to change some of your screen preferences

xfce4-keyboard-settings

is a GTK+ 3 GUI to allow you to change some of your keyboard preferences

xfce4-mime-settings

is a GTK+ 3 GUI to allow you to change which applications are used to handle different mime types

xfce4-mouse-settings

is a GTK+ 3 GUI to allow you to change some of your mouse preferences

xfce4-settings-editor

is a GTK+ 3 GUI to allow you to change your preferences stored in Xfconf

xfce4-settings-manager

is a GTK+ 3 GUI to allow you to change many of your Xfce preferences

xfsettingsd

is the Xfce settings daemon

Last updated on

Xfdesktop-4.16.0

Introduction to Xfdesktop

Xfdesktop is a desktop manager for the Xfce Desktop Environment. Xfdesktop sets the background image / color, creates the right click menu and window list and displays the file icons on the desktop using Thunar libraries.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Xfdesktop Dependencies

Required

Exo-4.16.3 and libwnck-40.1

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xfdesktop

Installation of Xfdesktop

Install Xfdesktop by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: xfdesktop and xfdesktop-settings
Installed Libraries: None
Installed Directories: /usr/share/backgrounds/xfce and /usr/share/pixmaps/xfdesktop

Short Descriptions

xfdesktop

is the Xfce Desktop Environment's desktop manager

xfdesktop-settings

is a GTK+ 3 application that allows you to change your desktop background, some preferences for the right click menu and what icons are displayed on the desktop

Last updated on

Xfwm4-4.16.1

Introduction to Xfwm4

Xfwm4 is the window manager for Xfce.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Xfwm4 Dependencies

Required

libwnck-40.1 and libxfce4ui-4.16.1

Recommended
Optional

libxpresent

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xfwm4

Installation of Xfwm4

Install Xfwm4 by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: xfwm4, xfwm4-settings, xfwm4-tweaks-settings and xfwm4-workspace-settings
Installed Libraries: None
Installed Directories: /usr/lib/xfce4/xfwm4, /usr/share/themes/{Daloa,Default{,-hdpi,-xhdpi},Kokodi,Moheli}, and /usr/share/xfwm4

Short Descriptions

xfwm4

is the Xfce window manager

xfwm4-settings

is a GTK+ 3 application that allows setting some preferences such as your theme, keyboard shortcuts and mouse focus behaviour

xfwm4-tweaks-settings

is a GTK+ 3 application that allows setting some more preferences for Xfwm4

xfwm4-workspace-settings

is a GTK+ 3 application that allows setting your workspace preferences

Last updated on

xfce4-session-4.16.0

Introduction to Xfce4 Session

Xfce4 Session is a session manager for Xfce. Its task is to save the state of your desktop (opened applications and their location) and restore it during a next startup. You can create several different sessions and choose one of them on startup.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Xfce4 Session Dependencies

Required

libwnck-40.1 and libxfce4ui-4.16.1

Recommended
Required Runtime

Xfdesktop-4.16.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xfce4-session

Installation of Xfce4 Session

Install Xfce4 Session by running the following commands:

./configure --prefix=/usr \
            --sysconfdir=/etc \
            --disable-legacy-sm &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-legacy-sm: This switch disables legacy session management which isn't necessary on modern system.

Configuring Xfce4 Session

There are several optional run time dependencies for Xfce4: dbus-1.12.20, GnuPG-2.2.34, hicolor-icon-theme-0.17 and OpenSSH-8.8p1

When building an Xfce4 package, some configuration files are installed in /usr/share/applications, /usr/share/icons, and /usr/share/mime. In order to use those files in your Xfce4 session, you need to update various databases. Do that by running, as the root user (you need to have the recommended dependencies installed):

update-desktop-database &&
update-mime-database /usr/share/mime

Starting Xfce4

You can start Xfce4 from runlevel 3, using xinit-1.4.1, or from runlevel 5, using a Display Manager, such as lightdm-1.30.0.

To start Xfce4 using xinit-1.4.1, run the following commands:

cat > ~/.xinitrc << "EOF"
dbus-launch --exit-with-session startxfce4
EOF

startx

The X session starts on the first unused virtual terminal, normally vt7. You can switch to another vtn simultaneously pressing the keys Ctrl-Alt-Fn (n=1, 2, ...). To switch back to the X session, normally started at vt7, use Ctrl-Alt-F7. The vt where the command startx was executed will display many messages, including X starting messages, applications automatically started with the session, and eventually, some warning and error messages. You may prefer to redirect those messages to a log file, which not only will keep the initial vt uncluttered, but can also be used for debugging purposes. This can be done starting X with:

startx &> ~/.x-session-errors

Note

You may wish to drop dbus-launch, e.g., just using startxfce4 in ~/.xinitrc. However some capabilities such as mounting or umounting file systems from a file manager will not be possible, or the reboot option will be absent or inoperative, among other problems.

When shutting down or rebooting, the shutdown messages appear on the vt where X was running. If you wish to see those messages, simultaneously press keys Alt-F7 (assuming that X was running on vt7).

Contents

Installed Programs: startxfce4, xfce4-session, xfce4-session-logout, xfce4-session-settings, and xflock4
Installed Library: None
Installed Directories: /usr/lib/xfce4/session

Short Descriptions

xfce4-session

starts up the Xfce Desktop Environment

xfce4-session-logout

logs out from Xfce

xfce4-session-settings

is a GTK+ 3 GUI which allows you to alter your preferences for your Xfce Session

Last updated on

Chapter 36. Xfce Applications

This is a small collection of optional applications that add extra capabilities to your Xfce desktop.

Parole-4.16.0

Introduction to Parole

Parole is a DVD/CD/music player for Xfce that uses GStreamer.

This package is known to build and work properly using an LFS-11.1 platform.

Note

Although this version of parole works with most files, it is unable to play DVDs, reporting an error in the gstreamer backend.

Package Information

Parole Dependencies

Required

gst-plugins-base-1.20.0, gst-plugins-good-1.20.0 and libxfce4ui-4.16.1

Recommended
Optional

GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/parole

Installation of Parole

Install Parole by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Using Parole

If you have installed Gstreamer Plugins Ugly with support for libdvdnav and libdvdread and would like to use Parole to play a DVD, click Media> Open location and enter dvd:// into the box.

Similarly, to play a CD, click Media> Open location and enter cdda:// into the box.

Contents

Installed Program: parole
Installed Libraries: Two libraries under /usr/lib/parole-0/
Installed Directories: /usr/include/parole, /usr/lib/parole-0 and /usr/share/parole

Short Descriptions

parole

is a GTK+ 3 media player that uses GStreamer

Last updated on

xfce4-terminal-0.8.10

Introduction to Xfce4 Terminal

Xfce4 Terminal is a GTK+3 terminal emulator. This is useful for running commands or programs in the comfort of an Xorg window; you can drag and drop files into the Xfce4 Terminal or copy and paste text with your mouse.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Xfce4 Terminal Dependencies

Required

libxfce4ui-4.16.1 and VTE-0.66.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xfce4-terminal

Installation of Xfce4 Terminal

Install Xfce4 Terminal by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Program: xfce4-terminal
Installed Libraries: None
Installed Directory: /usr/share/xfce4/terminal

Short Descriptions

xfce4-terminal

is a GTK+ 3 terminal emulator

Last updated on

Xfburn-0.6.2

Introduction to Xfburn

Xfburn is a GTK+ 3 GUI frontend for Libisoburn. This is useful for creating CDs and DVDs from files on your computer or ISO images downloaded from elsewhere.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Xfburn Dependencies

Required

Exo-4.16.3, libburn-1.5.4, libisofs-1.5.4, and libxfce4ui-4.16.1

Optional

gst-plugins-base-1.20.0 and Cdrdao-1.2.4 (runtime)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xfburn

Installation of Xfburn

Install Xfburn by running the following commands:

./configure --prefix=/usr --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Program: xfburn
Installed Libraries: None
Installed Directory: /usr/share/xfburn

Short Descriptions

xfburn

is a GTK+ 3 application for creating CDs and DVDs

Last updated on

Ristretto-0.12.2

Introduction to Ristretto

Ristretto is a fast and lightweight image viewer for the Xfce desktop.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Ristretto Dependencies

Required

libexif-0.6.24 and libxfce4ui-4.16.1

Optional

tumbler-4.16.0 (runtime)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/ristretto

Installation of Ristretto

Install Ristretto by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Program: ristretto
Installed Libraries: None
Installed Directories: None

Short Descriptions

ristretto

is a fast and lightweight image viewer

Last updated on

xfce4-notifyd-0.6.3

Introduction to the Xfce4 Notification Daemon

The Xfce4 Notification Daemon is a small program that implements the "server-side" portion of the Freedesktop desktop notifications specification. Applications that wish to pop up a notification bubble in a standard way can use Xfce4-Notifyd to do so by sending standard messages over D-Bus using the org.freedesktop.Notifications interface.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

The Xfce4 Notification Daemon Dependencies

Required

libnotify-0.7.9, libxfce4ui-4.16.1, and xfce4-panel-4.16.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xfce4-notifyd

Installation of the Xfce4 Notification Daemon

Prevent installing unused files:

sed -e "s/^systemd_user_in_files =.*/systemd_user_in_files =/" \
    -i Makefile.in

Install the Xfce4 Notification Daemon by running the following commands:

./configure --prefix=/usr --sysconfdir=/etc &&
make

This package does not come with a test suite.

Now, as the root user:

make install

You can test the notification daemon with the command notify-send:

notify-send -i info Information "Hi ${USER}, This is a Test"

Contents

Installed Program: xfce4-notifyd-config
Installed Libraries: libnotification-plugin.so
Installed Directories: /usr/share/themes/Bright/xfce-notify-4.0, /usr/share/themes/Default/xfce-notify-4.0, /usr/share/themes/Retro/xfce-notify-4.0, /usr/share/themes/Smoke/xfce-notify-4.0 and /usr/share/themes/ZOMG-PONIES!/xfce-notify-4.0

Short Descriptions

xfce4-notifyd-config

is a GTK+ GUI that allows you to change some of your preferences (theme and screen position) for the notifications that the Xfce4 Notification Daemon displays

Last updated on

xfce4-pulseaudio-plugin-0.4.3

Introduction to the Xfce4 Pulseaudio Plugin

The Xfce4 Pulseaudio Plugin is a plugin for the Xfce panel which provides a convenient way to adjust the audio volume of the PulseAudio sound system and to an auto mixer tool like pavucontrol. It can optionally handle multimedia keys for controlling the audio volume.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Xfce4 Pulseaudio Plugin Dependencies

Required

dbus-glib-0.112, libnotify-0.7.9, PulseAudio-15.0, and xfce4-panel-4.16.3

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xfce4-pulseaudio-plugin

Installation of the Xfce4 Pulseaudio Plugin

Install the Xfce4 Pulseaudio Plugin by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Program: None
Installed Libraries: libpulseaudio-plugin.so
Installed Directories: None

Last updated on

Part X. LXDE

Chapter 37. LXDE Desktop

LXDE is an extremely fast-performing and energy-saving desktop environment.

LXDE comes with a beautiful interface, multi-language support, standard keyboard shortcuts and additional features like tabbed file browsing. LXDE uses less CPU and less RAM than other environments. It is especially designed for cloud computers with low hardware specifications, such as netbooks, mobile devices (e.g. MIDs) or older computers.

Build LXDE core packages in the order presented in the book for the easiest resolution of dependencies.

lxmenu-data-0.1.5

Introduction to LXMenu Data

The LXMenu Data package provides files required to build freedesktop.org menu spec-compliant desktop menus for LXDE.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lxmenu-data

Installation of LXMenu Data

Install LXMenu Data by running the following commands:

./configure --prefix=/usr --sysconfdir=/etc &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: None
Installed Directories: /etc/xdg/menus and /usr/share/desktop-directories

Last updated on

libfm-extra-1.3.2

Introduction to libfm-extra

The libfm-extra package contains a library and other files required by menu-cache-gen libexec of menu-cache-1.1.0.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libfm-extra Dependencies

Required

GLib-2.70.4

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libfm-extra

Installation of libfm-extra

Install libfm-extra by running the following commands:

./configure --prefix=/usr     \
            --sysconfdir=/etc \
            --with-extra-only \
            --with-gtk=no     \
            --disable-static  &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--with-extra-only: This switch disables all components except for the libfm-extra library.

--with-gtk=no: This switch disables support for GTK+ because it is not necessary for this package.

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Library: libfm-extra.so
Installed Directories: /usr/include/libfm (symlink) and /usr/include/libfm-1.0

Short Descriptions

libfm-extra.so

contains the libfm-extra API functions

Last updated on

menu-cache-1.1.0

Introduction to Menu Cache

The Menu Cache package contains a library for creating and utilizing caches to speed up the manipulation for freedesktop.org defined application menus.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Menu Cache Dependencies

Required

libfm-extra-1.3.2

Optional

GTK-Doc-1.33.2 and xdg-utils-1.1.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/menu-cache

Installation of Menu Cache

First fix a memory leak and multiple definitions issues:

patch -Np1 -i ../menu-cache-1.1.0-consolidated_fixes-1.patch

Install Menu Cache by running the following commands:

./configure --prefix=/usr    \
            --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this option if GTK-Doc is installed and you wish to build and install the API documentation.

Contents

Installed Programs: None
Installed Library: libmenu-cache.so
Installed Directories: /usr/{include,libexec,share/gtk-doc/html}/menu-cache

Short Descriptions

libmenu-cache.so

contains the menu-cache API functions

Last updated on

libfm-1.3.2

Introduction to libfm

The libfm package contains a library used to develop file managers providing some file management utilities.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libfm Dependencies

Required

GTK+-3.24.31 or GTK+-2.24.33, and menu-cache-1.1.0

Recommended
Optional

GTK-Doc-1.33.2, dbus-glib-0.112 and Gvfs-1.48.1 or udisks (for volume management - experimental)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libfm

Installation of libfm

Install libfm by running the following commands:

./configure --prefix=/usr     \
            --sysconfdir=/etc \
            --disable-static  &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--with-gtk=3: This option selects the version of gtk+ to use. The default is gtk+-2.

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Program: libfm-pref-apps and lxshortcut
Installed Libraries: libfm.so, libfm-extra.so and libfm-gtk.so
Installed Directories: /etc/xdg/libfm, /usr/lib/libfm, /usr/share/gtk-doc/html/libfm and /usr/share/libfm

Short Descriptions

libfm-pref-apps

sets preferred applications for programs based on libfm

lxshortcut

is a small program used to edit application shortcuts

libfm.so

contains the libfm API functions

Last updated on

PCManFM-1.3.2

Introduction to PCManFM

The PCManFM package contains an extremely fast, lightweight, yet feature-rich file manager with tabbed browsing.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

PCManFM Dependencies

Required

libfm-1.3.2

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pcmanfm

Installation of PCManFM

Install PCManFM by running the following commands:

./configure --prefix=/usr     \
            --sysconfdir=/etc &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Program: pcmanfm
Installed Libraries: None
Installed Directories: /etc/xdg/pcmanfm, /usr/lib/pcmanfm and /usr/share/pcmanfm

Short Descriptions

pcmanfm

is a lightweight GTK+ based file manager for X Window System

Last updated on

libwnck-2.30.7

Introduction to libwnck

The libwnck package contains a Window Navigator Construction Kit.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libwnck Dependencies

Required

GTK+-2.24.33

Recommended
Optional

gobject-introspection-1.70.0 and GTK-Doc-1.33.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libwnck2

Installation of libwnck

Install libwnck by running the following commands:

./configure --prefix=/usr \
            --disable-static \
            --program-suffix=-1 &&
make GETTEXT_PACKAGE=libwnck-1

This package does not come with a test suite.

Now, as the root user:

make GETTEXT_PACKAGE=libwnck-1 install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--program-suffix=-1: This option adds -1 to the end of the names of the installed programs to avoid overwriting the programs installed by libwnck-40.1.

GETTEXT_PACKAGE=libwnck-1: This parameter adds -1 to the end of the names of the gettext files installed by the package to avoid overwriting the files installed by libwnck-40.1.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Contents

Installed Programs: wnckprop-1 and wnck-urgency-monitor-1
Installed Library: libwnck-1.so
Installed Directories: /usr/include/libwnck-1.0 and /usr/share/gtk-doc/html/libwnck-1.0

Short Descriptions

wnckprop-1

Prints, modifies, or interacts with the properties of a screen/workspace/window

libwnck-1.so

contains functions for writing pagers and task lists

Last updated on

LXPanel-0.10.1

Introduction to LXPanel

The LXPanel package contains a lightweight X11 desktop panel.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

LXPanel Dependencies

Required

gdk-pixbuf-xlib-2.40.2, keybinder-0.3.1, libwnck-2.30.7, lxmenu-data-0.1.5 and menu-cache-1.1.0

Recommended
Optional

libindicator (indicator plugin)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lxpanel

Installation of LXPanel

Install LXPanel by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: lxpanel and lxpanelctl
Installed Libraries: liblxpanel.so and several under /usr/lib/lxpanel/plugins
Installed Directories: /etc/xdg/lxpanel, /usr/include/lxpanel, /usr/lib/lxpanel, and /usr/share/lxpanel

Short Descriptions

lxpanel

is a lightweight GTK+ based panel for the LXDE Desktop

lxpanelctl

is a program that controls lxpanel

Last updated on

LXAppearance-0.6.3

Introduction to LXAppearance

The LXAppearance package contains a desktop-independent theme switcher for GTK+.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

LXAppearance Dependencies

Required

GTK+-2.24.33

Recommended
Optional

libxslt-1.1.35 with docbook-xml-4.5 and docbook-xsl-1.79.2 (to build man pages)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lxappearance

Installation of LXAppearance

Install LXAppearance by running the following commands:

./configure --prefix=/usr     \
            --sysconfdir=/etc \
            --enable-dbus     &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--enable-dbus: This switch enables DBus support in LXAppearance which is useful for communicating with LXSession. Remove it if you are not building LXDE or have not installed dbus-glib-0.112.

--enable-man: Use this switch if you have installed optional dependencies and wish to rebuild the manual pages.

Contents

Installed Program: lxappearance
Installed Libraries: None
Installed Directories: /usr/include/lxappearance and /usr/share/lxappearance

Short Descriptions

lxappearance

is a program used to change GTK+ themes, icon themes, and fonts used by applications

Last updated on

LXSession-0.5.5

Introduction to LXSession

The LXSession package contains the default session manager for LXDE.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

LXSession Dependencies

Required

dbus-glib-0.112, libunique-1.1.6, Polkit-0.120, and Vala-0.54.7

Optional

lsb-tools-0.9 (may be used at runtime to display the distribution release in the logout dialog), GTK+-3.24.31, and libxslt-1.1.35 with docbook-xml-4.5 and docbook-xsl-1.79.2 (to build man pages)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lxsession

Installation of LXSession

Install LXSession by running the following commands:

./configure --prefix=/usr --disable-man &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-man: This switch disables building of the manual pages. Remove it if you have installed optional dependencies and wish to build the manual pages.

--enable-gtk3: Builds against GTK+-3 instead of GTK+-2, which is required anyway by libunique.

Contents

Installed Programs: lxclipboard, lxlock, lxpolkit, lxsession, lxsession-db, lxsession-default, lxsession-default-apps, lxsession-default-terminal, lxsession-edit, lxsession-logout, lxsession-xdg-autostart, lxsession-xsettings, and lxsettings-daemon
Installed Libraries: None
Installed Directory: /usr/share/lxsession

Short Descriptions

lxclipboard

is a clipboard utility for LXSession and LXDE

lxlock

locks the local X display until a password is entered

lxpolkit

is a polkit agent

lxsession

is a lightweight X session manager

lxsession-db

is used to modify the database for managing sessions in lxsession

lxsession-default

launch default applications set by LXsession

lxsession-default-apps

is an utility to configure lxsession and its default applications

lxsession-default-terminal

launch the default terminal set by LXSession

lxsession-edit

is the standard session edit manager used by LXDE

lxsession-logout

is a program to logout from LXSession

lxsession-xdg-autostart

handles the autostart spec of freedesktop.org

lxsession-xsettings

is a tool to configure gtk+ themes, keyboard, and mouse for you on session startup

lxsettings-daemon

is the settings daemon for LXsession

Last updated on

lxde-common-0.99.2

Introduction to LXDE Common

The LXDE Common package provides a set of default configuration for LXDE.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

LXDE Common Dependencies

Required

lxde-icon-theme-0.5.1, LXPanel-0.10.1, LXSession-0.5.5, openbox-3.6.1 (runtime), and PCManFM-1.3.2

Recommended
Optional Runtime Dependencies

A notification daemon such as notification-daemon-3.20.0 or xfce4-notifyd-0.6.3, and a display manager such as lxdm-0.5.3 or lightdm-1.30.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lxde-common

Installation of LXDE Common

Install LXDE Common by running the following commands:

./configure --prefix=/usr --sysconfdir=/etc &&
make

This package does not come with a test suite.

Now, as the root user:

make install

If you have installed recommended dependencies, run the following commands as the root user:

update-mime-database /usr/share/mime &&
gtk-update-icon-cache -qf /usr/share/icons/hicolor &&
update-desktop-database -q

Starting LXDE

You can start LXDE from runlevel 3, using xinit-1.4.1, or from runlevel 5, using a Display Manager, such as lxdm-0.5.3.

To start LXDE using xinit-1.4.1, run the following commands:

cat > ~/.xinitrc << "EOF"
# No need to run dbus-launch, since it is run by startlxde
startlxde
EOF

startx

The X session starts on the first unused virtual terminal, normally vt7. You can switch to another vtn simultaneously pressing the keys Ctrl-Alt-Fn (n=1, 2, ...). To switch back to the X session, normally started at vt7, use Ctrl-Alt-F7. The vt where the command startx was executed will display many messages, including X starting messages, applications automatically started with the session, and eventually, some warning and error messages. You may prefer to redirect those messages to a log file, which not only will keep the initial vt uncluttered, but can also be used for debug purposes. This can be done starting X with:

startx &> ~/.x-session-errors

When shutting down or rebooting, the shutdown messages appear on the vt where X was running. If you wish to see those messages, simultaneously press keys Alt-F7 (assuming that X was running on vt7).

Contents

Installed Programs: lxde-logout, openbox-lxde and startlxde
Installed Libraries: None
Installed Directories: /etc/xdg/{lxpanel,lxsession,openbox,pcmanfm}/LXDE and /usr/share/lxde

Short Descriptions

lxde-logout

is used to quit the desktop session for LXDE

openbox-lxde

is a wrapper script which runs Openbox with LXDE specific config file

startlxde

is used to start the desktop session for LXDE

Last updated on

Chapter 38. LXDE Applications

This is a small collection of optional applications that add extra capabilities to the LXDE desktop.

GPicView-0.2.5

Introduction to GPicView

The GPicView package contains a lightweight image viewer.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GPicView Dependencies

Required

GTK+-2.24.33

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gpicview

Installation of GPicView

Install GPicView by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&
sed -i 's/Utility;//' /usr/share/applications/gpicview.desktop

If you have xdg-utils-1.1.3 installed, as the root user, you should run the xdg-icon-resource forceupdate --theme hicolor command, for the installed icon to be displayed in the menu item.

Command Explanations

sed -i ...: Fixes submenu for GPicView.

Contents

Installed Program: gpicview
Installed Libraries: None
Installed Directory: /usr/share/gpicview

Short Descriptions

gpicview

is a lightweight image viewer

Last updated on

lxappearance-obconf-0.2.3

Introduction to LXAppearance OBconf

The LXAppearance OBconf package contains a plugin for LXAppearance to configure OpenBox.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

LXAppearance OBconf Dependencies

Required

LXAppearance-0.6.3 and openbox-3.6.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lxappearance-obconf

Installation of LXAppearance OBconf

Install LXAppearance OBconf by running the following commands:

./configure --prefix=/usr --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Library: /usr/lib/lxappearance/plugins/obconf.so
Installed Directories: /usr/lib/lxappearance and /usr/share/lxappearance/obconf

Last updated on

LXInput-0.3.5

Introduction to LXInput

The LXInput package contains a small program used to configure keyboard and mouse for LXDE.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

LXInput Dependencies

Required

GTK+-2.24.33

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lxinput

Installation of LXInput

Install LXInput by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Program: lxinput
Installed Libraries: None
Installed Directory: /usr/share/lxinput

Short Descriptions

lxinput

is a program used to configure keyboard and mouse

Last updated on

LXRandR-0.3.2

Introduction to LXRandR

The LXRandR package contains a monitor configuration tool for LXDE.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

LXRandR Dependencies

Required

GTK+-2.24.33 and Xorg Applications

Optional

libxslt-1.1.35 with docbook-xml-4.5 and docbook-xsl-1.79.2 (to build man pages)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lxrandr

Installation of LXRandR

Install LXRandR by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--enable-man: Use this switch if you have installed optional dependencies and wish to build the manual pages.

Contents

Installed Program: lxrandr
Installed Libraries: None
Installed Directories: None

Short Descriptions

lxrandr

is a GTK+ interface to XRandR

Last updated on

LXTask-0.1.10

Introduction to LXTask

The LXTask package contains a lightweight and desktop-independent task manager.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

LXTask Dependencies

Required

GTK+-2.24.33

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lxtask

Installation of LXTask

Install LXTask by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Program: lxtask
Installed Libraries: None
Installed Directories: None

Short Descriptions

lxtask

is a lightweight and desktop-independent task manager

Last updated on

Vte-0.28.2

Introduction to Vte

Vte is a library (libvte) implementing a terminal emulator widget for GTK+ 2, and a minimal demonstration application (vte) that uses libvte.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Vte Dependencies

Required

GTK+-2.24.33

Optional

gobject-introspection-1.70.0, GTK-Doc-1.33.2 and PyGTK-2.24.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/vte2

Installation of Vte

Install Vte by running the following commands:

./configure --prefix=/usr \
            --libexecdir=/usr/lib/vte \
            --disable-static  &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--libexecdir=/usr/lib/vte : both this package and VTE-0.66.2 install files of the same name. This switch ensures that they do not overwrite each other if both are installed.

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Program: vte
Installed Library: libvte.so
Installed Directories: /usr/include/vte-0.0, /usr/lib/vte, /usr/share/gtk-doc/html/vte-0.0 and /usr/share/vte

Short Descriptions

vte

is a simple terminal emulator

libvte.so

contains the Vte API functions

Last updated on

LXTerminal-0.4.0

Introduction to LXTerminal

The LXTerminal package contains a VTE-based terminal emulator for LXDE with support for multiple tabs.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

LXTerminal Dependencies

Required

Vte-0.28.2

Optional

libxslt-1.1.35 with docbook-xml-4.5 and docbook-xsl-1.79.2 (to build man pages)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lxterminal

Installation of LXTerminal

Install LXTerminal by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--enable-man: Use this switch if you have installed optional dependencies and wish to build the manual pages.

Contents

Installed Program: lxterminal
Installed Libraries: None
Installed Directory: /usr/share/lxterminal

Short Descriptions

lxterminal

a lightweight terminal emulator for the LXDE desktop

Last updated on

Part XI. X Software

Chapter 39. Office Programs

This chapter is a collection of programs that are useful for viewing or editing office documents. Some specialise in doing one thing (such as word processing or manipulating a spreadsheet). LibreOffice is a suite of programs that can manipulate many different formats including powerpoint presentations.

AbiWord-3.0.5

Introduction to AbiWord

AbiWord is a word processor which is useful for writing reports, letters and other formatted documents.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

AbiWord Dependencies

Required

Boost-1.78.0, cURL-7.81.0, FriBidi-1.0.11, GOffice-0.10.51, and wv-1.2.9

Recommended
Optional

dbus-glib-0.112, evolution-data-server-3.42.4, gobject-introspection-1.70.0, libchamplain-0.12.20, libgcrypt-1.10.0, libical-3.0.14, libsoup-2.74.2, Redland-1.0.17, telepathy-glib-0.24.2, Valgrind-3.18.1. Aiksaurus, GtkMathView, libwmf, libwpd, libwpg, libwps, Link Grammar Parser, Loudmouth, OTS, and Psiconv

Note

To enable many of the optional dependencies, review the information from ./configure --help for the necessary switches you must pass to the configure script.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/abiword

Installation of AbiWord

Install AbiWord by running the following commands:

sed -e "s/free_suggestions/free_string_list/" \
    -e "s/_to_personal//"                     \
    -e "s/in_session/added/"                  \
    -i src/af/xap/xp/enchant_checker.cpp      &&

./configure --prefix=/usr &&
make

This program does not come with a functional test suite.

Now, as the root user:

make install

Note

In order to install the local help files, a graphics session is recommended.

If you wish to install the local help files, untar and build them first:

Note

The current version of the docs expands to abiword-docs-3.0.1 and not the expected abiword-docs-3.0.2.

tar -xf ../abiword-docs-3.0.2.tar.gz &&
cd abiword-docs-3.0.1                &&
./configure --prefix=/usr            &&
make

and then, as the root user:

make install

Command Explanations

sed ...: This command corrects the source for changes in the dependency enchant-2.3.2.

--enable-plugins="collab openxml goffice grammar": Build some or all plugins. The openxml plugin enables Abiword to open some .docx files. The grammar plugin requires Link Grammar Parser

Configuring AbiWord

Config File

~/.AbiSuite/templates/normal.awt

Configuration Information

Choose the right template for your language and locale from the list produced by the following command:

ls /usr/share/abiword-3.0/templates

Create the folder ~/.AbiSuite/templates then copy the normal.awt you want into it:

install -v -m750 -d ~/.AbiSuite/templates &&
install -v -m640    /usr/share/abiword-3.0/templates/normal.awt-<lang> \
                    ~/.AbiSuite/templates/normal.awt

Change <lang> by the above command to fit the name of the file you want.

If you are using multiple languages, you may need to edit the template to use a font with greater coverage (e.g. one of the Dejavu fonts, because Abiword does not use fontconfig and can only display glyphs that are provided in the chosen font.

If you have desktop-file-utils-0.26 installed, you should run the update-desktop-database command to update the mimeinfo cache and allow the Help system to work.

If you have xdg-utils-1.1.3 installed, you should run the xdg-icon-resource forceupdate --theme hicolor command, for the installed icon to be displayed in the menu item.

Contents

Installed Program: abiword
Installed Library: libabiword-3.0.so
Installed Directories: /usr/include/abiword-3.0, /usr/lib/abiword-3.0, and /usr/share/abiword-3.0

Short Descriptions

abiword

is the word processor, a wrapper for the functions in libabiword-3.0 - it can also be used on the command line, see man 1 abiword

libabiword-3.0.so

provides functions to access MS Word documents

Last updated on

Gnumeric-1.12.51

Introduction to Gnumeric

The Gnumeric package contains a spreadsheet program which is useful for mathematical analysis.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Gnumeric Dependencies

Required

GOffice-0.10.51 and itstool-2.0.7

Recommended Runtime
Optional

DConf-0.40.0 (to prevent some test failures), gobject-introspection-1.70.0, PyGObject-3.42.0, Valgrind-3.18.1 (for some tests), dblatex (for PDF docs), libgda, Mono, pxlib, and Psiconv

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gnumeric

Installation of Gnumeric

Install Gnumeric by running the following commands:

./configure --prefix=/usr  &&
make

This package must be installed before the test suite is run.

Now, as the root user:

make install

To run the tests, issue make check. Tests should be run from an active X session, and DConf-0.40.0 should be installed to prevent some failures. Eight valgrind tests are known to fail.

Command Explanations

--enable-pdfdocs: Use this switch if you have installed dblatex and wish to create PDF docs.

Contents

Installed Programs: gnumeric (symlink), gnumeric-1.12.51, ssconvert, ssdiff, ssgrep, and ssindex
Installed Libraries: libspreadsheet.so
Installed Directories: /usr/include/libspreadsheet-1.12, /usr/lib/gnumeric, /usr/lib/goffice/0.10/plugins/gnumeric, /usr/share/gnumeric, and /usr/share/help/{C,cs,de,es}/gnumeric

Short Descriptions

gnumeric

is a symlink to gnumeric-1.12.51

gnumeric-1.12.51

is GNOME's spreadsheet application

ssconvert

is a command line utility to convert spreadsheet files between various spreadsheet file formats

ssdiff

is a command line utility to compare two spreadsheets

ssgrep

is a command line utility to search spreadsheets for strings

ssindex

is a command line utility to generate index data for spreadsheet files

libspreadsheet.so

contains the gnumeric API functions

Last updated on

LibreOffice-7.3.0

Introduction to LibreOffice

LibreOffice is a full-featured office suite. It is largely compatible with Microsoft Office and is descended from OpenOffice.org.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Core Download: https://download.documentfoundation.org/libreoffice/src/7.3.0/libreoffice-7.3.0.3.tar.xz

  • Core Download MD5 sum: 8d7d3fb99d3680d58c92f42e20657965

  • Core Download size: 243 MB

  • Estimated disk space required: 7.0 GB including the additional files if downloaded during the build (793 MB installed). Installing the whole set of languages requires more than 25 GB (around 3 GB installed)

  • Estimated build time: 55 SBU with parallelism=4 (will vary due to download time)

Additional Downloads

Note

Around 80 smallish tarballs and zip files will be downloaded during the build. The download time will vary with the local internet speed and server load. The download time will probably be between 30 and 60 minutes. If you have not downloaded one or more of the following, they too will also be downloaded during the build.

LibreOffice Dependencies

Required

Archive-Zip-1.68, UnZip-6.0, Wget-1.21.2, Which-2.21, and Zip-3.0

Recommended

Note

Most of these packages are recommended because if they're not installed, the build process will compile and install its own (often older) version, with the side effect of increasing build and installed disk space and build time.

Optional

Avahi-0.8, BlueZ-5.63, DConf-0.40.0, desktop-file-utils-0.26, Doxygen-1.9.3 (not relevant if using --disable-odk), evolution-data-server-3.42.4, GDB-11.2, GnuTLS-3.7.3, KDE Frameworks-5.91.0, libpaper-1.1.24+nmu5, MariaDB-10.6.7 or MySQL, MIT Kerberos V5-1.19.2, NASM-2.15.05, SANE-1.0.32, telepathy-glib-0.24.2, Valgrind-3.18.1, VLC-3.0.16, Zenity-3.32.0, Apache Commons Codec, Apache Commons HttpClient, Apache Commons Lang, Apache Commons Logging, BeanShell, box2d, CoinMP, Cppunit, Firebird, glyphy, Gnome VFS, hamcrest, Hunspell, Hyphen, iwyu, junit4, libabw, libcdr, libcmis, libebook, libepubgen, libetonyek, libexttextcat, libfreehand, liblangtag, libmspub, libmwaw, libnumbertext, libodfgen, libpagemaker, libqrcodegen, libqxp, librevenge (WordPerfect Document importer), libstaroffice, libvisio, libwpd, libwpg, libwps, libzmf, lp_solve, mdds, MyThes, odfvalidator, officeotron, OpenCOLLADA, Orcus, SystemTap, and VIGRA

There are many optional dependencies not listed here. They can be found in download.lst (source directory).

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libreoffice

Installation of LibreOffice

Important

Unlike the other packages, we assume that you have not yet unpacked the package. This is because the --no-overwrite-dir switch is needed in case you unpack as the root user.

tar -xf libreoffice-7.3.0.3.tar.xz --no-overwrite-dir &&
cd libreoffice-7.3.0.3

First, fix a problem if bison-3.8 or later is installed:

if bison --version|grep -q 3.8; then
  sed -i 's/yyn/yyrule/' connectivity/source/parse/sqlbison.y
fi

If you have downloaded the dictionaries, help and translations tarballs, create symlinks to them from the source directory so they won't get downloaded again:

install -dm755 external/tarballs &&
ln -sv ../../../libreoffice-dictionaries-7.3.0.3.tar.xz external/tarballs/ &&
ln -sv ../../../libreoffice-help-7.3.0.3.tar.xz         external/tarballs/ &&
ln -sv ../../../libreoffice-translations-7.3.0.3.tar.xz external/tarballs/

The instructions in the package unpack some tarballs into a location it cannot find later. Create some symlinks to help out:

ln -sv src/libreoffice-help-7.3.0.3/helpcontent2/ &&
ln -sv src/libreoffice-dictionaries-7.3.0.3/dictionaries/ &&
ln -sv src/libreoffice-translations-7.3.0.3/translations/

Note

During the build process, some packages will be downloaded (including the ones listed as recommended and optional dependencies) if they are not present on the system. Because of this, build time may vary from the published time more than usual.

Due to the large size of the package, you may prefer to install it in /opt, instead of /usr. Depending on your choice, replace <PREFIX> by /usr or by /opt/libreoffice-7.3.0.3:

export LO_PREFIX=<PREFIX>

Locales "fr" and "en-GB", you will find below, are just examples; you should change them to suit your needs - you might want to read the "Command Explanations", further below, before proceeding.

Note

If you set the ACLOCAL environment variable to support installing Xorg in /opt, you will need to unset it for this package.

If building on a 32 bit machine, CFLAGS is set to -Os, which breaks the build. Prevent this by issuing:

case $(uname -m) in
   i?86) sed /-Os/d -i solenv/gbuild/platform/LINUX_INTEL_GCC.mk ;;
esac

Prepare LibreOffice for compilation by running the following commands:

sed -e "/gzip -f/d"   \
    -e "s|.1.gz|.1|g" \
    -i bin/distro-install-desktop-integration &&

sed -e "/distro-install-file-lists/d" -i Makefile.in &&

./autogen.sh --prefix=$LO_PREFIX         \
             --sysconfdir=/etc           \
             --with-vendor=BLFS          \
             --with-lang='fr en-GB'      \
             --with-help                 \
             --with-myspell-dicts        \
             --without-junit             \
             --without-system-dicts      \
             --disable-dconf             \
             --disable-odk               \
             --enable-release-build=yes  \
             --enable-python=system      \
             --with-jdk-home=/opt/jdk    \
             --with-system-apr           \
             --with-system-boost         \
             --with-system-clucene       \
             --with-system-curl          \
             --with-system-epoxy         \
             --with-system-expat         \
             --with-system-glm           \
             --with-system-gpgmepp       \
             --with-system-graphite      \
             --with-system-harfbuzz      \
             --with-system-icu           \
             --with-system-jpeg          \
             --with-system-lcms2         \
             --with-system-libatomic_ops \
             --with-system-libpng        \
             --with-system-libxml        \
             --with-system-neon          \
             --with-system-nss           \
             --with-system-odbc          \
             --with-system-openldap      \
             --with-system-openssl       \
             --with-system-poppler       \
             --with-system-postgresql    \
             --with-system-redland       \
             --with-system-serf          \
             --with-system-zlib

The instructions below will only build the package without running any unit tests. If you prefer to run the unit tests, replace make build-nocheck with make build or (as a regular user only) just make, but do not be surprised if a unit test fails right at the end of the build and breaks it.

Build the package:

make build-nocheck

Now, as the root user:

make distro-pack-install

If installed in /opt/libreoffice-7.3.0.3 some additional steps are necessary. Issue the following commands as the root user:

if [ "$LO_PREFIX" != "/usr" ]; then

  # This symlink is necessary for the desktop menu entries
  ln -svf $LO_PREFIX/lib/libreoffice/program/soffice /usr/bin/libreoffice &&

  # Set up a generic location independent of version number
  ln -sfv libreoffice-7.3.0.3 /opt/libreoffice

  # Icons
  mkdir -vp /usr/share/pixmaps
  for i in $LO_PREFIX/share/icons/hicolor/32x32/apps/*; do
    ln -svf $i /usr/share/pixmaps
  done &&

  # Desktop menu entries
  for i in $LO_PREFIX/lib/libreoffice/share/xdg/*; do
    ln -svf $i /usr/share/applications/libreoffice-$(basename $i)
  done &&

  # Man pages
  for i in $LO_PREFIX/share/man/man1/*; do
    ln -svf $i /usr/share/man/man1/
  done

  unset i
fi

If you have installed desktop-file-utils-0.26, and you wish to update the MIME database, issue, as the root user:

update-desktop-database

The suite and main modules can be started from the menu. From a terminal, the suite can be started with the libreoffice command and the modules with the libreoffice --<module> command, respectively, where <module> is one of base, calc, draw, impress, math, web, or writer. Modules cannot be started using their shell starting script names (see "Installed Programs", below), if LO_PREFIX is other than /usr, unless the $LO_PREFIX/bin directory is appended to the PATH.

Command Explanations

sed -e ...: The first sed prevents compression of the manual pages and the second one prevents the install from failing.

--with-vendor=BLFS: This switch sets BLFS as the vendor which is mentioned when you click "About" from the Help menu on the toolbar.

--with-lang='fr en-GB': This switch sets what languages to support. To list several languages, separate them with a space. For all languages, use --with-lang=ALL. Note that the translations file is not needed and won't be downloaded if using only en_US as a language.

Note

For a list of the available languages, look in solenv/inc/langlist.mk.

--with-help: Without this switch, the help files are not built.

--with-jdk-home=/opt/jdk: This parameter will silence a warning that the configure script attempted to find JAVA_HOME automatically (even though that is passed in the environment). Omit this if you disabled java.

--with-myspell-dicts: This switch adds myspell dictionaries to the LibreOffice installation set.

--with-system-boost: This switch enables using system boost. From time to time, recent versions of boost break the build of libreoffice. In this case, it is possible to use the bundled copy of boost, by removing this flag.

--disable-dconf: This switch disables compiling LibreOffice with the GNOME DConf configuration system support.

--without-junit: This switch disables the tests for the deprecated HSQLDB driver which is written in Java.

--without-system-dicts: This switch disables the use of dictionaries from system paths so that the ones installed by this package are used.

--disable-odk: This switch disables installing the office development kit. Remove if you want to develop a LibreOffice based application.

--enable-release-build=yes: This switch enables a Release Build. LibreOffice can be built as a Release Build or as a Developer Build, because their default installation paths and user profile paths are different. Developer Build displays the words "Dev" and "Beta" in several places (e.g, menu and splash screen).

--enable-python=system: This switch tells LibreOffice to use the system installed Python 3 instead of the bundled one.

--with-system-*: These switches prevent LibreOffice from trying to compile its own versions of these dependencies. If you've not installed some of the dependencies, remove the corresponding switches.

make distro-pack-install: This does a normal install, but if you add a DESTDIR environment variable it will also install a lot of (text) gid_Module_* files in the DESTDIR, to help distributions which want to break the package into parts.

--with-parallelism=<count>: This switch tells LibreOffice to use <count> CPU cores to compile in parallel. (Do not include literal angle brackets.) The default is to use all available cores on the system.

--disable-cups: Use this switch if you don't need printing support.

--disable-dbus: Use this switch if you've not installed D-Bus-1.8.0 or later. It also disables Bluetooth support and font install via PackageKit.

--disable-firebird-sdbc: By default, the ability to connect to a firebird database is enabled. Add this switch if you do not need that feature.

--disable-gstreamer-1-0: Use this switch if you have not installed gst-plugins-base-1.20.0.

--disable-postgresql-sdbc: This switch disables compiling LibreOffice with the ability to connect to a PostgreSQL database. Use it if you have not installed PostgreSQL and you do not want LibreOffice to compile its bundled copy.

--disable-skia: Use Cairo-1.17.4 for rendering instead of skia.

--enable-gtk3-kde5: This switch allows the Visual Class Library, which is responsible for widgets, to be built with KF5 file dialogs if GTK+-3, Qt5 and Plasma are all available.

--enable-lto: This switch will enable Link Time Optimization, which results in slightly smaller libraries (about 40 MB). This is said to make LibreOffice programs load faster (and possibly run faster, e.g. when recalculating a spreadsheet). On an 8-core machine with 16GB of memory, the difference in compile times was minimal, but an extra 2GB was used for the work files. On machines with fewer processors or a lack of memory, the compile might be much slower.

--without-java: This switch disables Java support in LibreOffice. Java is needed for the deprecated HSQLDB driver, which allows reading databases created by other programs or in earlier versions of libreoffice base.

--without-fonts: LibreOffice includes a number of third-party TrueType fonts. If you have already installed some or all of the same fonts, you may prefer to use the system versions.

--enable-kf5: Builds with KDE/Plasma integration. If Qt-5.15.2 and/or KDE Frameworks-5.91.0 are not installed in /usr, the include and library directories must be specified in QT5INC, QT5LIB, KF5INC, and KF5LIB, respectively.

--enable-evolution2: Enables support for Evolution address books through Evolution Data Server. Note that Evolution Data Server must be installed for this feature to function.

Contents

Installed Programs: libreoffice, lobase, localc, lodraw, loffice, lofromtemplate, loimpress, lomath, loweb, lowriter, soffice and unopkg; several programs under $LO_PREFIX/lib/libreoffice/program
Installed Libraries: several libraries under $LO_PREFIX/lib/libreoffice/program
Installed Directory: $LO_PREFIX/lib/libreoffice

Short Descriptions

libreoffice (or soffice)

is the main libreofice suite (symlink to $LO_PREFIX/lib/libreoffice/program/soffice)

lobase

is the database manager module shell starting script

localc

is the spreadsheet module shell starting script

lodraw

is the vector graphics editor and diagramming tool module shell starting script

loimpress

is the (PowerPoint) presentations editor and displayer module shell starting script

lomath

is the mathematical formula editor module shell starting script

loweb

is the HTML editor module shell starting script

lowriter

is the word processor module shell starting script

unopkg

is a tool to manage LibreOffice extensions from the command line

Last updated on

Chapter 40. Graphical Web Browsers

This chapter contains a wonderful selection of browsers. We hope you can find one you enjoy using or give them each a trial run.

Epiphany-41.3

Introduction to Epiphany

Epiphany is a simple yet powerful GNOME web browser targeted at non-technical users. Its principles are simplicity and standards compliance.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Epiphany Dependencies

Required

Gcr-3.40.0, gnome-desktop-41.3, ISO Codes-4.9.0, JSON-GLib-1.6.6, libnotify-0.7.9, libportal-0.5, Nettle-3.7.3, and WebKitGTK-2.34.6

Recommended
Optional

Appstream-Glib

Runtime Dependencies

gnome-keyring-40.0 (for storing passwords) and Seahorse-41.0 (for managing stored passwords)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/epiphany

Installation of Epiphany

First, fix building with newer versions of meson:

sed -i '/merge_file/{n;d}' data/meson.build

Next, fix an issue building Epiphany with libportal-0.5 or later:

sed "/dependency/s@'libportal'@'libportal-gtk3'@" -i meson.build
sed "/portal-gtk3/s@portal/@portal-gtk3/@" -i lib/ephy-flatpak-utils.c

Install Epiphany by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release .. &&
ninja

Now, as the root user:

ninja install

Note

If you installed the package to your system using a DESTDIR method, /usr/share/glib-2.0/schemas/gschemas.compiled was not updated/created. Create (or update) the file using the following command as the root user:

glib-compile-schemas /usr/share/glib-2.0/schemas

One test would fail if this package is not installed, so it's better to run the test suite after installation. To test the results, issue ninja test. The tests must be run from a graphical session.

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Program: epiphany
Installed Libraries: None
Installed Directories: /usr/{lib,libexec,share,share/help/*}/epiphany

Short Descriptions

epiphany

is a GNOME web browser based on the WebKit2 rendering engine

Last updated on

Falkon-3.2.0

Introduction to falkon

Falkon is a KDE web browser using the QtWebEngine rendering engine. It was previously known as QupZilla. It aims to be a lightweight web browser available through all major platforms.

Although falkon is now part of KDE, it can be installed without KDE (with the loss of kwallet functionality).

Warning

Falkon relies on QtWebEngine. That uses a forked copy of chromium, and is therefore vulnerable to many issues found there. The Qt developers have always preferred to make releases at the same time as the rest of Qt (rather than adding emergency fixes). Now that they are keen to move to Qt6, the 5.15.3 and later Qt-5.15 releases are initially only available to paying customers. QtWebEngine is something of an exception because of its LGPL licence, but getting the git sources (with the forked chromium submodule) to a point where they will successfully build on a current BLFS system can take a lot of effort. Be aware that future fixes for vulnerabilities might be very delayed, to the extent that you might wish to consider using a different browser.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

falkon Dependencies

Required

extra-cmake-modules-5.91.0, KDE Frameworks-5.91.0 (for karchive), and qtwebengine-5.15.8

Note

Strictly speaking, only karchive is required to build falkon, but several other packages in KF5 can be used if they are present. To build only karchive, download that package from the directory specified in KDE Frameworks-5.91.0 and use the build instructions on that page changing the $KF5_PREFIX to /usr.

Optional

gnome-keyring-40.0 and PySide2 for experimental Python plugins (compiling this from source is very slow).

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/falkon

Installation of falkon

Install falkon by running the following commands:

Unless you have installed both PySide2 and ki18n, remove the translations for the sample hellopython.py script:

rm -rf po/

Now build the program:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_BUILD_TYPE=Release  \
      .. &&

make

To test the results, issue: make test. All tests should pass. If any fail, the full results will be in Testing/Temporary/LastTest.log.

Now, as the root user:

make install

If you have installed Pyside2 you will want to examine the hellopython.py which is in the scripts/ directory, and perhaps copy it to your home directory.

Command Explanations

-DBUILD_TESTING=OFF: This will save a little time and space by not building the test programs, use this if you do not wish to run the test.

Contents

Installed Programs: falkon
Installed Library: libFalkonPrivate.so.3
Installed Directory: ${FALKON_PREFIX}/lib/plugins, ${FALKON_PREFIX}/share/falkon.

Short Descriptions

falkon

is a web browser which uses qtwebengine

libFalkonPrivate.so.3

contains functions used by falkon

Last updated on

Firefox-91.6.0

Introduction to Firefox

Firefox is a stand-alone browser based on the Mozilla codebase.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Note

The directory name is firefox-91.6.0

Extracting the tarball will reset the permissions of the current directory to 0755 if you have permission to do that. If you do this in a directory where the sticky bit is set, such as /tmp it will end with error messages:

tar: .: Cannot utime: Operation not permitted
tar: .: Cannot change mode to rwxr-xr-t: Operation not permitted
tar: Exiting with failure status due to previous errors

This does finish with non-zero status, but it does NOT mean there is a real problem. Do not untar as the root user in a directory where the sticky bit is set - that will unset it.

As with other large packages which use C++ (or rust), the SBU times to build this vary more widely than you might expect. The build times will increase significantly if your machine has to swap.

Although upstream prefer to use PulseAudio, for the moment Alsa can still be used. Both may need runtime configuration to get sound working.

Firefox Dependencies

Required

Autoconf-2.13, Cbindgen-0.20.0, dbus-glib-0.112, both GTK+-3.24.31 and GTK+-2.24.33, libnotify-0.7.9, LLVM-13.0.1 (clang, used for bindgen even if using gcc), nodejs-16.14.0, PulseAudio-15.0 (or alsa-lib-1.2.6.1 if you edit the mozconfig; now deprecated by mozilla), in either case please read the Configuration Information, Python-3.10.2 (rebuilt after installing SQLite-3.37.2), startup-notification-0.12, UnZip-6.0, yasm-1.3.0, and Zip-3.0

Recommended

Note

If you don't install recommended dependencies, then internal copies of those packages will be used. They might be tested to work, but they can be out of date or contain security holes.

Optional

cURL-7.81.0, Doxygen-1.9.3, FFmpeg-4.4.1 (runtime, to play mov, mp3 or mp4 files), liboauth-1.0.3, Valgrind-3.18.1, Wget-1.21.2, Wireless Tools-29, libproxy

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/firefox

Installation of Firefox

The configuration of Firefox is accomplished by creating a mozconfig file containing the desired configuration options. A default mozconfig is created below. To see the entire list of available configuration options (and an abbreviated description of some of them), issue ./mach configure && ./configure --help | less. You may also wish to review the entire file and uncomment any other desired options. Create the file by issuing the following command:

cat > mozconfig << "EOF"
# If you have a multicore machine, all cores will be used by default.

# If you have installed (or will install) wireless-tools, and you wish
# to use geolocation web services, comment out this line
ac_add_options --disable-necko-wifi

# API Keys for geolocation APIs - necko-wifi (above) is required for MLS
# Uncomment the following line if you wish to use Mozilla Location Service
#ac_add_options --with-mozilla-api-keyfile=$PWD/mozilla-key

# Uncomment the following line if you wish to use Google's geolocaton API
# (needed for use with saved maps with Google Maps)
#ac_add_options --with-google-location-service-api-keyfile=$PWD/google-key

# startup-notification is required since firefox-78

# Uncomment the following option if you have not installed PulseAudio
#ac_add_options --disable-pulseaudio
# or uncomment this if you installed alsa-lib instead of PulseAudio
#ac_add_options --enable-alsa

# Comment out following options if you have not installed
# recommended dependencies:
ac_add_options --with-system-icu
ac_add_options --with-system-libevent
ac_add_options --with-system-libvpx
ac_add_options --with-system-nspr
ac_add_options --with-system-nss
ac_add_options --with-system-webp

# Do not specify the gold linker which is not the default. It will take
# longer and use more disk space when debug symbols are disabled.

# libdavid (av1 decoder) requires nasm. Uncomment this if nasm
# has not been installed.
#ac_add_options --disable-av1

# You cannot distribute the binary if you do this
ac_add_options --enable-official-branding

# Stripping is now enabled by default.
# Uncomment these lines if you need to run a debugger:
#ac_add_options --disable-strip
#ac_add_options --disable-install-strip

# Disabling debug symbols makes the build much smaller and a little
# faster. Comment this if you need to run a debugger. Note: This is
# required for compilation on i686.
ac_add_options --disable-debug-symbols

# The elf-hack is reported to cause failed installs (after successful builds)
# on some machines. It is supposed to improve startup time and it shrinks
# libxul.so by a few MB - comment this if you know your machine is not affected.
ac_add_options --disable-elf-hack

# The BLFS editors recommend not changing anything below this line:
ac_add_options --prefix=/usr
ac_add_options --enable-application=browser
ac_add_options --disable-crashreporter
ac_add_options --disable-updater
# enabling the tests will use a lot more space and significantly
# increase the build time, for no obvious benefit.
ac_add_options --disable-tests

# The default level of optimization again produces a working build with gcc.
ac_add_options --enable-optimize

ac_add_options --enable-system-ffi
ac_add_options --enable-system-pixman

ac_add_options --with-system-jpeg
ac_add_options --with-system-png
ac_add_options --with-system-zlib

# The following option unsets Telemetry Reporting. With the Addons Fiasco,
# Mozilla was found to be collecting user's data, including saved passwords and
# web form data, without users consent. Mozilla was also found shipping updates
# to systems without the user's knowledge or permission.
# As a result of this, use the following command to permanently disable
# telemetry reporting in Firefox.
unset MOZ_TELEMETRY_REPORTING

mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/firefox-build-dir
EOF

Compile Firefox by issuing the following commands:

First apply a patch which works around unexplained failures on some machines (a message that a python check on libgkrust.a identified 1 networking function, getsockname) in the rust static library.

patch -Np1 -i ../firefox-91.6.0esr-disable_rust_test-1.patch

If building on a 32 bit machine, the following sed works around an issue with an incompatible double type in one header file:

case "$(uname -m)" in
    i?86) sed -e '/typedef[ ]*double/s/double/long double/' \
              -i modules/fdlibm/src/math_private.h ;;
esac

If the geolocation APIs are needed:

Note

The Google and Mozilla API Keys below are specific to LFS. If using these instructions for another distro, or if you intend to distribute binary copies of the software using these instructions, please obtain your own keys following the instructions located at http://www.chromium.org/developers/how-tos/api-keys and https://location.services.mozilla.com/api respectively.

echo "AIzaSyDxKL42zsPjbke5O8_rPVpVrLrJ8aeE9rQ" > google-key
echo "613364a7-9418-4c86-bcee-57e32fd70c23" > mozilla-key

Note

If you are compiling this package in chroot you must do two things. First, as the root user, ensure that /dev/shm is mounted. If you do not do this, the Python configury will fail with a traceback report referencing /usr/lib/pythonN.N/multiprocessing/synchronize.py. Run:

mountpoint -q /dev/shm || mount -t tmpfs devshm /dev/shm

Second, either as the root user export the $SHELL environment variable using export SHELL=/bin/sh or else prepend SHELL=/bin/sh when running the ./mach commands.

Now invoke the Python mach script to compile the package.

export CC=gcc CXX=g++ &&
export MACH_USE_SYSTEM_PYTHON=1            &&
export MOZBUILD_STATE_PATH=${PWD}/mozbuild &&
./mach configure                           &&
./mach build

The mozconfig above disables the tests because they use a lot more time and disk space for no obvious benefit. If you have nevertheless enabled them, you can run the tests by executing ./mach gtest. This will require a network connection, and to be run from within an Xorg session - there is a popup dialog when it fails to connect to ALSA (that does not create a failed test). One or two tests will fail. To see the details of the failure(s) you will need to log the output from that command so that you can review it.

Now, as the root user:

MACH_USE_SYSTEM_PYTHON=1 ./mach install

Empty the environment variables which were set above:

unset CC CXX MACH_USE_SYSTEM_PYTHON MOZBUILD_STATE_PATH

Command Explanations

export CC=gcc CXX=g++ ...: Upstream now prefer clang so that they can use one compiler everywhere. On the X86 architectures clang now appears to support most of the same security-hardening options as GCC. With the current versions and the default flags, GCC creates a marginally bigger build but takes typically 2 SBU less time on a 4-core machine using the mozconfig above.

export MOZBUILD_STATE_PATH=${PWD}/mozbuild: The build is now supposed to tell you that it intends to create ~/.mozbuild, and offer you an option to press <ENTER> to accept this, or Ctrl-C to cancel and restart the build after specifying the directory. In practice, the message may not appear until after <ENTER> is keyed, i.e. the build stalls.

That directory is used for a (probably random) telemetry identifier. Creating this in the build directory, and deleting that after the installation, prevents it being used. If you wish to participate in telemetry, export MOZBUILD_STATE_PATH to point to its default directory and remove the entry from the mozconfig.

MACH_USE_SYSTEM_PYTHON=1: Use the system python to create a virtual environment for mach without downloading any python wheels.

./mach configure: This validates the supplied dependencies and the mozconfig.

./mach build --verbose: Use this alternative if you need details of which files are being compiled, together with any C or C++ flags being used. But do not add '--verbose' to the install command, it is not accepted there.

./mach build -jN: The build should, by default, use all the online CPU cores. If using all the cores causes the build to swap because you have insufficient memory, using fewer cores can be faster.

Configuring Firefox

If you use a desktop environment like Gnome or KDE you may like to create a firefox.desktop file so that Firefox appears in the panel's menus. As the root user:

mkdir -pv /usr/share/applications &&
mkdir -pv /usr/share/pixmaps      &&

MIMETYPE="text/xml;text/mml;text/html"                                     &&
MIMETYPE="$MIMETYPE;application/xhtml+xml;application/vnd.mozilla.xul+xml" &&
MIMETYPE="$MIMETYPE;x-scheme-handler/http;x-scheme-handler/https"          &&

cat > /usr/share/applications/firefox.desktop << EOF &&
[Desktop Entry]
Encoding=UTF-8
Name=Firefox Web Browser
Comment=Browse the World Wide Web
GenericName=Web Browser
Exec=firefox %u
Terminal=false
Type=Application
Icon=firefox
Categories=GNOME;GTK;Network;WebBrowser;
MimeType=$MIMETYPE
StartupNotify=true
EOF

unset MIMETYPE &&

ln -sfv /usr/lib/firefox/browser/chrome/icons/default/default128.png \
        /usr/share/pixmaps/firefox.png

Configuration Information

The application settings for firefox are accessible by keying about:config in the address bar.

Occasionally, getting working sound in firefox can be a problem. Although upstream prefers pulseaudio, on balance using Alsa may be easier.

If you enabled Alsa for sound, you may need to alter one variable to get working sound. If you run firefox from a term and try to play something with sound you might encounter error messages like:

Sandbox: seccomp sandbox violation: pid 3941, tid 4030, syscall 16, args 48 2147767296 139909894784796 0 0 0.

That was on x86_64, on i686 the syscall number is 54. To allow this syscall, in about:config change security.sandbox.content.syscall_whitelist to 16 (or 54 if using i686).

If you use pulseaudio in a Desktop Environment, it might already be started by that DE. But if it is not, although firefox-57 managed to start it, firefox-58 did not. If you run firefox from a term and this problem is present, trying to play sound will encounter error messages warning Can't get cubeb context!

The fix for this is to close firefox, start pulseaudio to check it does start (if not, read the information on Configuring in PulseAudio-15.0) and restart firefox to check it is working. If it now works, add the following to your ~/.xinitrc: pulseaudio --verbose --log-target=syslog& (unfortunately, on some systems this does not work).

You may wish to use multiple profiles within firefox. To do that, invoke firefox as firefox --ProfileManager. You can also check which profile is currently in use from about:profiles.

Although WebRender (using the GPU for compositing) is not used by default, it now appears to work well on supported hardware (ATI, Nvidia and Intel GPUs with Mesa-18 or later. For an explanation, please see hacks.mozilla.org. The only downside seems to be that on a machine with limited RAM it might use more RAM.

To check if WebRender is being used, look in about:support. In the Graphics section Compositing will either show 'Basic' (i.e. not in use) or 'WebRender'. To enable it, go to about:config and change gfx.webrender.all to True. You will need to restart firefox.

It may be useful to mention the processes from firefox which can appear in top - as well as firefox itself, there may be multiple Web Content processes, and now an RDD Process (Remote Data Decoder) which appears when playing web videos encoded with av1 (libdav1d). If WebRender has been enabled, a GPU Process will also appear when firefox has to repaint (e.g. scrolling, opening a new tab, or playing a video).

Contents

Installed Programs: firefox
Installed Libraries: Numerous libraries, browser components, plugins, extensions, and helper modules installed in /usr/lib/firefox
Installed Directory: /usr/lib/firefox

Short Descriptions

firefox

is a GTK+-3 internet browser that uses the Mozilla Gecko rendering engine

Last updated on

SeaMonkey-2.53.10.2

Introduction to SeaMonkey

SeaMonkey is a browser suite, the Open Source sibling of Netscape. It includes the browser, composer, mail and news clients, and an IRC client. It is the follow-on to the Mozilla browser suite.

The Mozilla project also hosts two subprojects that aim to satisfy the needs of users who don't need the complete browser suite or prefer to have separate applications for browsing and e-mail. These subprojects are Firefox-91.6.0 and Thunderbird-91.6.1. Both are based on the Mozilla source code.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Note

The tarball seamonkey-2.53.10.2.source.tar.xz will untar to seamonkey-2.53.10.2 directory.

SeaMonkey Dependencies

Required

Autoconf-2.13, both GTK+-2.24.33 and GTK+-3.24.31, Python-2.7.18, rustc-1.58.1, UnZip-6.0, yasm-1.3.0, and Zip-3.0

Recommended

Note

If you don't install recommended dependencies, then internal copies of those packages will be used. They might be tested to work, but they can be out of date or contain security holes.

Optional

alsa-lib-1.2.6.1, cURL-7.81.0, dbus-glib-0.112, Doxygen-1.9.3, GConf-3.2.6, gst-plugins-base-1.20.0 (and other plugins, only for tests), startup-notification-0.12, Valgrind-3.18.1, Wget-1.21.2, Wireless Tools-29, Hunspell, and Watchman

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/seamonkey

Installation of SeaMonkey

The configuration of SeaMonkey is accomplished by creating a mozconfig file containing the desired configuration options. A default mozconfig file is created below. To see the entire list of available configuration options (and an abbreviated description of each one), issue ./configure --help. You may also wish to review the entire file and uncomment any other desired options. Create the file by issuing the following command:

cat > mozconfig << "EOF"
# If you have a multicore machine, all cores will be used

# If you have installed DBus-Glib comment out this line:
ac_add_options --disable-dbus

# If you have installed dbus-glib, and you have installed (or will install)
# wireless-tools, and you wish to use geolocation web services, comment out
# this line
ac_add_options --disable-necko-wifi

# Uncomment these lines if you have installed optional dependencies:
#ac_add_options --enable-system-hunspell
#ac_add_options --enable-startup-notification

# Uncomment the following option if you have not installed PulseAudio
#ac_add_options --disable-pulseaudio
# and uncomment this if you installed alsa-lib instead of PulseAudio
#ac_add_options --enable-alsa

# Comment out following option if you have gconf installed
ac_add_options --disable-gconf

# Comment out following options if you have not installed
# recommended dependencies:
ac_add_options --with-system-icu
ac_add_options --with-system-libevent
ac_add_options --with-system-nspr
ac_add_options --with-system-nss
ac_add_options --with-system-webp

# The elf-hack is reported to cause failed installs (after successful builds)
# on some machines. It is supposed to improve startup time and it shrinks
# libxul.so by a few MB - comment this if you know your machine is not affected.
ac_add_options --disable-elf-hack

# Seamonkey has some additional features that are not turned on by default,
# such as an IRC client, calendar, and DOM Inspector. The DOM Inspector
# aids with designing web pages. Comment these options if you do not
# desire these features.
ac_add_options --enable-calendar
ac_add_options --enable-dominspector
ac_add_options --enable-irc

# The BLFS editors recommend not changing anything below this line:
ac_add_options --prefix=/usr
ac_add_options --enable-application=comm/suite

ac_add_options --disable-crashreporter
ac_add_options --disable-updater
ac_add_options --disable-tests

# rust-simd does not compile with recent versions of rust.
# It is disabled in recent versions of firefox
ac_add_options --disable-rust-simd

ac_add_options --enable-optimize="-O2"
ac_add_options --enable-strip
ac_add_options --enable-install-strip
ac_add_options --enable-official-branding

# The option to use system cairo was removed in 2.53.9.
ac_add_options --enable-system-ffi
ac_add_options --enable-system-pixman

ac_add_options --with-system-bz2
ac_add_options --with-system-jpeg
ac_add_options --with-system-png
ac_add_options --with-system-zlib
EOF

Note

If you are compiling this package in chroot you must do two things. First, as the root user, ensure that /dev/shm is mounted. If you do not do this, the Python configury will fail with a traceback report referencing /usr/lib/pythonN.N/multiprocessing/synchronize.py. Run:

mountpoint -q /dev/shm || mount -t tmpfs devshm /dev/shm

Second, either as the root user export the $SHELL environment variable using export SHELL=/bin/sh or else prepend SHELL=/bin/sh when running the first make command.

Compile SeaMonkey by running the following commands:

export CC=gcc CXX=g++ &&
./mach configure      &&
./mach build

This package does not come with a test suite.

Install SeaMonkey by issuing the following commands as the root user:

./mach install                  &&
chown -R 0:0 /usr/lib/seamonkey &&

cp -v $(find -name seamonkey.1 | head -n1) /usr/share/man/man1

Command Explanations

export CC=gcc CXX=g++ ...: Upstream now prefer clang so that they can use one compiler everywhere. On the X86 architectures clang takes a little longer than gcc to compile mozilla applications.

./mach configure: This validates the supplied dependencies and the mozconfig.

./mach build --verbose: Use this alternative if you need details of which files are being compiled, together with any C or C++ flags being used. But do not add '--verbose' to the install command, it is not accepted there.

./mach build -jN: The build should, by default, use all the online CPU cores. If using all the cores causes the build to swap because you have insufficient memory, using fewer cores can be faster.

Configuring SeaMonkey

For installing various SeaMonkey add-ons, refer to Add-ons for Seamonkey.

Along with using the Preferences menu to configure SeaMonkey's options and preferences to suit individual tastes, finer grain control of many options is only available using a tool not available from the general menu system. To access this tool, you'll need to open a browser window and enter about:config in the address bar. This will display a list of the configuration preferences and information related to each one. You can use the Search: bar to enter search criteria and narrow down the listed items. Changing a preference can be done using two methods. One, if the preference has a boolean value (True/False), simply double-click on the preference to toggle the value and two, for other preferences simply right-click on the desired line, choose Modify from the menu and change the value. Creating new preference items is accomplished in the same way, except choose New from the menu and provide the desired data into the fields when prompted.

If you use a desktop environment like Gnome or KDE you may wish to create a seamonkey.desktop file so that SeaMonkey appears in the panel's menus. If you didn't enable Startup-Notification in your mozconfig change the StartupNotify line to false. As the root user:

mkdir -pv /usr/share/{applications,pixmaps}              &&

cat > /usr/share/applications/seamonkey.desktop << "EOF"
[Desktop Entry]
Encoding=UTF-8
Type=Application
Name=SeaMonkey
Comment=The Mozilla Suite
Icon=seamonkey
Exec=seamonkey
Categories=Network;GTK;Application;Email;Browser;WebBrowser;News;
StartupNotify=true
Terminal=false
EOF

ln -sfv /usr/lib/seamonkey/chrome/icons/default/default128.png \
        /usr/share/pixmaps/seamonkey.png

Contents

Installed Programs: seamonkey
Installed Libraries: Numerous libraries, browser, and email/newsgroup components, plugins, extensions, and helper modules installed in /usr/lib/seamonkey-2.53.10.2
Installed Directory: /usr/lib/seamonkey

Short Descriptions

seamonkey

is the Mozilla browser/email/newsgroup/chat client suite

Last updated on

Chapter 41. Other X-based Programs

These programs use the X Window System and don't fit easily into any of the other chapters.

Balsa-2.6.3

Introduction to Balsa

The Balsa package contains a GNOME-2 based mail client.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Balsa Dependencies

Required

Aspell-0.60.8, enchant-2.3.2, GMime-3.2.7, GPGME-1.17.0, GTK+-3.24.31, and libnotify-0.7.9

Required (Runtime)

MTA (that provides a sendmail command)

Optional

Compface-1.5.2, Gcr-3.40.0, gtksourceview-3.24.11, libcanberra-0.30, libsecret-0.20.5, MIT Kerberos V5-1.19.2, OpenLDAP-2.6.1, Procmail-3.22, SQLite-3.37.2, WebKitGTK-2.34.6, html2text, osmo, rubrica, yelp-tools

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/balsa

Installation of Balsa

Install Balsa by running the following commands:

./configure --prefix=/usr            \
            --sysconfdir=/etc        \
            --localstatedir=/var/lib \
            --without-html-widget    &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--without-html-widget: This option disables building the HTML renderer. If you want the HTML renderer to be built, verify that you have WebKitGTK-2.34.6 installed, and then remove this option.

--with-canberra: Enable libcanberra support.

--with-compface: Enable compface support.

--with-gcr: Use libgcr for TLS support.

--with-gss: Enable GSSAPI support.

--with-ldap: Use this option to enable LDAP address book support if OpenLDAP is installed.

--with-libsecret: Enable strong password support and support for gnome-keyring to store passwords.

--with-sqlite: Use this option to enable SQLite address book support if SQLite is installed.

Contents

Installed Programs: balsa and balsa-ab
Installed Libraries: None
Installed Directories: /etc/sounds/events, /usr/share/balsa, and /usr/share/sounds/balsa

Short Descriptions

balsa

is a glib based mail client

balsa-ab

is the address-book application used by balsa

Last updated on

feh-3.8

Introduction to feh

feh is a fast, lightweight image viewer which uses Imlib2. It is commandline-driven and supports multiple images through slideshows, thumbnail browsing or multiple windows, and montages or index prints (using TrueType fonts to display file info). Advanced features include fast dynamic zooming, progressive loading, loading via HTTP (with reload support for watching webcams), recursive file opening (slideshow of a directory hierarchy), and mouse wheel/keyboard control.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://feh.finalrewind.org/feh-3.8.tar.bz2

  • Download MD5 sum: 53be3654ce3b6371da5ca6e06bf61bf7

  • Download size: 2.0 MB

  • Estimated disk space required: 5.5 MB (with tests)

  • Estimated build time: less than 0.1 SBU (with tests)

feh Dependencies

Required

libpng-1.6.37 and imlib2-1.8.0 (built with giflib-5.2.1 support, for the tests)

Recommended
Optional

libexif-0.6.24

Optional (runtime)

libjpeg-turbo-2.1.2 (for lossless image rotation) and ImageMagick-7.1.0-25 (to load unsupported formats)

Optional (test suite)

Test-Command-0.11 (required)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/feh

Installation of feh

Install feh by running the following commands:

sed -i "s:doc/feh:&-3.8:" config.mk &&
make PREFIX=/usr

To test the results, issue: make test.

Now, as the root user:

make PREFIX=/usr install

Command Explanations

sed -i "s:doc/feh:&-3.8:" config.mk: This sed fixes the doc directory to a versioned one, as used in BLFS.

curl=0: Use this make flag if you don't have the cURL package installed.

exif=1: This make flag enables builtin Exif tag display support.

Contents

Installed Program: feh
Installed Libraries: None
Installed Directories: /usr/share/doc/feh-3.8 and /usr/share/feh

Short Descriptions

feh

is an image viewer and cataloguer

Last updated on

FontForge-20201107

Introduction to FontForge

The FontForge package contains an outline font editor that lets you create your own postscript, truetype, opentype, cid-keyed, multi-master, cff, svg and bitmap (bdf, FON, NFNT) fonts, or edit existing ones.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

FontForge Dependencies

Required

libspiro-20200505, libuninameslist-20211114, and libxml2-2.9.13

Recommended
Optional

giflib-5.2.1, git-2.35.1, libjpeg-turbo-2.1.2, libtiff-4.3.0, WOFF2-1.0.2, and Sphinx (to build html documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/fontforge

Installation of FontForge

Install FontForge by running the following commands:

mkdir build &&
cd build    &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_BUILD_TYPE=Release  \
      -Wno-dev .. &&
make

To test the results, issue: make check.

Now, as the root user:

make install

If you have installed sphinx-build, HTML documentation was built and installed in /usr/share/doc/fontforge. To be able to access it as a versioned directory, create a symlink as the root user:

ln -sv fontforge /usr/share/doc/fontforge-20201107

Command Explanations

-DCMAKE_BUILD_TYPE=Release: This switch is used to create an optimized release without debug information.

-Wno-dev: This switch is used to suppress warnings intended for the package's developers.

-DENABLE_X11=ON: use an X11 backend instead of GDK3 (gtk+-3) for basic Xorg graphics.

Contents

Installed Programs: fontforge, fontimage, fontlint and sfddiff
Installed Library: libfontforge.so and /usr/lib/python3.10.2/site-packages/{fontforge,psMat}.so
Installed Directories: /usr/share/fontforge and optionally /usr/share/doc/fontforge{,-20201107}

Short Descriptions

fontforge

is a program that allows you to create and modify font files

fontimage

is a program that produces an image showing representative glyphs of the font

fontlint

is a program that checks the font for certain common errors

sfddiff

is a program that compares two font files

Last updated on

Gimp-2.10.30

Introduction to Gimp

The Gimp package contains the GNU Image Manipulation Program which is useful for photo retouching, image composition and image authoring.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Note

Updating the help files is still a work in progress, with large parts of the text for many languages not yet translated. The file below is a git snapshot.

Gimp Dependencies

Required

gegl-0.4.34, gexiv2-0.14.0, glib-networking-2.70.1, GTK+-2.24.33, HarfBuzz-3.4.0. libjpeg-turbo-2.1.2, libmypaint-1.6.1, librsvg-2.52.6, libtiff-4.3.0, Python2 libxml2-2.9.13 module (to build the translated help files), Little CMS-2.13.1, mypaint-brushes-1.3.1, Poppler-22.02.0 (including poppler-data) and a graphical environment

Recommended
Optional

AAlib-1.4rc5, alsa-lib-1.2.6.1, Gvfs-1.48.1 (to access the online help), libmng-2.0.3, libwebp-1.2.2, OpenJPEG-2.4.0, an MTA (that provides a sendmail program), GTK-Doc-1.33.2, appstream-glib, libbacktrace, libheif with libde265 (both needed to read macOS heic images), libunwind, libwmf, and OpenEXR

When you have run configure, you will see that WebKit is not found - that dependency is for the legacy webkit-1.0 which should never be used on a modern system exposed to the internet.

Optional, for building the help system

dblatex (for PDF docs), pngnq and pngcrush to optimize the png files, but see the note on the help download above

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gimp

Installation of Gimp

Install Gimp by running the following commands:

./configure --prefix=/usr --sysconfdir=/etc &&
make

To test the results (requires an X-Windowed terminal) issue: make check.

Now, as the root user:

make install

Note

This package installs icon files into the /usr/share/icons/hicolor hierarchy and desktop files into the /usr/share/applications hierarchy. You can improve system performance and memory usage by updating /usr/share/icons/hicolor/index.theme and /usr/share/applications/mimeinfo.cache. To perform the update you must have GTK+-2.24.33 or GTK+-3.24.31 installed (for the icon cache) and desktop-file-utils-0.26 (for the desktop cache) and issue the following commands as the root user:

gtk-update-icon-cache -qtf /usr/share/icons/hicolor &&
update-desktop-database -q

Installation of Gimp-Help

The gimp-help tarball contains images and English text help for help files, together with translations. Because of the issues mentioned in the note above, you are recommended to use the online help, either by building against Gvfs-1.48.1 so that 'help' can open the latest XML files in your browser, or else you can manually open the html in your browser by going to https://docs.gimp.org/2.10/en (change the language code if desired).

If you nevertheless wish to install local copies of the help files to read offline, unpack the gimp-help tarball and change into the root of the newly created source tree. Prepare for the build with the following command:

ALL_LINGUAS="ca da de el en en_GB es fi fr it ja ko nn pt_BR ro ru zh_CN" \
./autogen.sh --prefix=/usr

Remove from ALL_LINGUAS the codes for any languages which you do not wish to install. Alternatively, remove the line starting with ALL_LINGUAS, if you wish to build all languages.

Now build the help files:

make

Issue the following commands as the root user to install the help files:

make install &&
chown -R root:root /usr/share/gimp/2.0/help

Command Explanations

ALL_LINGUAS="ca da de el en en_GB ...": by default, the help files will be rendered in all the available languages. Remove the codes of any languages you do not wish to build.

--disable-python: This option is necessary if you have not installed PyGTK.

--enable-gtk-doc: Use this parameter if GTK-Doc is installed and you wish to rebuild and install the API documentation.

Configuring The Gimp

Config Files

/etc/gimp/2.0/* and ~/.gimp-2.8/gimprc

Contents

Installed Programs: gimp (symlink), gimp-2.10, gimp-console (symlink), gimp-console-2.10, gimp-test-clipboard-2.0, and gimptool-2.0
Installed Libraries: libgimp-2.0.so, libgimpbase-2.0.so, libgimpcolor-2.0.so, libgimpconfig-2.0.so, libgimpmath-2.0.so, libgimpmodule-2.0.so, libgimpthumb-2.0.so, libgimpui-2.0.so, and libgimpwidgets-2.0.so
Installed Directories: /etc/gimp, /usr/include/gimp-2.0, /usr/{lib,share}/gimp, /usr/share/gtk-doc/html/libgimp{,base,color,config}, and /usr/share/gtk-doc/html/libgimp{math,module,thumb,widgets}

Short Descriptions

gimp

is a symbolic link to gimp-2.10

gimp-2.10

is the Gnu Image Manipulation Program. It works with a variety of image formats and provides a large selection of tools

gimp-console

is a symbolic link to gimp-console-2.10

gimp-console-2.10

is a console program that behaves as if The Gimp was called with the --no-interface command-line option

gimptool-2.0

is a tool that can build plug-ins or scripts and install them if they are distributed in one source file. gimptool-2.0 can also be used by programs that need to know what libraries and include-paths The Gimp was compiled with

libgimp-2.0.so

provides C bindings for The Gimp's Procedural Database (PDB) which offers an interface to core functions and to functionality provided by plug-ins

libgimpbase-2.0.so

provides the C functions for basic Gimp functionality such as determining enumeration data types, gettext translation, determining The Gimp's version number and capabilities, handling data files and accessing the environment

libgimpcolor-2.0.so

provides the C functions relating to RGB, HSV and CMYK colors as well as converting colors between different color models and performing adaptive supersampling on an area

libgimpconfig-2.0.so

contains C functions for reading and writing config information

libgimpmath-2.0.so

contains C functions which provide mathematical definitions and macros, manipulate 3x3 transformation matrices, set up and manipulate vectors and the MD5 message-digest algorithm

libgimpmodule-2.0.so

provides the C functions which implement module loading using GModule and supports keeping a list of GimpModule's found in a given searchpath

libgimpthumb-2.0.so

provides the C functions for handling The Gimp's thumbnail objects

libgimpui-2.0.so

contains The Gimp's common user interface functions

libgimpwidgets-2.0.so

contains The Gimp and GTK's widget creation and manipulation functions

Last updated on

Gparted-1.3.1

Introduction to Gparted

Gparted is the Gnome Partition Editor, a Gtk 3 GUI for other command line tools that can create, reorganise or delete disk partitions.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Gparted Dependencies

Required

Gtkmm-3.24.5 and parted-3.4

Optional

btrfs-progs-5.16.2 (if using a btrfs filesystem), exfatprogs, and udftools

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gparted

Installation of Gparted

Install Gparted by running the following commands:

./configure --prefix=/usr    \
            --disable-doc    \
            --disable-static &&
make

To run the tests, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--disable-doc: This switch disables building of the optional documentation. Remove it if you have installed GNOME Doc Utils.

--enable-xhost-root: This switch provides an interim workaround to allow GParted to run under Wayland by using xhost to grant and revoke root access to the X11 display.

Using Gparted

To manipulate file systems Gparted has a run time dependency on various file system tools (you only need to install the tools for file systems you actually use): Hdparm-9.63 (required for optionally displaying serial number device information), btrfs-progs-5.16.2, dosfstools-4.2, e2fsprogs (installed as part of LFS), jfsutils-1.1.15, reiserfsprogs-3.6.27, xfsprogs-5.14.2, mtools (required to read and write FAT16/32 volume labels and UUIDs), hfsutils, hfsprogs, nilfs-utils and Reiser4progs.

Root privileges are required to run Gparted. If you wish to run the application from the menu, further applications and configurations are necessary. Examples of applications that may be used: gksu, kdesudo, or xdg-su. Another simple solution is ssh-askpass-8.8p1.

ssh-askpass

To optionally use ssh-askpass-8.8p1 if it is installed in your system, run the following commands as the root user:

cp -v /usr/share/applications/gparted.desktop /usr/share/applications/gparted.desktop.back &&
sed -i 's/Exec=/Exec=sudo -A /'               /usr/share/applications/gparted.desktop

Now, clicking on the menu item for Gparted, a dialog appears on the screen, asking for the administrator password.

Contents

Installed Programs: gparted and gparted_polkit (optional)
Installed Libraries: None
Installed Directories: None

Short Descriptions

gparted

is a shell script which sets up the environment before calling gpartedbin

gparted_polkit

is an optional script which can be used to run gparted with polkit, from a menu

Last updated on

HexChat-2.16.1

Introduction to HexChat

HexChat is an IRC chat program. It allows you to join multiple IRC channels (chat rooms) at the same time, talk publicly, have private one-on-one conversations, etc. File transfers are also possible.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

HexChat Dependencies

Required

dbus-glib-0.112, GLib-2.70.4, and libnotify-0.7.9

Recommended
Optional

dbus-glib-0.112, ISO Codes-4.9.0, libnotify-0.7.9, pciutils-3.7.0, libproxy, luajit, if python is enabled cffi and pycparser.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/hexchat

Installation of HexChat

Install HexChat by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr         \
      --buildtype=release   \
      -Dwith-lua=false      \
      -Dwith-python=false   \
      ..                    &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Command Explanations

-Dwith-lua=false: By default, this package will look for luajit. However, the Lua plugin support is currently broken and will cause the application to crash on startup.

-Dwith-python=false: If the Python interface should be enabled, remove this switch or set it to true. When enabling Python, two additional modules (cffi and pycparser) needs to be installed prior to installation of Hexchat.

-Dwith-libcanberra=false: Use this switch if you have libcanberra not installed.

Contents

Installed Program: hexchat
Installed Libraries: None
Installed Directory: /usr/lib/hexchat

Short Descriptions

hexchat

is a graphical Internet Relay Chat (IRC) client

Last updated on

Inkscape-1.1.2

Introduction to Inkscape

Inkscape is a what you see is what you get Scalable Vector Graphics editor. It is useful for creating, viewing and changing SVG images.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Note

The tarball inkscape-1.1.2.tar.xz will extract to inkscape-1.1.2_2022-02-04_0a00cf5339.

Inkscape Dependencies

Required

Boost-1.78.0, double-conversion-3.2.0, GC-8.0.6, GDL-3.40.0, Gsl-2.7.1, Gtkmm-3.24.5, libsoup-2.74.2, libxslt-1.1.35, Poppler-22.02.0, popt-1.18 and Wget-1.21.2 (to download the test dependencies)

Recommended
Optional

Aspell-0.60.8, dbus-1.12.20 (to run inkscape from scripts), Doxygen-1.9.3, gtkspell, libcdr, libvisio, libwpg (or libwpd) and NumPy (at runtime for some extensions)

Optional Runtime Dependencies (for some of the Inkscape extensions)

XML::XQL

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/inkscape

Installation of Inkscape

Install Inkscape by running the following commands:

mkdir build                       &&
cd    build                       &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_BUILD_TYPE=Release  \
      ..                          &&
make

This package does not come with a working test suite.

Now, as the root user:

make install

Note

This package installs icon files into the /usr/share/icons/hicolor hierarchy and desktop files into the /usr/share/applications hierarchy. You can improve system performance and memory usage by updating /usr/share/icons/hicolor/index.theme and /usr/share/applications/mimeinfo.cache. To perform the update you must have GTK+-2.24.33 or GTK+-3.24.31 installed (for the icon cache) and desktop-file-utils-0.26 (for the desktop cache) and issue the following commands as the root user:

gtk-update-icon-cache -qtf /usr/share/icons/hicolor &&
update-desktop-database -q

Command Explanations

-DCMAKE_BUILD_TYPE=Release: This switch is used to build the release library without any debug `assert` in the code.

-DWITH_DBUS=ON: use this if you wish to use inkscape in interactive scripts which manipulate images.

Contents

Installed Programs: inkscape and inkview
Installed Library: libinkscape_base.so
Installed Directories: /usr/lib/inkscape and /usr/share/inkscape

Short Descriptions

inkscape

is a SVG (Scalable Vector Graphics) editing program

inkview

is a simple program for displaying SVG files

libinkscape_base.so

provides the routines used by inkscape and inkview

Last updated on

Pidgin-2.14.8

Introduction to Pidgin

Pidgin is a Gtk+ 2 instant messaging client that can connect with a wide range of networks including Bonjour, ICQ, GroupWise, Jabber/XMPP, IRC, Gadu-Gadu, SILC, SIMPLE, and Zephyr.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Pidgin Dependencies

Required

GTK+-2.24.33

Recommended
Optional

Avahi-0.8 (required for the Bonjour plugin), Cyrus SASL-2.1.27, dbus-1.12.20, Doxygen-1.9.3, evolution-data-server-3.42.4, GConf-3.2.6, Graphviz-2.50.0, libidn-1.38 (required, if you wish to run the test suite), libnsl-2.0.0, NetworkManager-1.34.0, SQLite-3.37.2 (required for the Contact Availability Prediction plugin), startup-notification-0.12, Tk-8.6.12, Farstream (Version 0.1) (required for video and voice support), Gtkspell, libgadu, Meanwhile (required for Sametime protocol support), Mono, SILC Client, SILC Toolkit, Zephyr, and MIT Kerberos V5-1.19.2 (required for Kerberos support in the Zephyr module)

Optional (runtime)

xdg-utils-1.1.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pidgin

Installation of Pidgin

First, fix a test that fails:

sed '/09-13/s@^@//@' -i libpurple/tests/test_util.c

Compile Pidgin by running the following commands:

./configure --prefix=/usr        \
            --sysconfdir=/etc    \
            --with-gstreamer=1.0 \
            --disable-avahi      \
            --disable-gtkspell   \
            --disable-meanwhile  \
            --disable-idn        \
            --disable-nm         \
            --disable-vv         &&
make

If you have Doxygen-1.9.3 installed (Graphviz-2.50.0 can be used also) and you wish to create the API documentation, issue:

make docs

To test the results, issue: make check.

Now, as the root user:

make install &&
mkdir -pv /usr/share/doc/pidgin-2.14.8 &&
cp -v README doc/gtkrc-2.0 /usr/share/doc/pidgin-2.14.8

If you created the API documentation, install it using the following commands as the root user:

mkdir -pv /usr/share/doc/pidgin-2.14.8/api &&
cp -rv doc/html/* /usr/share/doc/pidgin-2.14.8/api

Note

This package installs icon files into the /usr/share/icons/hicolor hierarchy and desktop files into the /usr/share/applications hierarchy. You can improve system performance and memory usage by updating /usr/share/icons/hicolor/index.theme and /usr/share/applications/mimeinfo.cache. To perform the update you must have GTK+-2.24.33 or GTK+-3.24.31 installed (for the icon cache) and desktop-file-utils-0.26 (for the desktop cache) and issue the following commands as the root user:

gtk-update-icon-cache -qtf /usr/share/icons/hicolor &&
update-desktop-database -q

Command Explanations

--with-gstreamer=1.0: Remove this switch and add --disable-gstreamer if you've not installed gstreamer-1.20.0.

--disable-avahi: Remove this switch if you've installed Avahi-0.8.

--disable-gtkspell: Remove this switch if you've installed Gtkspell and wish to enable spellchecking support.

--disable-meanwhile: Remove this switch if you've installed Meanwhile.

--disable-idn: Remove this switch if you've installed libidn-1.38.

--disable-nm: Remove this switch if you've installed NetworkManager-1.34.0.

--disable-vv: Remove this switch if you've installed Farstream (Version 0.1) and wish to enable voice and video communication support. You should also remove the --disable-gstreamer flag.

--enable-cyrus-sasl: Use this switch if you've installed Cyrus SASL-2.1.27 and wish to build Pidgin with SASL support.

--disable-gnutls: Use this switch if you've got both GnuTLS-3.7.3 and nss-3.75 installed, but want to use nss-3.75 for the SSL support.

Configuring Pidgin

Config Files

~/.purple/* and ~/.gtkrc-2.0

Configuration Information

Most configuration can be accomplished by using the various preference settings inside the programs. Additionally, you can create a ~/.gtkrc-2.0 file which can store gtk+-2 theme settings that affect Pidgin and other Gtk+ 2 applications. Note that an example gtkrc-2.0 file was installed during the package installation and can be used as a starting point or reference.

Contents

Installed Programs: pidgin, purple-client-example, purple-remote, purple-send, purple-send-async, and purple-url-handler
Installed Library: libpurple.so, and libpurple-client.so
Installed Directories: /usr/include/libpurple, /usr/include/pidgin, /usr/lib/pidgin, /usr/lib/purple-2, /usr/share/doc/pidgin-2.14.8, /usr/share/pixmaps/pidgin, /usr/share/purple, and /usr/share/sounds/purple

Short Descriptions

pidgin

is a GTK+ 2 instant messaging client

purple-client-example

is an example that demonstrates how to use the libpurple-client library to communicate with purple

purple-remote

sends remote commands to Pidgin/Finch

purple-send

calls purple API functions using DBus and prints the return value

purple-send-async

calls purple API functions using DBus. As opposed to purple-send, it does not print the return value

purple-url-handler

is a python script to handle URLs with purple

Last updated on

Rox-Filer-2.11

Introduction to Rox-Filer

rox-filer is a fast, lightweight, gtk2 file manager.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

rox-filer Dependencies

Required

libglade-2.6.4 and shared-mime-info-2.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/rox-filer

Kernel Configuration

If you want rox-filer to be able to update the contents of a directory when changes are made to the files by other applications (eg, if a script is running) you will need to enable dnotify support in your kernel. In make menuconfig:

File systems --->
  [*] Dnotify support   [CONFIG_DNOTIFY]

Save the new .config and then compile the kernel.

Installation of Rox-Filer

Compile rox-filer with the following commands:

cd ROX-Filer                                                        &&
sed -i 's:g_strdup(getenv("APP_DIR")):"/usr/share/rox":' src/main.c &&
sed -i 's/gboolean/extern &/' src/session.h                     &&

mkdir build                        &&
pushd build                        &&
  ../src/configure LIBS="-lm -ldl" &&
  make                             &&
popd

Now install it as the root user:

mkdir -p /usr/share/rox                              &&
cp -av Help Messages Options.xml ROX images style.css .DirIcon /usr/share/rox &&

cp -av ../rox.1 /usr/share/man/man1                  &&
cp -v  ROX-Filer /usr/bin/rox                        &&
chown -Rv root:root /usr/bin/rox /usr/share/rox      &&

cd /usr/share/rox/ROX/MIME                           &&
ln -sv text-x-{diff,patch}.png                       &&
ln -sv application-x-font-{afm,type1}.png            &&
ln -sv application-xml{,-dtd}.png                    &&
ln -sv application-xml{,-external-parsed-entity}.png &&
ln -sv application-{,rdf+}xml.png                    &&
ln -sv application-x{ml,-xbel}.png                   &&
ln -sv application-{x-shell,java}script.png          &&
ln -sv application-x-{bzip,xz}-compressed-tar.png    &&
ln -sv application-x-{bzip,lzma}-compressed-tar.png  &&
ln -sv application-x-{bzip-compressed-tar,lzo}.png   &&
ln -sv application-x-{bzip,xz}.png                   &&
ln -sv application-x-{gzip,lzma}.png                 &&
ln -sv application-{msword,rtf}.png

Command Explanations

sed -i 's:g_strdup(getenv("APP_DIR")):"/usr/share/rox":' src/main.c: This command hard codes /usr/share/rox as the directory for rox-filer's private files. Without this sed rox needs the environment variable ${APP_DIR} to be set.

sed -i 's/gboolean/extern &/' src/session.h: This command fixes a multiple definition flagged as an error by GCC 10 and higher.

ln -sv application-...: These commands duplicate the icons for some common mime types. Without these links rox-filer would just display the default "unknown binary blob" icon.

Configuring RoxFiler

Configuration Information

Most of the configuration of rox-filer is achieved by right clicking on a rox-filer window and choosing "Options" from the menu. It stores its settings in ~/.config/rox.sourceforge.net.

A rox-filer feature is that if there is an executable file called AppRun in a directory rox-filer will first run AppRun before it opens the folder.

As an example of how this may be used, if you have ssh access to another computer (perhaps another computer on your local network) with ssh configured for passwordless logins and you have sshfs-3.7.2 installed you can use AppRun to mount the remote computer in a local folder using sshfs. For this example AppRun script to work the folder must have the same name as the hostname of the remote computer:

cat > /path/to/hostname/AppRun << "HERE_DOC"
#!/bin/bash

MOUNT_PATH="${0%/*}"
HOST=${MOUNT_PATH##*/}
export MOUNT_PATH HOST
sshfs -o nonempty ${HOST}:/ ${MOUNT_PATH}
rox -x ${MOUNT_PATH}
HERE_DOC

chmod 755 /path/to/hostname/AppRun

That works fine for mounting, but to unmount it the command fusermount -u ${MOUNTPOINT} is ran. You could set that as your default umount command in your rox preferences, but you would then be unable to unmount any normal mountpoints (that need umount). A script is needed that will unmount a Fuse mountpoint with fusermount -u ${MOUNTPOINT} and everything else with umount. As the root user:

cat > /usr/bin/myumount << "HERE_DOC" &&
#!/bin/bash
sync
if mount | grep "${@}" | grep -q fuse
then fusermount -u "${@}"
else umount "${@}"
fi
HERE_DOC

chmod 755 /usr/bin/myumount

Now, to make Rox use this simple script, open a Rox window, right click on it and choose Options from the menu. In the left hand list choose "Action windows" and then on the right hand side, where it says "Unmount command" change umount to myumount.

If you use a desktop environment like Gnome or KDE you may like to create a rox.desktop file so that rox-filer appears in the panel's menus. As the root user:

ln -s ../rox/.DirIcon /usr/share/pixmaps/rox.png &&
mkdir -p /usr/share/applications &&

cat > /usr/share/applications/rox.desktop << "HERE_DOC"
[Desktop Entry]
Encoding=UTF-8
Type=Application
Name=Rox
Comment=The Rox File Manager
Icon=rox
Exec=rox
Categories=GTK;Utility;Application;System;Core;
StartupNotify=true
Terminal=false
HERE_DOC

Contents

Installed Programs: rox
Installed Libraries: None
Installed Directories: /usr/share/rox

Short Descriptions

rox

is the rox file manager

Last updated on

rxvt-unicode-9.30

Introduction to rxvt-unicode

rxvt-unicode is a clone of the terminal emulator rxvt, an X Window System terminal emulator which includes support for XFT and Unicode.

This package is known to build and work properly using an LFS-11.1 platform.

Note

Please be aware that rxvt-unicode is affected by an issue in perl where the SIGFPE handler is set to SIG_IGN (i.e. the signal is ignored). If you are building an LFS system from within urxvt and running the testsuites, tests in bash and check which test raising this signal will fail.

Package Information

rxvt-unicode Dependencies

Required

libptytty-2.0 and a graphical environment

Optional

gdk-pixbuf-2.42.6 (for background images) and startup-notification-0.12

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/rxvt-unicode

Installation of rxvt-unicode

Install rxvt-unicode by running the following commands:

./configure --prefix=/usr --enable-everything &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--enable-everything: Add support for all non-multichoice options. Details about the different options can be found in the file README.configure.

--disable-xft: Remove support for Xft fonts.

--disable-perl: Disable the embedded Perl interpreter.

--disable-afterimage: Remove support for libAfterImage.

Configuring rxvt-unicode

The rxvt-unicode terminal emulator uses the resource class URxvt and the resource name urxvt. You can add X resource definitions to a user's ~/.Xresources or ~/.Xdefaults files or to the system-wide /etc/X11/app-defaults/URxvt file. The following example will load the matcher Perl extension (assuming Perl support wasn't disabled), which enables a left button click to open an underlined URL in the specified browser, sets a background and foreground color and loads an Xft font (as the root user):

cat >> /etc/X11/app-defaults/URxvt << "EOF"
! Use the specified colour as the windows background colour [default white]
URxvt*background: black

! Use the specified colour as the windows foreground colour [default black]
URxvt*foreground: yellow

! Select the fonts to be used. This is a comma separated list of font names
URxvt*font: xft:Monospace:pixelsize=18

! Comma-separated list(s) of perl extension scripts (default: "default")
URxvt*perl-ext: matcher

! Specifies the program to be started with a URL argument. Used by
URxvt*url-launcher: firefox

! When clicked with the mouse button specified in the "matcher.button" resource
! (default 2, or middle), the program specified in the "matcher.launcher"
! resource (default, the "url-launcher" resource, "sensible-browser") will be
! started with the matched text as first argument.
! Below, default modified to mouse left button.
URxvt*matcher.button:     1
EOF

In order to view the defined X resources, issue:

xrdb -query

In order to add the modifications of the new user configuration file, keeping previously X configurations (of course, unless you are changing any on previously define), issue:

xrdb -merge ~/.Xresources

The rxvt-unicode application can also run in a daemon mode, which makes it possible to open multiple terminal windows within the same process. The urxvtc client then connects to the urxvtd daemon and requests a new terminal window. Use this option with caution. If the daemon crashes, all the running processes in the terminal windows are terminated.

You can start the urxvtd daemon in the system or personal startup X session script (e.g., ~/.xinitrc) by adding the following lines near the top of the script:

# Start the urxvtd daemon
urxvtd -q -f -o &

For more information, examine the urxvt, urxvtd, urxvtc, and urxvtperl man pages.

If you use a Desktop Environment, a menu entry can be included, issuing, as the root user:

cat > /usr/share/applications/urxvt.desktop << "EOF" &&
[Desktop Entry]
Encoding=UTF-8
Name=Rxvt-Unicode Terminal
Comment=Use the command line
GenericName=Terminal
Exec=urxvt
Terminal=false
Type=Application
Icon=utilities-terminal
Categories=GTK;Utility;TerminalEmulator;
#StartupNotify=true
Keywords=console;command line;execute;
EOF

update-desktop-database -q

For that, you need desktop-file-utils-0.26 and at least one of gnome-icon-theme-3.12.0, oxygen-icons5-5.91.0 and lxde-icon-theme-0.5.1. Uncomment the line with StartupNotify=true if startup-notification-0.12 is installed.

Contents

Installed Programs: urxvt, urxvtd, and urxvtc
Installed Libraries: Many Perl extensions located under /usr/lib/urxvt/perl
Installed Directory: /usr/lib/urxvt

Short Descriptions

urxvt

is a terminal emulator for the X Window System

urxvtd

is the urxvt terminal daemon

urxvtc

controls the urxvtd daemon

Last updated on

Thunderbird-91.6.1

Introduction to Thunderbird

Thunderbird is a stand-alone mail/news client based on the Mozilla codebase. It uses the Gecko rendering engine to enable it to display and compose HTML emails.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Thunderbird Dependencies

Required

Autoconf-2.13, Cbindgen-0.20.0, dbus-glib-0.112, both GTK+-3.24.31 and GTK+-2.24.33, LLVM-13.0.1 including clang, nodejs-16.14.0, PulseAudio-15.0 (or alsa-lib-1.2.6.1 if you edit the mozconfig; although it is now deprecated by mozilla), Python-3.10.2 (rebuilt with the sqlite module), startup-notification-0.12, Zip-3.0, UnZip-6.0, and yasm-1.3.0

Recommended

Note

If you don't install recommended dependencies, then internal copies of those packages will be used. They might be tested to work, but they can be out of date or contain security holes.

Optional

Cyrus SASL-2.1.27, Doxygen-1.9.3, GConf-3.2.6, Wget-1.21.2, Wireless Tools-29, and watchman

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Thunderbird

Installation of Thunderbird

Note

The build process for Thunderbird can use 8GB+ of RAM when linking. Make sure that you have adequate swap or RAM before continuing.

The configuration of Thunderbird is accomplished by creating a mozconfig file containing the desired configuration options. A default mozconfig is created below. To see the entire list of available configuration options (and a brief description of each), issue mozilla/configure --help. Create the file with the following command:

cat > mozconfig << "EOF"
# If you have a multicore machine, all cores will be used.

# If you have installed wireless-tools comment out this line:
ac_add_options --disable-necko-wifi

# Uncomment the following option if you have not installed PulseAudio
#ac_add_options --disable-pulseaudio
# and uncomment this if you installed alsa-lib instead of PulseAudio
#ac_add_options --enable-alsa

# Comment out following options if you have not installed
# recommended dependencies:
ac_add_options --with-system-libevent
ac_add_options --with-system-nspr
ac_add_options --with-system-nss
ac_add_options --with-system-icu

# The elf-hack causes failed installs on some machines.
# It is supposed to improve startup time and it shrinks libxul.so
# by a few MB - comment this if you know your machine is not affected.
ac_add_options --disable-elf-hack

# The BLFS editors recommend not changing anything below this line:
ac_add_options --prefix=/usr
ac_add_options --enable-application=comm/mail

ac_add_options --disable-crashreporter
ac_add_options --disable-updater
ac_add_options --disable-debug
ac_add_options --disable-debug-symbols
ac_add_options --disable-tests

ac_add_options --enable-optimize=-O2
ac_add_options --enable-linker=gold
ac_add_options --enable-strip
ac_add_options --enable-install-strip

ac_add_options --enable-official-branding

ac_add_options --enable-system-ffi
ac_add_options --enable-system-pixman

ac_add_options --with-system-jpeg
ac_add_options --with-system-png
ac_add_options --with-system-zlib
EOF

If building on a 32 bit machine, the following sed works around an issue with an incompatible double type in one header file:

case "$(uname -m)" in
    i?86) sed -e '/typedef[ ]*double/s/double/long double/' \
              -i modules/fdlibm/src/math_private.h ;;
esac

Now invoke the Python mach script to compile Thunderbird:

Note

If you are compiling this package in chroot you must do two things. First, as the root user, ensure that /dev/shm is mounted. If you do not do this, the Python configury will fail with a traceback report referencing /usr/lib/pythonN.N/multiprocessing/synchronize.py. Run:

mountpoint -q /dev/shm || mount -t tmpfs devshm /dev/shm

Second, either as the root user export the $SHELL environment variable using export SHELL=/bin/sh or else prepend SHELL=/bin/sh when running the ./mach commands.

export CC=gcc CXX=g++ &&
export MACH_USE_SYSTEM_PYTHON=1 &&
./mach create-mach-environment &&
./mach configure      &&
./mach build

This package does not come with a test suite.

Install Thunderbird by running the following commands as the root user:

MACH_USE_SYSTEM_PYTHON=1 ./mach install

Empty the environment variables which were set above:

unset CC CXX MACH_USE_SYSTEM_PYTHON

Command Explanations

CC=gcc CXX=g++ ./mach configure: Thunderbird now uses this python3 script to run the configuration, build and install. Forcing GCC causes the build to come out smaller and run faster.

MACH_USE_SYSTEM_PYTHON=1: Use the system python to create a virtual environment for mach without downloading any python wheels.

./mach build --verbose: Use this alternative if you need details of which files are being compiled, together with any C or C++ flags being used.

Configuring Thunderbird

Configuration Information

If your Window or Desktop Manager does not allow you to configure a default browser, you can add a configuration parameter to Thunderbird so that a browser will start when you click on an Internet/intranet/local URL. The procedure to check or modify any of the configuration parameters is quite simple and the instructions here can be used to view or modify any of the parameters.

First, open the configuration dialog by opening the Edit drop-down menu. Choose Preferences and then scroll down to the bottom of the page. Then, click the Config Editor button. Click on the I accept the risk! button. This will display a list of the configuration preferences and information related to each one. You can use the Filter: bar to enter search criteria and narrow down the listed items. Changing a preference can be done using two methods. One, if the preference has a boolean value (True/False), simply double-click on the preference to toggle the value and two, for other preferences simply right-click on the desired line, choose Modify from the menu and change the value. Creating new preference items is accomplished in the same way, except choose New from the menu and provide the desired data into the fields when prompted.

The configuration preference item you need to check so that Thunderbird uses a specified browser is the network.protocol-handler.app.http which should be set to the path of the desired browser, e.g. /usr/bin/firefox.

Tip

There is a multitude of configuration parameters you can tweak to customize Thunderbird. A very extensive, but not so up-to-date list of these parameters can be found at http://preferential.mozdev.org/preferences.html.

If you use a desktop environment such as GNOME or KDE, a desktop file thunderbird.desktop may be created, in order to include a Thunderbird entry in the menu. Run the following commands as the root user:

mkdir -pv /usr/share/{applications,pixmaps} &&

cat > /usr/share/applications/thunderbird.desktop << "EOF" &&
[Desktop Entry]
Name=Thunderbird Mail
Comment=Send and receive mail with Thunderbird
GenericName=Mail Client
Exec=thunderbird %u
Terminal=false
Type=Application
Icon=thunderbird
Categories=Network;Email;
MimeType=text/html;text/xml;application/xhtml+xml;application/xml;application/rss+xml;x-scheme-handler/mailto;
StartupNotify=true
EOF

ln -sfv /usr/lib/thunderbird/chrome/icons/default/default256.png \
        /usr/share/pixmaps/thunderbird.png

Contents

Installed Program: thunderbird
Installed Libraries: libldap60.so, libldif60.so, liblgpllibs.so, libmozgtk.so, libmozsandbox.so, libmozsqlite3.so, libmozwayland.so, libprldap60.so, librnp.so, and libxul.so, all in the /usr/lib/thunderbird directory
Installed Directory: /usr/lib/thunderbird

Short Descriptions

thunderbird

is Mozilla's email and newsgroup client

Last updated on

Tigervnc-1.12.0

Introduction to Tigervnc

Tigervnc is an advanced VNC (Virtual Network Computing) implementation. It allows creation of an Xorg server not tied to a physical console and also provides a client for viewing of the remote graphical desktop.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Note

The version of Xorg may eventually be a few versions out of date, but is required for the customizations needed for this package.

Tigervnc Dependencies

Required

CMake-3.22.2, FLTK-1.3.8, GnuTLS-3.7.3, libgcrypt-1.10.0, libjpeg-turbo-2.1.2, Pixman-0.40.0, Xorg Applications, and Xorg Legacy Fonts

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/tigervnc

Installation of Tigervnc

First, make adjustments to the configuration files to make them compatible with LFS systems:

patch -Np1 -i ../tigervnc-1.12.0-configuration_fixes-1.patch

Install tigervnc by running the following commands:

# Put code in place
mkdir -p unix/xserver &&
tar -xf ../xorg-server-1.20.7.tar.bz2 \
    --strip-components=1              \
    -C unix/xserver                   &&
( cd unix/xserver &&
  patch -Np1 -i ../xserver120.patch ) &&

# Build viewer
cmake -G "Unix Makefiles"         \
      -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_BUILD_TYPE=Release  \
      -DINSTALL_SYSTEMD_UNITS=OFF \
      -Wno-dev . &&
make &&

# Build server
pushd unix/xserver &&
  autoreconf -fiv  &&

  CPPFLAGS="-I/usr/include/drm"       \
  ./configure $XORG_CONFIG            \
      --disable-xwayland    --disable-dri        --disable-dmx         \
      --disable-xorg        --disable-xnest      --disable-xvfb        \
      --disable-xwin        --disable-xephyr     --disable-kdrive      \
      --disable-devel-docs  --disable-config-hal --disable-config-udev \
      --disable-unit-tests  --disable-selective-werror                 \
      --disable-static      --enable-dri3                              \
      --without-dtrace      --enable-dri2        --enable-glx          \
      --with-pic &&
  make  &&
popd

This package does not come with a test suite.

Now, as the root user:

#Install viewer
make install &&

#Install server
( cd unix/xserver/hw/vnc && make install ) &&

[ -e /usr/bin/Xvnc ] || ln -svf $XORG_PREFIX/bin/Xvnc /usr/bin/Xvnc

Finally, modify the PAM file to be compatible with elogind:

sed -i 's/pam_systemd.so/pam_elogind.so/' /etc/pam.d/tigervnc

Command Explanations

tar -xf .. xorg-server...: This command extracts the standard Xorg package into the tree in a location needed for modification.

--disable ...: Most options that are usually needed for the standard Xorg server are not needed for the Xvnc instance being built.

[ -e /usr/bin/Xvnc ] || ln ... Xvnc: If the Xvnc server is not installed in the /usr/bin directory, then create a link so the vncserver script can find it.

Configuring Tigervnc

The default installation of this package makes some changes in the way it is used. The vncserver perl script is placed in /usr/libexec and the server is designed to be run via a systemd style .service file or the vncsession script as the root user. The man page for vncserver is placed in section 8 of the man pages. The new procedures require a display manager to be installed.

To restore the previous behavior, install the additional downloaded files as the root user:

install -m755 --owner=root ../vncserver /usr/bin &&
cp ../vncserver.1 /usr/share/man/man1

Using the previous procedures, the user specific configuration files of vncserver reside in the .vnc directory in the user's home directory. The xstartup file in that directory is a script specifying what commands to run when a VNC desktop is started. If no xstartup file exists, vncserver will try to start an xterm in a twm session. An example xstartup would be:

#!/bin/sh
[ -x /etc/vnc/xstartup ] && exec /etc/vnc/xstartup
[ -r $HOME/.Xresources ] && xrdb $HOME/.Xresources
startlxde &

The xstartup file must be executable for the commands in it to be executed, so run chmod a+x ~/.vnc/xstartup.

Set up the vnc passwd with vncpasswd. The server can then be started with the vncserver command. See the man pages in section 1 for the vncserver for the server system and vncviewer for the remote system.

Contents

Installed Programs: Xvnc, vncconfig, vncpasswd, vncserver, vncviewer, and x0vncserver
Installed Libraries: libvnc.so
Installed Directories: /usr/share/doc/tigervnc-1.12.0

Short Descriptions

Xvnc

is a X VNC (Virtual Network Computing) server. It is based on a standard X server, but it has a virtual screen rather than a physical one

vncconfig

is a program to configure and control a VNC server

vncpasswd

allows you to set the password used to access VNC desktops

vncserver

is a perl script used to start or stop a VNC server

vncviewer

is a client used to connect to VNC desktops

x0vncserver

is a program to make an X display on a physical terminal accessible via TigerVNC or compatible viewers

Last updated on

Transmission-3.00

Introduction to Transmission

Transmission is a cross-platform, open source BitTorrent client. This is useful for downloading large files (such as Linux ISOs) and reduces the need for the distributors to provide server bandwidth.

Note

The download speed of the client defaults to 50 KB/s which is quite slow. It can be raised, but even on a fast internet connection, the highest speeds seen were about 500 KB/s. For those that have internet capabilities faster than about 1 MB/s, direct downloads (if available) will be much faster.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Transmission Dependencies

Required

cURL-7.81.0, and libevent-2.1.12

Recommended (to build a GUI)
Optional

Doxygen-1.9.3 and GDB-11.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/transmission

Installation of Transmission

Install Transmission by running the following commands:

./configure --prefix=/usr --enable-cli &&
make

Compile the Qt GUI with the following commands:

pushd qt        &&
  qmake qtr.pro &&
  make          &&
popd

This package does not come with a test suite.

Now, as the root user:

make install

If you compiled the Qt GUI, install it by running the following commands as the root user:

make INSTALL_ROOT=/usr -C qt install &&

install -m644 qt/transmission-qt.desktop /usr/share/applications/transmission-qt.desktop &&
install -m644 qt/icons/transmission.png  /usr/share/pixmaps/transmission-qt.png

Command Explanations

--enable-cli: This switch enables building the cli client.

--without-gtk: This switch disables building of the GTK+ interface if GTK+ is present on the system (useful for Qt5 or cli only builds).

Contents

Installed Programs: transmission-cli, transmission-create, transmission-daemon, transmission-edit, transmission-gtk, transmission-qt, transmission-remote and transmission-show
Installed Libraries: None
Installed Directory: /usr/share/transmission

Short Descriptions

transmission-cli

is a lightweight, command-line BitTorrent client with scripting capabilities

transmission-create

is a command line tool used to create .torrent files

transmission-daemon

is a daemon-based Transmission session that can be controlled via RPC commands from transmission's web interface or transmission-remote

transmission-edit

is a command-line utility to modify .torrent files' announce URLs

transmission-gtk

is a GTK+ bittorrent client

transmission-qt

is a Qt bittorrent client

transmission-remote

is a remote control utility for transmission-daemon and transmission

transmission-show

is a command line tool to display bittorrent .torrent file metadata

Last updated on

xarchiver-0.5.4.17

Introduction to xarchiver

XArchiver is a GTK+ archive manager with support for tar, xz, bzip2, gzip, zip, 7z, rar, lzo and many other archive formats.

This package is known to build and work properly using an LFS-11.1 platform.

Note

xarchiver is only a command line or graphical interface to archiving utilities such as tar and zip.

Package Information

xarchiver Dependencies

Required

GTK+-2.24.33 or GTK+-3.24.31

Optional (Runtime)

cpio-2.13, LZO-2.10, p7zip-17.04, UnRar-6.1.4, UnZip-6.0, and Zip-3.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xarchiver

Installation of xarchiver

Install xarchiver by running the following commands:

./configure  --prefix=/usr               \
             --libexecdir=/usr/lib/xfce4 \
             --docdir=/usr/share/doc/xarchiver-0.5.4.17 &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Note

This package installs icon files into the /usr/share/icons/hicolor hierarchy and desktop files into the /usr/share/applications hierarchy. You can improve system performance and memory usage by updating /usr/share/icons/hicolor/index.theme and /usr/share/applications/mimeinfo.cache. To perform the update you must have GTK+-2.24.33 or GTK+-3.24.31 installed (for the icon cache) and desktop-file-utils-0.26 (for the desktop cache) and issue the following commands as the root user:

gtk-update-icon-cache -qtf /usr/share/icons/hicolor &&
update-desktop-database -q

Command Explanations

--libexecdir=/usr/lib/xfce4: This switch fixes the location for the thunar-archive-plugin, so it will work if thunar-4.16.10 is installed.

--disable-gtk3: This switch allows building against GTK+2 or use --disable-gtk2 to force building against GTK+3 when GTK+2 is installed, too.

Contents

Installed Program: xarchiver
Installed Libraries: None
Installed Directories: /usr/lib/xfce4/thunar-archive-plugin, /usr/share/doc/xarchiver-0.5.4.17, and /usr/share/pixmaps/xarchiver

Short Descriptions

xarchiver

is a GTK+ archive manager

Last updated on

xdg-utils-1.1.3

Introduction to xdg-utils

xdg-utils is a a set of command line tools that assist applications with a variety of desktop integration tasks. It is required for Linux Standards Base (LSB) conformance.

Warning

A security vulnerability exists in all versions of xdg-utils from version 1.1.0rc1 when handling mailto: URIs. An attacker could potentially send a victim a URI that automatically attaches a sensitive file to a new email. If a victim user does not notice that an attachment was added and sends the email, this could result in sensitive information disclosure.

To mitigate this flaw, either do not use mailto links at all, or always double-check in the user interface that there are no unwanted attachments before sending emails, especially when the email originates from clicking on a mailto link.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

xdg-utils Dependencies

Required

xmlto-0.0.28 with one of Lynx-2.8.9rel.1, Links-2.25, or W3m

Required (runtime)

Xorg Applications

Optional (runtime)

dbus-1.12.20

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xdg-utils

Installation of xdg-utils

Compile xdg-utils with the following commands:

./configure --prefix=/usr --mandir=/usr/share/man &&
make

Caution

The tests for the scripts must be made from an X-Window based session. There are several run-time requirements to run the tests including a browser and an MTA. Running the tests as root user is not recommended.

To run the tests, issue: make -k test.

Now install it as the root user:

make install

Contents

Installed Programs: xdg-desktop-menu, xdg-desktop-icon, xdg-mime, xdg-icon-resource, xdg-open, xdg-email, xdg-screensaver, xdg-settings
Installed Libraries: None
Installed Directories: None

Short Descriptions

xdg-desktop-menu

is a command line tool for (un)installing desktop menu items

xdg-desktop-icon

is a command line tool for (un)installing icons to the desktop

xdg-mime

is a command line tool for querying information about file type handling and adding descriptions for new file types

xdg-icon-resource

is a command line tool for (un)installing icon resources

xdg-open

opens a file or URL in the user's preferred application

xdg-email

opens the user's preferred e-mail composer in order to send a mail message

xdg-screensaver

is a command line tool for controlling the screensaver

xdg-settings

is a command line tool for managing various settings from the desktop environment

Last updated on

XScreenSaver-6.02

Introduction to XScreenSaver

The XScreenSaver package is a modular screen saver and locker for the X Window System. It is highly customizable and allows the use of any program that can draw on the root window as a display mode. The purpose of XScreenSaver is to display pretty pictures on your screen when it is not in use, in keeping with the philosophy that unattended monitors should always be doing something interesting, just like they do in the movies. However, XScreenSaver can also be used as a screen locker, to prevent others from using your terminal while you are away.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

XScreenSaver Dependencies

Required

gdk-pixbuf-xlib-2.40.2, libglade-2.6.4, and Xorg Applications

Recommended
Optional

GDM-41.3, Linux-PAM-1.5.2, MIT Kerberos V5-1.19.2, and GLE

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xscreensaver

Installation of XScreenSaver

Change a harcoded library name, which prevents using the settings found by configure:

sed -i 's/-lsystemd/-lelogind/' driver/Makefile.in

Install XScreenSaver by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--with-setuid-hacks: This switch allows some demos to be installed setuid root which is needed in order to ping other hosts.

Configuring XScreenSaver

Config Files

/etc/X11/app-defaults/XScreenSaver and ~/.xscreensaver

Linux PAM Configuration

If XScreenSaver has been built with Linux PAM support, you need to create a PAM configuration file, to get it working correctly with BLFS.

Issue the following commands as the root user to create the configuration file for Linux PAM:

cat > /etc/pam.d/xscreensaver << "EOF"
# Begin /etc/pam.d/xscreensaver

auth    include system-auth
account include system-account

# End /etc/pam.d/xscreensaver
EOF

Contents

Installed Programs: xscreensaver, xscreensaver-command, xscreensaver-demo, and xscreensaver-settings
Installed Libraries: None
Installed Directories: /usr/libexec/xscreensaver and /usr/share/xscreensaver

Short Descriptions

xscreensaver

is a screen saver and locker daemon

xscreensaver-command

controls a running xscreensaver process by sending it client messages

xscreensaver-demo

is a symlink to xscreensaver-settings

xscreensaver-settings

is a graphical front-end for setting the parameters used by the background xscreensaver daemon

Last updated on

Part XII. Multimedia

Chapter 42. Multimedia Libraries and Drivers

Many multimedia programs require libraries and/or drivers in order to function properly. The packages in this section fall into this category. Generally you only need to install these if you are installing a program which has the library listed as either a requirement, or as an option to enable it to support certain functionality.

ALSA-1.2.6

The Linux kernel now provides ALSA support by default. However, applications need to interface to that capability. The following six sections of the book deal with the separate components of ALSA: the libraries, the plugins, the utilities, the tools, the firmware and the OSS compatibility libraries.

Last updated on

alsa-lib-1.2.6.1

Introduction to ALSA Library

The ALSA Library package contains the ALSA library used by programs (including ALSA Utilities) requiring access to the ALSA sound interface.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

ALSA Library Dependencies

Optional

Doxygen-1.9.3, Python-2.7.18, and alsa-ucm-conf

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/alsa-lib

Kernel Configuration

If needed, enable the following options in the kernel configuration and recompile the kernel:

Device Drivers --->
  <*/M> Sound card support --->                  [CONFIG_SOUND]
    <*/M> Advanced Linux Sound Architecture ---> [CONFIG_SND]
            Select settings and drivers appropriate for your hardware.

In the Device Drivers ⇒ Sound card support ⇒ Advanced Linux Sound Architecture section of the kernel configuration, select the settings and drivers appropriate for your hardware. Ensure that the deprecated Device Drivers ⇒ Sound card support ⇒ Open Sound System is not selected. If necessary, recompile and install your new kernel.

Installation of ALSA Library

Install ALSA Library by running the following commands:

./configure &&
make

If you have Doxygen installed and you wish to build the library API documentation, run the following commands from the top-level directory of the source tree:

make doc

To test the results, issue: make check.

Now, as the root user:

make install

To install the API documentation, run the following command as the root user:

install -v -d -m755 /usr/share/doc/alsa-lib-1.2.6.1/html/search &&
install -v -m644 doc/doxygen/html/*.* \
                /usr/share/doc/alsa-lib-1.2.6.1/html &&
install -v -m644 doc/doxygen/html/search/* \
                /usr/share/doc/alsa-lib-1.2.6.1/html/search

Configuring ALSA Library

Config Files

~/.asoundrc and /etc/asound.conf

Configuration Information

The default alsa.conf is adequate for most installations. For extra functionality and/or advanced control of your sound device, you may need to create additional configuration files. For information on the available configuration parameters, visit https://www.alsa-project.org/main/index.php/Asoundrc.

Contents

Installed Program: aserver
Installed Library: libasound.so and libatopology.so
Installed Directories: /usr/include/alsa, /usr/share/alsa and /usr/share/doc/alsa-lib-1.2.6.1

Short Descriptions

aserver

is the ALSA server

libasound.so

contains the ALSA API functions

libatopology.so

contains API functions for the ALSA topologies

Last updated on

alsa-plugins-1.2.6

Introduction to ALSA Plugins

The ALSA Plugins package contains plugins for various audio libraries and sound servers.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

ALSA Plugins Dependencies

Required

alsa-lib-1.2.6.1

Optional

FFmpeg-4.4.1, libsamplerate-0.2.2, PulseAudio-15.0, Speex-1.2.0, JACK, libavtp, and maemo

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/alsa-plugins

Installation of ALSA Plugins

Install ALSA Plugins by running the following commands:

./configure --sysconfdir=/etc &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: Numerous libasound_module_<module>.so modules including conf_pulse, ctl_arcam_av, ctl_oss, ctl_pulse, pcm_a52, pcm_jack, pcm_oss, pcm_pulse, pcm_speex, pcm_upmix, pcm_usb_stream, pcm_vdownmix, rate_lavrate*, rate_samplerate*, and rate_speexrate*
Installed Directories: /usr/lib/alsa-lib

Short Descriptions

libasound_module_pcm_oss.so

Allows native ALSA applications to run on OSS

libasound_module_pcm_upmix.so

Allows upmixing sound to 4 or 6 channels

libasound_module_pcm_vdownmix.so

Allows downmixing sound from 4-6 channels to 2 channel stereo output

libasound_module_pcm_jack.so

Allows native ALSA applications to work with jackd

libasound_module_pcm_pulse.so

Allows native ALSA applications to access a PulseAudio sound daemon

libasound_module_pcm_a52.so

Converts S16 linear sound format to A52 compressed format and sends it to an SPDIF output

libasound_module_rate_samplerate.so

Provides an external rate converter through libsamplerate

Last updated on

alsa-utils-1.2.6

Introduction to ALSA Utilities

The ALSA Utilities package contains various utilities which are useful for controlling your sound card.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

ALSA Utilities Dependencies

Required

alsa-lib-1.2.6.1

Optional

docutils-0.18.1, fftw-3.3.10, libsamplerate-0.2.2, xmlto-0.0.28, and Dialog

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/alsa-utils

Installation of ALSA Utilities

Install ALSA Utilities by running the following commands:

./configure --disable-alsaconf \
            --disable-bat   \
            --disable-xmlto \
            --with-curses=ncursesw &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-alsaconf: This switch disables building the alsaconf configuration tool which is incompatible with Udev.

--disable-xmlto: Omit this switch if you have installed xmlto-0.0.28 and wish to regenerate the man pages.

--disable-bat: Omit this switch if you have installed fftw-3.3.10 and wish to install the Basic Audio Tester (BAT).

--with-curses=ncursesw: This switch forces the use of wide-character ncurses libraries.

Configuring ALSA Utilities

Config Files

/var/lib/alsa/asound.state

Configuration Information

Note that all channels of your sound card are muted by default. You can use the alsamixer program to change this. Use speaker-test to check that your settings have been applied correctly. You should hear pink noise on your speakers.

The alsactl program is normally run from a standard udev rule. The first time it is run, it will complain that there is no state in /var/lib/alsa/asound.state. You can prevent this by running the following command as the root user:

alsactl -L store

The volume settings should be restored from the saved state by Udev when the device is detected (during boot or when plugged in for USB devices).

All sound devices are not accessible for any user except root and members of the audio group. Add any users that might use the sound devices to that group:

usermod -a -G audio <username>

Note

You may need to log out and back in again to refresh your group memberships. 'su <username>' should work as well.

Boot Script

To automatically store and restore volume settings (if the udev rule doesn't work for you) when the system is rebooted, install the /etc/rc.d/init.d/alsa boot script from the blfs-bootscripts-20210826 package.

make install-alsa

Contents

Installed Programs: aconnect, alsactl, alsaloop, alsamixer, alsatplg, alsaucm, alsa-info.sh, amidi, amixer, aplay, aplaymidi, arecord (symlink), arecordmidi, aseqdump, aseqnet, axfer, iecset, and speaker-test
Installed Libraries: None
Installed Directories: /usr/share/sounds/alsa and /var/lib/alsa

Short Descriptions

aconnect

is a utility for connecting and disconnecting two existing ports in the ALSA sequencer system

alsactl

is used to control advanced settings for ALSA sound card drivers. Use this if alsamixer cannot utilize all of your sound card's features

alsaloop

allows creation of a PCM loopback between a PCM capture device and a PCM playback device

alsamixer

is an Ncurses based mixer program for use with the ALSA sound card drivers

alsatplg

is a utility used to compile topology configuration files into binary files for kernel drivers

alsaucm

allows applications to access the hardware in an abstracted manner

amidi

is used to read from and write to ALSA RawMIDI ports

amixer

allows command-line control of the mixers for the ALSA sound card drivers

aplay

is a command-line soundfile player for the ALSA sound card drivers

aplaymidi

is a command-line utility that plays the specified MIDI file(s) to one or more ALSA sequencer ports

arecord

is a command-line soundfile recorder for the ALSA sound card drivers

arecordmidi

is a command-line utility that records a standard MIDI file from one or more ALSA sequencer ports

aseqdump

is a command-line utility that prints the sequencer events it receives as text

aseqnet

is an ALSA sequencer client which sends and receives event packets over a network

axfer

is a command-line recorder and player used to transfer audio frames between sound devices and files

iecset

is a small utility to set or dump the IEC958 (or so-called S/PDIF) status bits of the specified sound card via the ALSA control API

speaker-test

is a command-line speaker test tone generator for ALSA

Last updated on

alsa-tools-1.2.5

Introduction to ALSA Tools

The ALSA Tools package contains advanced tools for certain sound cards.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

ALSA Tools Dependencies

Required

alsa-lib-1.2.6.1

Optional

GTK+-2.24.33 (to build echomixer, envy24control and rmedigicontrol), GTK+-3.24.31 (to build hdajackretask) and FLTK-1.3.8 (to build hdspconf and hdspmixer)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/alsa-tools

Installation of ALSA Tools

Note

When installing multiple packages in a script, the installation needs to be done as the root user. There are three general options that can be used to do this:

  1. Run the entire script as the root user (not recommended).

  2. Use the sudo command from the Sudo-1.9.9 package.

  3. Use su -c "command arguments" (quotes required) which will ask for the root password for every iteration of the loop.

One way to handle this situation is to create a short bash function that automatically selects the appropriate method. Once the command is set in the environment, it does not need to be set again.

as_root()
{
  if   [ $EUID = 0 ];        then $*
  elif [ -x /usr/bin/sudo ]; then sudo $*
  else                            su -c \\"$*\\"
  fi
}

export -f as_root

First, start a subshell that will exit on error:

bash -e

Now, remove a tool that needs Qt2 or 3 and two unneed files (for the BLFS instructions below):

rm -rf qlo10k1 Makefile gitcompile

The ALSA Tools package is only needed by those with advanced requirements for their sound card. The tools can be built all together at once, but if only a subset is needed, you need to cd into the directory of each tool you wish to compile and run the commands. Here, we present instructions to build all tools.

Install all ALSA Tools by running the following commands:

for tool in *
do
  case $tool in
    seq )
      tool_dir=seq/sbiload
    ;;
    * )
      tool_dir=$tool
    ;;
  esac

  pushd $tool_dir
    ./configure --prefix=/usr
    make
    as_root make install
    as_root /sbin/ldconfig
  popd

done
unset tool tool_dir

Finally, exit the shell that was started earlier:

exit

Contents

Installed Programs: as10k1, cspctl, dl10k1, echomixer, envy24control, hda-verb, hdajackretask, hdajacksensetest, hdspconf, hdsploader, hdspmixer, hwmixvolume, init_audigy, init_audigy_eq10, init_live, lo10k1, ld10k1, ld10k1d, mixartloader, pcxhrloader, rmedigicontrol, sbiload, sscape_ctl, us428control, usx2yloader, and vxloader
Installed Library: liblo10k1.so
Installed Directories: /etc/hotplug, /usr/include/lo10k1, /usr/share/ld10k1, and /usr/share/sounds

Short Descriptions

as10k1

is an assembler for the emu10k1 DSP chip present in the Creative SB Live, PCI 512, and emu APS sound cards. It is used to make audio effects such as a flanger, chorus or reverb

cspctl

is an SB16/AWE32 Creative Signal Processor (ASP/CSP) control program

echomixer

is the Linux equivalent of the Echoaudio console application from Echoaudio. It is a tool to control all the features of any Echoaudio soundcard. This includes clock sources, input and output gains, mixers, etc

envy24control

is a control tool for Envy24 (ice1712) based sound cards

hdajackretask

is a GUI to make it easy to retask your jacks - e g, turn your Mic jack into an extra Headphone, or why not make them both line outs and connect them to your surround receiver

hda-verb

is a small program to send HD-audio commands to the given ALSA hwdep device on the hd-audio interface

hdspconf

is a GUI to control the Hammerfall HDSP Alsa Settings. Up to four hdsp cards are supported

hdsploader

is used to load the firmware required by the Hammerfall HDSP sound cards

hdspmixer

is the Linux equivalent of the Totalmix application from RME. It is a tool to control the advanced routing features of the RME Hammerfall DSP soundcard series

hwmixvolume

allows you to control the volume of individual streams on sound cards that use hardware mixing

init_audigy*

are tools used to initialize Creative Sound Blaster Audigy-series cards

init_live

is a tool used to initialize Creative Sound Blaster Live cards

ld10k1

is the server of a EMU10K{1,2} patch loader for ALSA

lo10k1

is the client of a EMU10K{1,2} patch loader for ALSA

dl10k1

loads config dumps generated by lo10k1 and ld10k1

ld10k1d

is an init script for the ld10k1 patch loader

mixartloader

is a helper program to load the firmware binaries onto the Digigram's miXart board sound drivers. The following modules require this program: snd-mixart. These drivers don't work properly at all until the certain firmwares are loaded, i.e. no PCM nor mixer devices will appear

pcxhrloader

is a helper program to load the firmware binaries onto Digigram's pcxhr compatible board sound drivers. The following modules require this program: snd-pcxhr. These drivers don't work properly at all until certain firmwares are loaded, i.e. no PCM nor mixer devices will appear

rmedigicontrol

is a control tool for RME Digi32 and RME Digi96 sound cards. It provides a graphical frontend for all the sound card controls and switches

sbiload

is an OPL2/3 FM instrument loader for the ALSA sequencer

sscape_ctl

is an ALSA SoundScape control utility

us428control

is a Tascam US-428 control program

usx2yloader

is a helper program to load the 2nd Phase firmware binaries onto the Tascam USX2Y USB sound cards. It has proven to work so far for the US122, US224 and US428. The snd-usb-usx2y module requires this program

vxloader

is a helper program to load the firmware binaries onto the Digigram's VX-board sound drivers. The following modules require this program: snd-vx222, snd-vxpocket, snd-vxp440. These drivers don't work properly at all until the certain firmwares are loaded, i.e. no PCM nor mixer devices will appear

Last updated on

alsa-firmware-1.2.4

Introduction to ALSA Firmware

The ALSA Firmware package contains firmware for certain sound cards.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

ALSA Firmware Dependencies

Required

alsa-tools-1.2.5

Optional

AS31 (for rebuilding the firmware from source)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/alsa-firmware

Installation of ALSA Firmware

The ALSA Firmware package is only needed by those with advanced requirements for their sound card. See the README for configure options.

Install ALSA Firmware by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: None
Installed Directories: Several directories in /lib/firmware and /usr/share/alsa/firmware

Last updated on

alsa-oss-1.1.8

Introduction to alsa-oss

The alsa-oss package contains the alsa-oss compatibility library. This is used by programs which wish to use the alsa-oss sound interface.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

ALSA OSS Dependencies

Required

alsa-lib-1.2.6.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/alsa-oss

Installation of ALSA OSS

Install ALSA OSS by running the following commands:

./configure --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Program: aoss
Installed Libraries: libalsatoss.so, libaoss.so, and libossredir.a
Installed Directories: None

Short Descriptions

aoss

is a simple wrapper script which facilitates the use of the ALSA oss compatibility library. It just sets the appropriate LD_PRELOAD path and then runs the command

Last updated on

AudioFile-0.3.6

Introduction to AudioFile

The AudioFile package contains the audio file libraries and two sound file support programs useful to support basic sound file formats.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

AudioFile Dependencies

Required

alsa-lib-1.2.6.1

Recommended
Optional

asciidoc-10.1.1 and Valgrind-3.18.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/audiofile

Installation of AudioFile

Install AudioFile by running the following commands:

patch -Np1 -i ../audiofile-0.3.6-consolidated_patches-1.patch &&
autoreconf -fiv                             &&

./configure --prefix=/usr --disable-static  &&

make

Now, as the root user:

make install

To test the results, issue: make check. Note that the tests will fail if the --disable-static option is used and tests are executed before make install. You have three options:

(a) configure without --disable-static, run the tests, but do not install, then start a fresh build using --disable-static just for installing the package.

(b) configure with --disable-static, but only run the tests after the package is installed.

(c) configure with --disable-static, but only run the tests after a DESTDIR install.

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: sfconvert and sfinfo
Installed Libraries: libaudiofile.so
Installed Directories: None

Short Descriptions

sfinfo

displays the sound file format, audio encoding, sampling rate and duration for audio formats supported by this library

sfconvert

converts sound file formats where the original format and destination format are supported by this library

libaudiofile.so

contains functions used by programs to support AIFF, AIFF-compressed, Sun/NeXT, WAV and BIC audio formats

Last updated on

FAAC-1_30

Introduction to FAAC

FAAC is an encoder for a lossy sound compression scheme specified in MPEG-2 Part 7 and MPEG-4 Part 3 standards and known as Advanced Audio Coding (AAC). This encoder is useful for producing files that can be played back on iPod. Moreover, iPod does not understand other sound compression schemes in video files.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/faac

Installation of FAAC

Install FAAC by running the following commands:

./bootstrap                                &&
./configure --prefix=/usr --disable-static &&
make

This package does not come with a test suite. However, basic functionality can be tested by encoding a sample WAV file (the sample file is installed by the alsa-utils-1.2.6 package:

./frontend/faac -o Front_Left.mp4 /usr/share/sounds/alsa/Front_Left.wav

Then, decode the result using the faad program from the FAAD2-2_10_0 package and play back the decoded file (requires the aplay program from the alsa-utils-1.2.6 package:

faad Front_Left.mp4
aplay Front_Left.wav

aplay should identify the file as Signed 16 bit Little Endian, Rate 48000 Hz, Stereo, and you should hear the words front left.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Other AAC encoders

The quality of FAAC is not up to par with the best AAC encoders currently available. Also, it only supports AAC and not High Efficiency AAC (also known as aacPlus), which provides better quality at low bitrates by means of using the spectral band replication technology. There are the following alternative programs for producing AAC and HE-AAC streams:

  • Nero AAC Codec: available only in the binary form, the command-line AAC and HE-AAC encoders for Linux are in the same archive as the Windows application.

  • 3GPP Enhanced aacPlus general audio codec: available in the source form, can encode only HE-AAC up to 48 kbps out of the box, but the maximum bitrate can be changed by editing the tuning table in the FloatFR_sbrenclib/src/sbr_main.c file.

Note, however, that iPod supports only Low Complexity AAC profile, which is the default in FAAC, but may not be the default in Nero AAC Encoder and is completely unavailable in the 3GPP encoder.

Contents

Installed Program: faac
Installed Libraries: libfaac.so and libmp4v2.so
Installed Directories: None

Short Descriptions

faac

is a command-line AAC encoder

libfaac.so

contains functions for encoding AAC streams

libmp4v2.so

contains functions for creating and manipulating MP4 files

Last updated on

FAAD2-2_10_0

Introduction to FAAD2

FAAD2 is a decoder for a lossy sound compression scheme specified in MPEG-2 Part 7 and MPEG-4 Part 3 standards and known as Advanced Audio Coding (AAC).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/faad2

Installation of FAAD2

Install FAAD2 by running the following commands:

./bootstrap                                &&
./configure --prefix=/usr --disable-static &&
make

This package does not come with a test suite. However, basic functionality can be tested by decoding the sample AAC file:

./frontend/faad -o sample.wav ../sample.aac

This should display a copyright message and the following information about the sample file:

sample.aac file info:
ADTS, 4.608 sec, 13 kbps, 16000 Hz


  ---------------------
 | Config:  2 Ch       |
  ---------------------
 | Ch |    Position    |
  ---------------------
 | 00 | Left front     |
 | 01 | Right front    |
  ---------------------

Now play the result (requires the aplay program from the alsa-utils-1.2.6 package):

aplay sample.wav

aplay should identify the file as Signed 16 bit Little Endian, Rate 16000 Hz, Stereo, and you should hear some piano notes.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Program: faad
Installed Library: libfaad.so and libfaad_drm.so
Installed Directories: None

Short Descriptions

faad

is a command-line utility for decoding AAC and MP4 files

libfaad.so

contains functions for decoding AAC streams

Last updated on

fdk-aac-2.0.2

Introduction to fdk-aac

fdk-aac package provides the Fraunhofer FDK AAC library, which is purported to be a high quality Advanced Audio Coding implementation.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/fdk-aac

Installation of fdk-aac

Install fdk-aac by running the following commands:

./configure --prefix=/usr --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Library: libfdk-aac.so
Installed Directory: /usr/include/fdk-aac

Short Descriptions

libfdk-aac.so

provides the functions used to encode audio in AAC format

Last updated on

FLAC-1.3.3

Introduction to FLAC

FLAC is an audio CODEC similar to MP3, but lossless, meaning that audio is compressed without losing any information.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://downloads.xiph.org/releases/flac/flac-1.3.3.tar.xz

  • Download MD5 sum: 26703ed2858c1fc9ffc05136d13daa69

  • Download size: 1.0 MB

  • Estimated disk space required: 21 MB (additional 95 MB to run the test suite)

  • Estimated build time: 0.1 SBU (additional 0.7 SBU to run the test suite)

Additional Downloads

FLAC Dependencies

Optional

libogg-1.3.5, NASM-2.15.05, DocBook-utils-0.6.14, Doxygen-1.9.3 and Valgrind-3.18.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/flac

Installation of FLAC

Install FLAC by running the following commands:

patch -Np1 -i ../flac-1.3.3-security_fixes-1.patch      &&
./configure --prefix=/usr                                \
            --disable-thorough-tests                     \
            --docdir=/usr/share/doc/flac-1.3.3          &&
make

To test the results, issue: make check. Note that if you passed the --enable-exhaustive-tests and --enable-valgrind-testing parameters to configure and then run the test suite, it will take a very long time (up to 300 SBUs) and use about 375 MB of disk space.

Now, as the root user:

make install

Command Explanations

--disable-thorough-tests: This parameter is used so that the test suite will complete in a reasonable amount of time. Remove it if you desire more extensive tests.

Contents

Installed Programs: flac and metaflac
Installed Libraries: libFLAC.so and libFLAC++.so
Installed Directories: /usr/include/FLAC, /usr/include/FLAC++ and /usr/share/doc/flac-1.3.3

Short Descriptions

flac

is a command-line utility for encoding, decoding and converting FLAC files

metaflac

is a program for listing, adding, removing, or editing metadata in one or more FLAC files

libFLAC{,++}.so

these libraries provide native FLAC and Ogg FLAC C/C++ APIs for programs utilizing FLAC

Last updated on

frei0r-plugins-1.7.0

Introduction to Frei0r-plugins

Frei0r is a minimalistic plugin API for video effects. Note that the 0 in the name is a zero, not a capital letter o.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Frei0r-plugins Dependencies

Recommended

gavl-1.4.0

Optional

Doxygen-1.9.3 and opencv-4.5.5 (currently broken)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/frei0r

Installation of Frei0r-plugins

Install Frei0r by running the following commands:

mkdir -vp build &&
cd        build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_BUILD_TYPE=Release  \
      -DWITHOUT_OPENCV=TRUE       \
      -Wno-dev ..                 &&

make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

-DWITHOUT_OPENCV=TRUE: This option instructs the make procedure to disable building plugins dependent upon opencv.

-DWITHOUT_GAVL=TRUE: This option instructs the make procedure to disable building plugins dependent upon gavl.

Contents

Installed Program: None
Installed Libraries: Over 130 video effects plugins
Installed Directories: /usr/lib/frei0r-1

Last updated on

gavl-1.4.0

Introduction to Gavl

Gavl is short for Gmerlin Audio Video Library. It is a low level library that handles the details of audio and video formats like colorspaces, samplerates, multichannel configurations etc. It provides standardized definitions for those formats as well as container structures for carrying audio samples or video images inside an application.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Gavl Dependencies

Required

libpng-1.6.37

Optional

Doxygen-1.9.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gavl

Installation of Gavl

Install Gavl by running the following commands:

LIBS=-lm                      \
./configure --prefix=/usr     \
            --without-doxygen \
            --docdir=/usr/share/doc/gavl-1.4.0 &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

LIBS=-lm: This variable ensures the math library is searched when linking.

--without-doxygen: This switch disables use of Doxygen. Omit if Doxygen is installed and you wish to build the API documentation.

Contents

Installed Program: None
Installed Libraries: libgavl.so
Installed Directories: /usr/include/gavl and /usr/share/doc/gavl-1.4.0

Short Descriptions

libgavl.so

is the Gmerlin Audio Video Library

Last updated on

gstreamer-1.20.0

Introduction to gstreamer

gstreamer is a streaming media framework that enables applications to share a common set of plugins for tasks such as video encoding and decoding, audio encoding and decoding, audio and video filters, audio visualisation, web streaming and anything else that streams in real-time or otherwise. This package only provides base functionality and libraries. You may need at least gst-plugins-base-1.20.0 and one of Good, Bad, Ugly or Libav plugins.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

gstreamer Dependencies

Required

GLib-2.70.4

Recommended
Optional

GTK+-3.24.31 (for examples), Gsl-2.7.1 (used by one test if installed), Valgrind-3.18.1, bash-completion, hotdoc, libdw, and libunwind

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gstreamer10

Installation of gstreamer

Note

If you do not have an Objective-C compiler installed, the build system for this package will emit a warning about a failed sanity check. This is harmless, and it is safe to continue.

Install gstreamer by running the following commands:

mkdir build &&
cd    build &&

meson  --prefix=/usr       \
       --buildtype=release \
       -Dgst_debug=false   \
       -Dpackage-origin=https://www.linuxfromscratch.org/blfs/view/svn/ \
       -Dpackage-name="GStreamer 1.20.0 BLFS" &&
ninja

To test the results, issue: ninja test.

Caution

If you are reinstalling gstreamer from a previous version, it is best if you remove the prior version, including plugins, before installing the new version. If there is a mixture of versions installed, using processes may hang or not work properly. As the root user:

rm -rf /usr/bin/gst-* /usr/{lib,libexec}/gstreamer-1.0

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: gst-inspect-1.0, gst-launch-1.0, gst-stats-1.0, gst-tester-1.0, and gst-typefind-1.0
Installed Libraries: libgstbase-1.0.so, libgstcheck-1.0.so, libgstcontroller-1.0.so, libgstnet-1.0.so, and libgstreamer-1.0.so
Installed Directories: /usr/{include,lib,libexec,share}/gstreamer-1.0

Short Descriptions

gst-inspect-1.0

is a tool that prints out information on available gstreamer plugins, information about a particular plugin, or information about a particular element

gst-launch-1.0

is a tool that builds and runs basic gstreamer pipelines

gst-stats-1.0

is a tool used to gather statistics about gstreamer operations

gst-tester-1.0

runs a test plan in TAP compatible format while integrating with the meson test harness

gst-typefind-1.0

uses the gstreamer type finding system to determine the relevant gstreamer plugin to parse or decode files, and the corresponding MIME type

libgstbase-1.0.so

provides some base classes to be extended by elements and utillity classes that are most useful for plugin developers

libgstcheck-1.0.so

provides functionality for writing unit tests that use the check framework

libgstcontroller-1.0.so

provides functionality to animate element properties over time

libgstnet-1.0.so

provides network elements and objects

libgstreamer-1.0.so

provides all of the core gstreamer services, including initialization, plugin management and types, as well as the object hierarchy that defines elements and bins, along with some more specialized elements

Last updated on

gst-plugins-base-1.20.0

Introduction to GStreamer Base Plug-ins

The GStreamer Base Plug-ins is a well-groomed and well-maintained collection of GStreamer plug-ins and elements, spanning the range of possible types of elements one would want to write for GStreamer. You will need at least one of Good, Bad, Ugly or Libav plugins for GStreamer applications to function properly.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GStreamer Base Plug-ins Dependencies

Required

gstreamer-1.20.0

Recommended
Optional

graphene-1.10.6, GTK+-3.24.31 (for examples), Opus-1.3.1, Qt-5.15.2 (for examples), SDL-1.2.15, SDL2-2.0.20, Valgrind-3.18.1, hotdoc, libvisual, Orc, and Tremor

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gst10-plugins-base

Installation of GStreamer Base Plug-ins

Note

If you do not have an Objective-C compiler installed, the build system for this package will emit a warning about a failed sanity check. This is harmless, and it is safe to continue.

Note

If you need a plugin for a given dependency, that dependency needs to be installed before this package.

Install GStreamer Base Plug-ins by running the following commands:

mkdir build &&
cd    build &&

meson  --prefix=/usr       \
       --buildtype=release \
       -Dpackage-origin=https://www.linuxfromscratch.org/blfs/view/svn/ \
       -Dpackage-name="GStreamer 1.20.0 BLFS"    \
       --wrap-mode=nodownload &&
ninja

To test the results, issue: ninja test. The tests require an X terminal running, or all of the GL tests will fail. Five tests may produce timeouts on some systems depending on their graphics hardware and speed.

Note

When installing, the build process does some additional linking. If you do not have Xorg in /usr, the LIBRARY_PATH variable needs to be defined for the root user. If using sudo to assume root, use the -E option to pass your current environment variables for the install process.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

--wrap-mode=nodownload: This switch prevents meson from downloading any optional dependency which is not installed on the system.

Contents

Installed Programs: gst-device-monitor-1.0, gst-discoverer-1.0, and gst-play-1.0
Installed Libraries: libgstallocators-1.0.so, libgstapp-1.0.so, libgstaudio-1.0.so, libgstfft-1.0.so, libgstgl-1.0.so, libgstpbutils-1.0.so, libgstriff-1.0.so, libgstrtp-1.0.so, libgstrtsp-1.0.so, libgstsdp-1.0.so, libgsttag-1.0.so, libgstvideo-1.0.so, and several plugins under /usr/lib/gstreamer-1.0
Installed Directories: /usr/include/gstreamer-1.0/gst/{allocators,app,audio,fft,gl,pbutils}, /usr/include/gstreamer-1.0/gst/{riff,rtp,rtsp,sdp,tag,video}, and /usr/share/gst-plugins-base

Short Descriptions

gst-device-monitor-1.0

is a command line tool that can be used to test GStreamer's device monitoring functionality

gst-discoverer-1.0

is a tool that can be used to print basic metadata and stream information about a media file

gst-play-1.0

is a command line tool that can be used to test basic playback using the playbin element

Last updated on

gst-plugins-good-1.20.0

Introduction to GStreamer Good Plug-ins

The GStreamer Good Plug-ins is a set of plug-ins considered by the GStreamer developers to have good quality code, correct functionality, and the preferred license (LGPL for the plug-in code, LGPL or LGPL-compatible for the supporting library). A wide range of video and audio decoders, encoders, and filters are included.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GStreamer Good Plug-ins Dependencies

Required

gst-plugins-base-1.20.0

Recommended
Optional

AAlib-1.4rc5, ALSA OSS-1.1.8, GTK+-3.24.31 (for examples), libdv-1.0.0, PulseAudio-15.0, Qt-5.15.2, Speex-1.2.0, taglib-1.12, Valgrind-3.18.1, v4l-utils-1.22.1, Wayland-1.20.0, hotdoc, JACK, libcaca, libavc1394, libiec61883, libraw1394, libshout, Orc, TwoLame, and WavPack

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gst10-plugins-good

Installation of GStreamer Good Plug-ins

Note

If you do not have an Objective-C compiler installed, the build system for this package will emit a warning about a failed sanity check. This is harmless, and it is safe to continue.

Note

If you need a plugin for a given dependency, that dependency needs to be installed before this package.

Install GStreamer Good Plug-ins by running the following commands:

mkdir build &&
cd    build &&

meson  --prefix=/usr       \
       --buildtype=release \
       -Dpackage-origin=https://www.linuxfromscratch.org/blfs/view/svn/ \
       -Dpackage-name="GStreamer 1.20.0 BLFS" &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: None
Installed Libraries: Several plugins under /usr/lib/gstreamer-1.0
Installed Directories: /usr/share/gstreamer-1.0/presets

Last updated on

gst-plugins-bad-1.20.0

Introduction to GStreamer Bad Plug-ins

The GStreamer Bad Plug-ins package contains a set of plug-ins that aren't up to par compared to the rest. They might be close to being good quality, but they're missing something - be it a good code review, some documentation, a set of tests, a real live maintainer, or some actual wide use.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GStreamer Bad Plug-ins Dependencies

Required

gst-plugins-base-1.20.0

Recommended
Optional

BlueZ-5.63, cURL-7.81.0, FAAC-1_30, FAAD2-2_10_0, fdk-aac-2.0.2, GTK+-3.24.31 (for examples), Little CMS-2.13.1, libass-0.15.2, libexif-0.6.24 (for one test), libmpeg2-0.5.1, librsvg-2.52.6, libsndfile-1.0.31, libssh2-1.10.0, libusb-1.0.25, libwebp-1.2.2, libxkbcommon-1.4.0, neon-0.32.2, Nettle-3.7.3 or libgcrypt-1.10.0 (for SSL support in hls plugin, if both are not installed OpenSSL will be used instead), opencv-4.5.5 (with additional modules), OpenJPEG-2.4.0, Opus-1.3.1, SBC-1.5, SDL-1.2.15, Valgrind-3.18.1, Wayland-1.20.0 (GTK+-3.24.31 must have been compiled with wayland support), wpebackend-fdo-1.12.0, x265-20220219, aom, bs2b, Chromaprint, dssim, Flite, FluidSynth, Game Music Emu, GSM, hotdoc, LADSPA, libavtp, libdc1394-2, libdca, libde265, libkate, libmfx, libmms, libmodplug, libnice, libofa, libopenmpt, libopenni, libsrtp, lilv, LRDF, ltc-tools, microdns, MJPEG Tools, OpenAL, OpenEXR, OpenH264, Orc, rtmpdump, spandsp, srt, svthevcenc, VO AAC, VO AMRWB, Vulkan, WildMidi, WPE-WebKit, ZBAR, ZVBI, and zxing

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gst10-plugins-bad

Installation of GStreamer Bad Plug-ins

Note

If you do not have an Objective-C compiler installed, the build system for this package will emit a warning about a failed sanity check. This is harmless, and it is safe to continue.

Note

If you need a plugin for a given dependency, that dependency needs to be installed before this package.

Install GStreamer Bad Plug-ins by running the following commands:

mkdir build &&
cd    build &&

meson  --prefix=/usr       \
       --buildtype=release \
       -Dpackage-origin=https://www.linuxfromscratch.org/blfs/view/svn/ \
       -Dpackage-name="GStreamer 1.20.0 BLFS" &&
ninja

To test the results, issue: ninja test. Several tests need a terminal emulator in a graphical session.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: gst-transcoder-1.0 and playout
Installed Libraries: libgstadaptivedemux-1.0.so, libgstbadaudio-1.0.so, libgstbasecamerabinsrc-1.0.so, libgstcodecparsers-1.0.so, libgstcodecs-1.0.so, libgstinsertbin-1.0.so, libgstisoff-1.0.so, libgstmpegts-1.0.so, libgstphotography-1.0.so, libgstplay-1.0.so, libgstplayer-1.0.so, libgstsctp-1.0.so, libgsttranscoder-1.0.so, libgsturidownloader-1.0.so, libgstva-1.0.so, libgstwayland-1.0.so, libgstwebrtc-1.0.so, and several plugins under /usr/lib/gstreamer-1.0
Installed Directories: /usr/include/gstreamer-1.0/gst/{audio,basecamerabinsrc,codecparsers}, /usr/include/gstreamer-1.0/gst/{insertbin,interfaces,isoff,mpegts}, /usr/include/gstreamer-1.0/gst/{play,player,sctp,transcoder}, and /usr/include/gstreamer-1.0/gst/{uridownloader,wayland,webrtc}

Short Descriptions

gst-transcoder-1.0

is used to transcode a stream into a different format

playout

is an example application used to sequentially play a list of audio-video files

Last updated on

gst-plugins-ugly-1.20.0

Introduction to GStreamer Ugly Plug-ins

The GStreamer Ugly Plug-ins is a set of plug-ins considered by the GStreamer developers to have good quality and correct functionality, but distributing them might pose problems. The license on either the plug-ins or the supporting libraries might not be how the GStreamer developers would like. The code might be widely known to present patent problems.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GStreamer Ugly Plug-ins Dependencies

Required

gst-plugins-base-1.20.0

Recommended
Optional

libmpeg2-0.5.1, libcdio-2.1.0 (for CD-ROM drive access), Valgrind-3.18.1, hotdoc, libsidplay, OpenCore AMR, Orc, and TwoLame

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gst10-plugins-ugly

Installation of GStreamer Ugly Plug-ins

Note

If you do not have an Objective-C compiler installed, the build system for this package will emit a warning about a failed sanity check. This is harmless, and it is safe to continue.

Note

If you need a plugin for a given dependency, that dependency needs to be installed before this package.

Install GStreamer Ugly Plug-ins by running the following commands:

mkdir build &&
cd    build &&

meson  --prefix=/usr       \
       --buildtype=release \
       -Dpackage-origin=https://www.linuxfromscratch.org/blfs/view/svn/ \
       -Dpackage-name="GStreamer 1.20.0 BLFS" &&
ninja

To test the results, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: None
Installed Libraries: Several plugins under /usr/lib/gstreamer-1.0
Installed Directories: None

Last updated on

gst-libav-1.20.0

Introduction to GStreamer Libav

The GStreamer Libav package contains GStreamer plugins for Libav (a fork of FFmpeg).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

GStreamer Libav Dependencies

Required

FFmpeg-4.4.1 and gst-plugins-base-1.20.0

Recommended
Optional

hotdoc and Orc

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gst10-libav

Installation of GStreamer Libav

Note

If you do not have an Objective-C compiler installed, the build system for this package will emit a warning about a failed sanity check. This is harmless, and it is safe to continue.

Install GStreamer Libav by running the following commands:

mkdir build &&
cd    build &&

meson  --prefix=/usr       \
       --buildtype=release \
       -Dpackage-origin=https://www.linuxfromscratch.org/blfs/view/svn/ \
       -Dpackage-name="GStreamer 1.20.0 BLFS" &&
ninja

To test the results, issue: ninja test

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: None
Installed Library: libgstlibav.so
Installed Directory: None

Last updated on

gstreamer-vaapi-1.20.0

Introduction to gstreamer-vaapi

The gstreamer-vaapi package contains a gstreamer plugin for hardware accelerated video decode/encode for the prevailing coding standards today (MPEG-2, MPEG-4 ASP/H.263, MPEG-4 AVC/H.264, and VC-1/VMW3).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

gstreamer-vaapi Dependencies

Required

GTK+-3.24.31, gstreamer-1.20.0, gst-plugins-base-1.20.0, gst-plugins-bad-1.20.0, and libva-2.13.0

Optional

hotdoc

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gstreamer10-vaapi

Installation of gstreamer-vaapi

Note

If you do not have an Objective-C compiler installed, the build system for this package will emit a warning about a failed sanity check. This is harmless, and it is safe to continue.

Install gstreamer-vaapi by running the following commands:

mkdir build &&
cd    build &&

meson  --prefix=/usr       \
       --buildtype=release \
       -Dpackage-origin=https://www.linuxfromscratch.org/blfs/view/svn/ &&
ninja

This package does not come with a test suite.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

Contents

Installed Programs: None
Installed Library: libgstvaapi.so
Installed Directory: None

Last updated on

id3lib-3.8.3

Introduction to id3lib

id3lib is a library for reading, writing and manipulating id3v1 and id3v2 multimedia data containers.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/id3lib

Installation of Id3lib

Install id3lib by running the following commands:

patch -Np1 -i ../id3lib-3.8.3-consolidated_patches-1.patch &&

libtoolize -fc                &&
aclocal                       &&
autoconf                      &&
automake --add-missing --copy &&

./configure --prefix=/usr --disable-static &&
make

This packages does not come with a working test suite.

Now, as the root user:

make install  &&
cp doc/man/* /usr/share/man/man1 &&

install -v -m755 -d /usr/share/doc/id3lib-3.8.3 &&
install -v -m644 doc/*.{gif,jpg,png,ico,css,txt,php,html} \
                    /usr/share/doc/id3lib-3.8.3

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: id3convert, id3cp, id3info, and id3tag
Installed Library: libid3.so
Installed Directories: /usr/include/id3 and /usr/share/doc/id3lib-3.8.3

Short Descriptions

id3convert

converts between id3v1/v2 tagging formats

id3cp

extracts id3v1/v2 tags from digital audio files

id3info

prints id3v1/v2 tag contents

id3tag

is a utility for editing id3v1/v2 tags

libid3.so

provides functions for the id3v1/v2 tag editing programs as well as other external programs and libraries

Last updated on

Liba52-0.7.4

Introduction to Liba52

liba52 is a free library for decoding ATSC A/52 (also known as AC-3) streams. The A/52 standard is used in a variety of applications, including digital television and DVD.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Optional

djbfft

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/liba52

Installation of Liba52

Install liba52 by running the following commands:

./configure --prefix=/usr \
            --mandir=/usr/share/man \
            --enable-shared \
            --disable-static \
            CFLAGS="${CFLAGS:--g -O2} $([ $(uname -m) = x86_64 ] && echo -fPIC)" &&
make

To test the results, issue: make check.

Now, as the root user:

make install &&
cp liba52/a52_internal.h /usr/include/a52dec &&
install -v -m644 -D doc/liba52.txt \
    /usr/share/doc/liba52-0.7.4/liba52.txt

Command Explanations

CFLAGS="-g -O2 ...: This sets CFLAGS to -g -O2 (which is the default) but then on x86_64 adds -fPIC. This is needed to compile liba52 on x86_64.

--disable-static: This switch prevents installation of static versions of the libraries.

cp liba52/a52_internal.h ...: Copying this header file into /usr/include/a52dec allows some other programs (such as xine-lib) to compile and link against a system installed liba52.

Contents

Installed Programs: a52dec and extract_a52
Installed Library: liba52.so
Installed Directories: /usr/include/a52dec and /usr/share/doc/liba52-0.7.4

Short Descriptions

a52dec

plays ATSC A/52 audio streams

extract_a52

extracts ATSC A/52 audio from an MPEG stream

liba52.so

provides functions for the programs dealing with ATSC A/52 streams

Last updated on

Libao-1.2.0

Introduction to Libao

The libao package contains a cross-platform audio library. This is useful to output audio on a wide variety of platforms. It currently supports WAV files, OSS (Open Sound System), ESD (Enlighten Sound Daemon), ALSA (Advanced Linux Sound Architecture), NAS (Network Audio system), aRTS (analog Real-Time Synthesizer), and PulseAudio (next generation GNOME sound architecture).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Libao Dependencies

Optional

a graphical environment, ALSA-1.2.6, and PulseAudio-15.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libao

Installation of Libao

Install libao by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&
install -v -m644 README /usr/share/doc/libao-1.2.0

Configuring Libao

Config Files

/etc/libao.conf and ~/.libao

Configuration Information

Currently, the only configuration option available is setting the default output device. Issue man libao.conf for details.

Contents

Installed Programs: None
Installed Libraries: libao.so and plugins under /usr/lib/ao/plugins-4
Installed Directories: /usr/include/ao, /usr/lib/ao and /usr/share/doc/libao-1.2.0

Short Descriptions

libao.so

provides functions for programs wishing to output sound over supported platforms

Last updated on

libass-0.15.2

Introduction to libass

libass is a portable subtitle renderer for the ASS/SSA (Advanced Substation Alpha/Substation Alpha) subtitle format that allows for more advanced subtitles than the conventional SRT and similar formats.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libass Dependencies

Required

FreeType-2.11.1, FriBidi-1.0.11, and NASM-2.15.05

Recommended
Optional

HarfBuzz-3.4.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libass

Installation of libass

Install libass by running the following commands:

./configure --prefix=/usr --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--disable-fontconfig: Use this switch if you didn't install Fontconfig.

Contents

Installed Programs: None
Installed Library: libass.so
Installed Directory: /usr/include/ass

Short Descriptions

libass.so

provides the functions used to render ASS/SSA subtitle format

Last updated on

libcanberra-0.30

Introduction to libcanberra

libcanberra is an implementation of the XDG Sound Theme and Name Specifications, for generating event sounds on free desktops, such as GNOME.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

libcanberra Dependencies

Required

libvorbis-1.3.7

Recommended
Optional

GTK+-2.24.33, PulseAudio-15.0 and tdb

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libcanberra

Installation of libcanberra

At first, apply a patch to fix an issue causing some applications to crash in Wayland based desktop environment:

patch -Np1 -i ../libcanberra-0.30-wayland-1.patch

Install libcanberra by running the following commands:

./configure --prefix=/usr --disable-oss &&
make

This package does not come with a test suite.

Now, as the root user:

make docdir=/usr/share/doc/libcanberra-0.30 install

Command Explanations

--disable-oss: disable optional deprecated OSS support

--disable-gtk: disable optional GTK+ 2 support

--disable-gtk3: disable optional GTK+ 3 support

Contents

Installed Programs: canberra-boot and canberra-gtk-play
Installed Libraries: libcanberra-gtk.so, libcanberra-gtk3.so and libcanberra.so
Installed Directories: /usr/lib/libcanberra-0.30, /usr/share/doc/libcanberra-0.30 and /usr/share/gtk-doc/html/libcanberra

Short Descriptions

canberra-gtk-play

is an application used for playing sound events

libcanberra-gtk.so

contains the libcanberra bindings for GTK+ 2

libcanberra-gtk3.so

contains the libcanberra bindings for GTK+ 3

libcanberra.so

contains the libcanberra API functions

Last updated on

libcddb-1.3.2

Introduction to libcddb

The libcddb is a library that implements the different protocols (CDDBP, HTTP, SMTP) to access data on a CDDB server.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libcddb

Installation of libcddb

Install libcddb by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check. Two tests fail due to missing test servers.

Now, as the root user:

make install

Contents

Installed Programs: cddb_query
Installed Library: libcddb.so
Installed Directories: /usr/include/cddb

Short Descriptions

cddb_query

provides a user interface to a CDDB server

Last updated on

libcdio-2.1.0

Introduction to libcdio

The libcdio is a library for CD-ROM and CD image access. The associated libcdio-cdparanoia library reads audio from the CD-ROM directly as data, with no analog step between, and writes the data to a file or pipe as .wav, .aifc or as raw 16 bit linear PCM.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

libcdio Dependencies

Optional

libcddb-1.3.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libcdio

Installation of libcdio

Install libcdio by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Now install libcdio-paranoia:

tar -xf ../libcdio-paranoia-10.2+2.0.1.tar.bz2 &&
cd libcdio-paranoia-10.2+2.0.1 &&

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Contents

Installed Programs: cdda-player, cd-drive, cd-info, cd-paranoia, cd-read, iso-info, iso-read, and mmc-tool
Installed Library: libcdio.so, libcdio++.so, libcdio_cdda, libcdio_paranoia, libiso9660, libiso9660++, and libudf.so
Installed Directories: /usr/include/cdio and /usr/include/cdio++

Short Descriptions

cd-drive

shows CD-ROM drive characteristics

cd-info

shows information about a CD or CD-image

cd-paranoia

is an audio CD reading utility which includes extra data verification features

cd-read

reads Information from a CD or CD-image

cdda-player

is a simple curses CD player

iso-info

shows Information about an ISO 9660 image

iso-read

reads portions of an ISO 9660 image

mmc-tool

issues libcdio multimedia commands

libcdio.so

contains the primary cdio API functions

Last updated on

libdiscid-0.6.2

Introduction to libdiscid

The libdiscid package contains a library for creating MusicBrainz DiscIDs from audio CDs. It reads a CD's table of contents (TOC) and generates an identifier which can be used to lookup the CD at MusicBrainz (http://musicbrainz.org). Additionally, it provides a submission URL for adding the DiscID to the database.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Optional

Doxygen-1.9.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libdiscid

Installation of libdiscid

Install libdiscid by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Library: libdiscid.so
Installed Directory: /usr/include/discid

Short Descriptions

libdiscid.so

contains the DiscID API functions

Last updated on

libdvdcss-1.4.3

Introduction to libdvdcss

libdvdcss is a simple library designed for accessing DVDs as a block device without having to bother about the decryption.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libdvdcss Dependencies

Optional (to Create Documentation)

Doxygen-1.9.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libdvdcss

Installation of libdvdcss

Install libdvdcss by running the following commands:

./configure --prefix=/usr    \
            --disable-static \
            --docdir=/usr/share/doc/libdvdcss-1.4.3 &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Library: libdvdcss.so
Installed Directories: /usr/include/dvdcss and /usr/share/doc/libdvdcss-1.4.3

Short Descriptions

libdvdcss.so

provides the functionality that is required for transparent DVD access with CSS decryption

Last updated on

Libdvdread-6.1.2

Introduction to Libdvdread

libdvdread is a library which provides a simple foundation for reading DVDs.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libdvdread

Installation of Libdvdread

Install libdvdread by running the following commands:

./configure --prefix=/usr    \
            --disable-static \
            --docdir=/usr/share/doc/libdvdread-6.1.2 &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Library: libdvdread.so
Installed Directories: /usr/include/dvdread and /usr/share/doc/libdvdread-6.1.2

Short Descriptions

libdvdread.so

provides functionality required to access DVDs

Last updated on

Libdvdnav-6.1.1

Introduction to Libdvdnav

libdvdnav is a library that allows easy use of sophisticated DVD navigation features such as DVD menus, multiangle playback and even interactive DVD games.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Libdvdnav Dependencies

Required

libdvdread-6.1.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libdvdnav

Installation of Libdvdnav

Install libdvdnav by running the following commands:

./configure --prefix=/usr    \
            --disable-static \
            --docdir=/usr/share/doc/libdvdnav-6.1.1 &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Library: libdvdnav.so
Installed Directories: /usr/include/dvdnav and /usr/share/doc/libdvdnav-6.1.1

Short Descriptions

libdvdnav.so

is the DVD navigation library

Last updated on

Libdv-1.0.0

Introduction to Libdv

The Quasar DV Codec (libdv) is a software CODEC for DV video, the encoding format used by most digital camcorders. It can be used to copy videos from camcorders using a firewire (IEEE 1394) connection.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Libdv Dependencies

Optional

popt-1.18, SDL-1.2.15, and a graphical environment

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libdv

Installation of Libdv

Install libdv by running the following commands:

./configure --prefix=/usr \
            --disable-xv \
            --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&
install -v -m755 -d      /usr/share/doc/libdv-1.0.0 &&
install -v -m644 README* /usr/share/doc/libdv-1.0.0

Command Explanations

--disable-xv: This parameter is required if an X Window System is not installed. It also prevents configure testing for libXv which is only used for an obsolete program playdv that will not be built with current linux headers and would also need other obsolete dependencies.

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: dubdv, dvconnect, and encodedv
Installed Library: libdv.so
Installed Directories: /usr/include/libdv and /usr/share/doc/libdv-1.0.0

Short Descriptions

dubdv

inserts audio into a digital video stream

dvconnect

is a small utility to send or capture raw data from and to the camcorder

encodedv

encodes a series of images to a digital video stream

libdv.so

provides functions for programs interacting with the Quasar DV CODEC

Last updated on

libmad-0.15.1b

Introduction to libmad

libmad is a high-quality MPEG audio decoder capable of 24-bit output.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libmad

Installation of libmad

Install libmad by running the following commands:

patch -Np1 -i ../libmad-0.15.1b-fixes-1.patch                &&
sed "s@AM_CONFIG_HEADER@AC_CONFIG_HEADERS@g" -i configure.ac &&
touch NEWS AUTHORS ChangeLog                                 &&
autoreconf -fi                                               &&

./configure --prefix=/usr --disable-static &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Some packages check for the pkg-config file for libmad. This file is particularly needed so that Cdrdao can recognize the installed libmad.

As the root user:

cat > /usr/lib/pkgconfig/mad.pc << "EOF"
prefix=/usr
exec_prefix=${prefix}
libdir=${exec_prefix}/lib
includedir=${prefix}/include

Name: mad
Description: MPEG audio decoder
Requires:
Version: 0.15.1b
Libs: -L${libdir} -lmad
Cflags: -I${includedir}
EOF

Command Explanations

touch NEWS AUTHORS ChangeLog: Prevent autoreconf from returning an error.

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Library: libmad.so
Installed Directories: None

Short Descriptions

libmad.so

is a MPEG audio decoder library

Last updated on

libmpeg2-0.5.1

Introduction to libmpeg2

The libmpeg2 package contains a library for decoding MPEG-2 and MPEG-1 video streams. The library is able to decode all MPEG streams that conform to certain restrictions: constrained parameters for MPEG-1, and main profile for MPEG-2. This is useful for programs and applications needing to decode MPEG-2 and MPEG-1 video streams.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libmpeg2 Dependencies

Optional

a graphical environment and SDL-1.2.15

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libmpeg2

Installation of libmpeg2

Install libmpeg2 by running the following commands:

sed -i 's/static const/static/' libmpeg2/idct_mmx.c &&

./configure --prefix=/usr    \
            --enable-shared  \
            --disable-static &&
make

To test the results, issue: make check. To perform a more comprehensive regression test, see the file test/README in the source tree.

Now, as the root user:

make install &&

install -v -m755 -d /usr/share/doc/mpeg2dec-0.5.1 &&
install -v -m644 README doc/libmpeg2.txt \
                    /usr/share/doc/mpeg2dec-0.5.1

Command Explanations

sed -i ...: This sed fixes problems with recent GCC compilers.

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: corrupt_mpeg2, extract_mpeg2 and mpeg2dec
Installed Libraries: libmpeg2.so and libmpeg2convert.so
Installed Directories: /usr/include/mpeg2dec and /usr/share/doc/mpeg2dec-0.5.1

Short Descriptions

extract_mpeg2

extracts MPEG video streams from a multiplexed stream

mpeg2dec

decodes MPEG1 and MPEG2 video streams

libmpeg2.so

contains API functions used to decode MPEG video streams

libmpeg2convert.so

contains API functions used for color conversions of MPEG video streams

Last updated on

libmusicbrainz-2.1.5

Introduction to libmusicbrainz

The libmusicbrainz package contains a library which allows you to access the data held on the MusicBrainz server. This is useful for adding MusicBrainz lookup capabilities to other applications.

MusicBrainz is a community music metadatabase that attempts to create a comprehensive music information site. You can use the MusicBrainz data either by browsing the web site, or you can access the data from a client program — for example, a CD player program can use MusicBrainz to identify CDs and provide information about the CD, about the artist or other related information.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

libmusicbrainz Dependencies

Optional to Build the Python Bindings

Python-2.7.18

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libmusicbrainz

Installation of libmusicbrainz

Install libmusicbrainz by running the following commands:

patch -Np1 -i ../libmusicbrainz-2.1.5-missing-includes-1.patch &&

CXXFLAGS="${CXXFLAGS:--O2 -g} -std=c++98" \
./configure --prefix=/usr --disable-static &&
make

If Python is installed, build the bindings with the following commands:

(cd python && python2 setup.py build)

This package does not come with a stand-alone test suite (to test you must have Python installed and perform the test after the package is installed).

Now, as the root user:

make install &&
install -v -m644 -D docs/mb_howto.txt \
    /usr/share/doc/libmusicbrainz-2.1.5/mb_howto.txt

To test the Python bindings, issue the following: (cd python && python2 setup.py test).

If you built the Python bindings, issue the following commands as the root user to install them:

(cd python && python2 setup.py install)

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Library: libmusicbrainz.so
Installed Directories: /usr/include/musicbrainz and /usr/share/doc/libmusicbrainz-2.1.5

Short Descriptions

libmusicbrainz.so

contains API functions to access the MusicBrainz database, both for looking up data and also for submitting new data

Last updated on

libmusicbrainz-5.1.0

Introduction to libmusicbrainz

The libmusicbrainz package contains a library which allows you to access the data held on the MusicBrainz server.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

libmusicbrainz Dependencies

Required

CMake-3.22.2, libxml2-2.9.13 and neon-0.32.2

Optional

Doxygen-1.9.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libmusicbrainz5

Installation of libmusicbrainz

First, fix a problem caused by CMake-3.18.0:

patch -Np1 -i ../libmusicbrainz-5.1.0-cmake_fixes-1.patch

Install libmusicbrainz by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Release .. &&
make

If you have installed Doxygen-1.9.3, optionally build the API documentation:

doxygen ../Doxyfile

This package does not come with a test suite.

Now, as the root user:

make install

If you have built the API documentation, install, as the root user:

rm -rf /usr/share/doc/libmusicbrainz-5.1.0 &&
cp -vr docs/ /usr/share/doc/libmusicbrainz-5.1.0

Contents

Installed Programs: None
Installed Library: libmusicbrainz5.so
Installed Directory: /usr/include/libmusicbrainz5 and /usr/share/doc/libmusicbrainz-5.1.0

Short Descriptions

libmusicbrainz5.so

contains API functions for accessing the MusicBrainz database

Last updated on

libogg-1.3.5

Introduction to libogg

The libogg package contains the Ogg file structure. This is useful for creating (encoding) or playing (decoding) a single physical bit stream.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libogg

Installation of libogg

Install libogg by running the following commands:

./configure --prefix=/usr    \
            --disable-static \
            --docdir=/usr/share/doc/libogg-1.3.5 &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Library: libogg.so
Installed Directories: /usr/include/ogg and /usr/share/doc/libogg-1.3.5

Short Descriptions

libogg.so

provides the functions required for programs to read or write Ogg formatted bit streams

Last updated on

libquicktime-1.2.4

Introduction to libquicktime

The libquicktime package contains the libquicktime library, various plugins and codecs, along with graphical and command line utilities used for encoding and decoding QuickTime files. This is useful for reading and writing files in the QuickTime format. The goal of the project is to enhance, while providing compatibility with the Quicktime 4 Linux library.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

libquicktime Dependencies

Optional

alsa-lib-1.2.6.1, Doxygen-1.9.3, FAAC-1_30, FAAD2-2_10_0, FFmpeg-4.4.1, GTK+-2.24.33, LAME-3.100, libdv-1.0.0, libjpeg-turbo-2.1.2, libpng-1.6.37, libvorbis-1.3.7, x264-20220219, Xorg Libraries, and Schroedinger

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libquicktime

Installation of libquicktime

Install libquicktime by running the following commands:

patch -Np1 -i ../libquicktime-1.2.4-ffmpeg4-1.patch &&

./configure --prefix=/usr     \
            --enable-gpl      \
            --without-doxygen \
            --docdir=/usr/share/doc/libquicktime-1.2.4
make

This package does not come with a test suite.

Now, as the root user:

make install &&

install -v -m755 -d /usr/share/doc/libquicktime-1.2.4 &&
install -v -m644    README doc/{*.txt,*.html,mainpage.incl} \
                    /usr/share/doc/libquicktime-1.2.4

Command Explanations

--enable-gpl: Changes the licence to GPL. This enables some extra plugins, such as FAAC, FAAD2, and x264.

--without-doxygen: This is necessary if you do not have Doxygen, omit this if it is installed and you wish the API documentation installed.

--with-libdv: Build with libdv support. Not enabled by default.

Contents

Installed Programs: libquicktime_config, lqtplay, lqtremux, lqt_transcode, qt2text, qtdechunk, qtdump, qtinfo, qtrechunk, qtstreamize, and qtyuv4toyuv
Installed Libraries: libquicktime.so and several plugin codec libraries
Installed Directories: /usr/include/lqt, /usr/lib/libquicktime, and /usr/share/doc/libquicktime-1.2.4

Short Descriptions

libquicktime_config

is a graphical front end to examine and configure the available libquicktime audio and video codecs

lqtplay

is a simple QuickTime movie player for X Window System

lqt_transcode

is a command-line program used to encode video and/or audio files from one format to another

qt2text

is used to dump all text strings from a quicktime file

qtdechunk

can take movies containing rgb frames and write them out as ppm images

qtdump

displays the parsed contents of the provided file

qtinfo

prints various pieces of metadata parsed by the libquicktime library for the provided file

qtrechunk

concatenates input frames into a QuickTime movie

qtstreamize

is used to make a file streamable by placing the moov header at the beginning of the file

qtyuv4toyuv

is used to write a YUV4 encoded movie as a planar YUV 4:2:0 file

libquicktime.so

is a library for reading and writing QuickTime files. It provides convenient access to QuickTime files with a variety of supported codecs. The library contains new functions integrated with all the original QuickTime 4 Linux library functions used to encode and decode QuickTime files

Last updated on

libsamplerate-0.2.2

Introduction to libsamplerate

libsamplerate is a sample rate converter for audio.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libsamplerate Dependencies

Optional

alsa-lib-1.2.6.1, libsndfile-1.0.31, and fftw-3.3.10 (for tests)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libsamplerate

Installation of libsamplerate

Install libsamplerate by running the following commands:

./configure --prefix=/usr    \
            --disable-static \
            --docdir=/usr/share/doc/libsamplerate-0.2.2 &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Program: None
Installed Library: libsamplerate.so
Installed Directory: /usr/share/doc/libsamplerate-0.2.2

Last updated on

libsndfile-1.0.31

Introduction to libsndfile

Libsndfile is a library of C routines for reading and writing files containing sampled audio data.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libsndfile Dependencies

Recommended
Optional

alsa-lib-1.2.6.1, Speex-1.2.0, and SQLite-3.37.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libsndfile

Installation of libsndfile

Install libsndfile by running the following commands:

./configure --prefix=/usr    \
            --disable-static \
            --docdir=/usr/share/doc/libsndfile-1.0.31 &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: sndfile-cmp, sndfile-concat, sndfile-convert, sndfile-deinterleave, sndfile-info, sndfile-interleave, sndfile-metadata-get, sndfile-metadata-set, sndfile-play, and sndfile-salvage
Installed Library: libsndfile.so
Installed Directory: /usr/share/doc/libsndfile-1.0.31

Short Descriptions

sndfile-cmp

compares two audio files

sndfile-concat

concatenates two or more audio files

sndfile-convert

converts a sound files from one format to another

sndfile-deinterleave

splits a multi-channel into multiple single channel files

sndfile-info

displays information about a sound file

sndfile-interleave

converts multiple single channel files into a multi-channel file

sndfile-metadata-get

retrieves metadata from a sound file

sndfile-metadata-set

sets metadata in a sound file

sndfile-play

plays a sound file

sndfile-salvage

Salvages the audio data from WAV files which are more than 4G in length

libsndfile.so

contains the libsndfile API functions

Last updated on

libtheora-1.1.1

Introduction to libtheora

libtheora is a reference implementation of the Theora video compression format being developed by the Xiph.Org Foundation.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libtheora Dependencies

Required

libogg-1.3.5

Recommended
Optional

SDL-1.2.15 and libpng-1.6.37 (both to build the example players), Doxygen-1.9.3, texlive-20210325 (or install-tl-unx), BibTex, and Transfig (all four to build the API documentation), and Valgrind-3.18.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Libtheora

Installation of libtheora

Install libtheora by running the following commands:

sed -i 's/png_\(sizeof\)/\1/g' examples/png2theora.c &&
./configure --prefix=/usr --disable-static &&
make

If you wish to run the tests, issue: make check.

Now, as the root user:

make install

If you wish to install the examples (so that you can hack on theora), install them as the root user:

cd examples/.libs &&
for E in *; do
  install -v -m755 $E /usr/bin/theora_${E}
done

Command Explanations

sed -i 's/png_\(sizeof\)/\1/g' examples/png2theora.c: This sed fixes build with libpng 1.6.

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None, unless you installed the examples
Installed Libraries: libtheora.so, libtheoraenc.so, and libtheoradec.so
Installed Directories: /usr/include/theora and /usr/share/doc/libtheora-1.1.1

Short Descriptions

libtheora*.so

contains the functions to read and write video files

Last updated on

libvorbis-1.3.7

Introduction to libvorbis

The libvorbis package contains a general purpose audio and music encoding format. This is useful for creating (encoding) and playing (decoding) sound in an open (patent free) format.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libvorbis Dependencies

Required

libogg-1.3.5

Optional

Doxygen-1.9.3 and texlive-20210325 (or install-tl-unx) (specifically, pdflatex and htlatex) to build the PDF documentation

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Libvorbis

Installation of libvorbis

Install libvorbis by running the following commands:

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check.

Now, as the root user:

make install &&
install -v -m644 doc/Vorbis* /usr/share/doc/libvorbis-1.3.7

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-docs: This switch enables building the documentation in formats other than the supplied html.

Contents

Installed Programs: None
Installed Libraries: libvorbis.so, libvorbisenc.so and libvorbisfile.so
Installed Directories: /usr/include/vorbis and /usr/share/doc/libvorbis-1.3.7

Short Descriptions

libvorbis.so

provides the functions used to read and write sound files

Last updated on

libvpx-1.11.0

Introduction to libvpx

This package, from the WebM project, provides the reference implementations of the VP8 Codec, used in most current html5 video, and of the next-generation VP9 Codec.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libvpx Dependencies

Recommended
Optional

cURL-7.81.0 (to download test files) and Doxygen-1.9.3 (to build documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libvpx

Installation of libvpx

Install libvpx by running the following commands:

sed -i 's/cp -p/cp/' build/make/Makefile &&

mkdir libvpx-build            &&
cd    libvpx-build            &&

../configure --prefix=/usr    \
             --enable-shared  \
             --disable-static &&
make

To test the results, issue: LD_LIBRARY_PATH=. make test. The test suite downloads several files as part of its test process.

Now, as the root user:

make install

Command Explanations

sed ... : This command corrects ownership and permissions of installed files.

mkdir libvpx-build && cd libvpx-build: The libvpx developers recommend building in a dedicated build directory.

--disable-vp8: This switch prevents building of VP8 codec support.

--disable-vp9: This switch prevents building of VP9 codec support.

--disable-static: This switch prevents installation of static versions of the libraries.

--target=generic-gnu: This switch disables optimizations specific for x86 and x86-64, allowing to build this package without nasm and yasm installed.

LD_LIBRARY_PATH=.: This is needed for the testsuite to use the just built library.

Contents

Installed Programs: vpxdec and vpxenc
Installed Libraries: libvpx.so
Installed Directories: /usr/include/vpx

Short Descriptions

vpxdec

is the WebM Project VP8 and VP9 decoder

vpxenc

is the WebM project VP8 and VP9 encoder

libvpx.so

provides functions to use the VP8 and VP9 video codecs

Last updated on

MLT-7.4.0

Introduction to MLT

MLT package is the Media Lovin Toolkit. It is an open source multimedia framework, designed and developed for television broadcasting. It provides a toolkit for broadcasters, video editors, media players, transcoders, web streamers and many more types of applications.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

MLT Dependencies

Required

frei0r-plugins-1.7.0 and Qt-5.15.2

Optional

Doxygen-1.9.3, fftw-3.3.10, libexif-0.6.24, SDL-1.2.15, SDL2-2.0.20, JACK, MOVEit, SoX, and vid.stab

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/mlt

Installation of MLT

Install MLT by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_BUILD_TYPE=Release  \
      -Wno-dev .. &&

make

This package does not come with a test suite. However a test .mp4 file can be played in a local graphical environment with ./src/melt/melt <filename>.mp4.

Note

This application uses advanced graphical capabilities. In some cases, firmware for your specific graphics adaptor may be needed. See the section called “Firmware for Video Cards” for more information.

Now, as the root user:

make install

Contents

Installed Program: melt-7 and melt (symlink to melt-7)
Installed Libraries: libmlt-7.so, libmlt++-7.so, and over twenty plugins
Installed Directories: /usr/include/mlt-7, /usr/include/melt-7/mlt++, /usr/include/melt-7/framework, /usr/lib/mlt-7, /usr/lib/cmake/Mlt7, and /usr/share/mlt-7

Short Descriptions

melt

is a test tool for MLT

Last updated on

Opus-1.3.1

Introduction to Opus

Opus is a lossy audio compression format developed by the Internet Engineering Task Force (IETF) that is particularly suitable for interactive speech and audio transmission over the Internet. This package provides the Opus development library and headers.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Optional

Doxygen-1.9.3 and texlive-20210325 (or install-tl-unx)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Opus

Installation of Opus

Install Opus by running the following commands:

./configure --prefix=/usr    \
            --disable-static \
            --docdir=/usr/share/doc/opus-1.3.1 &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Library: libopus.so
Installed Directory: /usr/include/opus and /usr/share/doc/opus-1.3.1

Short Descriptions

libopus.so

provides the functions used to read and write Opus format

Last updated on

Pipewire-0.3.47

Introduction to Pipewire

The pipewire package contains a server and user-space API to handle multimedia pipelines. This includes a universal API to connect to multimedia devices, as well as sharing multimedia files between applications.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Pipewire Dependencies

Recommended
Optional

Valgrind-3.18.1, Doxygen-1.9.3 and Graphviz-2.50.0 (for documentation), JACK, ldacBT, libcamera, Vulkan, and xmltoman

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pipewire

Installation of Pipewire

Install pipewire by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr --buildtype=release -Dsession-managers= .. &&
ninja

To test the result, issue: ninja test.

Now, as the root user:

ninja install

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dsession-managers=: This switch prevents automatic downloading external dependencies.

-Ddocs=true: This switch enables the generation of HTML documentation. The optional dependencies for documentation need to be installed for this to work.

-Dman=true: This switch enables the generation of manual pages. The optional dependencies for documentation need to be installed for this to work.

Contents

Installed Programs: pipewire, pipewire-media-session, pipewire-pulse, pw-cat, pw-cli, pw-dot, pw-dump, pw-jack, pw-link, pw-loopback, pw-metadata, pw-mididump, pw-mon, pw-profiler, pw-reserve, pw-top, pw-v4l2, spa-acp-tool, spa-inspect, spa-json-dump, spa-monitor, spa-resample, and pw-dsdplay, pw-midiplay, pw-midirecord, pw-play, and pw-record (symlinks to pw-cat)
Installed Libraries: libpipewire-0.3.so and 30 modules below /usr/lib/pipewire-0.3
Installed Directories: /etc/pipewire, /usr/include/pipewire-0.3, /usr/include/spa-0.2, /usr/lib/alsa-lib, /usr/lib/gstreamer-1.0, /usr/lib/pipewire-0.3, and /usr/lib/spa-0.2

Short Descriptions

pipewire

is a service that allows access to multimedia devices and allows sharing of multimedia files between applications

pipewire-media-session

is a service that allows a desktop environment to know when media files are being played through pipewire

pipewire-pulse

starts a Pulseaudio-compatible version of the pipewire service

pw-cat

allows you to play or record media using a pipewire instance

pw-cli

allows you to interact with a pipewire instance

pw-dot

lists all of the daemons and objects in use by pipewire

pw-dump

dumps debug messages from a local or remote pipewire instance to the console

pw-jack

runs JACK applications on a pipewire instance

pw-link

links pipewire ports together

pw-loopback

initializes a loopback link between two different pipewire ports. This is useful for testing and debugging

pw-metadata

inspects, adds, and removes metadata for objects

pw-mididump

dumps MIDI messages from a file to the screen

pw-mon

allows you to monitor pipewire instances

pw-profiler

tracks memory usage and API calls used by pipewire

pw-reserve

reserves or monitors a device via D-Bus

pw-top

displays real-time performance information from pipewire

pw-v4l2

runs v4l2 applications on a pipewire instance

spa-acp-tool

inspects the card profile of a given sound card

spa-inspect

allows you to inspect pipewire plugins

spa-json-dump

dumps the current pipewire configuration in JSON format.

spa-monitor

allows you to monitor pipewire plugins

spa-resample

resamples a given file

libpipewire-0.3.so

contains API functions for handling multimedia pipelines

Last updated on

PulseAudio-15.0

Introduction to PulseAudio

PulseAudio is a sound system for POSIX OSes, meaning that it is a proxy for sound applications. It allows you to do advanced operations on your sound data as it passes between your application and your hardware. Things like transferring the audio to a different machine, changing the sample format or channel count and mixing several sounds into one are easily achieved using a sound server.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

PulseAudio Dependencies

Required

libsndfile-1.0.31

Recommended
Optional

Avahi-0.8, BlueZ-5.63, Doxygen-1.9.3 (for documentation), fftw-3.3.10, GTK+-3.24.31, libsamplerate-0.2.2, SBC-1.5 (Bluetooth support), Valgrind-3.18.1, JACK, libasyncns, LIRC, ORC, soxr, TDB, and WebRTC AudioProcessing

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pulseaudio

Installation of PulseAudio

Install PulseAudio by running the following commands:

mkdir build &&
cd    build &&

meson --prefix=/usr       \
      --buildtype=release \
      -Ddatabase=gdbm     \
      -Ddoxygen=false     \
      -Dbluez5=disabled   &&
ninja

To test the results, issue: ninja test. One test fails if the tests are not run as the root user, but this can be ignored.

Now, as the root user:

ninja install

Running PulseAudio as a system-wide daemon is possible but not recommended. See https://www.freedesktop.org/wiki/Software/PulseAudio/Documentation/User/SystemWide/ for more information. While still as the root user, remove the D-Bus configuration file for the system wide daemon to avoid creating unnecessary system users and groups:

rm -fv /etc/dbus-1/system.d/pulseaudio-system.conf

Command Explanations

--buildtype=release: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

-Dbluez5=disabled: This switch prevents a runtime error if dbus-1.12.20 and SBC-1.5 are both installed but BlueZ-5.63 is not installed. Remove this if you have installed all three packages.

-Ddoxygen=false: This allows the package to compile if Doxygen-1.9.3 is not installed. Remove this if you have installed this and wish to build the documentation.

Configuring PulseAudio

Config Files

There are system wide configuration files: /etc/pulse/daemon.conf, /etc/pulse/client.conf, /etc/pulse/default.pa, and user configuration files with the same names in ~/.config/pulse. User configuration files take precedence over system wide ones.

Configuration Information

You may have to configure the audio system. You can start pulseaudio in command line mode using pulseaudio -C and then list various information and change settings. See man pulse-cli-syntax.

If pulseaudio was working but you no-longer have sound, after checking for hardware issues (speakers or headphones not connected, external amplifier not connected) you may need to fix it.

One suggestion is to close the application, such as firefox where sound has stopped working, then run: pactl list short sinks followed by: pacmd set-default-sink <sink #> and then restart the application.

If that does not work, a more drastic approach often works. After closing the application, close pulseaudio, either using pulseaudio --kill or, if that fails, killall -KILL pulseaudio and then rm -rf ~/.config/pulse/* (and perhaps also rm -rf ~/.pulse/* if you have used a very old version of pulse on this machine), then run pulseaudio --verbose to restart it. If the daemon starts, restart the application. See man pulseaudio for more options.

Contents

Installed Programs: pacat, pacmd, pactl, padsp, pamon (symlink to pacat), paplay (symlink to pacat), parec (symlink to pacat), parecord (symlink to pacat), qpaeq, pasuspender, pax11publish, pulseaudio, and start-pulseaudio-x11
Installed Libraries: libpulse.so, libpulse-mainloop-glib.so, libpulse-simple.so, libpulsecommon-15.0.so, libpulsecore-15.0.so, and libpulsedsp.so
Installed Directories: /etc/pulse, /usr/include/pulse, /usr/lib/cmake/PulseAudio, /usr/lib/{pulseaudio,pulse-15.0}, /usr/libexec/pulse, and /usr/share/pulseaudio

Short Descriptions

pacat

plays back or records raw or encoded audio streams on a PulseAudio sound server

pacmd

is a tool used to reconfigure a PulseAudio sound server during runtime

pactl

is used to control a running PulseAudio sound server

padsp

is the PulseAudio OSS Wrapper

pamon

is a symbolic link to pacat

paplay

is used to play audio files on a PulseAudio sound server

parec

is a symbolic link to pacat

parecord

is a symbolic link to pacat

pasuspender

is a tool that can be used to tell a local PulseAudio sound server to temporarily suspend access to the audio devices, to allow other applications to access them directly

pax11publish

is the PulseAudio X11 Credential Utility

pa-info

is a shell script that prints various information relating to the Pulseaudio server currently in use

pulseaudio

is a networked low-latency sound server for Linux

qpaeq

is an equalizer interface for PulseAudio equalizer sinks (Requires fftw-3.3.10 at build time)

start-pulseaudio-x11

starts PulseAudio and registers it to the X11 session manager

Last updated on

SBC-1.5

Introduction to SBC

The SBC is a digital audio encoder and decoder used to transfer data to Bluetooth audio output devices like headphones or loudspeakers.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

SBC Dependencies

Optional

libsndfile-1.0.31

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/sbc

Installation of SBC

Install SBC by running the following commands:

./configure --prefix=/usr --disable-static --disable-tester &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-tester: This disables the SBC tester. Remove it if you have installed libsndfile-1.0.31.

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: sbcdec, sbcenc, and sbcinfo
Installed Library: libsbc.so
Installed Directory: /usr/include/sbc

Short Descriptions

sbcdec

is a SBC decoder utility

sbcenc

is a SBC encoder utility

sbcinfo

is a subband codec (SBC) analyzer

libsbc.so

contains the SBC API functions

Last updated on

SDL-1.2.15

Introduction to SDL

The Simple DirectMedia Layer (SDL for short) is a cross-platform library designed to make it easy to write multimedia software, such as games and emulators.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

SDL Dependencies

Recommended
Optional

AAlib-1.4rc5, ALSA-1.2.6, GLU-9.0.2, NASM-2.15.05, PulseAudio-15.0, Pth-2.0.7, a graphical environment, DirectFB, GGI, libcaca, PicoGUI, and SVGAlib

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/sdl

Installation of SDL

Install SDL by running the following commands:

sed -e '/_XData32/s:register long:register _Xconst long:' \
    -i src/video/x11/SDL_x11sym.h &&

./configure --prefix=/usr --disable-static &&

make

Now, as the root user:

make install &&

install -v -m755 -d /usr/share/doc/SDL-1.2.15/html &&
install -v -m644    docs/html/*.html \
                    /usr/share/doc/SDL-1.2.15/html

Testing SDL

If you wish to, test the installation of SDL using the included test programs. It is not required to install any of the resulting binaries to validate the installation. Issue the following commands to build the test programs:

cd test &&
./configure &&
make

You'll need to manually run all the test programs (they are listed in the README file in this directory). Many of them will need to be manually killed, and you'll need to turn your speakers on with the volume at a suitable level.

Command Explanations

sed -e ...: This command fixes compilation with libX11-1.6.0 and later.

--disable-static: This switch prevents installation of static versions of the libraries.

--disable-alsa-shared: This switch disables dynamically loading ALSA shared libraries.

--disable-sdl-dlopen: This switch disables using dlopen for shared object loading. Loading image backend libraries like libpng dynamically on the fly does not work.

--disable-x11-shared: This switch disables dynamically loading X11 shared libraries.

Configuring SDL

Configuration Information

As with most libraries, there is no configuration to do, save that the library directory, i.e., /opt/lib or /usr/local/lib should appear in /etc/ld.so.conf so that ldd can find the shared libraries. After checking that this is the case, /sbin/ldconfig should be run while logged in as root.

Contents

Installed Program: sdl-config
Installed Libraries: libSDL.so and libSDLmain.a
Installed Directories: /usr/include/SDL and /usr/share/doc/SDL-1.2.15

Short Descriptions

sdl-config

determines the compile and linker flags that should be used to compile and link programs that use libSDL

libSDL.so

contains functions that provide low level access to audio, keyboard, mouse, joystick, 3D hardware via OpenGL, and 2D frame buffer across multiple platforms

Last updated on

SDL2-2.0.20

Introduction to SDL2

The Simple DirectMedia Layer Version 2 (SDL2 for short) is a cross-platform library designed to make it easy to write multimedia software, such as games and emulators.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://www.libsdl.org/release/SDL2-2.0.20.tar.gz

  • Download MD5 sum: a53acc02e1cca98c4123229069b67c9e

  • Download size: 6.9 MB

  • Estimated disk space required: 173 MB (with docs)

  • Estimated build time: 0.5 SBU (using parallelism=4; with docs)

SDL2 Dependencies

Recommended
Optional

ALSA-1.2.6, Doxygen-1.9.3 (to create documentation), ibus-1.5.25, NASM-2.15.05, PulseAudio-15.0, libsamplerate-0.2.2, a graphical environment, DirectFB, and fcitx

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/sdl

Installation of SDL2

Install SDL2 by running the following commands:

./configure --prefix=/usr &&
make

If you have Doxygen-1.9.3 installed and want to build the html documentation, run the following commands:

pushd docs  &&
  doxygen   &&
popd

Note

If you wish to build and run the package regression tests, do not delete the static libraries below until after the tests are built.

Now, as the root user:

make install              &&
rm -v /usr/lib/libSDL2*.a

If you built the documentation, install it as the root user:

install -v -m755 -d        /usr/share/doc/SDL2-2.0.20/html &&
cp -Rv  docs/output/html/* /usr/share/doc/SDL2-2.0.20/html

Testing SDL2

If you wish to, test the installation of SDL2 using the included test programs. None of the resulting binaries need to be installed. Issue the following commands to build the test programs:

cd test &&
./configure &&
make

Each of the test programs (they are listed in the README file in this directory) will need to be run individually. Many of them will need to be manually killed. Additionally, speakers need to be on with the volume at a suitable level.

Command Explanations

rm -v /usr/lib/libSDL2*.a: Normally static libraries can be disabled with a --disable-static option to configure, but that breaks the build in this package.

--disable-alsa-shared: This switch disables dynamically loading ALSA shared libraries.

--disable-sdl-dlopen: This switch disables using dlopen for shared object loading. Loading image backend libraries like libpng dynamically on the fly does not work.

--disable-x11-shared: This switch disables dynamically loading X11 shared libraries.

Configuring SDL2

Configuration Information

As with most libraries, there is no configuration to do, save that the library directory, i.e., /opt/lib or /usr/local/lib should appear in /etc/ld.so.conf so that ldd can find the shared libraries. After checking that this is the case, /sbin/ldconfig should be run while logged in as root.

Contents

Installed Program: sdl2-config
Installed Libraries: libSDL2.so
Installed Directories: /usr/include/SDL2 and /usr/share/doc/SDL-2.0.20

Short Descriptions

sdl2-config

determines the compile and linker flags that should be used to compile and link programs that use libSDL2

libSDL2.so

contains functions that provide low level access to audio, keyboard, mouse, joystick, 3D hardware via OpenGL, and 2D frame buffer across multiple platforms

Last updated on

sound-theme-freedesktop-0.8

Introduction to Sound Theme Freedesktop

The Sound Theme Freedesktop package contains sound themes for the desktop.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/sound-theme-freedesktop

Installation of Sound Theme Freedesktop

Install Sound Theme Freedesktop by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: None
Installed Libraries: None
Installed Directories: /usr/share/sounds/freedesktop

Last updated on

SoundTouch-2.3.1

Introduction to SoundTouch

The SoundTouch package contains an open-source audio processing library that allows changing the sound tempo, pitch and playback rate parameters independently from each other.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/soundtouch

Installation of SoundTouch

Install SoundTouch by running the following commands:

Caution

The bootstrap command below fails if the ACLOCAL environment variable is set as specified in Xorg-7. If it is used, ACLOCAL needs to be unset for this package and then reset for other packages.

./bootstrap &&
./configure --prefix=/usr \
            --docdir=/usr/share/doc/soundtouch-2.3.1 &&
make

This package does not come with a test suite.

Now, as the root user:

make install 

Command Explanations

--enable-openmp: This switch adds support for running the algorithms in parallel across several processor cores using OpenMP implementation provided by GCC.

Contents

Installed Program: soundstretch
Installed Library: libSoundTouch.so
Installed Directories: /usr/include/soundtouch and /usr/share/doc/soundtouch-2.3.1

Short Descriptions

soundstretch

is a program for processing WAV audio files by modifying sound tempo, pitch and playback rate properties independently from each other

libSoundTouch.so

contains SoundTouch API functions

Last updated on

Speex-1.2.0

Introduction to Speex

Speex is an audio compression format designed especially for speech. It is well-adapted to internet applications and provides useful features that are not present in most other CODECs.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Speex Dependencies

Required

libogg-1.3.5

Optional

Valgrind-3.18.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/speex

Installation of Speex

This package consists of two separate tarballs. They need to be extracted and built independently.

Install Speex by running the following commands:

./configure --prefix=/usr    \
            --disable-static \
            --docdir=/usr/share/doc/speex-1.2.0 &&
make

This package does not come with a test suite.

As the root user:

make install

Now extract and install the speexdsp package:

cd ..                          &&
tar -xf speexdsp-1.2.0.tar.gz &&
cd speexdsp-1.2.0             &&

./configure --prefix=/usr    \
            --disable-static \
            --docdir=/usr/share/doc/speexdsp-1.2.0 &&
make

Again, as the root user:

make install

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-binaries: Builds two binaries to encode and decode to and from the speex format.

Contents

Installed Programs: (optional) speexenc and speexdec
Installed Libraries: libspeex.so and libspeexdsp.so
Installed Directories: /usr/include/speex and /usr/share/doc/speex-1.2.0

Short Descriptions

speexdec

decodes a Speex file and produces a WAV or raw file

speexenc

encodes a WAV or raw files using Speex

libspeex.so

provides functions for the audio encoding/decoding programs

libspeexdsp.so

is a speech processing library that goes along with the Speex codec

Last updated on

Taglib-1.12

Introduction to Taglib

Taglib is a library used for reading, writing and manipulating audio file tags and is used by applications such as Amarok and VLC.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Taglib Dependencies

Required

CMake-3.22.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/taglib

Installation of Taglib

Install Taglib by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr \
      -DCMAKE_BUILD_TYPE=Release  \
      -DBUILD_SHARED_LIBS=ON \
      .. &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: taglib-config
Installed Libraries: libtag.so and libtag_c.so
Installed Directories: /usr/include/taglib

Short Descriptions

taglib-config

is a tool used to print information about the taglib installation

Last updated on

v4l-utils-1.22.1

Introduction to v4l-utils

v4l-utils provides a series of utilities for media devices, allowing to handle the proprietary formats available at most webcams (libv4l), and providing tools to test V4L devices.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

v4l-utils Dependencies

Required

LLVM-13.0.1 (with target BPF)

Recommended
Optional

Doxygen-1.9.3 and SDL2-2.0.20

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/v4l-utils

Installation of v4l-utils

Install v4l-utils by running the following commands:

./configure --prefix=/usr     \
            --sysconfdir=/etc \
            --disable-static  &&
make

This package does not come with a testsuite.

Now, as the root user:

make -j1 install

Contents

Installed Programs: cec-compliance, cec-ctl, cec-follower, cx18-ctl, decode_tm6000, dvb-fe-tool, dvb-format-convert, dvbv5-daemon, dvbv5-scan, dvbv5-zap, ir-ctl, ir-keytable, ivtv-ctl, media-ctl, qv4l2, qvidcap, rds-ctl, v4l2-compliance, v4l2-ctl, v4l2-dbg, and v4l2-sysfs-path
Installed Library: libdvbv5.so, libv4l1.so, libv4l2.so, libv4l2rds.so, libv4lconvert.so, v4l1compat.so, and v4l2convert.so
Installed Directories: /etc/rc_keymaps, /lib/udev/rc_keymaps, /usr/include/libdvbv5, and /usr/lib/libv4l

Short Descriptions

cx18-ctl

is a tool to handle cx18 based devices

decode_tm6000

decodes multiplexed formats from TM5600/TM6000 USB devices

dvb-fe-tool

is a command line tool for digital TV services

dvb-format-convert

is a tool meant to convert among different file formats. It is compliant with version 5 of the DVB API

dvbv5-scan

is a command line frequency scanning tool for digital TV services that are compliant with version 5 of the DVB API

dvbv5-zap

is a command line tuning tool for digital TV services that is compliant with version 5 of the DVB API

ir-keytable

is a tool that lists the Remote Controller devices, allows one to get/set IR keycode/scancode tables, test events generated by IR, and to adjust other Remote Controller options

ivtv-ctl

is a utility that can control many card settings, like changing the inputs from tuner to svideo or composite, setting video resolution or changing video mode (PAL, SECAM, NTSC)

media-ctl

is a utility used to configure V4L2 devices

qv4l2

is used to test video4linux capture devices

qvidcap

is used to capture video from a V4L2 device

rds-ctl

is a utility for decoding raw RDS data from V4L2 Radio devices and offers simple ways to access the received RDS information

v4l2-compliance

is a compliance test tool

v4l2-ctl

is a tool to control v4l2 controls from the cmdline

v4l2-dbg

is a tool to directly get and set registers of v4l2 devices

v4l2-sysfs-path

checks the media devices installed on a machine and the corresponding device nodes

Last updated on

x264-20220219

Introduction to x264

x264 package provides a library for encoding video streams into the H.264/MPEG-4 AVC format.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

x264 Dependencies

Recommended
Optional

ffms2, gpac or liblsmash

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/x264

Installation of x264

Install x264 by running the following commands:

./configure --prefix=/usr \
            --enable-shared \
            --disable-cli &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--disable-cli: This switch disables building the command-line encoder which is redundant since it requires FFmpeg for most of the input formats.

--disable-asm: Use this switch if you didn't install NASM.

Contents

Installed Programs: None
Installed Library: libx264.so
Installed Directory: None

Short Descriptions

libx264.so

provides the functions used to encode video streams into the H.264/MPEG-4 AVC format

Last updated on

x265-20220219

Introduction to x265

x265 package provides a library for encoding video streams into the H.265/HEVC format.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

x265 Dependencies

Required

CMake-3.22.2

Recommended
Optional

numactl

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/x265

Installation of x265

Install x265 by running the following commands:

mkdir bld &&
cd    bld &&

cmake -DCMAKE_INSTALL_PREFIX=/usr ../source &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&
rm -vf /usr/lib/libx265.a 

Command Explanations

rm -vf /usr/lib/libx265.a: BLFS does not recommend using static libraries.

Contents

Installed Program: x265
Installed Library: libx265.so
Installed Directories: None

Short Descriptions

libx265.so

provides the functions used to encode video streams into the H.265/HEVC format

Last updated on

xine-lib-1.2.11

Introduction to Xine Libraries

The Xine Libraries package contains xine libraries. These are useful for interfacing with external plug-ins that allow the flow of information from the source to the audio and video hardware.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Xine Libraries Dependencies

Required

a graphical environment, FFmpeg-4.4.1, and at least one of: ALSA-1.2.6, PulseAudio-15.0, or JACK

Recommended
Optional

AAlib-1.4rc5, FAAD2-2_10_0, FLAC-1.3.3, gdk-pixbuf-2.42.6, GLU-9.0.2, ImageMagick-7.1.0-25, liba52-0.7.4, libdvdcss-1.4.3, libmad-0.15.1b, libmng-2.0.3, libnsl-2.0.0, libtheora-1.1.1, libva-2.13.0 (requires GLU-9.0.2), libvdpau-1.4, libvorbis-1.3.7, libvpx-1.11.0, Mesa-21.3.6, Samba-4.15.5, SDL-1.2.15, Speex-1.2.0, Doxygen-1.9.3 (to create the API documentation), v4l-utils-1.22.1 DirectFB, libbluray, libcaca, libdca, libFAME, libmodplug, musepack, VCDImager, and WavPack,

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xine-lib

Installation of Xine Libraries

Install Xine Libraries by running the following commands:

./configure --prefix=/usr          \
            --disable-vcd          \
            --with-external-dvdnav \
            --docdir=/usr/share/doc/xine-lib-1.2.11 &&
make

To create the API documentation, Doxygen must be installed and issue the following command:

doxygen doc/Doxyfile

This package does not come with a test suite.

Now, as the root user:

make install

Note

When installing, the Makefile does some additional linking. If you do not have Xorg in /usr, the LIBRARY_PATH variable needs to be defined for the root user. If using sudo to assume root, use the -E option to pass your current environment variables for the install process.

If you built the API documentation, issue the following commands as the root user to install it:

install -v -m755 -d /usr/share/doc/xine-lib-1.2.11/api &&
install -v -m644    doc/api/* \
                    /usr/share/doc/xine-lib-1.2.11/api

Command Explanations

--disable-vcd: This switch is required to compile Xine Lib without VCDImager installed. Remove this option if you have installed VCDImager.

--with-external-dvdnav: This switch is required, because internal libraries cannot decrypt DVD.

--docdir=/usr/share/doc/xine-lib-1.2.11: This switch causes the documentation to be installed into a versioned directory instead of the default /usr/share/doc/xine-lib.

--disable-vaapi: use this switch if libva-2.13.0 is installed and GLU-9.0.2 is not, to prevent a build failure.

Contents

Installed Programs: xine-config and xine-list-1.2
Installed Libraries: libxine.so and numerous plugin modules and video extensions under /usr/lib/xine/plugins/2.8
Installed Fonts: Output display engine fonts located in /usr/share/xine-lib/fonts
Installed Directories: /usr/include/xine, /usr/lib/xine, /usr/share/xine-lib, and /usr/share/doc/xine-lib-1.2.11

Short Descriptions

xine-config

provides information to programs trying to link with the xine libraries

xine-list-1.2

is used to get supported filetype information from xine-lib

libxine.so

provides the API for processing audio/video files

Last updated on

XviD-1.3.7

Introduction to XviD

XviD is an MPEG-4 compliant video CODEC.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

XviD Dependencies

Optional

yasm-1.3.0 or NASM-2.15.05

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xvid

Installation of XviD

Note

This package tarball expands to xvidcore, not the expected xvidcore-1.3.7.

Install XviD by running the following commands:

cd build/generic &&
sed -i 's/^LN_S=@LN_S@/& -f -v/' platform.inc.in &&
./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

sed -i '/libdir.*STATIC_LIB/ s/^/#/' Makefile &&
make install &&

chmod -v 755 /usr/lib/libxvidcore.so.4.3 &&
install -v -m755 -d /usr/share/doc/xvidcore-1.3.7/examples &&
install -v -m644 ../../doc/* /usr/share/doc/xvidcore-1.3.7 &&
install -v -m644 ../../examples/* \
    /usr/share/doc/xvidcore-1.3.7/examples

Command Explanations

sed -i 's/^LN_S=@LN_S@/& -f -v/' platform.inc.in: Fix error during make install if reintalling or upgrading.

sed -i '/libdir.*STATIC_LIB/ s/^/#/' Makefile: This command disables installing the static library.

Contents

Installed Programs: None
Installed Library: libxvidcore.so
Installed Directory: /usr/share/doc/xvidcore-1.3.7

Short Descriptions

libxvidcore.so

provides functions to encode and decode most MPEG-4 video data

Last updated on

Chapter 43. Audio Utilities

This chapter contains programs involved with audio file manipulation; that is to say playing, recording, ripping and the other common things which people want to do. It also includes a package used to render text to speech using your system's audio hardware. To use much of this software, you will need to have the kernel sound drivers installed.

Audacious-4.1

Introduction to Audacious

Audacious is an audio player.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Required Plugins

Audacious Dependencies

Required

GTK+-2.24.33 or Qt-5.15.2 (or both), libxml2-2.9.13 (plugins), Xorg build environment (plugins), and a graphical environment (runtime)

Recommended

ALSA-1.2.6 and dbus-1.12.20, also gnome-icon-theme-3.12.0 (runtime)

Optional

libarchive-3.6.0 and Valgrind-3.18.1

Recommended (for Plugins)
Optional (for Plugins)

cURL-7.81.0, FAAD2-2_10_0, FFmpeg-4.4.1, FLAC-1.3.3, LAME-3.100, libcdio-2.1.0 (to identify and play CDs), libnotify-0.7.9, libsamplerate-0.2.2, libsndfile-1.0.31, libvorbis-1.3.7, PulseAudio-15.0, SDL-1.2.15, ampache-browser, adplug, The Bauer stereophonic-to-binaural DSP (bs2b) library, FluidSynth, JACK (requires libsamplerate-0.2.2), libcue, libmodplug, libmms, libopenmpt, libsidplayfp, LIRC, sndio, SoX, and WavPack

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/audacious

Installation of Audacious

Installation of the Main Audacious Program

Install Audacious by running the following commands (you may wish to change the stamp to another string):

TPUT=/bin/true ./configure --prefix=/usr \
                           --with-buildstamp="BLFS" &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Installation of Audacious Plugins

Install the required plugins package by issuing the following commands:

tar -xf ../audacious-plugins-4.1.tar.bz2                &&
cd audacious-plugins-4.1                                &&
TPUT=/bin/true ./configure --prefix=/usr --disable-wavpack &&
make

Now, as the root user:

make install

Note

This package installs icon files into the /usr/share/icons/hicolor hierarchy and desktop files into the /usr/share/applications hierarchy. You can improve system performance and memory usage by updating /usr/share/icons/hicolor/index.theme and /usr/share/applications/mimeinfo.cache. To perform the update you must have GTK+-2.24.33 or GTK+-3.24.31 installed (for the icon cache) and desktop-file-utils-0.26 (for the desktop cache) and issue the following commands as the root user:

gtk-update-icon-cache -qtf /usr/share/icons/hicolor &&
update-desktop-database -q

Command Explanations

TPUT=/bin/true: the default is for make to output text in color. This is fine if you are building in a terminal, but if you script the build process and pipe the output from make to a log file then the control characters used to color the text can make the logfile unreadable. This option prevents make from coloring the text.

--with-buildstamp: This switch appends the given text to the version string.

--disable-wavpack: This switch is required unless the optional WavPack package is installed.

--enable-gtk: Use this to enable GTK+ support.

--disable-qt: Use this to disable qt support.

--disable-mp3: Use this for the plugins if you have not installed mpg123 and do not wish to play mp3 files.

--enable-valgrind: Allow better Valgrind leak checks.

--disable-neon: Use this for the plugins if you have not installed neon, and do not want to use HTTP/HTTPS transport.

Configuring Audacious

If you prefer the old, smaller Winamp/XMMS interface, click on View> Interface> Winamp Classic Interface.

If you built with both Gtk and Qt user interfaces, the Qt version can be executed from a terminal, issuing audacious --qt. If you wish a desktop menu entry to execute this Qt version, issue the following commands as the root user:

cp -v /usr/share/applications/audacious{,-qt}.desktop &&

sed -e '/^Name/ s/$/ Qt/' \
    -e '/Exec=/ s/audacious/& --qt/' \
    -i /usr/share/applications/audacious-qt.desktop

Contents

Installed Programs: audacious and audtool
Installed Libraries: libaudcore.so, libaudgui.so, libaudqt.so, libaudtag.so, and several plugin libraries under /usr/lib/audacious/ sub-directories
Installed Directories: /usr/include/{audacious,libaudcore,libaudgui,libaudqt}, /usr/lib/audacious and /usr/share/audacious

Short Descriptions

audacious

is a Qt port of XMMS based on the Beep Media Player

audtool

is a small tool to modify the behavior of a running audacious instance

Last updated on

CDParanoia-III-10.2

Introduction to CDParanoia

The CDParanoia package contains a CD audio extraction tool. This is useful for extracting .wav files from audio CDs. A CDDA capable CDROM drive is needed. Practically all drives supported by Linux can be used.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/cdparanoia

Installation of CDParanoia

Note

This package does not support parallel build.

Install CDParanoia by running the following commands:

patch -Np1 -i ../cdparanoia-III-10.2-gcc_fixes-1.patch &&
./configure --prefix=/usr --mandir=/usr/share/man &&
make -j1

This package does not come with a test suite.

Now, as the root user:

make install &&
chmod -v 755 /usr/lib/libcdda_*.so.0.10.2

Contents

Installed Program: cdparanoia
Installed Libraries: libcdda_interface.{so,a} and libcdda_paranoia.{so,a}
Installed Directories: None

Short Descriptions

cdparanoia

is used for 'ripping' an audio-cd. Ripping is the process of digitally extracting music from an audio CD

libcdda_interface.{so,a}

contains functions used by cdparanoia, as well as other packages, which can automatically identify if a CD device is CDDA compatible

libcdda_paranoia.{so,a}

contains functions used by cdparanoia, as well as other packages, which provide data verification, synchronization, error handling and scratch reconstruction capability

Last updated on

kwave-21.12.2

Introduction to KWave

The KWave package contains a KF5 based Sound Editor application.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

KWave Dependencies

Required

AudioFile-0.3.6, fftw-3.3.10, id3lib-3.8.3, and KDE Frameworks-5.91.0

Recommended
Optional

Doxygen-1.9.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/kwave

Installation of KWave

Install KWave by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=$KF5_PREFIX \
      -DCMAKE_BUILD_TYPE=Release         \
      -DBUILD_TESTING=OFF                \
      -Wno-dev .. &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Programs: kwave
Installed Libraries: libkwave.so, libkwavegui.so, and 29 plugins
Installed Directories: $KF5_PREFIX/lib/plugins/kwave, $KF5_PREFIX/share/kwave, $KF5_PREFIX/share/doc/HTML/*/kwave

Short Descriptions

kwave

is a sound editor built on the KDE Frameworks 5

Last updated on

LAME-3.100

Introduction to LAME

The LAME package contains an MP3 encoder and optionally, an MP3 frame analyzer. This is useful for creating and analyzing compressed audio files.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

LAME Dependencies

Optional

Dmalloc, Electric Fence, libsndfile-1.0.31 and NASM-2.15.05

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/lame

Installation of LAME

Install LAME by running the following commands:

./configure --prefix=/usr --enable-mp3rtp --disable-static &&
make

To test the results, issue: make test.

Now, as the root user:

make pkghtmldir=/usr/share/doc/lame-3.100 install

Command Explanations

--enable-mp3rtp: This switch enables building the encode-to-RTP program.

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-nasm: Enable the use of NASM-2.15.05 to compile optimized assembly routines.

Contents

Installed Programs: lame and mp3rtp
Installed Library: libmp3lame.so
Installed Directories: /usr/include/lame and /usr/share/doc/lame-3.100

Short Descriptions

lame

creates MP3 audio files from raw PCM or .wav data

mp3rtp

is used to encode MP3 with RTP streaming of the output

libmp3lame.so

libraries provide the functions necessary to convert raw PCM and WAV files to MP3 files

Last updated on

mpg123-1.29.3

Introduction to mpg123

The mpg123 package contains a console-based MP3 player. It claims to be the fastest MP3 decoder for Unix.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

mpg123 Dependencies

Recommended
Optional

PulseAudio-15.0, SDL-1.2.15, JACK, OpenAL and PortAudio

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/mpg123

Installation of mpg123

Install mpg123 by running the following commands:

./configure --prefix=/usr &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Contents

Installed Programs: mpg123, mpg123-id3dump, mpg123-strip, and out123
Installed Libraries: libmpg123.so, libout123.so, and libsyn123
Installed Directory: /usr/lib/mpg123

Short Descriptions

mpg123

is used for playing MP3 files via the console

mpg123-id3dump

is a tool to dump ID3 meta data from MPEG audio files using libmpg123

mpg123-strip

extracts only MPEG frames from a stream using libmpg123 (stdin to stdout)

out123

plays raw PCM audio to an output device

libmpg123.so

contains the mpg123 API functions

libout123.so

contains the out123 API functions

Last updated on

pavucontrol-5.0

Introduction to pavucontrol

PulseAudio Volume Control (pavucontrol) is a simple GTK based volume control tool ("mixer") for the PulseAudio sound server. In contrast to classic mixer tools, this one allows you to control both the volume of hardware devices and of each playback stream separately.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

pavucontrol Dependencies

Required

Gtkmm-3.24.5, JSON-GLib-1.6.6, libcanberra-0.30, libsigc++-2.10.8, and PulseAudio-15.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pavucontrol

Installation of pavucontrol

Install pavucontrol by running the following commands:

./configure --prefix=/usr --docdir=/usr/share/doc/pavucontrol-5.0 &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Program: pavucontrol
Installed Libraries: None
Installed Directory: /usr/share/pavucontrol and /usr/share/doc/pavucontrol-5.0

Short Descriptions

pavucontrol

is a GUI configuration tool for sound settings using pulsaudio

Last updated on

pnmixer-0.7.2

Introduction to Pnmixer

The Pnmixer package provides a lightweight volume control with a tray icon.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Pnmixer Dependencies

Required

alsa-utils-1.2.6, GTK+-3.24.31, and libnotify-0.7.9

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/pnmixer

Installation of Pnmixer

Install Pnmixer by running the following commands:

mkdir build &&
cd    build &&

cmake -DCMAKE_INSTALL_PREFIX=/usr ..  &&
make

This package does not have a testsuite.

Now, as the root user:

make install

Contents

Installed Program: pnmixer
Installed Libraries: None
Installed Directories: /usr/share/pnmixer

Short Descriptions

pnmixer

is a lightweight volume control that sits in a tray

Last updated on

vorbis-tools-1.4.2

Introduction to Vorbis Tools

The Vorbis Tools package contains command-line tools useful for encoding, playing or editing files using the Ogg CODEC.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Vorbis Tools Dependencies

Required

libvorbis-1.3.7

Optional (required to build the ogg123 program)

libao-1.2.0

Optional

cURL-7.81.0, FLAC-1.3.3, Speex-1.2.0, and libkate

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/vorbistools

Installation of Vorbis Tools

Install Vorbis Tools by running the following commands:

./configure --prefix=/usr \
            --enable-vcut \
            --without-curl &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

--enable-vcut: This parameter is used so that the vcut program is built as it is not by default.

--without-curl: This parameter disables HTTP streaming in ogg123. Remove this parameter if you have cURL installed.

Configuring Vorbis Tools

Config Files

/etc/libao.conf, ~/.libao and ~/.ogg123rc

Configuration Information

Issue man libao.conf for information about setting the default output device. Also see /usr/share/doc/vorbis-tools-1.4.2/ogg123rc-example .

Contents

Installed Programs: ogg123, oggdec, oggenc, ogginfo, vcut and vorbiscomment
Installed Libraries: None
Installed Directory: /usr/share/doc/vorbis-tools-1.4.2

Short Descriptions

ogg123

is a command-line audio player for Ogg Vorbis streams

oggdec

is a simple decoder which converts Ogg Vorbis files into PCM audio files (WAV or raw)

oggenc

is an encoder that turns raw, WAV or AIFF files into an Ogg Vorbis stream

ogginfo

prints information stored in an audio file

vcut

splits a file into two files at a designated cut point

vorbiscomment

is an editor that changes information in the audio file metadata tags

Last updated on

Chapter 44. Video Utilities

This chapter always seems to be the favorite chapter. It's probably because there is a lot of satisfaction in playing your first video when you have spent so much time getting to that point. All those libraries, all the configurations and your reward is that you finally get to watch a movie. Not to worry though, there is always one more CODEC to install.

FFmpeg-4.4.1

Introduction to FFmpeg

FFmpeg is a solution to record, convert and stream audio and video. It is a very fast video and audio converter and it can also acquire from a live audio/video source. Designed to be intuitive, the command-line interface (ffmpeg) tries to figure out all the parameters, when possible. FFmpeg can also convert from any sample rate to any other, and resize video on the fly with a high quality polyphase filter. FFmpeg can use a Video4Linux compatible video source and any Open Sound System audio source.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (HTTP): https://ffmpeg.org/releases/ffmpeg-4.4.1.tar.xz

  • Download MD5 sum: 41a1ca8693acc56088e8eaf3899b91ea

  • Download size: 9.1 MB

  • Estimated disk space required: 212 MB (add 1.9 GB for the FATE suite/tests, add 1.4 GB for documentation)

  • Estimated build time: 1.4 SBU (using parallelism=4; add 1.1 SBU (with THREADS=4) to run the FATE suite after sample files are downloaded; add 0.8 SBU for doxygen docs)

FFmpeg Dependencies

Recommended
Recommended for desktop use
Optional

Doxygen-1.9.3, Fontconfig-2.13.1, FriBidi-1.0.11, frei0r-plugins-1.7.0, libcdio-2.1.0 (to identify and play CDs), libdrm-2.4.110 (for kmsgrab input), libwebp-1.2.2, opencv-4.5.5, OpenJPEG-2.4.0, GnuTLS-3.7.3, PulseAudio-15.0, Samba-4.15.5, Speex-1.2.0, texlive-20210325 (or install-tl-unx) for PDF and PS documentation, v4l-utils-1.22.1, XviD-1.3.7, a graphical environment, Flite, GSM, libaacplus, libbluray, libcaca, libcelt, libdc1394, libdca, libiec61883, libilbc, libmodplug, libnut (Git checkout), librtmp, libssh, OpenAL, OpenCore AMR, Srt, Schroedinger, TwoLAME, vo-aaenc, vo-amrwbenc, and ZVBI

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/ffmpeg

Installation of FFmpeg

Install FFmpeg by running the following commands:

sed -i 's/-lflite"/-lflite -lasound"/' configure &&

./configure --prefix=/usr        \
            --enable-gpl         \
            --enable-version3    \
            --enable-nonfree     \
            --disable-static     \
            --enable-shared      \
            --disable-debug      \
            --enable-avresample  \
            --enable-libass      \
            --enable-libfdk-aac  \
            --enable-libfreetype \
            --enable-libmp3lame  \
            --enable-libopus     \
            --enable-libtheora   \
            --enable-libvorbis   \
            --enable-libvpx      \
            --enable-libx264     \
            --enable-libx265     \
            --enable-openssl     \
            --docdir=/usr/share/doc/ffmpeg-4.4.1 &&

make &&

gcc tools/qt-faststart.c -o tools/qt-faststart

HTML documentation was built in the previous step. If you have texlive-20210325 installed and wish to build PDF and Postscript versions of the documentation, issue the following commands:

pushd doc &&
for DOCNAME in `basename -s .html *.html`
do
    texi2pdf -b $DOCNAME.texi &&
    texi2dvi -b $DOCNAME.texi &&

    dvips    -o $DOCNAME.ps   \
                $DOCNAME.dvi
done &&
popd &&
unset DOCNAME

If you have Doxygen-1.9.3 installed and you wish to build (if --disable-doc was used) or rebuild the html documentation, issue:

doxygen doc/Doxyfile

The fate-suite tests include comparisons with installed files, and should not be run before the package is installed. Therefore, if you desire to run them, instructions are given further below.

Now, as the root user:

make install &&

install -v -m755    tools/qt-faststart /usr/bin &&
install -v -m755 -d           /usr/share/doc/ffmpeg-4.4.1 &&
install -v -m644    doc/*.txt /usr/share/doc/ffmpeg-4.4.1

If the PDF and Postscript documentation was built, issue the following commands, as the root user, to install them:

install -v -m644 doc/*.pdf /usr/share/doc/ffmpeg-4.4.1 &&
install -v -m644 doc/*.ps  /usr/share/doc/ffmpeg-4.4.1

If you used doxygen to manually create the API documentation, install it by issuing the following commands as the root user:

install -v -m755 -d /usr/share/doc/ffmpeg-4.4.1/api                     &&
cp -vr doc/doxy/html/* /usr/share/doc/ffmpeg-4.4.1/api                  &&
find /usr/share/doc/ffmpeg-4.4.1/api -type f -exec chmod -c 0644 \{} \; &&
find /usr/share/doc/ffmpeg-4.4.1/api -type d -exec chmod -c 0755 \{} \;

To properly test the installation you must have rsync-3.2.3 installed and follow the instructions for the FFmpeg Automated Testing Environment (FATE). First, about 1 GB of sample files used to run FATE are downloaded with the command:

make fate-rsync SAMPLES=fate-suite/

The fate-suite directory is created and the files are downloaded there. That command actually runs an rsync command to obtain the sample files. You may want to compress and keep this directory for testing again, for testing in another system, or for when a new version of ffmpeg is released. Then, unpack the sample files in the source directory, and run the make fate-rsync ... command above to sync with the upstream repository. The download size and time are drastically reduced by doing this. Estimated values in "Package Information" do not include the download SBU. Some samples may have been removed in newer versions, so in order to be sure local and server fate samples are identical when you use previously saved samples, run the following command:

rsync -vrltLW  --delete --timeout=60 --contimeout=60 \
      rsync://fate-suite.ffmpeg.org/fate-suite/ fate-suite/

Next, execute FATE with the following commands (there are more than 3800 tests in the suite):

make fate THREADS=N SAMPLES=fate-suite/ | tee ../fate.log &&
grep ^TEST ../fate.log | wc -l

where N is an integer, N ≤ number of cores in the system.

A successful run should return no errors or warnings, just a list of tests and total amount at the end.

Command Explanations

sed -i ... configure: This command adds the ALSA library to the Flite LDFLAGS variable and enables the discovery of Flite.

find ... ;: Fixes permissions of documentation files and directories.

--enable-libfreetype: Enables Freetype support.

--enable-gpl: Enables the use of GPL code and permits support for postprocessing, swscale and many other features.

--enable-version3: Enables the use of (L)GPL version 3 code.

--enable-nonfree: Enables the use of nonfree code. Note that the resulting libraries and binaries will be unredistributable.

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-shared: Enables building shared libraries, otherwise only static libraries are built and installed.

--disable-debug: Disables building debugging symbols into the programs and libraries.

--enable-avresample: Enables Transcode-1.1.7 to be compiled.

--enable-libass: Enables ASS/SSA subtitle format rendering via libass.

--enable-libdrm: Use this switch if libdrm-2.4.110 is installed to build the kmsgrab input module which is useful for screen capturing or streaming.

--enable-libfdk-aac: Enables AAC audio encoding via libfdk-aac.

--enable-libmp3lame: Enables MP3 audio encoding via libmp3lame.

--enable-libvorbis --enable-libtheora: Enables Theora video encoding via libvorbis and libtheora.

--enable-libvorbis --enable-libvpx: Enables WebM encoding via libvorbis and libvpx.

--enable-libx264: Enables high-quality H.264/MPEG-4 AVC encoding via libx264.

--enable-libx265: Enables high-quality H.265/HEVC encoding via libx265.

--enable-openssl: Enables HTTPS protocol for network streams.

--enable-gnutls: Use this option instead of --enable-openssl, if you want to use GnuTLS instead of OpenSSL for HTTPS protocol.

--disable-doc: Disables building html documentation. This is only needed if Doxygen-1.9.3 is installed and you do not want to build the html documentation.

--enable-libpulse: Enables support for Pulseaudio for audio output.

gcc tools/qt-faststart.c -o tools/qt-faststart: This builds the qt-faststart program which can modify QuickTime formatted movies (.mov or .mp4) so that the header information is located at the beginning of the file instead of the end. This allows the movie file to begin playing before the entire file has been downloaded.

Note

Support for most of the dependency packages requires using options passed to the configure script. View the output from ./configure --help for complete information about enabling dependency packages.

Contents

Installed Programs: ffmpeg, ffplay, ffprobe, and qt-faststart
Installed Libraries: libavcodec.so, libavdevice.so, libavfilter.so, libavformat.so, libavutil.so, libavresample.so, libpostproc.so, libswresample.so, and libswscale.so
Installed Directories: /usr/include/libav{codec,device,filter,format,resample,util}, /usr/include/libpostproc, /usr/include/libsw{resample,scale}, /usr/share/doc/ffmpeg-4.4.1, and /usr/share/ffmpeg

Short Descriptions

ffmpeg

is a command-line tool to convert video files, network streams and input from a TV card to several video formats

ffplay

is a very simple and portable media player using the ffmpeg libraries and the SDL library

ffprobe

gathers information from multimedia streams and prints it in a human and machine-readable fashion

qt-faststart

moves the index file to the front of quicktime (mov/mp4) videos

libavcodec.so

is a library containing the FFmpeg codecs (both encoding and decoding)

libavdevice.so

is the FFmpeg device handling library

libavfilter.so

is a library of filters that can alter video or audio between the decoder and the encoder (or output)

libavformat.so

is a library containing the file formats handling (mux and demux code for several formats) used by ffplay as well as allowing the generation of audio or video streams

libavresample.so

is a library containing functions for resampling audio and video.

libavutil.so

is the FFmpeg utility library

libpostproc.so

is the FFmpeg post processing library

libswresample.so

is the FFmpeg audio rescaling library, it contains functions for converting audio sample formats

libswscale.so

is the FFmpeg image rescaling library

Last updated on

MPlayer-export-2021-07-29

Introduction to MPlayer

MPlayer is a powerful audio/video player controlled via the command line or a graphical interface that is able to play almost every popular audio and video file format. With supported video hardware and additional drivers, MPlayer can play video files without an X Window System installed.

Note

The latest stable version was released in April 2019. That version no longer builds properly with the latest build tools and system libraries. The version below is a snapshot that may not be available on the upstream server but was uploaded to our file server. If you want to test a later version, check http://www.mplayerhq.hu/MPlayer/releases/.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Skins

Note

Skins are only required in order to use the Gtk+ 2 user interface.

MPlayer Dependencies

Required

yasm-1.3.0

Recommended
Optional Input Drivers and Libraries

CDParanoia-III-10.2, libcdio-2.1.0 (to identify and play CDs), libdvdread-6.1.2, libdvdnav-6.1.1, libdvdcss-1.4.3, Samba-4.15.5, libbluray, LIVE555 Streaming Media, RTMPDump, TiVo vstream client, and XMMS

Optional Audio Output Drivers and Libraries

ALSA-1.2.6, PulseAudio-15.0, SDL-1.2.15, JACK, NAS, and OpenAL

Optional Video Output Drivers and Libraries

AAlib-1.4rc5, giflib-5.2.1, libjpeg-turbo-2.1.2, libmng-2.0.3, libpng-1.6.37, OpenJPEG1 DirectFB, libcaca, and SVGAlib

Optional CODECs

FAAC-1_30, FAAD2-2_10_0, LAME-3.100, liba52-0.7.4, libdv-1.0.0, libmad-0.15.1b, libmpeg2-0.5.1, libtheora-1.1.1, libvpx-1.11.0, LZO-2.10, mpg123-1.29.3, Speex-1.2.0, XviD-1.3.7, x264-20220219, CrystalHD, Dirac, GSM, iLBC, libdca, libnut, libmpcdec, OpenCore Adaptive Multi Rate, Schroedinger, Tremor, and TwoLAME

Optional Miscellaneous Dependencies

Fontconfig-2.13.1, FreeType-2.11.1, FriBidi-1.0.11, GnuTLS-3.7.3, Opus-1.3.1, and UnRar-6.1.4; libxslt-1.1.35, docbook-xml-4.5 and docbook-xsl-1.79.2 (all three required to build the HTML documentation); and Enca, libbs2b, and LIRC (and LIRC Client Daemon)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/mplayer

Installation of MPlayer

Main MPlayer Installation

Note

The package maintainers recommend building without any optimizations.

You may wish to examine the output from ./configure --help to find out what additional parameters to configure are needed to include the dependencies you have installed on your system.

Install MPlayer by running the following commands:

./configure --prefix=/usr                 \
            --confdir=/etc/mplayer        \
            --enable-dynamic-plugins      \
            --disable-libmpeg2-internal   \
            --disable-ffmpeg_a            \
            --enable-menu                 \
            --enable-runtime-cpudetection \
            --enable-gui                  &&
make

If you wish to build the HTML documentation, issue the following command:

make doc

This package does not come with a test suite.

Now, as the root user:

make install  &&
ln -svf ../icons/hicolor/48x48/apps/mplayer.png \
        /usr/share/pixmaps/mplayer.png

To install the HTML documentation, issue the following commands as the root user:

install -v -m755 -d /usr/share/doc/mplayer-export-2021-07-29 &&
install -v -m644    DOCS/HTML/en/* \
                    /usr/share/doc/mplayer-export-2021-07-29

You will only need codecs.conf if you want to change its properties, as the main binary contains an internal copy of it. Ensure any changes you make to codecs.conf achieve the desired results, as incorrect entries in this file have been known to cause errors and render the player unusable. If necessary, create the file as the root user:

install -v -m644 etc/codecs.conf /etc/mplayer

You may alternatively want to copy all the default configuration files to /etc/mplayer for future reference or more customization ability. As the root user:

install -v -m644 etc/*.conf /etc/mplayer

Skin Installation (Optional)

To enable the Gtk+ 2 frontend of MPlayer, you'll need to install at least one skin. Extract the desired skin and create the default location (as the root user):

tar -xvf  ../Clearlooks-2.0.tar.bz2 \
    -C    /usr/share/mplayer/skins &&
ln  -sfvn Clearlooks /usr/share/mplayer/skins/default

Note

This package installs icon files into the /usr/share/icons/hicolor hierarchy and desktop files into the /usr/share/applications hierarchy. You can improve system performance and memory usage by updating /usr/share/icons/hicolor/index.theme and /usr/share/applications/mimeinfo.cache. To perform the update you must have GTK+-2.24.33 or GTK+-3.24.31 installed (for the icon cache) and desktop-file-utils-0.26 (for the desktop cache) and issue the following commands as the root user:

gtk-update-icon-cache -qtf /usr/share/icons/hicolor &&
update-desktop-database -q

Command Explanations

--enable-gui: This option builds the GUI interface into mplayer.

--enable-menu: This option is set to enable the on-screen display.

--enable-runtime-cpudetection: This option makes MPlayer run with a generic CPU type, preventing optimizations that may cause runtime problems.

--disable-ffmpeg_a: You can use this option if you have installed FFmpeg-4.4.1. Dynamically linking to a system installed FFmpeg makes MPlayer and Mencoder about 9MB smaller.

--disable-libmpeg2-internal: This option makes MPlayer run with a system version of libmpeg2.

--language-doc="<lang>": This switch sets the language used for the documentation. Use ./configure --help for more information.

--language-man="<lang>": This switch sets the language used for the man pages. Use ./configure --help for more information.

--language-msg="<lang>": This switch sets the language used for messages and the GUI. Use ./configure --help for more information

--language="<lang>": This switch sets the default language used. Use ./configure --help for more information.

Note

Specific options override --language. You can pass a list of languages separated by whitespace or commas instead of a single language. Nonexisting translations will be dropped from each list. All documentation and man page translations available in the list will be installed, for the messages the first available translation will be used. The value "all" will activate all translations. The LINGUAS environment variable is honored. In all cases the fallback is English. Values listed by ./configure --help are not all available, as would normally be expected. You need to build test.

Configuring MPlayer

Config Files

/etc/mplayer/* and ~/.mplayer/*

Note

To play a DVD, it may be useful to ensure a /dev/dvd device is created. You may need to set this up as described in the section called “Devices for DVD Drives”.

Configuration Information

Typically, there's no configuration required for the system-wide files in /etc/mplayer (in fact, this directory is empty unless you copied the default files as mentioned above). Configuration can be accomplished by choosing the configuration button located on the MPlayer GUI. Any configuration changes made in the GUI will be saved in the user's ~/.mplayer directory.

Contents

Installed Programs: gmplayer, mplayer and mencoder
Installed Libraries: None
Installed Directories: /etc/mplayer, /usr/share/doc/mplayer-export-2021-07-29 and /usr/share/mplayer

Short Descriptions

gmplayer

is a symlink to mplayer which brings up the GTK+ 2 frontend of MPlayer

mplayer

is the main MPlayer video player

mencoder

is a powerful command line video decoding, encoding and filtering tool that is useful for (amongst other things) ripping DVDs to files on your hard disk (see /usr/share/doc/mplayer-export-2021-07-29/mencoder.html)

Last updated on

Transcode-1.1.7

Introduction to Transcode

Transcode was a fast, versatile and command-line based audio/video everything to everything converter primarily focussed on producing AVI video files with MP3 audio, but also including a program to read all the video and audio streams from a DVD.

Although outdated and no longer maintained, it can still be used to extract items from a DVD using only the required and recommended dependencies, or to recode to AVI files.

Subjects to the comments below, this package is known to build and minimally work using the current LFS platform.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Transcode Dependencies

Required

FFmpeg-4.4.1 (configured with --enable-avresample)

Recommended
Optional

FAAC-1_30, FreeType-2.11.1, ImageMagick-6, liba52-0.7.4, libdv-1.0.0, libjpeg-turbo-2.1.2, libogg-1.3.5, libquicktime-1.2.4, libtheora-1.1.1, libvorbis-1.3.7, libxml2-2.9.13, LZO-2.10, SDL-1.2.15, v4l-utils-1.22.1, x264-20220219, XviD-1.3.7 MJPEG Tools, and PVM3,

Optional (at runtime)

lsdvd

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/transcode

Installation of Transcode

Note

The details of how the FFmpeg libraries are used has changed since this version of Transcode was released. The patch allows the package to be compiled, but some or all of the internal calls to FFmpeg may fail at run time (they report an error and processing continues, but without any output).

For many packages, that would be a critical error. In this case, the main reason to install Transcode is for the tccat program, which works. Some of the transcode options work - for the others, use ffmpeg directly on the command line.

Note

Support for most of the dependency packages requires using options passed to the configure script. View the INSTALL file and the output from ./configure --help for complete information about enabling dependency packages.

Install Transcode by running the following commands:

sed -i 's|doc/transcode|&-$(PACKAGE_VERSION)|' \
       $(find . -name Makefile.in -exec grep -l 'docsdir =' {} \;) &&

patch -Np1 -i ../transcode-1.1.7-ffmpeg4-1.patch   &&
patch -Np1 -i ../transcode-1.1.7-gcc10_fix-1.patch &&

./configure --prefix=/usr     \
            --enable-alsa     \
            --enable-libmpeg2 &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Command Explanations

sed -i ...: Fixes install location for documentation.

Contents

Installed Programs: avifix, aviindex, avimerge, avisplit, avisync, tccat, tcdecode, tcdemux, tcextract, tcmodinfo, tcmp3cut, tcprobe, tcscan, tcxmlcheck, tcxpm2rgb, tcyait, and transcode
Installed Libraries: None
Installed Directories: /usr/lib/transcode and /usr/share/doc/transcode-1.1.7

Short Descriptions

avifix

fixes the header of an AVI file

aviindex

writes a text file describing the index of an AVI file

avimerge

merges AVI files of the same format. Do not try to merge AVI files of different formats, it will most likely result in errors (and format means same bitrates, too!)

avisplit

splits AVI files into multiple files

avisync

can shift audio in AVI files for better synchronizing of the audio and video data signal

tccat

concatenates input files using the input plugins of Transcode. This is useful for extracting VOB (Video OBject) files, either for a whole DVD or for selected Titles or Chapters, which can then be played or recoded

tcdecode

is used to decode input files to raw video and PCM audio streams

tcdemux

demultiplexes (separates) audio/video input that contains multiple streams, e.g., VOB files

tcextract

grabs single streams from a file containing multiple streams

tcmodinfo

loads a supplied Transcode filter module and prints its parameters

tcmp3cut

is a tool which can cut MP3 streams at milliseconds positions

tcprobe

prints information about the input file format

tcscan

performs several measurements on the given input data

tcxmlcheck

checks information in a SMIL input file

transcode

is the encoder's user interface that handles the plugins and other programs, being the glue between the modules. There are several well documented usage examples on both the homepage and the documentation included in the package

Last updated on

VLC-3.0.16

Introduction to VLC

VLC is a media player, streamer, and encoder. It can play from many inputs, such as files, network streams, capture devices, desktops, or DVD, SVCD, VCD, and audio CD. It can use most audio and video codecs (MPEG 1/2/4, H264, VC-1, DivX, WMV, Vorbis, AC3, AAC, etc.), and it can also convert to different formats and/or send streams through the network.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

VLC Dependencies

Recommended
Optional features and packages

dbus-1.12.20, libidn-1.38, and libssh2-1.10.0

Optional input plugins

libarchive-3.6.0, libcddb-1.3.2, libdv-1.0.0, libdvdcss-1.4.3, libdvdread-6.1.2, libdvdnav-6.1.1, opencv-4.5.5 (currently broken), Samba-4.15.5, v4l-utils-1.22.1, libbluray, libdc1394, libnfs, libproxy, libraw1394, Live555, and VCDImager (requires libcdio-2.1.0)

Optional mux/demux plugins

libogg-1.3.5, Game Music Emu, libdvbpsi, libshout, libmatroska (requires libebml), libmodplug, Musepack, and sidplay-libs

Optional codec plugins

FAAD2-2_10_0, FLAC-1.3.3, libass-0.15.2, libmpeg2-0.5.1, libpng-1.6.37, libtheora-1.1.1, libva-2.13.0, libvorbis-1.3.7, Opus-1.3.1, Speex-1.2.0, x264-20220219, aom, aribb24, dav1d, Dirac, FluidLite, FluidSynth, libdca, libkate, OpenMAX, Schroedinger, Shine, SoX, Tremor, Twolame, and Zapping VBI

Optional video plugins

AAlib-1.4rc5, Fontconfig-2.13.1, FreeType-2.11.1, FriBidi-1.0.11, librsvg-2.52.6, libvdpau-1.4, SDL-1.2.15 (with SDL_image), libcaca, and libmfx

Optional audio plugins

PulseAudio-15.0, libsamplerate-0.2.2, spatialaudio, and JACK

Optional interface plugins

Qt-5.15.2 (required for the graphical user interface), libtar, libvncclient, LIRC, and freerdp

Optional visualisations and video filter plugins

Goom, libvsxu, and projectM

Optional service discovery plugins

Avahi-0.8, libmtp and libupnp

Miscellaneous options

GnuTLS-3.7.3, libnotify-0.7.9, libxml2-2.9.13, taglib-1.12, xdg-utils-1.1.3 (runtime), AtmoLight, libmicrodns, protobuf, and srt

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/vlc

Installation of VLC

Install VLC by running the following commands:

export LUAC=/usr/bin/luac5.2                   &&
export LUA_LIBS="$(pkg-config --libs lua52)"   &&
export CPPFLAGS="$(pkg-config --cflags lua52)" &&

BUILDCC=gcc ./configure --prefix=/usr    \
                        --disable-opencv \
                        --disable-vpx    &&

make

To test the results, issue: make check.

Now, as the root user:

make docdir=/usr/share/doc/vlc-3.0.16 install

Note

This package installs icon files into the /usr/share/icons/hicolor hierarchy and desktop files into the /usr/share/applications hierarchy. You can improve system performance and memory usage by updating /usr/share/icons/hicolor/index.theme and /usr/share/applications/mimeinfo.cache. To perform the update you must have GTK+-2.24.33 or GTK+-3.24.31 installed (for the icon cache) and desktop-file-utils-0.26 (for the desktop cache) and issue the following commands as the root user:

gtk-update-icon-cache -qtf /usr/share/icons/hicolor &&
update-desktop-database -q

Command Explanations

export ...: These commands ensure building with Lua-5.2.4. Upstream does not support lua 5.4 yet.

--disable-opencv: This switch is required to disable opencv which is not compatible with this version of vlc.

--disable-vpx: This switch is required to disable libvpx. The latest version is not compatible with this version of vlc.

--disable-lua: Use this switch if you don't have Lua installed.

--disable-mad: Use this switch if you don't have libmad installed.

--disable-avcodec --disable-swscale: Use these switches if you don't have FFmpeg installed.

--disable-a52: Use this switch if you don't have liba52 installed.

--disable-xcb: Use this switch if you don't have X Window System installed.

--disable-alsa: Use this switch if you don't have ALSA installed.

--disable-libgcrypt: Use this switch if you don't have libgcrypt installed.

--disable-sftp: The default is to build the sftp module if libssh2-1.10.0 is installed. Use this switch if you do not want to build this module.

Note

There are many options to VLC's configure command. Check the configure --help output for a complete list.

Contents

Installed Programs: cvlc, nvlc, qvlc, rvlc, svlc, vlc and vlc-wrapper
Installed Libraries: libvlccore.so, libvlc.so, and many plugins in /usr/lib/vlc/plugins
Installed Directories: /usr/{include,lib,share}/vlc, /usr/share/kde4, and /usr/share/doc/vlc-3.0.16

Short Descriptions

cvlc

is a script to run VLC with the dummy interface

nvlc

is a script to run VLC with the ncurses interface

qvlc

is a script to run VLC with the Qt interface

rvlc

is a script to run VLC with a command line interface

svlc

is a script to run VLC with the skins interface

vlc

is the VLC media player

vlc-wrapper

is a wrapper to drop privileges with VLC

Last updated on

xine-ui-0.99.13

Introduction to Xine User Interface

The xine User Interface package contains a multimedia player. It plays back CDs, DVDs and VCDs. It also decodes multimedia files like AVI, MOV, WMV, MPEG and MP3 from local disk drives, and displays multimedia streamed over the Internet.

This package is known to build and work properly using an LFS-11.1 platform.

Note

Although this version of xine-ui works with most files, it is unable to open encrypted (content-scrambled) DVDs with the current version of libdvdcss.

Package Information

Xine User Interface Dependencies

Required

xine-lib-1.2.11 and shared-mime-info-2.1

Optional

cURL-7.81.0, AAlib-1.4rc5, LIRC, and libcaca

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xine-ui

Installation of Xine User Interface

Install xine User Interface by running the following commands:

./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make docsdir=/usr/share/doc/xine-ui-0.99.13 install

Note

This package installs icon files into the /usr/share/icons/hicolor hierarchy and desktop files into the /usr/share/applications hierarchy. You can improve system performance and memory usage by updating /usr/share/icons/hicolor/index.theme and /usr/share/applications/mimeinfo.cache. To perform the update you must have GTK+-2.24.33 or GTK+-3.24.31 installed (for the icon cache) and desktop-file-utils-0.26 (for the desktop cache) and issue the following commands as the root user:

gtk-update-icon-cache -qtf /usr/share/icons/hicolor &&
update-desktop-database -q

Command Explanations

docsdir=/usr/share/doc/xine-ui-0.99.13: This parameter causes the Xine UI documentation to be installed in the versioned directory /usr/share/doc/xine-ui-0.99.13, rather that the default /usr/share/doc/xine-ui.

Configuring Xine User Interface

Config Files

~/.xine/config

Configuration Information

The above file is created and maintainable through the xine setup dialog box. The documentation for the configuration settings is located at /usr/share/doc/xine-ui-0.99.13/README.config_en.

If you have a DVB TV card, you can watch TV with the command xine dvb:// and change channels with the scroll wheel on your mouse.

Contents

Installed Programs: aaxine, cacaxine, fbxine, xine, xine-bugreport, xine-check, and xine-remote
Installed Libraries: None
Installed Directories: /usr/share/xine and /usr/share/doc/xine-ui-0.99.13

Short Descriptions

aaxine

is an ASCII art video player which utilizes AAlib as the frontend for the xine Libraries

cacaxine

is a color ASCII art video player which utilizes CACA as the frontend for the xine Libraries

fbxine

is a frame buffer interface to the xine Libraries

xine

is a multimedia player designed to play MPEG streams (audio and video), MPEG elementary streams (MP3), MPEG transport streams, Ogg files, AVI files, ASF files, some Quicktime files, VCDs and DVDs

xine-bugreport

produces a terse system description and guides you through the process of reporting a bug

xine-check

tests the xine video player installation for common problems. It tests the operating system settings, installation of plugins, CD/DVD drive settings and video support parameters

xine-remote

is a tool to connect to a xine remote control server

Last updated on

Chapter 45. CD/DVD-Writing Utilities

This chapter contains information on CD/DVD-writing utilities in Linux.

Additional sources of information include:

Cdrdao-1.2.4

Introduction to Cdrdao

The Cdrdao package contains CD recording utilities. These are useful for burning a CD in disk-at-once mode.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Cdrdao Dependencies

Recommended

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/cdrdao

Installation of Cdrdao

Install Cdrdao by running the following commands:

./configure --prefix=/usr --mandir=/usr/share/man &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&
install -v -m755 -d /usr/share/doc/cdrdao-1.2.4 &&
install -v -m644 README /usr/share/doc/cdrdao-1.2.4

Command Explanations

--mandir=/usr/share/man: Install manual pages in /usr/share/man instead of /usr/man.

Contents

Installed Programs: cdrdao, cue2toc, toc2cddb, toc2cue and optionally toc2mp3
Installed Libraries: None
Installed Directories: /usr/share/cdrdao, /usr/share/doc/cdrdao-1.2.4

Short Descriptions

cdrdao

records audio or data CD-Rs in disk-at-once (DAO) mode based on a textual description of the CD contents

cue2toc

converts CUE to TOC format for audio CDs

toc2cddb

converts a Cdrdao TOC file into a cddb file and prints it to stdout

toc2cue

converts TOC to CUE format for audio CDs

toc2mp3

converts an audio CD disk image (.toc file) to MP3 files

Last updated on

Cdrtools-3.02a09

Introduction to Cdrtools

The Cdrtools package contains CD recording utilities. These are useful for reading, creating or writing (burning) CDs, DVDs, and Blu-ray discs.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Cdrtools Depedendencies

Required

alsa-lib-1.2.6.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Cdrtools

Installation of Cdrtools

Note

This package does not support parallel build.

Install Cdrtools by running the following commands:

export GMAKE_NOWARN=true &&
make -j1 INS_BASE=/usr DEFINSUSR=root DEFINSGRP=root

This package does not come with a test suite.

Now, as the root user:

export GMAKE_NOWARN=true &&
make INS_BASE=/usr MANSUFF_LIB=3cdr DEFINSUSR=root DEFINSGRP=root install &&
install -v -m755 -d /usr/share/doc/cdrtools-3.02a09 &&
install -v -m644 README.* READMEs/* ABOUT doc/*.ps \
                    /usr/share/doc/cdrtools-3.02a09

Command Explanations

export GMAKE_NOWARN=true: This variable avoids a warning when using GNU make.

INS_BASE=/usr: This parameter moves the install directory from /opt/schily to /usr.

DEFINSUSR=root DEFINSGRP=root: These parameters install all programs with root:root ownership instead of the default bin:bin.

MANSUFF_LIB=3cdr: This parameter prevents Cdrtools from overwriting important pages which are already installed by LFS. The installed man pages of section 3 will have a suffix 3cdr and can be shown using man 3cdr <manpage>.

Contents

Installed Programs: btcflash, cdda2mp3, cdda2ogg, cdda2wav, cdrecord, devdump, isodebug, isodump, isoinfo, isovfy, mkhybrid, mkisofs, readcd, rscsi, scgcheck, scgskeleton
Installed Libraries: libcdrdeflt.a, libdeflt.a, libedc_ecc.a, libedc_ecc_dec.a, libfile.a, libfind.a, libhfs.a, libmdigest.a, libparanoia.a, librscg.a, libscg.a, libscgcmd.a, libschily.a, libsiconv.a
Installed Directories: /usr/lib/{profiled,siconv}, /usr/include/{scg,schily}, /usr/share/doc/cdda2wav,cdrecord,libparanoia,mkisofs,rscsi}

Short Descriptions

btcflash

flashes the firmware on BTC DRW1008 DVD+/-RW recorder. Please exercise care with this program

cdda2wav

converts Compact Disc audio into WAV sound files

cdrecord

records audio or data Compact Discs

devdump

is a diagnostic program used to dump an ISO-9660 device or file in hex

isodebug

is used to display the command-line parameters used to create an ISO-9660 image

isodump

is a diagnostic program used to dump a device or file based on ISO-9660

isoinfo

is used to analyze or list an ISO-9660 image

isovfy

is used to verify an ISO-9660 image

mkhybrid

is a symbolic link to mkisofs used to create ISO-9660/HFS hybrid filesystem images

mkisofs

is used to create ISO-9660/JOLIET/HFS filesystem images, optionally with Rock Ridge attributes

readcd

reads or writes Compact Discs

rscsi

is a remote SCSI manager

scgcheck

is used to check and verify the Application Binary Interface of libscg

libscg.a

is a highly portable SCSI transport library

Last updated on

dvd+rw-tools-7.1

Introduction to dvd+rw-tools

The dvd+rw-tools package contains several utilities to master the DVD media, both +RW/+R and -R[W]. The principle tool is growisofs which provides a way to both lay down and grow an ISO9660 file system on (as well as to burn an arbitrary pre-mastered image to) all supported DVD media. This is useful for creating a new DVD or adding to an existing image on a partially burned DVD.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

dvd+rw-tools Dependencies

Required

Cdrtools-3.02a09 (runtime)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/dvd+rw-tools

Installation of dvd+rw-tools

Install dvd+rw-tools by running the following commands:

sed -i '/stat.h/a #include <sys/sysmacros.h>' growisofs.c &&
sed -i '/stdlib/a #include <limits.h>' transport.hxx &&
make all rpl8 btcflash

This package does not come with a test suite.

Now, as the root user:

make prefix=/usr install &&
install -v -m644 -D index.html \
    /usr/share/doc/dvd+rw-tools-7.1/index.html

Command Explanations

sed -i '/stdlib/a #include <limits.h>' ...: This sed includes limits.h, one of the kernel headers. This is needed due to a change in the 2.6.23 kernel headers.

make all rpl8 btcflash: This command uses additional targets so that all the utilities are built.

Contents

Installed Programs: btcflash, dvd+rw-booktype, dvd+rw-format, dvd+rw-mediainfo, dvd-ram-control, growisofs, and rpl8
Installed Libraries: None
Installed Directory: /usr/share/doc/dvd+rw-tools-7.1

Short Descriptions

growisofs

is a combined mkisofs frontend/DVD recording program

Last updated on

libburn-1.5.4

Introduction to libburn

libburn is a library for writing preformatted data onto optical media: CD, DVD and BD (Blu-Ray).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libburn Dependencies

Optional

Doxygen-1.9.3 (to generate HTML documentation)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libburn

Installation of libburn

Install libburn by running the following commands:

./configure --prefix=/usr --disable-static &&
make

If you have installed Doxygen and wish to generate the HTML documentation, issue the following command:

doxygen doc/doxygen.conf

This package does not come with a test suite.

Now, as the root user:

make install

If you have built the HTML documentation, install it by running the following commands as the root user:

install -v -dm755 /usr/share/doc/libburn-1.5.4 &&
install -v -m644 doc/html/* /usr/share/doc/libburn-1.5.4

Contents

Installed Program: cdrskin
Installed Library: libburn.so
Installed Directory: /usr/include/libburn

Short Descriptions

cdrskin

burns preformatted data to CD, DVD, and BD via libburn

libburn.so

contains the libburn API functions

Last updated on

libisoburn-1.5.4

Introduction to libisoburn

libisoburn is a frontend for libraries libburn and libisofs which enables creation and expansion of ISO-9660 filesystems on all CD/DVD/BD media supported by libburn. This includes media like DVD+RW, which do not support multi-session management on media level and even plain disk files or block devices.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libisoburn Dependencies

Required

libburn-1.5.4 and libisofs-1.5.4

Optional

Doxygen-1.9.3 (to generate HTML documentation), Tk-8.6.12 (for xorriso-tcltk), and libjte

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libisoburn

Installation of libisoburn

Install libisoburn by running the following commands:

./configure --prefix=/usr              \
            --disable-static           \
            --enable-pkg-check-modules &&
make

If you have installed Doxygen and wish to generate the HTML documentation, issue the following command:

doxygen doc/doxygen.conf

This package does not come with a test suite.

Now, as the root user:

make install

If you have built the HTML documentation, install it by running the following commands as the root user:

install -v -dm755 /usr/share/doc/libisoburn-1.5.4 &&
install -v -m644 doc/html/* /usr/share/doc/libisoburn-1.5.4

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-pkg-check-modules: Enable pkg-config check for libburn and libisofs.

Contents

Installed Programs: osirrox, xorrecord, xorriso, xorriso-dd-target, xorrisofs, and xorriso-tcltk
Installed Library: libisoburn.so
Installed Directories: /usr/include/libisoburn and /usr/share/doc/libisoburn-1.5.4

Short Descriptions

osirrox

is a symbolic link to xorriso that copies files from ISO image to a disk filesystem

xorrecord

is a symbolic link to xorriso that provides a cdrecord type user interface

xorriso

is a program to create, load, manipulate, read, and write ISO 9660 filesystem images with Rock Ridge extensions

xorriso-dd-target

is a program to check a USB or memory card device to see whether it is suitable for image copying

xorrisofs

is a symbolic link to xorriso that that provides a mkisofs type user interface

xorriso-tcltk

is a frontend that operates xorriso in dialog mode

libisoburn.so

contains the libisoburn API functions

Last updated on

libisofs-1.5.4

Introduction to libisofs

libisofs is a library to create an ISO-9660 filesystem with extensions like RockRidge or Joliet.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

libisofs Dependencies

Optional

Doxygen-1.9.3 (to generate HTML documentation) and libjte

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/libisofs

Installation of libisofs

Install libisofs by running the following commands:

./configure --prefix=/usr --disable-static &&
make

If you have installed Doxygen and wish to generate the HTML documentation, issue the following command:

doxygen doc/doxygen.conf

This package does not come with a test suite.

Now, as the root user:

make install

If you have built the HTML documentation, install it by running the following commands as the root user:

install -v -dm755 /usr/share/doc/libisofs-1.5.4 &&
install -v -m644 doc/html/* /usr/share/doc/libisofs-1.5.4

Command Explanations

--disable-static: This switch prevents installation of static versions of the libraries.

Contents

Installed Programs: None
Installed Library: libisofs.so
Installed Directory: /usr/include/libisofs

Short Descriptions

libisofs.so

contains the libisofs API functions

Last updated on

Part XIII. Printing, Scanning and Typesetting

Chapter 46. Printing

This chapter contains spooling printer management systems and ghostscript applications to render PostScript for display on terminals or paper.

Cups-2.4.1

Introduction to Cups

The Common Unix Printing System (CUPS) is a print spooler and associated utilities. It is based on the "Internet Printing Protocol" and provides printing services to most PostScript and raster printers.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Cups Dependencies

Required

GnuTLS-3.7.3

Recommended
Optional

Avahi-0.8, libpaper-1.1.24+nmu5, LLVM-13.0.1 (with clang), MIT Kerberos V5-1.19.2, PHP-8.1.3, and Python-2.7.18

Required (Postinstall)

cups-filters-1.28.12

Optional (Postinstall)

Gutenprint-5.3.4 and hplip (HP printers)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/cups

Kernel Configuration

Note

There used to be a conflict between the Cups libusb backend and the usblp kernel driver. This is no longer the case and cups will work with both of these enabled.

If you want to use the kernel usblp driver (for example, if you wish to use escputil from Gutenprint-5.3.4) enable the following options in your kernel configuration and recompile the kernel:

Device Drivers  --->
  [*] USB support  --->                          [CONFIG_USB_SUPPORT]
    <*/M>  OHCI HCD (USB 1.1) support            [CONFIG_USB_OHCI_HCD]
    <*/M>  UHCI HCD (most Intel and VIA) support [CONFIG_USB_UHCI_HCD]
    <*/M>  USB Printer support                   [CONFIG_USB_PRINTER]

If you have a parallel printer, enable the following options in your kernel configuration and recompile the kernel:

Device Drivers  --->
  <*/M> Parallel port support  --->    [CONFIG_PARPORT]
    <*/M> PC-style hardware            [CONFIG_PARPORT_PC]
  Character devices  --->
    <*/M> Parallel printer support     [CONFIG_PRINTER]

Installation of Cups

You will need to add an lp user, as Cups will create some files owned by this user. (The lp user is the default used by Cups, but may be changed to a different user by passing a parameter to the configure script.) Use the following command as the root user:

useradd -c "Print Service User" -d /var/spool/cups -g lp -s /bin/false -u 9 lp

You will also need a dedicated group that will contain users allowed to do Cups administrative tasks. Add the group by running the following command as the root user:

groupadd -g 19 lpadmin

If you want to add a user to the Cups administrative group, run the following command as the root user:

usermod -a -G lpadmin <username>

If you didn't install xdg-utils-1.1.3, use the following sed to change the default browser that will be used to access the Cups web interface:

sed -i 's#@CUPS_HTMLVIEW@#firefox#' desktop/cups.desktop.in

Replace firefox with the web browser of your choice.

Upstream prefers clang than gcc, but the building system will try to use a compiler warning option unsupported by clang. If clang is installed, remove this warning option:

sed -e "s/format-truncation//" \
    -i configure \
       config-scripts/cups-compiler.m4

Build Cups by running the following commands:

./configure --libdir=/usr/lib            \
            --disable-systemd            \
            --with-rcdir=/tmp/cupsinit   \
            --with-system-groups=lpadmin \
            --with-docdir=/usr/share/cups/doc-2.4.1 &&
make

To test the results, issue: LC_ALL=C make -k check. An already active graphical session with bus address is necessary to run the tests. Make sure that there is not other instance of Cups running, otherwise at least 4 tests will fail with "address in use". One test, httpAddrGetList, is known to fail.

Now, as the root user:

make install &&
ln -svnf ../cups/doc-2.4.1 /usr/share/doc/cups-2.4.1

Remove the shipped bootscript, which is incompatible with LFS:

rm -rf /tmp/cupsinit &&

Create a basic Cups client configuration file by running the following command as the root user:

echo "ServerName /run/cups/cups.sock" > /etc/cups/client.conf

Note

This package installs icon files into the /usr/share/icons/hicolor hierarchy and you can improve system performance and memory usage by updating /usr/share/icons/hicolor/index.theme. To perform the update you must have GTK+-2.24.33 or GTK+-3.24.31 installed and issue the following command as the root user:

gtk-update-icon-cache -qtf /usr/share/icons/hicolor

Command Explanations

sed ... configure: This sed removes a compiler option which is no longer supported. Leaving this change out, the compilation will run thru but a warning about an invalid warning option will be emitted on every compiler invocation.

CC=gcc CXX=g++: Setting them if you prefer to use gcc instead of clang, which is now preferred by the upstream.

--disable-systemd: Systemd is not supported by this version of BLFS.

--with-rcdir=/tmp/cupsinit: This switch tells the build process to install the shipped bootscript into /tmp instead of /etc/rc.d.

--with-system-groups=lpadmin: This switch ensures that only lpadmin will be used as the Cups administrative group.

--disable-libusb: Use this switch if you have installed libusb-1.0.25, but wish to use the kernel usblp driver.

--enable-libpaper: Use this switch if you have installed libpaper and wish to use it with Cups.

Configuring Cups

Config Files

/etc/cups/*

Configuration Information

Normally, printers are set up via a web browser. The Cups server will normally connect via the url http://localhost:631. From there printers, print jobs, and the server configuration can be set up and managed. Remote system administration can also be set up. Configuration can also be done from the command line via the lpadmin, lpoptions, and lpstat commands.

Configuration of Cups is dependent on the type of printer and can be complex. Generally, PostScript printers are easier. For detailed instructions on configuration and use of Cups, see http://www.cups.org/documentation.php.

For non-PostScript printers to print with Cups, you need to install ghostscript-9.55.0 to convert PostScript to raster images and a driver (e.g. from Gutenprint-5.3.4) to convert the resulting raster images to a form that the printer understands. Foomatic drivers use ghostscript-9.55.0 to convert PostScript to a printable form directly, but this is considered suboptimal by Cups developers.

Linux PAM Configuration

If CUPS has been built with Linux PAM support, you need to create a PAM configuration file to get it working correctly with BLFS.

Issue the following command as the root user to create the configuration file for Linux PAM:

cat > /etc/pam.d/cups << "EOF"
# Begin /etc/pam.d/cups

auth    include system-auth
account include system-account
session include system-session

# End /etc/pam.d/cups
EOF

Boot Script

If you want the Cups print service to start automatically when the system is booted, install the init script included in the blfs-bootscripts-20210826 package:

make install-cups

Contents

Installed Programs: cancel, cupsaccept, cups-config, cupsctl, cupsd, cupsdisable, cupsenable, cupsfilter, cupsreject, cupstestppd, ippeveprinter, ipptool, lp, lpadmin, lpc, lpinfo, lpmove, lpoptions, lpq, lpr, lprm, lpstat, ppdc, ppdhtml, ppdi, ppdmerge, and ppdpo
Installed Libraries: libcupsimage.so and libcups.so
Installed Directories: /etc/cups, /usr/{include,lib,share}/cups, /usr/share/doc/cups-2.4.1, and /var/{cache,log,run,spool}/cups

Short Descriptions

cancel

cancels existing print jobs from the print queues

cupsaccept

accept jobs sent to a destination

cups-config

is a Cups program configuration utility

cupsctl

updates or queries the cupsd.conf file for a server

cupsd

is the scheduler for the Common Unix Printing System

cupsdisable

stop printers and classes

cupsenable

start printers and classes

cupsfilter

is a front-end to the Cups filter subsystem which allows you to convert a file to a specific format

cupsreject

reject jobs sent to a destination

cupstestppd

tests the conformance of PPD files

ippeveprinter

is an IPP Everywhere printer for CUPS

ipptool

sends IPP requests to the specified URI and tests and/or displays the results

lp

submits files for printing or alters a pending job

lpadmin

configures printer and class queues provided by Cups

lpc

provides limited control over printer and class queues provided by Cups

lpinfo

lists the available devices or drivers known to the Cups server

lpmove

moves the specified job to a new destination

lpoptions

displays or sets printer options and defaults

lpq

shows the current print queue status on the named printer

lpr

submits files for printing

lprm

cancels print jobs that have been queued for printing

lpstat

displays status information about the current classes, jobs, and printers

ppdc

compiles PPDC source files into one or more PPD files

ppdhtml

reads a driver information file and produces a HTML summary page that lists all of the drivers in a file and the supported options

ppdi

imports one or more PPD files into a PPD compiler source file

ppdmerge

merges two or more PPD files into a single, multi-language PPD file

ppdpo

extracts UI strings from PPDC source files and updates either a GNU gettext or Mac OS X strings format message catalog source file for translation

libcups.so

contains the Cups API functions

Last updated on

cups-filters-1.28.12

Introduction to CUPS Filters

The CUPS Filters package contains backends, filters and other software that was once part of the core CUPS distribution but is no longer maintained by Apple Inc.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

CUPS Filters Dependencies

Required

Cups-2.4.1, GLib-2.70.4, ghostscript-9.55.0, Little CMS-2.13.1, Poppler-22.02.0, and Qpdf-10.6.2

Recommended
Optional

Avahi-0.8 (required to build the DNSSD backend of the cups-browsed daemon, which is needed for operating some network printers), OpenLDAP-2.6.1, PHP-8.1.3 (use of this might be broken), Liblouis (Braille), and Liblouisutdml (Braille)

Optional printer drivers (runtime)

Gutenprint-5.3.4 (for supported printers), or other printer drivers, such as hplip

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/cups-filters

Installation of CUPS Filters

Install CUPS Filters by running the following commands:

./configure --prefix=/usr        \
            --sysconfdir=/etc    \
            --localstatedir=/var \
            --without-rcdir      \
            --disable-static     \
            --disable-avahi      \
            --docdir=/usr/share/doc/cups-filters-1.28.12 &&
make

To test the results, issue: make check. DejaVu fonts are needed for the tests.

Now, as the root user:

make install

Command Explanations

--disable-avahi: This switch is needed if the optional Avahi-0.8 is not installed. Remove it if avahi is installed and you need network printer discovery capabilities.

--without-rcdir: This switch disables installation of the bundled bootscript which is not compatible with BLFS.

--disable-static: This switch prevents installation of static versions of the libraries.

--with-test-font-path=VALUE: If you wish to run the tests, but you do not have the default /usr/share/fonts/dejavu/DejaVuSans.ttf use this switch to specify where DejaVuSans.ttf (or perhaps some other text TTF font - untested) is located.

Contents

Installed Programs: cups-browsed, driverless, driverless-fax, and foomatic-rip
Installed Libraries: libcupsfilters.so and libfontembed.so
Installed Directories: /usr/include/{cupsfilters,fontembed}, /usr/lib/cups/{backend,driver,filter}, /usr/share/cups/{braille,charsets}, /usr/share/doc/cups-filters-1.28.12, and /usr/share/ppd/cupsfilters

Short Descriptions

cups-browsed

is a daemon for browsing the Bonjour and CUPS broadcasts of shared, remote CUPS printers

driverless

is a PPD generator utility for driverless printing

driverless-fax

is a wrapper to driverless for FAX type devices

foomatic-rip

is a universal print filter/RIP wrapper which can be used as CUPS filter or stand-alone for spooler-less, direct printing

libcupsfilters.so

contains CUPS Filters API functions

Last updated on

ghostscript-9.55.0

Introduction to Ghostscript

Ghostscript is a versatile processor for PostScript data with the ability to render PostScript to different targets. It is a mandatory part of the cups printing stack.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

If you wish, you can download additional fonts.

Standard Fonts

Other Fonts

Ghostscript Dependencies

Recommended
Optional

Cairo-1.17.4, GTK+-3.24.31, libidn-1.38, libpaper-1.1.24+nmu5, and a graphical environment

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gs

Installation of Ghostscript

Note

The Ghostscript build system is not user-friendly. In order to use system copies of various graphics libraries, you must do it using unconventional methods.

Ghostscript includes (old) copies of several libraries. Some of these seem to have been patched to fix known vulnerabilities, but others of these copies are less-well maintained. To ensure that any future fixes are applied throughout the whole system, it is recommended that you first install the released versions of these libraries and then configure Ghostscript to link to them.

If you have installed the recommended dependencies on your system, remove the copies of freetype, lcms2, libjpeg, libpng, and openjpeg:

rm -rf freetype lcms2mt jpeg libpng openjpeg

Fix a build failure due to a typo in a source file:

sed -i 's/gscms_transformm_color_const/gscms_transform_color_const/' base/gsicc_lcms2.c

Compile Ghostscript:

rm -rf zlib &&

./configure --prefix=/usr           \
            --disable-compile-inits \
            --enable-dynamic        \
            --with-system-libtiff   &&
make

Note

The shared library depends on GTK+-3.24.31. It is only used by external programs like asymptote-2.78, dvisvgm-2.13.1, ImageMagick-7.1.0-25, and texlive-20210325.

To compile the shared library libgs.so, run the following additional command as an unprivileged user:

make so

This package does not come with a test suite. A set of example files may be used for testing, but it is only possible after installation of the package.

Now, as the root user:

make install

If you want the shared library too:

make soinstall &&
install -v -m644 base/*.h /usr/include/ghostscript &&
ln -sfvn ghostscript /usr/include/ps

Now make the documentation accessible from a standard place:

mv -v /usr/share/doc/ghostscript/9.55.0 /usr/share/doc/ghostscript-9.55.0  &&
rm -rfv /usr/share/doc/ghostscript &&
cp -r examples/ /usr/share/ghostscript/9.55.0/

If you have downloaded the fonts, unpack them to /usr/share/ghostscript and ensure the ownership of the files are root: root.

tar -xvf ../ghostscript-fonts-std-8.11.tar.gz -C /usr/share/ghostscript --no-same-owner &&
tar -xvf ../gnu-gs-fonts-other-6.0.tar.gz     -C /usr/share/ghostscript --no-same-owner &&
fc-cache -v /usr/share/ghostscript/fonts/

You can now test the rendering of various postscript and pdf files from the /usr/share/ghostscript/9.55.0/examples . To do this, run the following command (in a X Windows display):

gs -q -dBATCH /usr/share/ghostscript/9.55.0/examples/tiger.eps

Command Explanations

rm -rf zlib : zlib was installed as part of LFS.

--disable-compile-inits: This option makes gs and libgs.so slightly smaller.

--with-system-libtiff: Remove this option if you've not installed libtiff-4.3.0.

install -v -m644 base/*.h... : Some packages (ImageMagick is one) need the Ghostscript interface headers in place to link to the shared library. These commands install the headers.

ln -sfvn ghostscript /usr/include/ps: Some packages expect to find the interface headers in an alternate location.

mv -v /usr/share/doc/ghostscript/9.55.0 /usr/share/doc/ghostscript-9.55.0: This moves the documentation where it is expected to be found.

--disable-cups: this option will save a tiny amount of space by not linking gs and libgs.so to the Cups-2.4.1 libraries if you have installed those.

Contents

Installed Programs: dvipdf, eps2eps, gs, gsbj, gsc (from soinstall), gsdj, gsdj500, gslj, gslp, gsnd, gsx (from soinstall), lprsetup.sh, pdf2dsc, pdf2ps, pf2afm, pfbtopfa, pphs, printafm, ps2ascii, ps2epsi, ps2pdf, ps2pdf12, ps2pdf13, ps2pdf14, ps2pdfwr, ps2ps, ps2ps2, and unix-lpr.sh
Installed Library: libgs.so and /usr/lib/ghostscript/9.55.0/X11.so
Installed Directories: /usr/include/ghostscript, /usr/lib/ghostscript, /usr/share/ghostscript, and /usr/share/doc/ghostscript-9.55.0

Short Descriptions

gs

is an interpreter for Adobe Systems' PostScript(tm) and Portable Document Format (PDF)

libgs.so

provides Ghostscript functionality to other programs, such as GSView, ImageMagick, and libspectre

Ghostscript provides many different scripts used to convert PostScript, PDF, and other formats. Please refer to the HTML documentation or the man pages for information about the capabilities provided.

Last updated on

Gutenprint-5.3.4

Introduction to Gutenprint

The Gutenprint (formerly Gimp-Print) package contains high quality drivers for many brands and models of printers for use with Cups-2.4.1 and the GIMP-2.0. See a list of supported printers at http://gutenprint.sourceforge.net/p_Supported_Printers.php.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Gutenprint Dependencies

Recommended
Recommended (at runtime)
Optional (to Regenerate Documentation)

ImageMagick-7.1.0-25, texlive-20210325 (or install-tl-unx), Doxygen-1.9.3, and DocBook-utils-0.6.14

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/gutenprint

Kernel Configuration

If you intend to use escputil with a USB-connected Epson Stylus printer for commands such as --ink-level which need to access the raw device, you must enable the kernel's usblp driver. Enable the following options in your kernel configuration and recompile the kernel:

Device Drivers  --->
  [*] USB support  --->                          [CONFIG_USB_SUPPORT]
    <*/M>  OHCI HCD (USB 1.1) support            [CONFIG_USB_OHCI_HCD]
    <*/M>  UHCI HCD (most Intel and VIA) support [CONFIG_USB_UHCI_HCD]
    <*/M>  USB Printer support                   [CONFIG_USB_PRINTER]

Installation of Gutenprint

Install Gutenprint by running the following commands:

sed -i 's|$(PACKAGE)/doc|doc/$(PACKAGE)-$(VERSION)|' \
       {,doc/,doc/developer/}Makefile.in &&

./configure --prefix=/usr --disable-static &&
make

To test the results, issue: make check. The tests take a very long time and use a lot of disk space. When last tested (version 5.2.15 in June 2019) this needed 75 SBU and 13.5 GB to complete the tests (one test, rastertogutenprint failed because the CUPS ppds are for a previous version. Maybe genppds should be run before the tests). Note that the tests used only one CPU.

Now, as the root user:

make install &&
install -v -m755 -d /usr/share/doc/gutenprint-5.3.4/api/gutenprint{,ui2} &&
install -v -m644    doc/gutenprint/html/* \
                    /usr/share/doc/gutenprint-5.3.4/api/gutenprint &&
install -v -m644    doc/gutenprintui2/html/* \
                    /usr/share/doc/gutenprint-5.3.4/api/gutenprintui2

Command Explanations

sed -i '...' ...Makefile.in: This command is used so that the package documentation is installed in the conventional /usr/share/doc directory structure instead of /usr/share/gutenprint/doc.

--disable-static: This switch prevents installation of static versions of the libraries.

Configuring Gutenprint

Configuration Information

For CUPS to see newly installed print drivers, it has to be restarted (as the root user):

/etc/rc.d/init.d/cups restart

Then point your web browser to http://localhost:631/ to add a new printer to CUPS.

Contents

Installed Programs: cups-calibrate, cups-genppd.5.2, cups-genppdupdate, escputil, and testpattern
Installed Libraries: libgutenprint.so, libgutenprintui2.so and optionally, various CUPS filters and backend drivers under /usr/lib/gutenprint/5.2/modules/
Installed Directories: /usr/{include,lib,share}/gutenprint, /usr/include/gutenprintui2 and /usr/share/doc/gutenprint-5.3.4

Short Descriptions

cups-calibrate

calibrates the color output of printers using the Gutenprint, CUPS or ESP Print Pro drivers

cups-genppd.5.2

generates Gutenprint PPD files for use with CUPS

cups-genppdupdate

regenerates the Gutenprint PPD files in use by CUPS

escputil

is a command line utility to perform various maintenance tasks on Epson Stylus inkjet printers

testpattern

is a test program to learn how to use libgutenprint

Last updated on

Chapter 47. Scanning

This chapter contains scanning applications which allow you to convert printed documents into formatted documents readable by other applications.

SANE-1.0.32

Introduction to SANE

SANE is short for Scanner Access Now Easy. Scanner access, however, is far from easy, since every vendor has their own protocols. The only known protocol that should bring some unity into this chaos is the TWAIN interface, but this is too imprecise to allow a stable scanning framework. Therefore, SANE comes with its own protocol, and the vendor drivers can't be used.

SANE is split into back ends and front ends. The back ends are drivers for the supported scanners and cameras. The front ends are user interfaces to access the backends.

This package is known to build and work properly using an LFS-11.1 platform.

Back Ends Package Information

Additional Downloads (Front Ends)

Note

The upstream location for these files is at https://gitlab.com/sane-project but the file URLs use embedded md5sums. For convenience, the packages have been copied to the location above.

SANE Dependencies

Optional (Back Ends)

Avahi-0.8, Cups-2.4.1, libjpeg-turbo-2.1.2, libtiff-4.3.0, libusb-1.0.25, v4l-utils-1.22.1, Net-SNMP, libieee1284, libgphoto2, and texlive-20210325 (or install-tl-unx)

Optional (Front Ends)

a graphical environment, GTK+-2.24.33, and Gimp-2.10.30

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/sane

Kernel Configuration, Drivers and Additional Packages

To access your scanner, you will probably need the related kernel drivers and/or additional support packages. A SCSI scanner will need SCSI drivers, a parallel port scanner needs parallel port support (you should use enhanced EPP modes) and perhaps libieee1284, and a USB scanner will need the libusb-1.0.25 package. For HP devices, you may need hplip. Ensure you have the necessary drivers properly configured to access the devices.

Installation of SANE

Installation of SANE Back Ends

The SANE daemon should run with its own group. Create this group by issuing the following commands as the root user:

groupadd -g 70 scanner

Note

configure assumes that the user building SANE-backends is a member of the scanner group for testing the existence of this group. So the user building the package should be added to the scanner group. As the root user:

usermod -G scanner -a username

After adding the scanner group as above, you will need to log out and back in to activate it.

For a USB scanner, if you are linking to libusb-1.0.25, include the configure switch --enable-libusb_1_0. Install SANE-backends by running the following commands:

sg scanner -c "                  \
./configure --prefix=/usr        \
            --sysconfdir=/etc    \
            --localstatedir=/var \
            --with-group=scanner \
            --with-lockdir=/run/lock \
            --docdir=/usr/share/doc/sane-backends-1.0.32" &&
make

To test the results, issue: make check.

Now, as the root user:

make install                                         &&
install -m 644 -v tools/udev/libsane.rules           \
                  /etc/udev/rules.d/65-scanner.rules &&
mkdir -p          /run/lock/sane &&
chgrp -v scanner  /run/lock/sane

With the scanner on, run scanimage -L and the name and location of the device should appear. Of course, you need the device drivers configured, in order to run this test.

Installation of SANE Front Ends

The SANE-frontends package includes the graphical frontends xscanimage and xcam, and a command-line frontend scanadf. You don't need this package if you intend to use one of the more advanced graphical frontends like XSane-0.999. For a list of frontend packages, see http://www.sane-project.org/sane-frontends.html.

To install SANE-frontends, use the following commands:

tar -xf ../sane-frontends-1.0.14.tar.gz &&
cd sane-frontends-1.0.14                &&

sed -i -e "/SANE_CAP_ALWAYS_SETTABLE/d" src/gtkglue.c &&
./configure --prefix=/usr --mandir=/usr/share/man &&
make

This package does not come with a test suite.

Now, as the root user:

make install &&
install -v -m644 doc/sane.png xscanimage-icon-48x48-2.png \
    /usr/share/sane

If GIMP was linked into the build and you wish GIMP to use xscanimage as a scanning plugin, issue the following command as the root user:

ln -v -s ../../../../bin/xscanimage /usr/lib/gimp/2.0/plug-ins

Note

If the plugin xscanimage is disabled in GIMP's menu, in order to enable it, "create" a blank image using the menu or Ctrl-N. After that, it is enabled.

Command Explanations

sg scanner -c "...": runs the command between double quotes with principal group scanner. This may be needed if the user has been newly added to group scanner, and has not logged out and in.

--sysconfdir=/etc: This switch installs the configuration files in /etc/sane.d instead of /usr/etc/sane.d.

--with-group=scanner: This parameter causes the directory created for the locking files to be group owned by the scanner group instead of the default uucp group.

exit: This command is used to exit the shell created by the su command.

Configuring SANE

Config Files

/etc/sane.d/*.conf

Configuration Information

Backend Configuration

The backend configuration files are located in /etc/sane.d. Information for configuring the various backends can be found by using the man(5) page for the desired backend. Run man sane-<backend>, substituting the desired backend.

Add any desired users to the scanner group.

If you want to access a network scanner, include two lines in net.conf, as root user (make sure to replace <server_ip> by the actual value, below):

cat >> /etc/sane.d/net.conf << "EOF"
connect_timeout = 60
<server_ip>
EOF

On the server side, include the client ip in the access list of /etc/sane.d/saned.conf, restart the saned daemon, and make sure the firewall, if any, is open to the client.

Frontend Configuration

If you use a desktop environment like Gnome or KDE you may wish to create a xscanimage.desktop file so that xscanimage appears in the panel's menus. As the root user:

mkdir -pv /usr/share/{applications,pixmaps}               &&

cat > /usr/share/applications/xscanimage.desktop << "EOF" &&
[Desktop Entry]
Encoding=UTF-8
Name=XScanImage - Scanning
Comment=Acquire images from a scanner
Exec=xscanimage
Icon=xscanimage
Terminal=false
Type=Application
Categories=Application;Graphics
EOF

ln -svf ../sane/xscanimage-icon-48x48-2.png /usr/share/pixmaps/xscanimage.png
General Information

For general information about configuring and using SANE, see man sane. For information about USB scanning devices, run man sane-usb. For information about SCSI devices, run man sane-scsi.

Configuration and setup of the 'saned' daemon

The saned daemon is not meant to be used for untrusted clients. You should provide Firewalling protection to ensure only trusted clients access the daemon. Due to the complex security requirements to ensure only trusted clients access the daemon, BLFS does not provide instructions to configure the saned daemon. Some good (but outdated) information for setting up and securing the saned daemon can be found at http://penguin-breeder.org/sane/saned/.

Contents

Back Ends:
Installed Programs: gamma4scanimage, sane-config, saned, sane-find-scanner, and scanimage
Installed Libraries: libsane.so and numerous scanner backend modules
Installed Directories: /etc/sane.d, /usr/{include,lib,share}/sane, and /usr/share/doc/sane-1.0.32
Front Ends:
Installed Programs: scanadf, xcam, and xscanimage
Installed Library: GIMP plugin embedded in xscanimage
Installed Directories: None

Short Descriptions

gamma4scanimage

creates a gamma table in the format expected by scanimage

sane-config

is a tool used to determine the compiler and linker flags that should be used to compile and link SANE

saned

is the SANE daemon that allows remote clients to access image acquisition devices available on the local host

sane-find-scanner

is a command-line tool to find SCSI and USB scanners and determine their device files. Its primary purpose is to make sure that scanners can be detected by SANE backends

scanadf

is a command-line interface to control image acquisition devices which are equipped with an automatic document feeder (ADF)

scanimage

is a command line interface for scanning from image acquisition devices such as flatbed scanners or cameras. It is also used to list the available backend devices

xcam

is a graphical camera front end for SANE

xscanimage

is a graphical user interface for scanning

libsane.so

is the application programming interface that is used to communicate between frontends and backends

libsane-*.so

modules are backend scanning library plugins used to interface with scanning devices. See http://www.sane-project.org/sane-supported-devices.html for a list of supported backends

Last updated on

XSane-0.999

Introduction to XSane

XSane is another front end for SANE-1.0.32. It has additional features to improve the image quality and ease of use compared to xscanimage.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

XSane Dependencies

Required

GTK+-2.24.33 and SANE-1.0.32 (back ends)

Optional

Little CMS-1.19 and Gimp-2.10.30

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xsane

Installation of XSane

Install XSane by running the following commands:

sed -i -e 's/png_ptr->jmpbuf/png_jmpbuf(png_ptr)/' src/xsane-save.c &&
./configure --prefix=/usr                                           &&
make

This package does not come with a test suite.

Now, as the root user:

make xsanedocdir=/usr/share/doc/xsane-0.999 install &&
ln -v -s ../../doc/xsane-0.999 /usr/share/sane/xsane/doc

A browser of your choice can be used to get inline help, using the following command, as the root user:

ln -v -s <browser> /usr/bin/netscape

Note

Be sure to replace <browser> with the browser of your choice on your system.

Alternatively, if the environment variable BROWSER is set to the browser you want to use, eg, BROWSER="/usr/bin/firefox", the first time you run xsane, it will be recorded in ~/.sane/xsane/xsane.rc. If you wish to change it, edit this file, or remove it, and use the instructions above, so that a new one is created.

If GIMP is installed, issue the following command as the root user:

ln -v -s /usr/bin/xsane /usr/lib/gimp/2.0/plug-ins/

Command Explanations

ln -v -s ../../doc/xsane-0.999 /usr/share/sane/xsane/doc: This symlink is created to ensure that any program that looks for the XSane documentation in the default location will find it, as the documentation is installed in an alternate location specified in the make install command.

ln -v -s /usr/bin/xsane /usr/lib/gimp/2.0/plug-ins/: This creates a link in the system-wide GIMP plug-ins directory so that users can access XSane directly from GIMP. GIMP must be available before building XSane for this to work. Alternatively, create the link in ~/.gimp-2.0/plug-ins/ to provide individual user access. man xsane for additional information.

Contents

Installed Program: xsane
Installed Libraries: None
Installed Directory: /usr/share/doc/xsane-0.999 and /usr/share/sane/xsane

Short Descriptions

xsane

is a graphical user-interface to control an image acquisition device such as a flatbed scanner

Last updated on

Chapter 48. Standard Generalized Markup Language (SGML)

This chapter contains DocBook SGML document type definitions (DTDs), DocBook DSSSL Stylesheets and DocBook tools to validate, transform, format and publish DocBook documents.

sgml-common-0.6.3

Introduction to SGML Common

The SGML Common package contains install-catalog. This is useful for creating and maintaining centralized SGML catalogs.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/sgml-common

Installation of SGML Common

Instead of the normal convention of including the autotools files in the package, the maintainers included symlinks to the files in /usr/share/automake. For previous versions of Automake this convention is correct, but recent versions of Automake install the internal files in version specific directories. This causes the configure script to abort. To fix this error, the autotools are regenerated. Since the included Makefile.am file uses a syntax not supported by current versions of Automake, a patch is required to fix the syntax.

patch -Np1 -i ../sgml-common-0.6.3-manpage-1.patch &&
autoreconf -f -i

Install SGML Common by running the following commands:

./configure --prefix=/usr --sysconfdir=/etc &&
make

This package does not come with a test suite.

Now, as the root user:

make docdir=/usr/share/doc install &&

install-catalog --add /etc/sgml/sgml-ent.cat \
    /usr/share/sgml/sgml-iso-entities-8879.1986/catalog &&

install-catalog --add /etc/sgml/sgml-docbook.cat \
    /etc/sgml/sgml-ent.cat

Update Hint

Remove the above catalog items prior to upgrading (as the root user) with:

install-catalog --remove /etc/sgml/sgml-ent.cat \
    /usr/share/sgml/sgml-iso-entities-8879.1986/catalog &&

install-catalog --remove /etc/sgml/sgml-docbook.cat \
    /etc/sgml/sgml-ent.cat

Configuring SGML Common

Config Files

/etc/sgml/sgml.conf

Configuration Information

No change in this file is necessary.

Contents

Installed Programs: install-catalog and sgmlwhich
Installed Libraries: None
Installed Files: SGML and XML DocBook entity files
Installed Directories: /etc/sgml, /usr/share/doc/sgml-common-0.6.3, and /usr/share/sgml

Short Descriptions

install-catalog

creates a centralized catalog that maintains references to catalogs scattered throughout the /usr/share/sgml directory tree

sgmlwhich

prints to standard output the name of the main configuration file

SGML entities files

contains the basic character entities defined with SDATA entries

XML entities files

contains the basic character entities defined by a hexadecimal representation of the Unicode character number

Last updated on

docbook-3.1-dtd

Introduction to DocBook-3.1 SGML DTD

The DocBook SGML DTD package contains document type definitions for verification of SGML data files against the DocBook rule set. These are useful for structuring books and software documentation to a standard allowing you to utilize transformations already written for that standard.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

DocBook-3.1 SGML DTD Dependencies

Required

sgml-common-0.6.3 and UnZip-6.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/sgml-dtd-3

Installation of DocBook-3.1 SGML DTD

Note

The package source is distributed in zip format and requires unzip. You should create a directory and change to that directory before unzipping the file to ease the removal of the source files after the package has been installed.

Install DocBook-3.1 SGML DTD by running the following commands:

sed -i -e '/ISO 8879/d' \
       -e 's|DTDDECL "-//OASIS//DTD DocBook V3.1//EN"|SGMLDECL|g' \
       docbook.cat

This package does not come with a test suite.

Now, as the root user:

install -v -d -m755 /usr/share/sgml/docbook/sgml-dtd-3.1 &&
chown -R root:root . &&
install -v docbook.cat /usr/share/sgml/docbook/sgml-dtd-3.1/catalog &&
cp -v -af *.dtd *.mod *.dcl /usr/share/sgml/docbook/sgml-dtd-3.1 &&

install-catalog --add /etc/sgml/sgml-docbook-dtd-3.1.cat \
    /usr/share/sgml/docbook/sgml-dtd-3.1/catalog &&

install-catalog --add /etc/sgml/sgml-docbook-dtd-3.1.cat \
    /etc/sgml/sgml-docbook.cat

Command Explanations

sed -i -e '/ISO 8879/d' docbook.cat: This command removes the ENT definitions from the catalog file.

sed -i -e 's|DTDDECL "-//OASIS//DTD Docbook V3.1//EN"|SGMLDECL|g' docbook.cat: This command replaces the DTDDECL catalog entry, which is not supported by Linux SGML tools, with the SGMLDECL catalog entry.

Configuring DocBook-3.1 SGML DTD

Config Files

/etc/sgml/catalog

Configuration Information

The above installation script updates the catalog.

Using only the most current 3.x version of DocBook SGML DTD requires the following (perform as the root user):

cat >> /usr/share/sgml/docbook/sgml-dtd-3.1/catalog << "EOF"
  -- Begin Single Major Version catalog changes --

PUBLIC "-//Davenport//DTD DocBook V3.0//EN" "docbook.dtd"

  -- End Single Major Version catalog changes --
EOF

Contents

Installed Programs: None
Installed Libraries: None
Installed Files: SGML DTD and MOD files
Installed Directory: /usr/share/sgml/docbook/sgml-dtd-3.1

Short Descriptions

SGML DTD files

contains a document type definition which defines the element types and the attribute lists that can be used in the corresponding SGML files

SGML MOD files

contains components of the document type definition that are sourced into the DTD files

Last updated on

docbook-4.5-dtd

Introduction to DocBook-4.5 SGML DTD

The DocBook-4.5 SGML DTD package contains document type definitions for verification of SGML data files against the DocBook rule set. These are useful for structuring books and software documentation to a standard allowing you to utilize transformations already written for that standard.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

DocBook-4.5 SGML DTD Dependencies

Required

sgml-common-0.6.3 and UnZip-6.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/sgml-dtd

Installation of DocBook-4.5 SGML DTD

Note

The package source is distributed in zip format and requires unzip. You should create a directory and change to that directory before unzipping the file to ease the removal of the source files after the package has been installed.

Install DocBook-4.5 SGML DTD by running the following commands:

sed -i -e '/ISO 8879/d' \
       -e '/gml/d' docbook.cat

This package does not come with a test suite.

Now, as the root user:

install -v -d /usr/share/sgml/docbook/sgml-dtd-4.5 &&
chown -R root:root . &&

install -v docbook.cat /usr/share/sgml/docbook/sgml-dtd-4.5/catalog &&
cp -v -af *.dtd *.mod *.dcl /usr/share/sgml/docbook/sgml-dtd-4.5 &&

install-catalog --add /etc/sgml/sgml-docbook-dtd-4.5.cat \
    /usr/share/sgml/docbook/sgml-dtd-4.5/catalog &&

install-catalog --add /etc/sgml/sgml-docbook-dtd-4.5.cat \
    /etc/sgml/sgml-docbook.cat

Command Explanations

sed -i -e '/ISO 8879/d' -e '/gml/d' docbook.cat: This command removes the ENT definitions from the catalog file.

Configuring DocBook-4.5 SGML DTD

Config Files

/etc/sgml/catalog

Configuration Information

The above installation script updates the catalog.

Using only the most current 4.x version of DocBook SGML DTD requires the following (perform as the root user):

cat >> /usr/share/sgml/docbook/sgml-dtd-4.5/catalog << "EOF"
  -- Begin Single Major Version catalog changes --

PUBLIC "-//OASIS//DTD DocBook V4.4//EN" "docbook.dtd"
PUBLIC "-//OASIS//DTD DocBook V4.3//EN" "docbook.dtd"
PUBLIC "-//OASIS//DTD DocBook V4.2//EN" "docbook.dtd"
PUBLIC "-//OASIS//DTD DocBook V4.1//EN" "docbook.dtd"
PUBLIC "-//OASIS//DTD DocBook V4.0//EN" "docbook.dtd"

  -- End Single Major Version catalog changes --
EOF

Contents

Installed Programs: None
Installed Libraries: None
Installed Files: SGML DTD and MOD files
Installed Directory: /usr/share/sgml/docbook/sgml-dtd-4.5

Short Descriptions

SGML DTD files

contains a document type definition which defines the element types and the attribute lists that can be used in the corresponding SGML files

SGML MOD files

contains components of the document type definition that are sourced into the DTD files

Last updated on

OpenSP-1.5.2

Introduction to OpenSP

The OpenSP package contains a C++ library for using SGML/XML files. This is useful for validating, parsing and manipulating SGML and XML documents.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

OpenSP Dependencies

Required

sgml-common-0.6.3

Optional

libnsl-2.0.0 and xmlto-0.0.28

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/opensp

Installation of OpenSP

Install OpenSP by running the following commands:

sed -i 's/32,/253,/' lib/Syntax.cxx &&
sed -i 's/LITLEN          240 /LITLEN          8092/' \
    unicode/{gensyntax.pl,unicode.syn} &&

./configure --prefix=/usr                              \
            --disable-static                           \
            --disable-doc-build                        \
            --enable-default-catalog=/etc/sgml/catalog \
            --enable-http                              \
            --enable-default-search-path=/usr/share/sgml &&

make pkgdatadir=/usr/share/sgml/OpenSP-1.5.2

To test the results, issue: make check. As many as nine of the 23 tests may fail. Do not be alarmed.

Now, as the root user:

make pkgdatadir=/usr/share/sgml/OpenSP-1.5.2 \
     docdir=/usr/share/doc/OpenSP-1.5.2      \
     install &&

ln -v -sf onsgmls   /usr/bin/nsgmls   &&
ln -v -sf osgmlnorm /usr/bin/sgmlnorm &&
ln -v -sf ospam     /usr/bin/spam     &&
ln -v -sf ospcat    /usr/bin/spcat    &&
ln -v -sf ospent    /usr/bin/spent    &&
ln -v -sf osx       /usr/bin/sx       &&
ln -v -sf osx       /usr/bin/sgml2xml &&
ln -v -sf libosp.so /usr/lib/libsp.so

Command Explanations

sed -i 's/32,/253,/...unicode.syn}: These seds prevent some annoying messages that may otherwise appear while running openjade.

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-http: This switch adds support for HTTP.

--disable-doc-build: This switch prevents the configure script checking if you have xmlto installed. If you have xmlto, you can remove this option.

--enable-default-catalog=/etc/sgml/catalog: This switch sets the path to the centralized catalog.

--enable-default-search-path: This switch sets the default value of SGML_SEARCH_PATH.

--enable-xml-messages: This switch adds support for XML Formatted Messages.

make pkgdatadir=/usr/share/sgml/OpenSP-1.5.2 : This sets the pkgdatadir variable in the Makefile from /usr/share/OpenSP to /usr/share/sgml/OpenSP-1.5.2.

ln -v -sf ...: These commands create the SP equivalents of OpenSP executables and libraries.

Contents

Installed Programs: onsgmls, osgmlnorm, ospam, ospcat, ospent, osx, and the SP equivalent symlinks: nsgmls, sgml2xml, sgmlnorm, spam, spcat, spent, and sx
Installed Library: libosp.so and the SP equivalent symlink: libsp.so
Installed Directories: /usr/include/OpenSP, /usr/share/doc/OpenSP, and /usr/share/sgml/OpenSP-1.5.2

Short Descriptions

onsgmls

is used to process SGML files

osgmlnorm

prints on the standard output a normalized document instance for the SGML document contained in the concatenation of the entities with system identifiers .nf and .fi

ospam

is a markup stream editor

ospcat

prints effective system identifiers found in the catalogs

ospent

provides access to OpenSP's entity manager

osx

is an SGML normalizer or used to convert SGML files to XML files

nsgmls

is a symlink to onsgmls

sgml2xml

is a symlink to osx

sgmlnorm

is a symlink to osgmlnorm

spam

is a symlink to ospam

spcat

is a symlink to ospcat

spent

is a symlink to ospent

sx

is a symlink to osx

libosp.so

contains functions required by the OpenSP programs to parse, validate and manipulate SGML and XML files

libsp.so

is a symlink to libosp.so

Last updated on

OpenJade-1.3.2

Introduction to OpenJade

The OpenJade package contains a DSSSL engine. This is useful for SGML and XML transformations into RTF, TeX, SGML and XML.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Download

OpenJade Dependencies

Required

OpenSP-1.5.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/openjade

Installation of OpenJade

First fix problems when building with newer compilers:

patch -Np1 -i ../openjade-1.3.2-upstream-1.patch

Now fix a compilation problem with perl-5.16 and later:

sed -i -e '/getopts/{N;s#&G#g#;s#do .getopts.pl.;##;}' \
       -e '/use POSIX/ause Getopt::Std;' msggen.pl

Install OpenJade by running the following commands:

export CXXFLAGS="${CXXFLAGS:--O2 -g} -fno-lifetime-dse"            &&
./configure --prefix=/usr                                \
            --mandir=/usr/share/man                      \
            --enable-http                                \
            --disable-static                             \
            --enable-default-catalog=/etc/sgml/catalog   \
            --enable-default-search-path=/usr/share/sgml \
            --datadir=/usr/share/sgml/openjade-1.3.2   &&
make

This package does not come with a test suite.

Now, as the root user:

make install                                                   &&
make install-man                                               &&
ln -v -sf openjade /usr/bin/jade                               &&
ln -v -sf libogrove.so /usr/lib/libgrove.so                    &&
ln -v -sf libospgrove.so /usr/lib/libspgrove.so                &&
ln -v -sf libostyle.so /usr/lib/libstyle.so                    &&

install -v -m644 dsssl/catalog /usr/share/sgml/openjade-1.3.2/ &&

install -v -m644 dsssl/*.{dtd,dsl,sgm}              \
    /usr/share/sgml/openjade-1.3.2                             &&

install-catalog --add /etc/sgml/openjade-1.3.2.cat  \
    /usr/share/sgml/openjade-1.3.2/catalog                     &&

install-catalog --add /etc/sgml/sgml-docbook.cat    \
    /etc/sgml/openjade-1.3.2.cat

Command Explanations

export CXXFLAGS=...: This command prevents segmentation faults when the package is compiled with gcc-6.1.

make install-man: This command installs the openjade man page.

--disable-static: This switch prevents the building of the static library.

--enable-http: This switch adds support for HTTP.

--enable-default-catalog=/etc/sgml/catalog: This switch sets the path to the centralized catalog.

--enable-default-search-path: This switch sets the default value of SGML_SEARCH_PATH.

--datadir=/usr/share/sgml/openjade-1.3.2: This switch puts data files in /usr/share/sgml/openjade-1.3.2 instead of /usr/share.

ln -v -sf ...: These commands create the Jade equivalents of OpenJade executables and libraries.

Configuring OpenJade

Configuration Information

As the root user:

echo "SYSTEM \"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd\" \
    \"/usr/share/xml/docbook/xml-dtd-4.5/docbookx.dtd\"" >> \
    /usr/share/sgml/openjade-1.3.2/catalog

This configuration is only necessary if you intend to use OpenJade to process the BLFS XML files through DSSSL Stylesheets.

Contents

Installed Programs: openjade and the Jade equivalent symlink, jade
Installed Libraries: libogrove.so, libospgrove.so, libostyle.so, and the Jade equivalent symlinks: libgrove.so, libspgrove.so, and libstyle.so
Installed Directory: /usr/share/sgml/openjade-1.3.2

Short Descriptions

openjade

is a DSSSL engine used for transformations

jade

is a symlink to openjade

Last updated on

docbook-dsssl-1.79

Introduction to DocBook DSSSL Stylesheets

The DocBook DSSSL Stylesheets package contains DSSSL stylesheets. These are used by OpenJade or other tools to transform SGML and XML DocBook files.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Documentation and test data

DocBook DSSSL Stylesheets Dependencies

Required

sgml-common-0.6.3

Required (to Test the DocBook SGML Toolchain)

docbook-3.1-dtd, docbook-4.5-dtd, OpenSP-1.5.2, and OpenJade-1.3.2

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/docbook-dsssl

Installation of DocBook DSSSL Stylesheets

If you downloaded the documentation, run:

tar -xf ../docbook-dsssl-doc-1.79.tar.bz2 --strip-components=1

Install DocBook DSSSL Stylesheets by running the following commands as the root user:

install -v -m755 bin/collateindex.pl /usr/bin                      &&
install -v -m644 bin/collateindex.pl.1 /usr/share/man/man1         &&
install -v -d -m755 /usr/share/sgml/docbook/dsssl-stylesheets-1.79 &&
cp -v -R * /usr/share/sgml/docbook/dsssl-stylesheets-1.79          &&

install-catalog --add /etc/sgml/dsssl-docbook-stylesheets.cat \
    /usr/share/sgml/docbook/dsssl-stylesheets-1.79/catalog         &&

install-catalog --add /etc/sgml/dsssl-docbook-stylesheets.cat \
    /usr/share/sgml/docbook/dsssl-stylesheets-1.79/common/catalog  &&

install-catalog --add /etc/sgml/sgml-docbook.cat              \
    /etc/sgml/dsssl-docbook-stylesheets.cat

Command Explanations

The above commands create an installation script for this package.

Testing the DocBook SGML Toolchain (Optional)

The following commands will perform the necessary tests to confirm that your installed DocBook SGML toolchain will produce desired results. You must have the docbook-3.1-dtd, docbook-4.5-dtd, OpenSP-1.5.2, and OpenJade-1.3.2 packages installed, and perform the tests as the root user.

All tests will be performed from the /usr/share/sgml/docbook/dsssl-stylesheets-1.79/doc/testdata directory as the root user:

cd /usr/share/sgml/docbook/dsssl-stylesheets-1.79/doc/testdata

The first test should produce no output to stdout (your screen) and create a file named jtest.rtf in the current directory:

openjade -t rtf -d jtest.dsl jtest.sgm

The next test should return only the following line to stdout: onsgmls:I: "OpenSP" version "1.5.2"

onsgmls -sv test.sgm

The next test should produce no output to stdout and create a file named test.rtf in the current directory:

openjade -t rtf \
    -d /usr/share/sgml/docbook/dsssl-stylesheets-1.79/print/docbook.dsl \
    test.sgm

The last test should produce no output to stdout and create a file named c1.htm in the current directory:

openjade -t sgml \
    -d /usr/share/sgml/docbook/dsssl-stylesheets-1.79/html/docbook.dsl \
    test.sgm

Finally, clean up:

rm jtest.rtf test.rtf c1.htm

Contents

Installed Program: collateindex.pl
Installed Libraries: None
Installed Files: DSSSL stylesheets
Installed Directory: /usr/share/sgml/docbook/dsssl-stylesheets-1.79

Short Descriptions

collateindex.pl

is a Perl script that creates a DocBook index from raw index data

Last updated on

DocBook-utils-0.6.14

Introduction to DocBook-utils

The DocBook-utils package is a collection of utility scripts used to convert and analyze SGML documents in general, and DocBook files in particular. The scripts are used to convert from DocBook or other SGML formats into classical file formats like HTML, man, info, RTF and many more. There's also a utility to compare two SGML files and only display the differences in markup. This is useful for comparing documents prepared for different languages.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

DocBook-utils Dependencies

Required

OpenJade-1.3.2, docbook-dsssl-1.79, and docbook-3.1-dtd

Optional (Runtime Dependencies Only)

SGMLSpm-1.1 (for conversion to man and texinfo), and Lynx-2.8.9rel.1 or Links-2.25 or W3m (for conversion to ASCII text)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/docbook-utils

Installation of DocBook-utils

Install DocBook-utils by running the following commands:

patch -Np1 -i ../docbook-utils-0.6.14-grep_fix-1.patch &&
sed -i 's:/html::' doc/HTML/Makefile.in                &&

./configure --prefix=/usr --mandir=/usr/share/man      &&
make

This package does not come with a test suite.

Now, as the root user:

make docdir=/usr/share/doc install

Many packages use an alternate name for the DocBook-utils scripts. If you wish to create these alternate names, use the following command as the root user:

for doctype in html ps dvi man pdf rtf tex texi txt
do
    ln -svf docbook2$doctype /usr/bin/db2$doctype
done

Note

The jw script uses the which command to locate required utilities. You must install Which-2.21 before attempting to use any of the DocBook-utils programs.

Command Explanations

patch -Np1 -i ../docbook-utils-0.6.14-grep_fix-1.patch: This patch corrects the syntax in the jw (Jade Wrapper) script which is at the heart of much db2* processing, so that the current version of grep will not reject it.

sed -i 's:/html::' doc/HTML/Makefile.in: This command changes the installation directory of the HTML documents.

docdir=/usr/share/doc: This option is placed on the make install line because is is not recognized by configure.

Contents

Installed Programs: docbook2dvi, docbook2html, docbook2man, docbook2pdf, docbook2ps, docbook2rtf, docbook2tex, docbook2texi, docbook2txt, jw, and sgmldiff
Installed Libraries: None
Installed Directories: /usr/share/doc/docbook-utils-0.6.14 and /usr/share/sgml/docbook/utils-0.6.14
Installed Symlinks: db2dvi, db2html, db2man, db2pdf, db2ps, db2rtf, db2tex, db2texi, and db2txt

Short Descriptions

docbook2*

are simple one-line wrapper scripts to jw. They are provided as easy-to-remember names used to convert DocBook or other SGML files to the respective format

db2*

are symlinks pointing at the respectively named docbook2* commands, created to satisfy some program's use of these names

jw

is a script used to convert DocBook or other SGML files to various output formats. It hides most of OpenJade's complexity and adds comfortable features

sgmldiff

is used to compare two SGML files and only return the differences in the markup. This is especially useful to compare files that should be identical except for language differences in the content

Last updated on

Chapter 49. Extensible Markup Language (XML)

This chapter contains the DocBook XML document type definition (DTD) and DocBook Stylesheets which are used to validate, transform, format and publish DocBook documents.

docbook-xml-4.5

Introduction to DocBook-4.5 XML DTD

The DocBook-4.5 XML DTD-4.5 package contains document type definitions for verification of XML data files against the DocBook rule set. These are useful for structuring books and software documentation to a standard allowing you to utilize transformations already written for that standard.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

DocBook-4.5 XML DTD Dependencies

Required

libxml2-2.9.13, sgml-common-0.6.3, and UnZip-6.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/docbook-xml

Installation of DocBook-4.5 XML DTD

Note

The package source is distributed in zip format and requires unzip. You should create a directory and change to that directory before unzipping the file to ease the removal of the source files after the package has been installed.

Install DocBook XML DTD by running the following commands as the root user:

install -v -d -m755 /usr/share/xml/docbook/xml-dtd-4.5 &&
install -v -d -m755 /etc/xml &&
chown -R root:root . &&
cp -v -af docbook.cat *.dtd ent/ *.mod \
    /usr/share/xml/docbook/xml-dtd-4.5

Create (or update) and populate the /etc/xml/docbook catalog file by running the following commands as the root user:

if [ ! -e /etc/xml/docbook ]; then
    xmlcatalog --noout --create /etc/xml/docbook
fi &&
xmlcatalog --noout --add "public" \
    "-//OASIS//DTD DocBook XML V4.5//EN" \
    "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" \
    /etc/xml/docbook &&
xmlcatalog --noout --add "public" \
    "-//OASIS//DTD DocBook XML CALS Table Model V4.5//EN" \
    "file:///usr/share/xml/docbook/xml-dtd-4.5/calstblx.dtd" \
    /etc/xml/docbook &&
xmlcatalog --noout --add "public" \
    "-//OASIS//DTD XML Exchange Table Model 19990315//EN" \
    "file:///usr/share/xml/docbook/xml-dtd-4.5/soextblx.dtd" \
    /etc/xml/docbook &&
xmlcatalog --noout --add "public" \
    "-//OASIS//ELEMENTS DocBook XML Information Pool V4.5//EN" \
    "file:///usr/share/xml/docbook/xml-dtd-4.5/dbpoolx.mod" \
    /etc/xml/docbook &&
xmlcatalog --noout --add "public" \
    "-//OASIS//ELEMENTS DocBook XML Document Hierarchy V4.5//EN" \
    "file:///usr/share/xml/docbook/xml-dtd-4.5/dbhierx.mod" \
    /etc/xml/docbook &&
xmlcatalog --noout --add "public" \
    "-//OASIS//ELEMENTS DocBook XML HTML Tables V4.5//EN" \
    "file:///usr/share/xml/docbook/xml-dtd-4.5/htmltblx.mod" \
    /etc/xml/docbook &&
xmlcatalog --noout --add "public" \
    "-//OASIS//ENTITIES DocBook XML Notations V4.5//EN" \
    "file:///usr/share/xml/docbook/xml-dtd-4.5/dbnotnx.mod" \
    /etc/xml/docbook &&
xmlcatalog --noout --add "public" \
    "-//OASIS//ENTITIES DocBook XML Character Entities V4.5//EN" \
    "file:///usr/share/xml/docbook/xml-dtd-4.5/dbcentx.mod" \
    /etc/xml/docbook &&
xmlcatalog --noout --add "public" \
    "-//OASIS//ENTITIES DocBook XML Additional General Entities V4.5//EN" \
    "file:///usr/share/xml/docbook/xml-dtd-4.5/dbgenent.mod" \
    /etc/xml/docbook &&
xmlcatalog --noout --add "rewriteSystem" \
    "http://www.oasis-open.org/docbook/xml/4.5" \
    "file:///usr/share/xml/docbook/xml-dtd-4.5" \
    /etc/xml/docbook &&
xmlcatalog --noout --add "rewriteURI" \
    "http://www.oasis-open.org/docbook/xml/4.5" \
    "file:///usr/share/xml/docbook/xml-dtd-4.5" \
    /etc/xml/docbook

Create (or update) and populate the /etc/xml/catalog catalog file by running the following commands as the root user:

if [ ! -e /etc/xml/catalog ]; then
    xmlcatalog --noout --create /etc/xml/catalog
fi &&
xmlcatalog --noout --add "delegatePublic" \
    "-//OASIS//ENTITIES DocBook XML" \
    "file:///etc/xml/docbook" \
    /etc/xml/catalog &&
xmlcatalog --noout --add "delegatePublic" \
    "-//OASIS//DTD DocBook XML" \
    "file:///etc/xml/docbook" \
    /etc/xml/catalog &&
xmlcatalog --noout --add "delegateSystem" \
    "http://www.oasis-open.org/docbook/" \
    "file:///etc/xml/docbook" \
    /etc/xml/catalog &&
xmlcatalog --noout --add "delegateURI" \
    "http://www.oasis-open.org/docbook/" \
    "file:///etc/xml/docbook" \
    /etc/xml/catalog

Configuring DocBook-4.5 XML DTD

Config Files

/etc/xml/catalog and /etc/xml/docbook

Configuration Information

Caution

Various BLFS packages request DocBook XML DTD version 4.x before V4.5, so the following step must be done for those packages to be built successfully.

The above installation creates the files and updates the catalogs. In order to utilize DocBook XML DTD V4.5 when any version 4.x is requested in the System Identifier, you need to add additional statements to the catalog files. If you have any of the DocBook XML DTD's referenced below already installed on your system, remove those entries from the for command below (issue the commands as the root user):

for DTDVERSION in 4.1.2 4.2 4.3 4.4
do
  xmlcatalog --noout --add "public" \
    "-//OASIS//DTD DocBook XML V$DTDVERSION//EN" \
    "http://www.oasis-open.org/docbook/xml/$DTDVERSION/docbookx.dtd" \
    /etc/xml/docbook
  xmlcatalog --noout --add "rewriteSystem" \
    "http://www.oasis-open.org/docbook/xml/$DTDVERSION" \
    "file:///usr/share/xml/docbook/xml-dtd-4.5" \
    /etc/xml/docbook
  xmlcatalog --noout --add "rewriteURI" \
    "http://www.oasis-open.org/docbook/xml/$DTDVERSION" \
    "file:///usr/share/xml/docbook/xml-dtd-4.5" \
    /etc/xml/docbook
  xmlcatalog --noout --add "delegateSystem" \
    "http://www.oasis-open.org/docbook/xml/$DTDVERSION/" \
    "file:///etc/xml/docbook" \
    /etc/xml/catalog
  xmlcatalog --noout --add "delegateURI" \
    "http://www.oasis-open.org/docbook/xml/$DTDVERSION/" \
    "file:///etc/xml/docbook" \
    /etc/xml/catalog
done

Contents

Installed Programs: None
Installed Libraries: None
Installed Files: DTD, MOD and ENT files
Installed Directories: /etc/xml and /usr/share/xml/docbook/xml-dtd-4.5

Short Descriptions

DTD files

contain a document type definition which defines the element types and the attribute lists that can be used in the corresponding XML files

MOD files

contain components of the document type definition that are sourced into the DTD files

ENT files

contain lists of named character entities allowed in HTML

Last updated on

docbook-xml-5.0

Introduction to DocBook XML DTD and Schemas 5.0

The DocBook XML DTD and Schemas-5.0 package contains document type definitions and schemas for verification of XML data files against the DocBook rule set. These are useful for structuring books and software documentation to a standard allowing you to utilize transformations already written for that standard. In addition to providing a DTD, version 5 introduced the RelaxNG schema and Schematron rules, and is incompatible with previous versions of DocBook XML.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

DocBook XML DTD and Schemas 5.0 Dependencies

Required

libxml2-2.9.13, sgml-common-0.6.3, and UnZip-6.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/docbook5-xml

Installation of DocBook XML DTD and Schemas 5.0

Install DocBook XML DTD and Schemas by running the following commands as the root user:

install -vdm755 /usr/share/xml/docbook/schema/{dtd,rng,sch,xsd}/5.0 &&
install -vm644  dtd/* /usr/share/xml/docbook/schema/dtd/5.0         &&
install -vm644  rng/* /usr/share/xml/docbook/schema/rng/5.0         &&
install -vm644  sch/* /usr/share/xml/docbook/schema/sch/5.0         &&
install -vm644  xsd/* /usr/share/xml/docbook/schema/xsd/5.0

Create (or update) and populate the /etc/xml/docbook-5.0 catalog file by running the following commands as the root user:

if [ ! -e /etc/xml/docbook-5.0 ]; then
    xmlcatalog --noout --create /etc/xml/docbook-5.0
fi &&

xmlcatalog --noout --add "public" \
  "-//OASIS//DTD DocBook XML 5.0//EN" \
  "file:///usr/share/xml/docbook/schema/dtd/5.0/docbook.dtd" \
  /etc/xml/docbook-5.0 &&
xmlcatalog --noout --add "system" \
  "http://www.oasis-open.org/docbook/xml/5.0/dtd/docbook.dtd" \
  "file:///usr/share/xml/docbook/schema/dtd/5.0/docbook.dtd" \
  /etc/xml/docbook-5.0 &&
xmlcatalog --noout --add "system" \
  "http://docbook.org/xml/5.0/dtd/docbook.dtd" \
  "file:///usr/share/xml/docbook/schema/dtd/5.0/docbook.dtd" \
  /etc/xml/docbook-5.0 &&

xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.0/rng/docbook.rng" \
  "file:///usr/share/xml/docbook/schema/rng/5.0/docbook.rng" \
  /etc/xml/docbook-5.0 &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.0/rng/docbook.rng" \
  "file:///usr/share/xml/docbook/schema/rng/5.0/docbook.rng" \
  /etc/xml/docbook-5.0 &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.0/rng/docbookxi.rng" \
  "file:///usr/share/xml/docbook/schema/rng/5.0/docbookxi.rng" \
  /etc/xml/docbook-5.0 &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.0/rng/docbookxi.rng" \
  "file:///usr/share/xml/docbook/schema/rng/5.0/docbookxi.rng" \
  /etc/xml/docbook-5.0 &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.0/rnc/docbook.rnc" \
  "file:///usr/share/xml/docbook/schema/rng/5.0/docbook.rnc" \
  /etc/xml/docbook-5.0 &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.0/rng/docbook.rnc" \
  "file:///usr/share/xml/docbook/schema/rng/5.0/docbook.rnc" \
  /etc/xml/docbook-5.0 &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.0/rnc/docbookxi.rnc" \
  "file:///usr/share/xml/docbook/schema/rng/5.0/docbookxi.rnc" \
  /etc/xml/docbook-5.0 &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.0/rng/docbookxi.rnc" \
  "file:///usr/share/xml/docbook/schema/rng/5.0/docbookxi.rnc" \
  /etc/xml/docbook-5.0 &&

xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.0/xsd/docbook.xsd" \
  "file:///usr/share/xml/docbook/schema/xsd/5.0/docbook.xsd" \
  /etc/xml/docbook-5.0 &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.0/xsd/docbook.xsd" \
  "file:///usr/share/xml/docbook/schema/xsd/5.0/docbook.xsd" \
  /etc/xml/docbook-5.0 &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.0/xsd/docbookxi.xsd" \
  "file:///usr/share/xml/docbook/schema/xsd/5.0/docbookxi.xsd" \
  /etc/xml/docbook-5.0 &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.0/xsd/docbookxi.xsd" \
  "file:///usr/share/xml/docbook/schema/xsd/5.0/docbookxi.xsd" \
  /etc/xml/docbook-5.0 &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.0/xsd/xi.xsd" \
  "file:///usr/share/xml/docbook/schema/xsd/5.0/xi.xsd" \
  /etc/xml/docbook-5.0 &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.0/xsd/xi.xsd" \
  "file:///usr/share/xml/docbook/schema/xsd/5.0/xi.xsd" \
  /etc/xml/docbook-5.0 &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.0/xsd/xlink.xsd" \
  "file:///usr/share/xml/docbook/schema/xsd/5.0/xlink.xsd" \
  /etc/xml/docbook-5.0 &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.0/xsd/xlink.xsd" \
  "file:///usr/share/xml/docbook/schema/xsd/5.0/xlink.xsd" \
  /etc/xml/docbook-5.0 &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.0/xsd/xml.xsd" \
  "file:///usr/share/xml/docbook/schema/xsd/5.0/xml.xsd" \
  /etc/xml/docbook-5.0 &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.0/xsd/xml.xsd" \
  "file:///usr/share/xml/docbook/schema/xsd/5.0/xml.xsd" \
  /etc/xml/docbook-5.0 &&

xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.0/sch/docbook.sch" \
  "file:///usr/share/xml/docbook/schema/sch/5.0/docbook.sch" \
  /etc/xml/docbook-5.0 &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.0/sch/docbook.sch" \
  "file:///usr/share/xml/docbook/schema/sch/5.0/docbook.sch" \
  /etc/xml/docbook-5.0

While again as the root user, create the individual catalogs:

xmlcatalog --noout --create /usr/share/xml/docbook/schema/dtd/5.0/catalog.xml &&

xmlcatalog --noout --add "public" \
  "-//OASIS//DTD DocBook XML 5.0//EN" \
  "docbook.dtd" /usr/share/xml/docbook/schema/dtd/5.0/catalog.xml &&
xmlcatalog --noout --add "system" \
  "http://www.oasis-open.org/docbook/xml/5.0/dtd/docbook.dtd" \
  "docbook.dtd" /usr/share/xml/docbook/schema/dtd/5.0/catalog.xml &&

xmlcatalog --noout --create /usr/share/xml/docbook/schema/rng/5.0/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.0/rng/docbook.rng" \
  "docbook.rng" /usr/share/xml/docbook/schema/rng/5.0/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.0/rng/docbook.rng" \
  "docbook.rng" /usr/share/xml/docbook/schema/rng/5.0/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.0/rng/docbookxi.rng" \
  "docbookxi.rng" /usr/share/xml/docbook/schema/rng/5.0/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.0/rng/docbookxi.rng" \
  "docbookxi.rng" /usr/share/xml/docbook/schema/rng/5.0/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.0/rng/docbook.rnc" \
  "docbook.rnc" /usr/share/xml/docbook/schema/rng/5.0/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.0/rng/docbook.rnc" \
  "docbook.rnc" /usr/share/xml/docbook/schema/rng/5.0/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.0/rng/docbookxi.rnc" \
  "docbookxi.rnc" /usr/share/xml/docbook/schema/rng/5.0/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.0/rng/docbookxi.rnc" \
  "docbookxi.rnc" /usr/share/xml/docbook/schema/rng/5.0/catalog.xml &&

xmlcatalog --noout --create /usr/share/xml/docbook/schema/sch/5.0/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.0/sch/docbook.sch" \
  "docbook.sch" /usr/share/xml/docbook/schema/sch/5.0/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.0/sch/docbook.sch" \
  "docbook.sch" /usr/share/xml/docbook/schema/sch/5.0/catalog.xml &&

xmlcatalog --noout --create /usr/share/xml/docbook/schema/xsd/5.0/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.0/xsd/docbook.xsd" \
  "docbook.xsd" /usr/share/xml/docbook/schema/xsd/5.0/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.0/xsd/docbook.xsd" \
  "docbook.xsd" /usr/share/xml/docbook/schema/xsd/5.0/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.0/xsd/docbookxi.xsd" \
  "docbookxi.xsd" /usr/share/xml/docbook/schema/xsd/5.0/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.0/xsd/docbookxi.xsd" \
  "docbookxi.xsd" /usr/share/xml/docbook/schema/xsd/5.0/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.0/xsd/xlink.xsd" \
  "xlink.xsd" /usr/share/xml/docbook/schema/xsd/5.0/catalog.xml &&
xmlcatalog --noout --add "uri" \
   "http://www.oasis-open.org/docbook/xml/5.0/xsd/xlink.xsd" \
   "xlink.xsd" /usr/share/xml/docbook/schema/xsd/5.0/catalog.xml &&
xmlcatalog --noout --add "uri" \
   "http://docbook.org/xml/5.0/xsd/xml.xsd" \
   "xml.xsd" /usr/share/xml/docbook/schema/xsd/5.0/catalog.xml &&
xmlcatalog --noout --add "uri" \
   "http://www.oasis-open.org/docbook/xml/5.0/xsd/xml.xsd" \
   "xml.xsd" /usr/share/xml/docbook/schema/xsd/5.0/catalog.xml

Create (or update) and populate the system XML catalog (/etc/xml/catalog) by running the following commands as the root user:

if [ ! -e /etc/xml/catalog ]; then
    xmlcatalog --noout --create /etc/xml/catalog
fi &&
xmlcatalog --noout --add "delegatePublic" \
  "-//OASIS//DTD DocBook XML 5.0//EN" \
  "file:///usr/share/xml/docbook/schema/dtd/5.0/catalog.xml" \
  /etc/xml/catalog &&
xmlcatalog --noout --add "delegateSystem" \
  "http://docbook.org/xml/5.0/dtd/" \
  "file:///usr/share/xml/docbook/schema/dtd/5.0/catalog.xml" \
  /etc/xml/catalog &&
xmlcatalog --noout --add "delegateURI" \
  "http://docbook.org/xml/5.0/dtd/" \
  "file:///usr/share/xml/docbook/schema/dtd/5.0/catalog.xml" \
  /etc/xml/catalog &&
xmlcatalog --noout --add "delegateURI" \
  "http://docbook.org/xml/5.0/rng/"  \
  "file:///usr/share/xml/docbook/schema/rng/5.0/catalog.xml" \
  /etc/xml/catalog &&
xmlcatalog --noout --add "delegateURI" \
  "http://docbook.org/xml/5.0/sch/"  \
  "file:///usr/share/xml/docbook/schema/sch/5.0/catalog.xml" \
  /etc/xml/catalog &&
xmlcatalog --noout --add "delegateURI" \
  "http://docbook.org/xml/5.0/xsd/"  \
  "file:///usr/share/xml/docbook/schema/xsd/5.0/catalog.xml" \
  /etc/xml/catalog

Configuring DocBook XML DTD and Schemas 5.0

Config Files

/etc/xml/catalog and /etc/xml/docbook-5.0

Contents

Installed Files: DTD, RNC, RNG, SCH and XSD files
Installed Directories: /etc/xml and /usr/share/xml/docbook/schema/{dtd,rng,sch,xsd}/5.0

Short Descriptions

DTD files

contain the DocBook 5.0 document type definitions which define the element types and the attribute lists that can be used in the corresponding XML files

RNC, RNG, and SCH files

contain the Docbook 5.0 RelaxNG, RelaxNG Compact, and Schematron schema definitions

XSD files

files contain DocBook-5.0 Schematron rules

Last updated on

docbook-xml-5.1

Introduction to DocBook XML Schemas 5.1

The DocBook XML Schemas-5.1 package contains schema files and Schematron rules for verification of XML data files against the DocBook rule set. These are useful for structuring books and software documentation to a standard allowing you to utilize transformations already written for that standard.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

DocBook XML Schemas 5.1 Dependencies

Required

libxml2-2.9.13, sgml-common-0.6.3, and UnZip-6.0

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/docbook51-xml

Installation of DocBook XML Schemas 5.1

Note

The package source is distributed in zip format and requires unzip. You should create a directory and change to that directory before unzipping the file to ease the removal of the source files after the package has been installed.

Install DocBook XML Schemas by running the following commands as the root user:

install -vdm755 /usr/share/xml/docbook/schema/{rng,sch}/5.1         &&
install -m644   schemas/rng/* /usr/share/xml/docbook/schema/rng/5.1 &&
install -m644   schemas/sch/* /usr/share/xml/docbook/schema/sch/5.1 &&
install -m755   tools/db4-entities.pl /usr/bin                      &&
install -vdm755 /usr/share/xml/docbook/stylesheet/docbook5          &&
install -m644   tools/db4-upgrade.xsl \
                /usr/share/xml/docbook/stylesheet/docbook5

Create (or update) and populate the /etc/xml/docbook-5.1 catalog file by running the following commands as the root user:

if [ ! -e /etc/xml/docbook-5.1 ]; then
  xmlcatalog --noout --create /etc/xml/docbook-5.1
fi &&

xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.1/rng/docbook.rng" \
  "file:///usr/share/xml/docbook/schema/rng/5.1/docbook.rng" \
  /etc/xml/docbook-5.1 &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.1/rng/docbook.rng" \
  "file:///usr/share/xml/docbook/schema/rng/5.1/docbook.rng" \
  /etc/xml/docbook-5.1 &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.1/rng/docbookxi.rng" \
  "file:///usr/share/xml/docbook/schema/rng/5.1/docbookxi.rng" \
  /etc/xml/docbook-5.1 &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.1/rng/docbookxi.rng" \
  "file:///usr/share/xml/docbook/schema/rng/5.1/docbookxi.rng" \
  /etc/xml/docbook-5.1 &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.1/rnc/docbook.rnc" \
  "file:///usr/share/xml/docbook/schema/rng/5.1/docbook.rnc" \
  /etc/xml/docbook-5.1 &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.1/rng/docbook.rnc" \
  "file:///usr/share/xml/docbook/schema/rng/5.1/docbook.rnc" \
  /etc/xml/docbook-5.1 &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.1/rnc/docbookxi.rnc" \
  "file:///usr/share/xml/docbook/schema/rng/5.1/docbookxi.rnc" \
  /etc/xml/docbook-5.1 &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.1/rng/docbookxi.rnc" \
  "file:///usr/share/xml/docbook/schema/rng/5.1/docbookxi.rnc" \
  /etc/xml/docbook-5.1 &&

xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.1/sch/docbook.sch" \
  "file:///usr/share/xml/docbook/schema/sch/5.1/docbook.sch" \
  /etc/xml/docbook-5.1 &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.1/sch/docbook.sch" \
  "file:///usr/share/xml/docbook/schema/sch/5.1/docbook.sch" \
  /etc/xml/docbook-5.1

While again as the root user, create the individual catalogs:

xmlcatalog --noout --create /usr/share/xml/docbook/schema/rng/5.1/catalog.xml &&

xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.1/schemas/rng/docbook.schemas/rng" \
  "docbook.schemas/rng" /usr/share/xml/docbook/schema/rng/5.1/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.1/schemas/rng/docbook.schemas/rng" \
  "docbook.schemas/rng" /usr/share/xml/docbook/schema/rng/5.1/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.1/schemas/rng/docbookxi.schemas/rng" \
  "docbookxi.schemas/rng" /usr/share/xml/docbook/schema/rng/5.1/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.1/schemas/rng/docbookxi.schemas/rng" \
  "docbookxi.schemas/rng" /usr/share/xml/docbook/schema/rng/5.1/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.1/schemas/rng/docbook.rnc" \
  "docbook.rnc" /usr/share/xml/docbook/schema/rng/5.1/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.1/schemas/rng/docbook.rnc" \
  "docbook.rnc" /usr/share/xml/docbook/schema/rng/5.1/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.1/schemas/rng/docbookxi.rnc" \
  "docbookxi.rnc" /usr/share/xml/docbook/schema/rng/5.1/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.1/schemas/rng/docbookxi.rnc" \
  "docbookxi.rnc" /usr/share/xml/docbook/schema/rng/5.1/catalog.xml
xmlcatalog --noout --create /usr/share/xml/docbook/schema/sch/5.1/catalog.xml &&

xmlcatalog --noout --add "uri" \
  "http://docbook.org/xml/5.1/schemas/sch/docbook.schemas/sch" \
  "docbook.schemas/sch" /usr/share/xml/docbook/schema/sch/5.1/catalog.xml &&
xmlcatalog --noout --add "uri" \
  "http://www.oasis-open.org/docbook/xml/5.1/schemas/sch/docbook.schemas/sch" \
  "docbook.schemas/sch" /usr/share/xml/docbook/schema/sch/5.1/catalog.xml

Create (or update) and populate the system XML catalog (/etc/xml/catalog) by running the following commands as the root user:

if [ ! -e /etc/xml/catalog ]; then
  xmlcatalog --noout --create /etc/xml/catalog
fi &&
xmlcatalog --noout --add "delegatePublic" \
  "-//OASIS//DTD DocBook XML 5.1//EN" \
  "file:///usr/share/xml/docbook/schema/dtd/5.1/catalog.xml" \
  /etc/xml/catalog &&
xmlcatalog --noout --add "delegateSystem" \
  "http://docbook.org/xml/5.1/dtd/" \
  "file:///usr/share/xml/docbook/schema/dtd/5.1/catalog.xml" \
  /etc/xml/catalog &&
xmlcatalog --noout --add "delegateURI" \
  "http://docbook.org/xml/5.1/dtd/" \
  "file:///usr/share/xml/docbook/schema/dtd/5.1/catalog.xml" \
  /etc/xml/catalog &&
xmlcatalog --noout --add "delegateURI" \
  "http://docbook.org/xml/5.1/rng/"  \
  "file:///usr/share/xml/docbook/schema/rng/5.1/catalog.xml" \
  /etc/xml/catalog &&
xmlcatalog --noout --add "delegateURI" \
  "http://docbook.org/xml/5.1/sch/"  \
  "file:///usr/share/xml/docbook/schema/sch/5.1/catalog.xml" \
  /etc/xml/catalog &&
xmlcatalog --noout --add "delegateURI" \
  "http://docbook.org/xml/5.1/xsd/"  \
  "file:///usr/share/xml/docbook/schema/xsd/5.1/catalog.xml" \
  /etc/xml/catalog

Configuring DocBook XML Schemas 5.1

Config Files

/etc/xml/catalog and /etc/xml/docbook-5.1

Contents

Installed Programs: db4-entities.pl
Installed Files: RNC, RNG, SCH, and XSL files
Installed Directories: /etc/xml, /usr/share/xml/docbook/stylesheets, and /usr/share/xml/docbook/schema/{rng,sch}/5.1

Short Descriptions

db4-entities.pl

is a script to convert DocBook 4.x filed to DocBook 5.1

RNC, RNG, and SCH files

contain the Docbook 5.1 RelaxNG, RelaxNG Compact, and Schematron schema definitions

db4-upgrade.xsl

is an XSL stylesheet to assist in conversion from DocBook 4.x files to DocBook 5.1

Last updated on

docbook-xsl-nons-1.79.2

Introduction to DocBook XSL Stylesheets

The DocBook XSL Stylesheets package contains XSL stylesheets. These are useful for performing transformations on XML DocBook files.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Optional documentation

DocBook XSL Stylesheets Dependencies

Recommended (at runtime)
Optional (all used at runtime)

apache-ant-1.10.12 (to produce webhelp documents), libxslt-1.1.35 (or any other XSLT processor), to process Docbook documents - the Python2 modules libxml2 and libxslt can be used, Python-2.7.18 (at runtime), Ruby-3.1.0 (to utilize the epub stylesheets), Zip-3.0 (to produce epub3 documents), and Saxon6 and Xerces2 Java (used with apache-ant-1.10.12 to produce webhelp documents)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/docbook-xsl

Installation of DocBook XSL Stylesheets

First, fix a problem that causes stack overflows when doing recursion:

patch -Np1 -i ../docbook-xsl-nons-1.79.2-stack_fix-1.patch

If you downloaded the optional documentation tarball, unpack it with the following command:

tar -xf ../docbook-xsl-doc-1.79.2.tar.bz2 --strip-components=1

BLFS does not install the required packages to run the test suite and provide meaningful results.

Install DocBook XSL Stylesheets by running the following commands as the root user:

install -v -m755 -d /usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2 &&

cp -v -R VERSION assembly common eclipse epub epub3 extensions fo        \
         highlighting html htmlhelp images javahelp lib manpages params  \
         profiling roundtrip slides template tests tools webhelp website \
         xhtml xhtml-1_1 xhtml5                                          \
    /usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2 &&

ln -s VERSION /usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2/VERSION.xsl &&

install -v -m644 -D README \
                    /usr/share/doc/docbook-xsl-nons-1.79.2/README.txt &&
install -v -m644    RELEASE-NOTES* NEWS* \
                    /usr/share/doc/docbook-xsl-nons-1.79.2

If you downloaded the optional documentation tarball, install the documentation by issuing the following command as the root user:

cp -v -R doc/* /usr/share/doc/docbook-xsl-nons-1.79.2

Configuring DocBook XSL Stylesheets

Config Files

/etc/xml/catalog

Configuration Information

Note

If you are installing the current version of docbook-xsl-nons over a previous version of docbook-xsl, then remove the old rewrite entries in the catalog as the root user:

sed -i '/rewrite/d' /etc/xml/catalog

Create (or append) and populate the XML catalog file using the following commands as the root user:

if [ ! -d /etc/xml ]; then install -v -m755 -d /etc/xml; fi &&
if [ ! -f /etc/xml/catalog ]; then
    xmlcatalog --noout --create /etc/xml/catalog
fi &&

xmlcatalog --noout --add "rewriteSystem" \
           "https://cdn.docbook.org/release/xsl-nons/1.79.2" \
           "/usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2" \
    /etc/xml/catalog &&

xmlcatalog --noout --add "rewriteURI" \
           "https://cdn.docbook.org/release/xsl-nons/1.79.2" \
           "/usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2" \
    /etc/xml/catalog &&

xmlcatalog --noout --add "rewriteSystem" \
           "https://cdn.docbook.org/release/xsl-nons/current" \
           "/usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2" \
    /etc/xml/catalog &&

xmlcatalog --noout --add "rewriteURI" \
           "https://cdn.docbook.org/release/xsl-nons/current" \
           "/usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2" \
    /etc/xml/catalog &&

xmlcatalog --noout --add "rewriteSystem" \
           "http://docbook.sourceforge.net/release/xsl/current" \
           "/usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2" \
    /etc/xml/catalog &&

xmlcatalog --noout --add "rewriteURI" \
           "http://docbook.sourceforge.net/release/xsl/current" \
           "/usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2" \
    /etc/xml/catalog

Occasionally, you may find the need to install other versions of the XSL stylesheets as some projects reference a specific version. One example is BLFS-6.0, which required the 1.67.2 version. In these instances you should install any other required version in its own versioned directory and create catalog entries as follows (substitute the desired version number for <version>):

xmlcatalog --noout --add "rewriteSystem" \
           "http://docbook.sourceforge.net/release/xsl/<version>" \
           "/usr/share/xml/docbook/xsl-stylesheets-<version>" \
    /etc/xml/catalog &&

xmlcatalog --noout --add "rewriteURI" \
           "http://docbook.sourceforge.net/release/xsl/<version>" \
           "/usr/share/xml/docbook/xsl-stylesheets-<version>" \
    /etc/xml/catalog

Contents

Installed Files: /usr/share/xml/docbook/xsl-stylesheets-1.79.2/*/*.xsl
Installed Directories: /usr/share/xml/docbook/xsl-stylesheets-1.79.2 and /usr/share/doc/docbook-xsl-1.79.2

Short Descriptions

XSL Stylesheets

are used for performing transformations on XML files

Last updated on

itstool-2.0.7

Introduction to itstool

Itstool extracts messages from XML files and outputs PO template files, then merges translations from MO files to create translated XML files. It determines what to translate and how to chunk it into messages using the W3C Internationalization Tag Set (ITS).

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Itstool Dependencies

Required

docbook-xml-4.5

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/itstool

Installation of itstool

Install itstool by running the following commands:

PYTHON=/usr/bin/python3 ./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Program: itstool
Installed Libraries: None
Installed Directory: /usr/share/itstool

Short Descriptions

itstool

is used to create translated XML files

Last updated on

xmlto-0.0.28

Introduction to xmlto

The xmlto package is a front-end to a XSL toolchain. It chooses an appropriate stylesheet for the conversion you want and applies it using an external XSLT processor. It also performs any necessary post-processing.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

xmlto Dependencies

Required

docbook-xml-4.5, docbook-xsl-1.79.2, and libxslt-1.1.35

Optional (for DVI, PDF, and postscript backend post-processing)

fop-2.7, dblatex, and PassiveTeX

Optional (for text backend post-processing)

One of Links-2.25, Lynx-2.8.9rel.1, W3m, or ELinks

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xmlto

Installation of xmlto

Install xmlto by running the following commands:

LINKS="/usr/bin/links" \
./configure --prefix=/usr &&

make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

LINKS="/usr/bin/links": This environment variable fixes a bug causing xmlto to think that links command is the same as elinks. Setting this variable does not cause problems if links is not installed, unless you have ELinks installed, and wish to use it for text backend post-processing, in which case, remove it.

Contents

Installed Programs: xmlif and xmlto
Installed Libraries: None
Installed Directory: /usr/share/xmlto

Short Descriptions

xmlif

is a conditional processing instructions for XML

xmlto

applies an XSL stylesheet to an XML document

Last updated on

Chapter 50. PostScript

This chapter includes applications that create, manipulate or view PostScript files and create or view Portable Document Format PDF files.

Enscript-1.6.6

Introduction to Enscript

Enscript converts ASCII text files to PostScript, HTML, RTF, ANSI and overstrikes.

This package is known to build and work properly using an LFS-11.1 platform.

Caution

Enscript cannot convert UTF-8 encoded text to PostScript. The issue is discussed in detail in the Needed Encoding Not a Valid Option section of the Locale Related Issues page. The solution is to use paps-0.7.1, instead of Enscript, for converting UTF-8 encoded text to PostScript.

Package Information

Enscript Dependencies

Optional

texlive-20210325 (or install-tl-unx)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Enscript

Installation of Enscript

Install Enscript by running the following commands:

./configure --prefix=/usr              \
            --sysconfdir=/etc/enscript \
            --localstatedir=/var       \
            --with-media=Letter &&
make &&

pushd docs &&
  makeinfo --plaintext -o enscript.txt enscript.texi &&
popd

If you have texlive-20210325 installed, you can create Postscript and PDF documentation by issuing (does not support parallel make):

make -j1 -C docs ps pdf

To test the results, issue: make check.

Now, as the root user:

make install &&

install -v -m755 -d /usr/share/doc/enscript-1.6.6 &&
install -v -m644    README* *.txt docs/*.txt \
                    /usr/share/doc/enscript-1.6.6

If you built Postscript and PDF documentation, install it using the following command as the root user:

install -v -m644 docs/*.{dvi,pdf,ps} \
                 /usr/share/doc/enscript-1.6.6

Command Explanations

--sysconfdir=/etc/enscript: This switch puts configuration data in /etc/enscript instead of /usr/etc.

--localstatedir=/var: This switch sets the directory for runtime data to /var instead of /usr/var.

--with-media=Letter: This switch sets the medium format to letter size instead of the A4 default.

Contents

Installed Programs: diffpp, enscript, mkafmmap, over, sliceprint, and states
Installed Libraries: None
Installed Directories: /etc/enscript, /usr/share/doc/enscript-1.6.6, and /usr/share/enscript

Short Descriptions

diffpp

converts diff output files to a format suitable to be printed with enscript

enscript

is a filter, used primarily by printing scripts, that converts ASCII text files to PostScript, HTML, RTF, ANSI and overstrikes

mkafmmap

creates a font map from a given file

over

is a script which calls enscript and passes the correct parameters to create overstriked fonts

sliceprint

slices documents with long lines

states

is an awk-like text processing tool with some state machine extensions. It is designed for program source code highlighting and for similar tasks where state information helps input processing

Last updated on

ePDFView-0.1.8

Introduction to ePDFView

ePDFView is a free standalone lightweight PDF document viewer using Poppler and GTK+ libraries. It is a good replacement for Evince as it does not rely upon GNOME libraries.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

ePDFView Dependencies

Required

GTK+-2.24.33 and Poppler-22.02.0

Recommended (mainly for Desktop Environments)
Optional

Cups-2.4.1

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/epdfview

Installation of ePDFView

Install ePDFView by running the following commands:

patch -Np1 -i ../epdfview-0.1.8-fixes-2.patch &&
./configure --prefix=/usr &&
make

This package does not come with a test suite.

Now, as the root user:

make install

For Desktop Environment users, further (optional) instructions are necessary for properly displaying epdfview.desktop in the menu. As root user:

for size in 24 32 48; do
  ln -svf ../../../../epdfview/pixmaps/icon_epdfview-$size.png \
          /usr/share/icons/hicolor/${size}x${size}/apps
done &&
unset size &&

update-desktop-database &&
gtk-update-icon-cache -t -f --include-image-data /usr/share/icons/hicolor

Command Explanations

patch -Np1 -i ../epdfview-0.1.8-fixes-2.patch The patch does four things: fixes compiling with glib-2.32 or greater, corrects red appearing as blue with recent versions of poppler, allows the application to compile when Cups-2.4.1 has been installed, and fixes the display of embedded png images.

Contents

Installed Program: epdfview
Installed Libraries: None
Installed Directory: /usr/share/epdfview

Short Descriptions

epdfview

is a Gtk+-2 program for viewing PDF documents

Last updated on

fop-2.7

Introduction to fop

The FOP (Formatting Objects Processor) package contains a print formatter driven by XSL formatting objects (XSL-FO). It is a Java application that reads a formatting object tree and renders the resulting pages to a specified output. Output formats currently supported include PDF, PCL, PostScript, SVG, XML (area tree representation), print, AWT, MIF and ASCII text. The primary output target is PDF.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Additional Downloads

Required Additional Downloads:

Recommended packages

fop Dependencies

Required

apache-ant-1.10.12

Optional

a graphical environment (to run tests), JAI Image I/O Tools, and JEuclid

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/fop

Installation of fop

Ensure $JAVA_HOME is set correctly before beginning the build. To build the JIMI SDK and/or XMLUnit extension classes, ensure the corresponding .jar files can be found via the CLASSPATH environment variable.

Installing OFFO Hyphenation Patterns

Copy the XML hyphenation patterns into the fop source tree by running the following commands:

unzip ../offo-hyphenation.zip &&
cp offo-hyphenation/hyph/* fop/hyph &&
rm -rf offo-hyphenation

Installing a temporary Maven binary

Starting with fop-2.5, the Maven build system is required. We use the binary provided by apache, that we install in a temporary location:

tar -xf ../apache-maven-3.8.4-bin.tar.gz -C /tmp

Installing fop Components

The javadoc command that ships with OpenJDK 10 and later has become much stricter than previous versions regarding conformance of the Javadoc comments in source code to HTML. The FOP documentation does not meet those standards, so the conformance checks have to be disabled. This can be done with the following command:

sed -i '\@</javad@i\
<arg value="-Xdoclint:none"/>\
<arg value="--allow-script-in-comments"/>\
<arg value="--ignore-source-errors"/>' \
    fop/build.xml

The build.xml file calls for an old version of PDFBox components that are no longer available. Copy the updated PDFBox components into the source tree:

cp ../{pdf,font}box-2.0.25.jar fop/lib

Compile fop by running the following commands:

cd fop &&

LC_ALL=en_US.UTF-8                     \
PATH=$PATH:/tmp/apache-maven-3.8.4/bin \
ant all javadocs &&

mv build/javadocs .

This package comes with a testsuite, but the java infrastructure installed in this book does not allow running it.

Now, install Fop as the root user:

install -v -d -m755 -o root -g root          /opt/fop-2.7 &&
cp -vR build conf examples fop* javadocs lib /opt/fop-2.7 &&
chmod a+x /opt/fop-2.7/fop                                &&
ln -v -sfn fop-2.7 /opt/fop

The last thing to do is to clean what we have done:

rm -rf /tmp/apache-maven-3.8.4

Command Explanations

sed -i ... build.xml: This adds three switches to the javadoc command, preventing some errors from occurring when building the documentation.

export LC_ALL=en_US.UTF-8: the compiler fails if using an ASCII locale.

ant target: This reads the file build.xml and builds the target: compile compiles the java sources, jar-main generates jar archives, jar-hyphenation generates the hyphenation patterns for FOP, junit runs the junit tests, and javadocs builds the documentation. The all target runs all of the above.

ln -v -sf fop-2.7 /opt/fop: This is optional and creates a convenience symlink so that $FOP_HOME doesn't have to be changed each time there's a package version change.

Configuring fop

Config Files

~/.foprc

Configuration Information

Using fop to process some large FO's (including the FO derived from the BLFS XML sources), can lead to memory errors. Unless you add a parameter to the java command used in the fop script you may receive messages similar to the one shown below:

Exception in thread "main" java.lang.OutOfMemoryError: Java heap space

To avoid errors like this, you need to pass an extra parameter to the java command used in the fop script. This can be accomplished by creating a ~/.foprc (which is sourced by the fop script) and adding the parameter to the FOP_OPTS environment variable.

The fop script looks for a FOP_HOME environment variable to locate the fop class libraries. You can create this variable using the ~/.foprc file as well. Create a ~/.foprc file using the following commands:

cat > ~/.foprc << "EOF"
FOP_OPTS="-Xmx<RAM_Installed>m"
FOP_HOME="/opt/fop"
EOF

Replace <RAM_Installed> with a number representing the amount of RAM installed in your computer (in megabytes). An example would be FOP_OPTS="-Xmx768m".

To include the fop script in your path, update the system-wide profile with the following command as the root user:

cat > /etc/profile.d/fop.sh << "EOF"
# Begin /etc/profile.d/fop.sh

pathappend /opt/fop

# End /etc/profile.d/fop.sh
EOF

Note

Running fop can be somewhat verbose. The default logging level can be changed from INFO to any of FINEST, FINER, FINE, CONFIG, INFO, WARNING, SEVERE, ALL, or OFF. To do this, edit $JAVA_HOME/jre/lib/logging.properties and change the entries for .level and java.util.logging.ConsoleHandler.level to the desired value.

Contents

Installed Programs: fop
Installed Libraries: fop.jar and numerous support library classes located in /opt/fop/{build,lib}; JAI components include libmlib_jai.so, jai_codec.jar, jai_core.jar, and mlibwrapper_jai.jar
Installed Directory: /opt/fop-2.7

Short Descriptions

fop

is a wrapper script to the java command which sets up the fop environment and passes the required parameters

fop.jar

contains all the fop Java classes

Last updated on

MuPDF-1.19.0

Introduction to MuPDF

MuPDF is a lightweight PDF and XPS viewer.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

MuPDF Dependencies

Required

GLU-9.0.2 and Xorg Libraries

Recommended
Optional

xdg-utils-1.1.3 (runtime), jbig2dec, and MuJS

Required (runtime)

a graphical environment

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/mupdf

Installation of MuPDF

First, fix the Makefile to link properly with the shared library:

sed -i '/MU.*_EXE. :/{
        s/\(.(MUPDF_LIB)\)\(.*\)$/\2 | \1/
        N
        s/$/ -lmupdf -L$(OUT)/
        }' Makefile

Install MuPDF by running the following commands:

cat > user.make << EOF &&
USE_SYSTEM_FREETYPE := yes
USE_SYSTEM_HARFBUZZ := yes
USE_SYSTEM_JBIG2DEC := no
USE_SYSTEM_JPEGXR := no # not used without HAVE_JPEGXR
USE_SYSTEM_LCMS2 := no # need lcms2-art fork
USE_SYSTEM_LIBJPEG := yes
USE_SYSTEM_MUJS := no # build needs source anyways
USE_SYSTEM_OPENJPEG := yes
USE_SYSTEM_ZLIB := yes
USE_SYSTEM_GLUT := no # need freeglut2-art fork
USE_SYSTEM_CURL := yes
USE_SYSTEM_GUMBO := no
EOF

export XCFLAGS=-fPIC                               &&
make build=release shared=yes                      &&
unset XCFLAGS

This package does not come with a test suite.

Now, as the root user:

make prefix=/usr                        \
     shared=yes                         \
     docdir=/usr/share/doc/mupdf-1.19.0 \
     install                            &&

chmod 755 /usr/lib/libmupdf.so          &&
ln -sfv mupdf-x11 /usr/bin/mupdf

Command Explanations

ln -sfv mupdf-x11 /usr/bin/mupdf : This symbolic link chooses between mupdf-gl and mupdf-x11 when running mupdf.

Contents

Installed Program: mupdf (symlink), mupdf-gl, mupdf-x11, mupdf-x11-curl, muraster, and mutool
Installed Libraries: libmupdf.so
Installed Directories: /usr/include/mupdf, /usr/share/doc/mupdf-1.19.0

Short Descriptions

mupdf

is a program for viewing PDF, XPS, EPUB, and CBZ documents, and various image formats such as PNG, JPEG, GIFF, and TIFF

mupdf-gl

same as mupdf, using an opengl renderer

mupdf-x11

same as mupdf, using an X Window renderer

muraster

is a program used to perform rasterization tasks with PDF documents

mutool

is a program to perform various operations on PDF files, such as merging and cleaning PDF documents

libmupdf.so

contains the mupdf API functions

Last updated on

paps-0.7.1

Introduction to paps

paps is a text to PostScript converter that works through Pango. Its input is a UTF-8 encoded text file and it outputs vectorized PostScript. It may be used for printing any complex script supported by Pango.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

paps Dependencies

Required

Pango-1.50.4

Optional

Doxygen-1.9.3

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/Paps

Installation of paps

Install paps by running the following commands:

./configure --prefix=/usr --mandir=/usr/share/man &&
make

This package does not come with a test suite.

Now, as the root user:

make install

Contents

Installed Program: paps
Installed Library: None
Installed Directory: None

Short Descriptions

paps

is a text to PostScript converter that supports UTF-8 character encoding

Last updated on

Chapter 51. Typesetting

This chapter includes texlive applications that create output equivalent to typesetting.

There are two alternative routes through this chapter:

Some people may wish to use the binary installer, either because of the complexity of installing all of texlive from source, or because they only want a part of the package, or perhaps because they wish to get updates as soon as those are available (the source is only updated annually, but the binaries and associated tex and sty files are updated for approximately 10 months). These people should begin at Setting the PATH for TeX Live and then follow the install-tl-unx instructions. After installing, they can run tlmgr to update their system.

Most people reading BLFS will wish to build from source. BLFS used to start by installing install-tl-unx and then use that to bootstrap the build. Nowadays, we build almost the whole of texlive without a binary install, by adding the separately-packaged texmf files into this build. For this, begin at Setting the PATH for TeX Live then go to texlive-20210325 which will install most of texlive, together with all of the supporting files. This almost-complete install can then be used to build the remaining parts of texlive: asymptote-2.78, biber-2.17 and xindy-2.5.1.

Because the texmf files (including documentation, fonts, scripts and supporting files) are all in one tarball, it is not practical to limit what gets extracted in a sensible way (you could exclude one or other of the typesetting engines, not its many supporting files) when building from source in this manner.

In either case, BLFS installs into /opt/texlive/2021.

Also, please note that texlive is released annually, and updating from the previous year to the current year is no longer supported. If for some reason you wish to keep versions for multiple years, for most things you can mount the old or new system at /opt/texlive and fix up your PATH as necessary. However doing that will not preserve any changes in texmf-local and if you build from source and try to run a newer version of biber with an older version of biblatex it is unlikely to work.

Setting the PATH for TeX Live

Before starting to build TeX Live, set up your PATH so that the system can properly find the files. If you set up your login scripts as recommended in The Bash Shell Startup Files, update the needed paths by appending to the extrapaths.sh script. The programs are always installed in an <ARCH>-linux subdirectory and on 32-bit x86 this is always i386-linux. For x86_64 and i?86 we can generate this as $TEXARCH:

Note

If upgrading from a previous year's version, you should manually edit extrapaths.sh to ensure that the version for the year you wish to use is the only TeX present (some people need to keep multiple years available to ensure there are no regressions in their documents).

export TEXARCH=$(uname -m | sed -e 's/i.86/i386/' -e 's/$/-linux/') &&

cat >> /etc/profile.d/extrapaths.sh << EOF

# Begin texlive addition

pathappend /opt/texlive/2021/texmf-dist/doc/man  MANPATH
pathappend /opt/texlive/2021/texmf-dist/doc/info INFOPATH
pathappend /opt/texlive/2021/bin/$TEXARCH

# End texlive addition

EOF

unset TEXARCH

Note

The standard MANPATH and INFOPATH path are specified above to ensure they are included. If they are already set in the boot script procedure, the pathappend function will ensure duplicates are removed, so including them here will do no harm.

The new paths can be immediately activated by running source /etc/profile.

You should now proceed either to install-tl-unx for a binary installation of texlive, or to texlive-20210325 to begin installing from source.

Last updated on

install-tl-unx

Introduction to TeX Live and its installer

The TeX Live package is a comprehensive TeX document production system. It includes TeX, LaTeX2e, ConTeXt, Metafont, MetaPost, BibTeX and many other programs; an extensive collection of macros, fonts and documentation; and support for typesetting in many different scripts from around the world.

This page is for people who wish to use the binary installer to provide the programs, the scripts, and a lot of supporting files and documentation. The installer is updated frequently, so any published md5sum will soon be out of date. Newer versions of the installer are expected to work with these instructions, for so long as they install to a 2021/ directory.

There are two reasons why you may wish to install the binaries in BLFS: either you need a smaller install (e.g. at a minimum plain TeX without LaTeX2e, ConTeXt, etc), or you wish to use tlmgr to get updates whilst this version is supported (typically, until April of the year after it was released). For the latter, you might prefer to install in your /home directory as an unprivileged user, and to then make corresponding changes to the PATH in your ~/.bashrc or equivalent.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Recommended
Recommended (at runtime)

Note

As always with contributed binary software, it is possible that the required dependencies may change when the installer is updated. In particular, these dependencies have only been checked on x86_64.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/tl-installer

Binary Installation of TeX Live

The TeX Live set of programs with its supporting documents, fonts, and utilities is very large. The upstream maintainers recommend placing all files in a single directory structure. BLFS recommends /opt/texlive.

As with any other package, unpack the installer and change into its directory, install-tl-<CCYYMMDD>. This directory name changes when the installer is updated, so replace <CCYYMMDD> by the correct directory name.

Note

The distribution binaries installed below may use static linking for general linux system libraries. Additional libraries or interpreters as specified in the dependencies section do not need to be present during the install, but the programs that need them will not run until their specific dependencies have been installed.

With all contributed binary software, there may be a mismatch between the builder's toolchain and your hardware. In most of TeX this will probably not matter, but in uncommon corner cases you might hit problems. e.g. if your x86_64 processor does not support 3dnowext or 3dnow, the 2014-06-28 binary failed in conTeXt when running LuaTeX, although lualatex worked, as did the i686 binaries on the same machine. In such cases, the easiest solution is to install texlive from source. Similarly, the x86_64 binary version of asy runs very slowly when creating 3-D diagrams.

Now, as the root user:

TEXLIVE_INSTALL_PREFIX=/opt/texlive ./install-tl

This command is interactive and allows selection or modification of platform, packages, directories, and other options. The full installation scheme will require about 4.9 gigabytes of disk space. The time to complete the download will depend on your internet connection speed and the number of packages selected.

It has been established by debian that the python scripts in latex-make will work with python3, so update them to invoke that by running the following command as the root user:

for F in /opt/texlive/2021/texmf-dist/scripts/latex-make/*.py ; do
  test -f $F && sed -i 's%/usr/bin/env python%/usr/bin/python3%' $F || true
done

Command Explanations

test -f $F && sed ...: in a small install these files might not be present, so test if they exist and if not return 'true' to avoid any error if this command has been copied into one of your own install scripts.

./install-tl --location http://mirror.aut.ac.nz/CTAN/systems/texlive/tlnet/: use a variation of this if you wish to use a different mirror, e.g. because you are in New Zealand but the installer chooses to use an Australian mirror. The list of mirrors is at http://ctan.org/mirrors.

Contents

Installed Programs: Over 300 binaries and symlinks to scripts
Installed Libraries: None
Installed Directories: /opt/texlive

Short Descriptions

TeX programs

The programs included in TeX are too numerous to individually list. Please refer to the individual program HTML and PDF pages in the various html, man, or pdf files within the subdirectories of 2021/texmf-dist/. Using texdoc pdflatex ( replace pdflatex with the command name ) may also be useful

Last updated on

texlive-20210325-source

Introduction to TeX Live from source

Most of TeX Live can be built from source without a pre-existing installation, but xindy (for indexing) needs working versions of latex and pdflatex when configure is run, and the testsuite and install for asy (for vector graphics) will fail if TeX has not already been installed. Additionally, biber is not provided within the texlive source and the version of dvisvgm in the texlive tree cannot be built if shared system libraries are used.

All of those packages are dealt with on their own pages and can be built after installing this package. If you have not already done so, you should start at Setting the PATH for TeX Live so that the final commands to initialise the new installation will be found.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

  • Download (FTP): ftp://tug.org/texlive/historic/2021/texlive-20210325-source.tar.xz

  • Download MD5 sum: 19da95538956e26570ef7fb202af258f

  • Download size: 53 MB

  • Estimated disk space required: 8.1 GB including the additional download and the tests, 7.0 GB installed

  • Estimated build time: 4.2 SBU including the additional download and the tests, building with parallelism=4

Required Additional Downloads

Much of the texlive environment (including scripts, documentation, fonts, and various other files) is not part of the source tarball. You must download it separately. This will give you all of the additional files which are provided by a full install of the binary version, there is no realistic way to restrict which parts get installed.

Because of the size of this package, it is unlikely to be mirrored by BLFS mirrors. In case of difficulty, go to http://www.ctan.org/mirrors/ to find a more-accessible mirror.

From the 2019 year, the tlpdb database of the packages within texlive is no-longer installed with the source. But texdoc needs a cache file derived from this (and will create the cache on its first run).

TeX Live from source Dependencies

Recommended
Optional

The source ships with its own versions of several libraries which are either not under active development, or only used for limited functionality. If you install these, as with some other optional dependencies in this book you will need to tell configure to use the system versions. GD, t1lib, ZZIPlib, TECkit

Runtime dependencies

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/texlive

Installation of TeX Live

Install TeX Live by running the following commands:

Caution

If you wish to upgrade to current texlive on an older system where extra packages (asymptote. biber, dvisvgm or xindy) have been installed, you will need to reinstall those as well as fixing up your PATH for /opt/texlive/2021.

The shared libraries will be installed into a texlive directory. As the root user, add it to your /etc/ld.so.conf:

cat >> /etc/ld.so.conf << EOF
# Begin texlive 2021 addition

/opt/texlive/2021/lib

# End texlive 2021 addition
EOF

Note

A successful install requires some texlive commands to be run as the root user, so we will export the TEXARCH variable to let root use it.

Now, as a normal user:

export TEXARCH=$(uname -m |
 sed -e 's/i.86/i386/' -e 's/$/-linux/')                 &&
patch -Np1 -i ../texlive-20210325-upstream_fixes-1.patch &&

mkdir texlive-build &&
cd texlive-build    &&

../configure                                        \
    --prefix=/opt/texlive/2021                      \
    --bindir=/opt/texlive/2021/bin/$TEXARCH         \
    --datarootdir=/opt/texlive/2021                 \
    --includedir=/opt/texlive/2021/include          \
    --infodir=/opt/texlive/2021/texmf-dist/doc/info \
    --libdir=/opt/texlive/2021/lib                  \
    --mandir=/opt/texlive/2021/texmf-dist/doc/man   \
    --disable-native-texlive-build                  \
    --disable-static --enable-shared                \
    --disable-dvisvgm                               \
    --with-system-cairo                             \
    --with-system-fontconfig                        \
    --with-system-freetype2                         \
    --with-system-gmp                               \
    --with-system-graphite2                         \
    --with-system-harfbuzz                          \
    --with-system-icu                               \
    --with-system-libgs                             \
    --with-system-libpaper                          \
    --with-system-libpng                            \
    --with-system-mpfr                              \
    --with-system-pixman                            \
    --with-system-zlib                              \
    --with-banner-add=" - BLFS" &&

make

To test the results, issue: make check.

Now, as the root user:

make install-strip &&
/sbin/ldconfig &&
make texlinks &&
mkdir -pv /opt/texlive/2021/tlpkg/TeXLive/ &&
install -v -m644 ../texk/tests/TeXLive/* /opt/texlive/2021/tlpkg/TeXLive/ &&
tar -xf ../../texlive-20210325-tlpdb-full.tar.gz -C /opt/texlive/2021/tlpkg

Note

Only run make texlinks once. If it is rerun, it can change all the program symlinks so that they point to themselves and are useless.

Now install the additional files as the root user:

tar -xf ../../texlive-20210325-texmf.tar.xz -C /opt/texlive/2021 --strip-components=1

It has been established by debian that the python scripts in latex-make will work with python3, so update them to invoke that by running the following command as the root user:

for F in /opt/texlive/2021/texmf-dist/scripts/latex-make/*.py ; do
  sed -i 's%/usr/bin/env python%/usr/bin/python3%' $F
done

Still as the root user, initialise the new system (the commands fmtutil-sys --all and mtxrun --generate will produce a lot of output):

mktexlsr &&
fmtutil-sys --all &&
mtxrun --generate

You can now proceed to asymptote-2.78, biber-2.17, dvisvgm-2.13.1 and / or xindy-2.5.1 if you wish to install them.

Command Explanations

patch -Np1 -i ../texlive-20210325-source-upstream_fixes-1.patch: A small update to mpost and LuaTeX caused the binaries to be rebuilt. This patch applies the same fixes.

--prefix=, --bindir=, --datarootdir=, --infodir=, --mandir= ... : these switches ensure that the files installed from source will overwrite any corresponding files previously installed by install-tl-unx so that the alternative methods of installing texlive are consistent.

--includedir=, --libdir= ... : these switches ensure that the libraries and include files will be within the directories for this year's texlive.

--disable-static: This switch prevents installation of static versions of the libraries.

--enable-shared: Use shared versions of libkpathsea, libptexenc, libsynctex, libtexlua52 and libtexluajit.

--with-system-...: Unless this parameter is used, the included versions of these libraries will be statically compiled into the programs which need them. If you decided not to install a recommended library, omit the corresponding switch.

--disable-dvisvgm: As noted above, the shipped version of dvisvgm, which has modified configuration files, cannot be built with shared system libraries.

--without-x: use this if you do not have Xorg installed.

/sbin/ldconfig: this has to be run here so that make texlinks can use kpsewhich.

make texlinks : this runs the texlinks.sh script to create symbolic links from formats to engines. In practice, several of the targets such as xetex are now separate binaries and for these it will report "file already exists".

tar -xf texlive-20210325-texmf.tar.xz -C /opt/texlive/2021 --strip-components=1: the tarball contains the files for the texmf-dist directory, and because of its size we do not want to waste time and space untarring it and then copying the files.

install -v -m644 ../texk/tests/TeXLive/* /opt/texlive/2021/tlpkg/TeXLive/: This puts the perl modules TLConfig.pm and TLUtils.pm into the directory where the binary installer puts them - it is at the start of the perl @INC@ PATH within texlive when installed using the above configure switches. Without these modules, texlive is unusable.

mktexlsr: Create an ls-R file which lists what was installed - this is used by kpathsea to find files.

fmtutil-sys --all: This initializes the TeX formats, Metafont bases and Metapost mems.

mtxrun --generate: This initializes the ConTeXt system.

Contents

Installed Programs: Over 300 binaries and symlinks to scripts
Installed Libraries: libkpathsea.so, libptexenc.so, libsynctex.so, libtexlua52.so, libtexluajit.so
Installed Directories: /opt/texlive/2021/bin, /opt/texlive/2021/include, /opt/texlive/2021/lib, /opt/texlive/2021/texmf-dist

Short Descriptions

TeX programs

The programs included in TeX are too numerous to individually list. Please refer to the individual program HTML and PDF pages in the various html, man, or pdf files within the subdirectories of 2021/texmf-dist/. Using texdoc pdflatex ( replace pdflatex with the command name ) may also be useful

libkpathsea.so

(kpathsearch) exists to look up a file in a list of directories and is used by kpsewhich

libptexenc.so

is a library for Japanese pTeX (publishing TeX)

libsynctex.so

is the SyncTeX (Synchronize TeXnology) parser library

libtexlua52.so

provides Lua 5.2, modified for use with LuaTeX

libtexluajit.so

provides LuaJIT, modified for use with LuaJITTeX

Last updated on

asymptote-2.78

Introduction to asymptote

Asymptote is a powerful descriptive vector graphics language that provides a natural coordinate-based framework for technical drawing. Labels and equations can be typeset with LaTeX. As well as EPS, PDF and PNG output it can produce WebGL 3D HTML rendering and (using dvisvgm) SVG output.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

asymptote Dependencies

Required

ghostscript-9.55.0 and texlive-20210325

Recommended
Recommended at runtime
Optional

fftw-3.3.10, Gsl-2.7.1, libsigsegv-2.14, both Boost-1.78.0 and rapidjson to use LSP which can be used with emacs

Optional (at runtime)

ImageMagick-7.1.0-25 to convert output to other formats such as JPEG or to create animated GIFs, PyQt5 (not tested, has a build dependency of Qt-5.15.2) to use xasy.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/asymptote

Installation of asymptote

Install asymptote by running the following commands:

export TEXARCH=$(uname -m | sed -e 's/i.86/i386/' -e 's/$/-linux/') &&

./configure --prefix=/opt/texlive/2021                          \
            --bindir=/opt/texlive/2021/bin/$TEXARCH             \
            --datarootdir=/opt/texlive/2021/texmf-dist          \
            --infodir=/opt/texlive/2021/texmf-dist/doc/info     \
            --libdir=/opt/texlive/2021/texmf-dist               \
            --mandir=/opt/texlive/2021/texmf-dist/doc/man       \
            --disable-lsp                                       \
            --enable-gc=system                                  \
            --with-latex=/opt/texlive/2021/texmf-dist/tex/latex \
            --with-context=/opt/texlive/2021/texmf-dist/tex/context/third &&

make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

--prefix=, --bindir=, --datarootdir=, --infodir=, --mandir= ... : these switches ensure that the files installed from source will overwrite any corresponding files previously installed by install-tl-unx so that the alternative methods of installing texlive are consistent.

--libdir=/opt/texlive/2021/texmf-dist;: This parameter ensures that the asymptote directory will similarly overwrite any files installed by install-tl-unx.

--disable-lsp: The Language Server Protocol is enabled by default, with several third-party sources included, but it does not build unless boost and repidjson have been installed.

--enable-gc=system: this ensures that the system version of libgc.so will be used instead of the version shipped with this package.

--with-latex= ... --with-context=: These switches ensure that style files and a tex file will be installed into the texlive directories instead of creating a texmf-local directory for them.

Contents

Installed Programs: asy, xasy
Installed Libraries: None
Installed Directory: /opt/texlive/2021texmf-dist/asymptote, /opt/texlive/2021/doc/asymptote, /opt/texlive/2021/info/asymptote

Short Descriptions

asy

is a vector graphics program

xasy

is a Python3 script providing a Qt5 GUI for asy

Last updated on

biber-2.17

Introduction to biber

Biber is a BibTeX replacement for users of biblatex, written in Perl, with full Unicode support.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Note

If you have updated to a new release of texlive-source, biber and its perl dependencies are still present in /usr and do not need to be rebuilt. However, biblatex installs in /opt/texlive/2021 and does need to be reinstalled.

If you installed the above dependencies using the BLFS instructions for each of them, perl ./Build.PL will complain that Mozilla::CA is not installed, but that is not needed unless CPAN was used to install the modules. BLFS patches LWP::Protocol::https to use the system certificates, Mozilla::CA uses old certificates.

Required Additional Download

Biber Dependencies

Required

autovivification-0.18 Business-ISBN-3.007 Business-ISMN-1.202 Business-ISSN-1.004 Class-Accessor-0.51 Data-Compare-1.27 Data-Dump-1.25 Data-Uniqid-0.12 DateTime-Calendar-Julian-0.107 DateTime-Format-Builder-0.83 Encode-EUCJPASCII-0.03 Encode-HanExtra-0.23 Encode-JIS2K-0.03 File-Slurper-0.013 IO-String-1.08 IPC-Run3-0.048 Lingua-Translit-0.28 List-AllUtils-0.19 List-MoreUtils-0.430 Log-Log4perl-1.54 LWP-Protocol-https-6.10 Module-Build-0.4231 Parse-RecDescent-1.967015 PerlIO-utf8_strict-0.009 Regexp-Common-2017060201 Sort-Key-1.33 Text-BibTeX-0.88 Text-CSV-2.01 Text-Roman-3.5 Unicode-Collate-1.31 Unicode-LineBreak-2019.001 XML-LibXML-Simple-1.01 XML-LibXSLT-1.99 XML-Writer-0.900 and texlive-20210325 (or install-tl-unx, but for that you can use tlmgr update)

Recommended (required for the testsuite)

Note

It is possible to install all missing dependencies automatically. You must first install Module-Build-0.4231 using automatic installation of perl modules. Then run perl ./Build.PL and when it prompts you, become the root user and run ./Build installdeps - this will use CPAN and as noted above it will use Mozilla::CA instead of using system certificates.

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/biber

Installation of Biber

Install Biber by running the following commands:

perl ./Build.PL &&
./Build

To test the results, enter: ./Build test

Now, as the root user:

tar -xf ../biblatex-3.17.tds.tgz -C /opt/texlive/2021/texmf-dist &&
texhash &&
./Build install

Command Explanations

tar -xf biblatex-3.17.tds.tar.gz -C /opt/texlive/2021/texmf-dist: this installs the new biblatex files over those installed by texlive.

texhash : this updates the file hash tables (otherwise known as the file name database).

Contents

Installed Programs: biber
Installed Library: None
Installed Directory: /usr/lib/perl5/site_perl/5.*{,/<arch>-linux/auto}/Biber

Short Descriptions

biber

is used for producing bibliographies in LaTeX documents

Last updated on

dvisvgm-2.13.1

Introduction to dvisvgm

The dvisvgm package converts DVI, EPS and PDF files to SVG format.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

dvisvgm Dependencies

Required

Brotli-1.0.9, ghostscript-9.55.0 and Potrace-1.16

Recommended
Optional

asciidoc-10.1.1 with xmlto-0.0.28 and libxslt-1.1.35 (see command explanations), dblatex (with the above) and xxHash (the current version is included in the tarball)

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/dvisvgm

Installation of dvisvgm

To enable the build system to link to libkpathsea.so, as the root user create a symlink from /usr/lib:

ln -svf /opt/texlive/2021/lib/libkpathsea.so /usr/lib

The testsuite assumes that a modern version of Python has been installed as plain python. Changing this to use python3 requires a sed to one Makefile.in file.

Install dvisvgm by running the following commands:

sed -i 's/python/&3/' tests/Makefile.in       &&
./configure                                    \
 --bindir=/opt/texlive/2021/bin/${TEXARCH}     \
 --mandir=/opt/texlive/2021/texmf-dist/doc/man \
 --with-kpathsea=/opt/texlive/2021            &&
make

To test the results, issue: make check.

Now, as the root user:

make install

Command Explanations

ln -svf /opt/texlive/2021/lib/libkpathsea.so /usr/lib: Without this, the program will not link correctly,

autoreconf -fiv: The versions of autoconf and automake used when this package was created are older than the current versions in LFS. That causes 'make' to fail when it reaches the 'tests' subdirectory unless autoreconf is forced to install missing (i.e. newer) auxiliary files.

--with-kpathsea=/opt/texlive/2021: This allows the build system to find the headers for kpathsea

Contents

Installed Programs: dvisvgm
Installed Libraries: None
Installed Directories: None

Short Descriptions

dvisvgm

converts DVI, EPS and PDF files to the SVG format

Last updated on

xindy-2.5.1

Introduction to xindy

Xindy is an index processor that can be used to generate book-like indexes for arbitrary document-preparation systems. This includes systems such as TeX and LaTeX, the roff-family, and SGML/XML-based systems (e.g., HTML) that process some kind of text and generate indexing information.

This package is known to build and work properly using an LFS-11.1 platform.

Package Information

Required Additional Downloads

Xindy Dependencies

Required

Clisp-2.49 and texlive-20210325

User Notes: https://wiki.linuxfromscratch.org/blfs/wiki/xindy

Installation of xindy

Install xindy by running the following commands:

export TEXARCH=$(uname -m | sed -e 's/i.86/i386/' -e 's/$/-linux/') &&

sed -i "s/ grep -v '^;'/ awk NF/" make-rules/inputenc/Makefile.in &&

sed -i 's%\(indexentry\)%\1\\%' make-rules/inputenc/make-inp-rules.pl &&

patch -Np1 -i ../xindy-2.5.1-upstream_fixes-2.patch &&

./configure --prefix=/opt/texlive/2021              \
            --bindir=/opt/texlive/2021/bin/$TEXARCH \
            --datarootdir=/opt/texlive/2021         \
            --includedir=/usr/include               \
            --libdir=/opt/texlive/2021/texmf-dist   \
            --mandir=/opt/texlive/2021/texmf-dist/doc/man &&

make LC_ALL=POSIX

This package does not have a testsuite.

Now, as the root user:

make install

Command Explanations

sed -i "s/ grep -v '^;'/ awk NF/" ...: The build sorts files in latin{1..3} encodings to create latin.xdy, and unicode versions of these to create utf8.xdy after using grep -v '^;' to remove blank lines. With grep-2.23 any data not in the expected encoding is treated as binary, resulting in a useless file. This command uses an alternative way of removing blank lines.

sed -i 's%\(indexentry\)%\1\\%' ...: A regexp contains indexentry{ - perl has warned about the unescaped left brace for some time and now treats it as illegal. Change it to indexentry\{, doubling the backslash for sed.

patch -Np1 -i ../xindy-2.5.1-upstream_fixes-2.patch: Xindy is now maintained at CTAN. This patch updates the source with some of the changes made there (but ignoring changes which were only made to allow for spaces in pathnames and some trivial recent changes).

--prefix=, --bindir=, --datarootdir=, --infodir=, --mandir= ... : these switches ensure that the files installed from source will overwrite any corresponding files previously installed by install-tl-unx so that the alternative methods of installing texlive are consistent.

--includedir=/usr/include: This parameter ensures that the kpathsea headers from texlive-20210325 will be found.

make LC_ALL=POSIX: with the current version of coreutils it is essential to build xindy in the POSIX (or C) locale because in a UTF-8 locale the file latin.xdy will contain only a heading and then a line 'Binary file (standard input) matches' instead of the many lines of lisp merge-rule commands it ought to contain.

Contents

Installed Programs: tex2xindy, texindy, xindy
Installed Libraries: None
Installed Directory: /opt/texlive/2021/texmf-dist/xindy

Short Descriptions

tex2xindy

transforms a LaTeX index file into a xindy raw index file

texindy

is a wrapper for xindy that turns on many LaTeX conventions by default

xindy

creates a sorted and tagged index from a raw LaTeX index

Last updated on

Appendix A. Creative Commons License

Creative Commons Legal Code

Attribution-NonCommercial-ShareAlike 2.0

Important

CREATIVE COMMONS CORPORATION IS NOT A LAW FIRM AND DOES NOT PROVIDE LEGAL SERVICES. DISTRIBUTION OF THIS LICENSE DOES NOT CREATE AN ATTORNEY-CLIENT RELATIONSHIP. CREATIVE COMMONS PROVIDES THIS INFORMATION ON AN "AS-IS" BASIS. CREATIVE COMMONS MAKES NO WARRANTIES REGARDING THE INFORMATION PROVIDED, AND DISCLAIMS LIABILITY FOR DAMAGES RESULTING FROM ITS USE.

License

THE WORK (AS DEFINED BELOW) IS PROVIDED UNDER THE TERMS OF THIS CREATIVE COMMONS PUBLIC LICENSE ("CCPL" OR "LICENSE"). THE WORK IS PROTECTED BY COPYRIGHT AND/OR OTHER APPLICABLE LAW. ANY USE OF THE WORK OTHER THAN AS AUTHORIZED UNDER THIS LICENSE OR COPYRIGHT LAW IS PROHIBITED.

BY EXERCISING ANY RIGHTS TO THE WORK PROVIDED HERE, YOU ACCEPT AND AGREE TO BE BOUND BY THE TERMS OF THIS LICENSE. THE LICENSOR GRANTS YOU THE RIGHTS CONTAINED HERE IN CONSIDERATION OF YOUR ACCEPTANCE OF SUCH TERMS AND CONDITIONS.

  1. Definitions

    1. "Collective Work" means a work, such as a periodical issue, anthology or encyclopedia, in which the Work in its entirety in unmodified form, along with a number of other contributions, constituting separate and independent works in themselves, are assembled into a collective whole. A work that constitutes a Collective Work will not be considered a Derivative Work (as defined below) for the purposes of this License.

    2. "Derivative Work" means a work based upon the Work or upon the Work and other pre-existing works, such as a translation, musical arrangement, dramatization, fictionalization, motion picture version, sound recording, art reproduction, abridgment, condensation, or any other form in which the Work may be recast, transformed, or adapted, except that a work that constitutes a Collective Work will not be considered a Derivative Work for the purpose of this License. For the avoidance of doubt, where the Work is a musical composition or sound recording, the synchronization of the Work in timed-relation with a moving image ("synching") will be considered a Derivative Work for the purpose of this License.

    3. "Licensor" means the individual or entity that offers the Work under the terms of this License.

    4. "Original Author" means the individual or entity who created the Work.

    5. "Work" means the copyrightable work of authorship offered under the terms of this License.

    6. "You" means an individual or entity exercising rights under this License who has not previously violated the terms of this License with respect to the Work, or who has received express permission from the Licensor to exercise rights under this License despite a previous violation.

    7. "License Elements" means the following high-level license attributes as selected by Licensor and indicated in the title of this License: Attribution, Noncommercial, ShareAlike.

  2. Fair Use Rights. Nothing in this license is intended to reduce, limit, or restrict any rights arising from fair use, first sale or other limitations on the exclusive rights of the copyright owner under copyright law or other applicable laws.

  3. License Grant. Subject to the terms and conditions of this License, Licensor hereby grants You a worldwide, royalty-free, non-exclusive, perpetual (for the duration of the applicable copyright) license to exercise the rights in the Work as stated below:

    1. to reproduce the Work, to incorporate the Work into one or more Collective Works, and to reproduce the Work as incorporated in the Collective Works;

    2. to create and reproduce Derivative Works;

    3. to distribute copies or phonorecords of, display publicly, perform publicly, and perform publicly by means of a digital audio transmission the Work including as incorporated in Collective Works;

    4. to distribute copies or phonorecords of, display publicly, perform publicly, and perform publicly by means of a digital audio transmission Derivative Works;

    The above rights may be exercised in all media and formats whether now known or hereafter devised. The above rights include the right to make such modifications as are technically necessary to exercise the rights in other media and formats. All rights not expressly granted by Licensor are hereby reserved, including but not limited to the rights set forth in Sections 4(e) and 4(f).

  4. Restrictions.The license granted in Section 3 above is expressly made subject to and limited by the following restrictions:

    1. You may distribute, publicly display, publicly perform, or publicly digitally perform the Work only under the terms of this License, and You must include a copy of, or the Uniform Resource Identifier for, this License with every copy or phonorecord of the Work You distribute, publicly display, publicly perform, or publicly digitally perform. You may not offer or impose any terms on the Work that alter or restrict the terms of this License or the recipients' exercise of the rights granted hereunder. You may not sublicense the Work. You must keep intact all notices that refer to this License and to the disclaimer of warranties. You may not distribute, publicly display, publicly perform, or publicly digitally perform the Work with any technological measures that control access or use of the Work in a manner inconsistent with the terms of this License Agreement. The above applies to the Work as incorporated in a Collective Work, but this does not require the Collective Work apart from the Work itself to be made subject to the terms of this License. If You create a Collective Work, upon notice from any Licensor You must, to the extent practicable, remove from the Collective Work any reference to such Licensor or the Original Author, as requested. If You create a Derivative Work, upon notice from any Licensor You must, to the extent practicable, remove from the Derivative Work any reference to such Licensor or the Original Author, as requested.

    2. You may distribute, publicly display, publicly perform, or publicly digitally perform a Derivative Work only under the terms of this License, a later version of this License with the same License Elements as this License, or a Creative Commons iCommons license that contains the same License Elements as this License (e.g. Attribution-NonCommercial-ShareAlike 2.0 Japan). You must include a copy of, or the Uniform Resource Identifier for, this License or other license specified in the previous sentence with every copy or phonorecord of each Derivative Work You distribute, publicly display, publicly perform, or publicly digitally perform. You may not offer or impose any terms on the Derivative Works that alter or restrict the terms of this License or the recipients' exercise of the rights granted hereunder, and You must keep intact all notices that refer to this License and to the disclaimer of warranties. You may not distribute, publicly display, publicly perform, or publicly digitally perform the Derivative Work with any technological measures that control access or use of the Work in a manner inconsistent with the terms of this License Agreement. The above applies to the Derivative Work as incorporated in a Collective Work, but this does not require the Collective Work apart from the Derivative Work itself to be made subject to the terms of this License.

    3. You may not exercise any of the rights granted to You in Section 3 above in any manner that is primarily intended for or directed toward commercial advantage or private monetary compensation. The exchange of the Work for other copyrighted works by means of digital file-sharing or otherwise shall not be considered to be intended for or directed toward commercial advantage or private monetary compensation, provided there is no payment of any monetary compensation in connection with the exchange of copyrighted works.

    4. If you distribute, publicly display, publicly perform, or publicly digitally perform the Work or any Derivative Works or Collective Works, You must keep intact all copyright notices for the Work and give the Original Author credit reasonable to the medium or means You are utilizing by conveying the name (or pseudonym if applicable) of the Original Author if supplied; the title of the Work if supplied; to the extent reasonably practicable, the Uniform Resource Identifier, if any, that Licensor specifies to be associated with the Work, unless such URI does not refer to the copyright notice or licensing information for the Work; and in the case of a Derivative Work, a credit identifying the use of the Work in the Derivative Work (e.g., "French translation of the Work by Original Author," or "Screenplay based on original Work by Original Author"). Such credit may be implemented in any reasonable manner; provided, however, that in the case of a Derivative Work or Collective Work, at a minimum such credit will appear where any other comparable authorship credit appears and in a manner at least as prominent as such other comparable authorship credit.

    5. For the avoidance of doubt, where the Work is a musical composition:

      1. Performance Royalties Under Blanket Licenses. Licensor reserves the exclusive right to collect, whether individually or via a performance rights society (e.g. ASCAP, BMI, SESAC), royalties for the public performance or public digital performance (e.g. webcast) of the Work if that performance is primarily intended for or directed toward commercial advantage or private monetary compensation.

      2. Mechanical Rights and Statutory Royalties. Licensor reserves the exclusive right to collect, whether individually or via a music rights agency or designated agent (e.g. Harry Fox Agency), royalties for any phonorecord You create from the Work ("cover version") and distribute, subject to the compulsory license created by 17 USC Section 115 of the US Copyright Act (or the equivalent in other jurisdictions), if Your distribution of such cover version is primarily intended for or directed toward commercial advantage or private monetary compensation. 6. Webcasting Rights and Statutory Royalties. For the avoidance of doubt, where the Work is a sound recording, Licensor reserves the exclusive right to collect, whether individually or via a performance-rights society (e.g. SoundExchange), royalties for the public digital performance (e.g. webcast) of the Work, subject to the compulsory license created by 17 USC Section 114 of the US Copyright Act (or the equivalent in other jurisdictions), if Your public digital performance is primarily intended for or directed toward commercial advantage or private monetary compensation.

    6. Webcasting Rights and Statutory Royalties. For the avoidance of doubt, where the Work is a sound recording, Licensor reserves the exclusive right to collect, whether individually or via a performance-rights society (e.g. SoundExchange), royalties for the public digital performance (e.g. webcast) of the Work, subject to the compulsory license created by 17 USC Section 114 of the US Copyright Act (or the equivalent in other jurisdictions), if Your public digital performance is primarily intended for or directed toward commercial advantage or private monetary compensation.

  5. Representations, Warranties and Disclaimer

    UNLESS OTHERWISE MUTUALLY AGREED TO BY THE PARTIES IN WRITING, LICENSOR OFFERS THE WORK AS-IS AND MAKES NO REPRESENTATIONS OR WARRANTIES OF ANY KIND CONCERNING THE WORK, EXPRESS, IMPLIED, STATUTORY OR OTHERWISE, INCLUDING, WITHOUT LIMITATION, WARRANTIES OF TITLE, MERCHANTIBILITY, FITNESS FOR A PARTICULAR PURPOSE, NONINFRINGEMENT, OR THE ABSENCE OF LATENT OR OTHER DEFECTS, ACCURACY, OR THE PRESENCE OF ABSENCE OF ERRORS, WHETHER OR NOT DISCOVERABLE. SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION OF IMPLIED WARRANTIES, SO SUCH EXCLUSION MAY NOT APPLY TO YOU.

  6. Limitation on Liability. EXCEPT TO THE EXTENT REQUIRED BY APPLICABLE LAW, IN NO EVENT WILL LICENSOR BE LIABLE TO YOU ON ANY LEGAL THEORY FOR ANY SPECIAL, INCIDENTAL, CONSEQUENTIAL, PUNITIVE OR EXEMPLARY DAMAGES ARISING OUT OF THIS LICENSE OR THE USE OF THE WORK, EVEN IF LICENSOR HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

  7. Termination

    1. This License and the rights granted hereunder will terminate automatically upon any breach by You of the terms of this License. Individuals or entities who have received Derivative Works or Collective Works from You under this License, however, will not have their licenses terminated provided such individuals or entities remain in full compliance with those licenses. Sections 1, 2, 5, 6, 7, and 8 will survive any termination of this License.

    2. Subject to the above terms and conditions, the license granted here is perpetual (for the duration of the applicable copyright in the Work). Notwithstanding the above, Licensor reserves the right to release the Work under different license terms or to stop distributing the Work at any time; provided, however that any such election will not serve to withdraw this License (or any other license that has been, or is required to be, granted under the terms of this License), and this License will continue in full force and effect unless terminated as stated above.

  8. Miscellaneous

    1. Each time You distribute or publicly digitally perform the Work or a Collective Work, the Licensor offers to the recipient a license to the Work on the same terms and conditions as the license granted to You under this License.

    2. Each time You distribute or publicly digitally perform a Derivative Work, Licensor offers to the recipient a license to the original Work on the same terms and conditions as the license granted to You under this License.

    3. If any provision of this License is invalid or unenforceable under applicable law, it shall not affect the validity or enforceability of the remainder of the terms of this License, and without further action by the parties to this agreement, such provision shall be reformed to the minimum extent necessary to make such provision valid and enforceable.

    4. No term or provision of this License shall be deemed waived and no breach consented to unless such waiver or consent shall be in writing and signed by the party to be charged with such waiver or consent.

    5. This License constitutes the entire agreement between the parties with respect to the Work licensed here. There are no understandings, agreements or representations with respect to the Work not specified here. Licensor shall not be bound by any additional provisions that may appear in any communication from You. This License may not be modified without the mutual written agreement of the Licensor and You.

Important

Creative Commons is not a party to this License, and makes no warranty whatsoever in connection with the Work. Creative Commons will not be liable to You or any party on any legal theory for any damages whatsoever, including without limitation any general, special, incidental or consequential damages arising in connection to this license. Notwithstanding the foregoing two (2) sentences, if Creative Commons has expressly identified itself as the Licensor hereunder, it shall have all rights and obligations of Licensor.

Except for the limited purpose of indicating to the public that the Work is licensed under the CCPL, neither party will use the trademark "Creative Commons" or any related trademark or logo of Creative Commons without the prior written consent of Creative Commons. Any permitted use will be in compliance with Creative Commons' then-current trademark usage guidelines, as may be published on its website or otherwise made available upon request from time to time.

Creative Commons may be contacted at http://creativecommons.org/.

Appendix B. The MIT License

Copyright © 1999-2022 The BLFS Development Team

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Glossary

Acronyms

669

UNIS/Composer 669 Module

ABI

Application Binary Interface

ADSL

Asymmetric Digital Subscriber Line

AFS

Andrew File System

AIFF

Audio Interchange File Format

ALSA

Advanced Linux Sound Architecture

ANSI

American National Standards Institute

API

Application Programming Interface

APR

Apache Portable Runtime

ARP

Address Resolution Protocol

ASCII

American Standard Code for Information Interchange

ASN

Abstract Syntax Notation

ASF

Advanced Streaming Format

ATA

Advanced Technology Attachment

ATSC

Advanced Television Systems Committee

ATK

Accessibility ToolKit

AVI

Audio Video Interleave

AWT

Abstract Window Toolkit

BER

Basic Encoding Rules

BIND

Berkeley Internet Name Domain

BIOS

Basic Input/Output System

BLFS

Beyond Linux From Scratch

BMP

Bit MaP

CD

Compact Disk

CDDA

Compact Disc Digital Audio

CIFS

Common Internet File System

See Also SMB .

CMS

Cryptographic Message Syntax

CODEC

COmpression/DECompression module

CORBA

Common Object Request Broker Architecture

CPU

Central Processing Unit

CRD

Color Rendering Dictionary

CSA

Color Space Array

CSS (on DVD)

Contents Scrambling System

CSS

Cascading Style Sheets

CUPS

Common Unix Printing System

CVS

Concurrent Versions System

DAO

Disc At Once

DARPA

Directory Address Resolution Protocol Allocation

DEC

Digital Equipment Corporation

DER

Distinguished Encoding Rules

DES

Data Encryption Standard

DHCP

Dynamic Host Configuration Protocol

DICT

Dictionary Server Protocol (RFC 2229)

DIN

German Industrial Norm

DNS

Domain Name Service

DOS

Disk Operating System

DRI

Direct Rendering Infrastructure

DSC

Document Structuring Conventions

DSO

Dynamic Shared Objects

DSSSL

Document Style Semantics and Specification Language

DV

Digital Video

DVD

Digital Versatile Disk (also Digital Video Disk)

DVI

DeVice Independent

ELF

Executable and Linking Format

EPP

Enhanced Parallel Port

EPS

Encapsulated PostScript

ESD

Enlighten Sound Daemon

ESMTP

Extended Simple Mail Transfer Protocol

FAM

File Alteration Monitor

FAME

Fast Assembly Mpeg Encoder

FAQ

Frequently Asked Questions

FAX

Facsimile

FB

Frame Buffer

FHS

File Hierarchy Standard

FLAC

Free Lossless Audio CODEC

FO

Formatted Objects

FTP

File Transfer Protocol

GCC

GNU Compiler Collection

GDBM

GNU DataBase Manager

GDK

GTK+ Drawing Kit

GDM

GNOME Display Manager

GID

Group IDentity

GIF

Graphics Interchange Format

GLUT

OpenGL Utility Toolkit

GMP

GNU Multiple Precision Arithmetic

GNAT

GNU NYU Ada 9x Translator

GNOME

GNU Network Object Model Environment

GNU

GNU's Not Unix

GPL

General Public License

GPM

General Purpose Mouse

GSS

Generic Security Service

GSSAPI

Generic Security Service Application Programming Interface

GTK

GIMP ToolKit

GUI

Graphical User Interface

HFS

Hierarchical File System

HTML

HyperText Markup Language

HTTP

HyperText Transfer Protocol

HTTPS

HyperText Transfer Protocol Secured

HUP

Hang UP

IANA

Internet Assigned Numbers Authority

ICC

International Color Consortium

ICMP

Internet Control Message Protocol

IDE

Integrated Drive Electronics

Integrated Development Environment

IDL

Interface Definition Language

IJS

Ink Jet Systems

ILS

Internet Location Server

IMAP

Internet Message Access Protocol

IMON

Inode MONitor

IP

Internet Protocol

See Also TCP .

IPX

Internetwork Packet eXchange

IRC

Internet Relay Chat

ISDN

Integrated Services Digital Network

ISO

International Standards Organisation

ISP

Internet Service Provider

IT

ImpulseTracker Module

JAI

Java Advanced Imaging

JAR

Java ARchive

JDK

Java Development Kit

JFIF

JPEG File Interchange Format

JPEG

Joint Photographic Experts Group

KDC

Key Distribution Center

KDE

KDesktop Environment

LAME

Lame Ain't an MP3 Encoder

LAN

Local Area Network

LDAP

Lightweight Directory Access Protocol

LDIF

Lightweight Data Interchange Format

LFS

Linux From Scratch

LGPL

Library General Public License

LPR

Line PRinter

LZO

Lempel-Ziv-Oberhumer

LZW

Lempel-Ziv-Welch

MAC

Media Access Control

MCOP

Multimedia COmmunication Protocol

MCU

Multipoint Control Unit

MD

Message-Digest

MDA

Mail Delivery Agent

MED

MED/OctaMED Module

MIDI

Musical Instrument Digital Interface

MIF

Maker Interchange Format

MII

Media Independent Interface

MIME

Multipurpose Internet Mail Extensions

MIT

Massachusetts Institute of Technology

MNG

Multiple-image Network Graphics

MOD

ProTracker Module

MP3

MPEG-1 audio layer 3

MPEG

Moving Picture Experts Group

MSL

Magick Scripting Language

MTA

Mail Transport Agent

MTM

MultiTracker Module

MUA

Mail User Agent

NASM

Netwide ASseMbler

NNTP

Network News Transfer Protocol

NFS

Network File System

NIS

Network Information Service

NPTL

Native Posix Thread Library

NSPR

Netscape Portable Runtime

NSS

Network Security Services

NTP

Network Time Protocol

OAF

Object Activation Framework

ODBC

Open DataBase Connectivity

OMF

Open Metadata Framework

ORB

Object Request Broker

See Also CORBA .

ORDBMS

Object Relational Database Management System

OS

Operating System

OSF

Open Software Foundation

OSS

Open Sound System

PAM

Pluggable authentication Modules

PBM

Portable BitMap

PCI

Peripheral Component Interconnect

PCL

Printer Control Language

PCM

Pulse Code Modulation

PDC

Primary Domain Controller

PDF

Portable Document Format

PEAR

PHP Extension and Application Repository

PGM

Portable Grey Map

PGP

Pretty Good Privacy

PHP

PHP Hypertext Preprocessor

PIM

Personal Information Manager

PLIP

Parallel Line Internet Protocol

PNG

Portable Network Graphics

PO

Portable Object

POD

Plain Old Documentation

POP

Post Office Protocol

PPD

PostScript Printer Description

PPM

Portable Pixel Map

PPP

Point to Point Protocol

PPPoE

Point to Point Protocol over Ethernet

PS

PostScript

RADIUS

Remote Authentication Dial-In User Service

RAM

Random Access Memory

RARP

Reverse Address Resolution Protocol

RCS

Revision Control System

RFC

Request For Comments

RGB

Red Green Blue

RGBA

Red Green Blue Alpha

ROM

Read-Only Memory

RP

Roaring Penguin

RPC

Remote Procedure Call

RTC

Real Time Clock

RTP

Real Time Protocol

RW

Read Write

S3M

ScreamTracker Version 3 Module

S/MIME

Secure/MIME

SANE

Scanner Access Now Easy

SASL

Simple Authentication and Security Layer

SATA

Serial Advanced Technology Attachment

SBU

Standard Build Unit

SCSI

Small Computer System Interface

SDK

Software Development Kit

SGML

Standard Generalized Markup Language

SMART

Self Monitoring Analysis and Reporting Technology

SMB

Server Message Block

SMIL

Synchronized Multimedia Integration Language

SMTP

Simple Mail Transfer Protocol

SQL

Structured Query Language

SSH

Secure SHell

SSL

Secure Sockets Layer

SUID

Set User IDentity

SVG

Scalable Vector Graphics

SVGA

Super Video Graphics Array

TCL

Tool Command Language

TCP

Transmission Control Protocol

TGT

Ticket-Granting Ticket

TIFF

Tag(ged) Image File Format

TLS

Transport Layer Security

TTF

TrueType Font

TTS

Text To Speech

UCS

Universal Character Set

UDF

Universal Disk Format

UID

User IDentity

UDP

User Datagram Protocol

UI

User Interface

UML

Unified Modelling Language

URL

Uniform Resource Locator

USB

Universal Serial Bus

USR

Upstream Ready

UTF

UCS Transformation Format

UUCP

Unix-to-Unix Copy Protocol

VCD

Video Compact Disk

VESA

Video Electronics Standards Association

VGA

Video Graphics Array

VNC

Virtual Network Computer

VOB

Video OBject

VOIP

Voice Over IP

W3C

World Wide Web Consortium

WAV

Waveform Audio

WWW

World Wide Web

XDMCP

XDisplay Manager Control Protocol

XM

FastTracker Module

XML

eXtensible Markup Language

XSL

eXtensible Style Language

XSLT

eXtensible Style Language Transformation

XSM

X/Open System Management

XMMS

XMultiMedia System

YP

Yellow Pages

YUV

Luminance-Bandwidth-Chrominance

Index

Packages

Programs

Libraries

Kernel Configuration

Configuration Files

Bootscripts

Others