Extra-CMake-Modules-6.29.0

#### Beyond Linux® From Scratch (System V Edition) - Version r13.1-84

### Chapter 29. Introduction to KDE

- Prev

  KDE Preliminaries

- Next

  Phonon-4.12.0

- Up
- Home

# Extra-CMake-Modules-6.29.0

## Introduction to Extra CMake Modules

The Extra CMake Modules package contains extra CMake modules used by KDE Frameworks and other packages.

### Note

Development versions of BLFS may not build or run some packages properly if LFS or dependencies have been updated since the most recent stable versions of the books.

### Package Information

- Download (HTTP): https://download.kde.org/stable/frameworks/6.29/extra-cmake-modules-6.29.0.tar.xz

- Download MD5 sum: b3795f9b843a58746ca5461713c088d8

- Download size: 332 KB

- Estimated disk space required: 11 MB

- Estimated build time: less than 0.1 SBU

### Extra CMake Modules Dependencies

#### Required

CMake-4.4.3

#### Recommended

Qt-6.11.2

#### Optional

sphinx-9.1.0 (for building documentation) and ReuseTool (for running internal tests)

## 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 -D CMAKE_INSTALL_PREFIX=/usr \
          -D BUILD_WITH_QT6=ON         \
          -D DOC_INSTALL_DIR=/usr/share/doc/extra-cmake-modules-6.29.0 \
          .. &&
    make

This package does not come with a test suite.

### Note

Unlike other KF6 packages, this module is installed in /usr because it can be used by some non-KF6 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 for the presence of ECM. Since we install ECM into `/usr`, the check would set that variable to `/usr`, but most KDE packages expect it to be set to `/opt/kf6` and they will fail to build if it is set to something else.

`-D DOC_INSTALL-DIR=/usr/share/doc/extra...`: This switch allows installing the documentation (which is built if sphinx-9.1.0 is installed) into a versioned directory.

## Contents

Installed Programs: None
Installed Libraries: None
Installed Directories: /usr/share/ECM and /usr/share/doc/extra-cmake-modules-6.29.0 (if documentation was built)

- Prev

  KDE Preliminaries

- Next

  Phonon-4.12.0

- Up
- Home