8.49. Libelf from Elfutils-0.193

#### Linux From Scratch - Version 12.4-rc1

### Chapter 8. Installing Basic System Software

- Prev

  OpenSSL-3.5.2

- Next

  Libffi-3.5.2

- Up
- Home

# 8.49. Libelf from Elfutils-0.193

Libelf is a library for handling ELF (Executable and Linkable Format) files.

Approximate build time: 0.3 SBU
Required disk space: 156 MB

## 8.49.1. Installation of Libelf

Libelf is part of the elfutils-0.193 package. Use the elfutils-0.193.tar.bz2 file as the source tarball.

Prepare Libelf for compilation:

    ./configure --prefix=/usr        \
                --disable-debuginfod \
                --enable-libdebuginfod=dummy

Compile the package:

    make

To test the results, issue:

    make check

Two tests are known to fail, dwarf_srclang_check and run-backtrace-native-core.sh.

Install only Libelf:

    make -C libelf install
    install -vm644 config/libelf.pc /usr/lib/pkgconfig
    rm /usr/lib/libelf.a

## 8.49.2. Contents of Libelf

Installed library: libelf.so
Installed directory: /usr/include/elfutils

### Short Descriptions

`libelf.so` | Contains API functions to handle ELF object files

- Prev

  OpenSSL-3.5.2

- Next

  Libffi-3.5.2

- Up
- Home