#### Beyond Linux® From Scratch (systemd Edition) - Version r13.0-491

### Chapter 10. Graphics and Font Libraries

- Prev

  opencv-4.13.0

- Next

  Pixman-0.46.4

- Up
- Home

# OpenJPEG-2.5.4

## 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.

### 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://github.com/uclouvain/openjpeg/archive/v2.5.4/openjpeg-2.5.4.tar.gz

- Download MD5 sum: 6160de075bb5191e482bc0f024b375e4

- Download size: 2.1 MB

- Estimated disk space required: 16 MB (add 1.7 GB for tests)

- Estimated build time: 0.2 SBU (add 1.1 SBU for tests)

### OpenJPEG Dependencies

#### Required

CMake-4.3.2

#### Optional

git-2.53.0 (for tests), Little CMS-2.19, libpng-1.6.58, libtiff-4.7.1, and Doxygen-1.17.0 (to build the API documentation)

## Installation of OpenJPEG

Install OpenJPEG by running the following commands:

    mkdir -v build &&
    cd       build &&

    cmake -D CMAKE_BUILD_TYPE=Release  \
          -D CMAKE_INSTALL_PREFIX=/usr \
          -D BUILD_STATIC_LIBS=OFF ..  &&
    make

If you wish to run the tests, some additional files are required. Download these files and run the tests using the following commands, but note that 8 tests are known to fail:

    git clone https://github.com/uclouvain/openjpeg-data.git --depth 1 &&
    OPJ_DATA_ROOT=$PWD/openjpeg-data cmake -D BUILD_TESTING=ON ..      &&
    make                                                               &&
    make test

Now, as the `root` user:

    make install &&
    cp -rv ../doc/man -T /usr/share/man

## Contents

Installed Programs: opj_compress, opj_decompress, and opj_dump
Installed Libraries: libopenjp2.so
Installed Directories: /usr/include/openjpeg-2.5 and /usr/lib/openjpeg-2.5

### 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

- Prev

  opencv-4.13.0

- Next

  Pixman-0.46.4

- Up
- Home