libsndfile-1.2.2

#### Gaming Linux® From Scratch - Version 13.0

### Chapter 7. Audio

- Prev

  Speex-1.2.1

- Next

  PulseAudio-17.0

- Up
- Home

# libsndfile-1.2.2

## Introduction to libsndfile

Libsndfile is a library of C routines for reading and writing files containing sampled audio data.

- Download: https://github.com/libsndfile/libsndfile/releases/download/1.2.2/libsndfile-1.2.2.tar.xz

### libsndfile Dependencies

Recommended
FLAC-1.5.0, Opus-1.6.1, and libvorbis-1.3.7
Optional
alsa-lib-1.2.15.3, LAME-3.100, mgp123, and Speex-1.2.1

## Installation of libsndfile

Fix the code to allow building with GCC-15.x.x:

    sed '/typedef enum/,/bool ;/d' -i src/ALAC/alac_{en,de}coder.c

Install libsndfile by running the following commands:

    ./configure --prefix=/usr    \
                --docdir=/usr/share/doc/libsndfile-1.2.2 &&

    make

Now, as the `root` user:

    make install

## lib32 Installation of libsndfile

Install lib32-libsndfile by running the following commands:

    make distclean &&
    CC="gcc -m32" CXX="g++ -m32"         \
    PKG_CONFIG_PATH=/usr/lib32/pkgconfig \
    ./configure --prefix=/usr            \
                --libdir=/usr/lib32      \
                --host=i686-pc-linux-gnu &&

    make

Now, as the `root` user:

    make DESTDIR=$PWD/DESTDIR install     &&
    cp -vr DESTDIR/usr/lib32/* /usr/lib32 &&
    rm -rf DESTDIR                        &&
    ldconfig

## Command Explanations

### Note

Run ./configure --help for a full list of options.

## 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
Installed Directory: /usr/share/doc/libsndfile-1.2.2

### Short Descriptions

sndfile-cmp | compares two audio files
sndfile-concat | concatenates two or more audio files
sndfile-convert | converts a sound file 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 4GB in size
`libsndfile` | contains the libsndfile API functions

- Prev

  Speex-1.2.1

- Next

  PulseAudio-17.0

- Up
- Home