Bug 1850214

Summary: ImageMagick 6.9.10.68-3.el7 is not compiled with openjpeg2 (JPEG2000) support [rhel-7.9.z]
Product: Red Hat Enterprise Linux 7 Reporter: Karl <karl.clodfelter>
Component: ImageMagickAssignee: Jan Horak <jhorak>
Status: CLOSED ERRATA QA Contact: Desktop QE <desktop-qa-list>
Severity: high Docs Contact:
Priority: high    
Version: 7.8CC: ccheney, h.f.j.paulissen, jhorak, jreznik, tpelka, tpopela
Target Milestone: rcKeywords: Regression, ZStream
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: ImageMagick-6.9.10.68-4.el7 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-12-15 11:24:30 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Karl 2020-06-23 18:24:38 UTC
Description of problem:
Recently upgraded some RPMs on a system that had ImageMagick 6.7.8.9-18 installed (and working with JP2/J2K files) and received 6.9.10 from the repo. My JP2/J2K files stopped converting as a result. It appears this is a compile-time issue that would require me to recompile ImageMagick from source to fix it which means the 6.9.10 rpm creator has improperly removed JPEG2000 support from the program in creating the RPM.

"convert -list configure" does not indicate JPEG2000 support was included in configuration at time of compliation:

Path: /usr/lib64/ImageMagick-6.9.10//config-Q16/configure.xml

Name           Value
-------------------------------------------------------------------------------
CC             gcc -std=gnu99 -std=gnu99
CFLAGS         -I/usr/include/libxml2   -I/usr/include/cairo -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng15 -I/usr/include/uuid -I/usr/include/libdrm   -pthread -I/usr/include/librsvg-2.0 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/cairo -I/usr/include/libpng15 -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/uuid -I/usr/include/libdrm   -I/usr/include/libpng15    -I/usr/include/pango-1.0 -I/usr/include/cairo -I/usr/include/harfbuzz -I/usr/include/freetype2 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/fribidi -I/usr/include/libpng15 -I/usr/include/uuid -I/usr/include/pixman-1 -I/usr/include/libdrm   -pthread -I/usr/include/OpenEXR -I/usr/include/libdrm       -I/usr/include/freetype2 -I/usr/include/libpng15   -I/usr/include/uuid -I/usr/include/freetype2 -I/usr/include/libpng15      -fopenmp -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches   -m64 -mtune=generic -mtune=core-avx2 -fexceptions -pthread -DMAGICKCORE_HDRI_ENABLE=0 -DMAGICKCORE_QUANTUM_DEPTH=16
CODER_PATH     /usr/lib64/ImageMagick-6.9.10/modules-Q16/coders
CONFIGURE      ./configure  '--build=x86_64-redhat-linux-gnu' '--host=x86_64-redhat-linux-gnu' '--program-prefix=' '--disable-dependency-tracking' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' '--sbindir=/usr/sbin' '--sysconfdir=/etc' '--datadir=/usr/share' '--includedir=/usr/include' '--libdir=/usr/lib64' '--libexecdir=/usr/libexec' '--localstatedir=/var' '--sharedstatedir=/var/lib' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--enable-shared' '--disable-static' '--with-modules' '--with-perl' '--with-x' '--with-threads' '--with-magick_plus_plus' '--with-gslib' '--with-wmf' '--with-rsvg' '--with-xml' '--with-perl-options=INSTALLDIRS=vendor  CC='\''gcc -L/builddir/build/BUILD/ImageMagick-6.9.10-68/magick/.libs'\'' LDDLFLAGS='\''-shared -L/builddir/build/BUILD/ImageMagick-6.9.10-68/magick/.libs'\''' '--without-dps' '--without-included-ltdl' '--with-ltdl-include=/usr/include' '--with-lcms2=yes' '--with-ltdl-lib=/usr/lib64' 'build_alias=x86_64-redhat-linux-gnu' 'host_alias=x86_64-redhat-linux-gnu' 'CFLAGS=-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches   -m64 -mtune=generic' 'LDFLAGS=-Wl,-z,relro ' 'CXXFLAGS=-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches   -m64 -mtune=generic' 'PKG_CONFIG_PATH=:/usr/lib64/pkgconfig:/usr/share/pkgconfig'
CONFIGURE_PATH /etc/ImageMagick-6/
COPYRIGHT      Copyright (C) 1999-2019 ImageMagick Studio LLC
CPPFLAGS       -I/usr/include/ImageMagick-6
CXX            g++
CXXFLAGS       -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches   -m64 -mtune=generic -pthread
DEFS           -DHAVE_CONFIG_H
DELEGATES      bzlib mpeg fontconfig freetype gslib jng jpeg lcms lzma openexr pango png rsvg tiff wmf x xml zlib
DISTCHECK_CONFIG_FLAGS 'CFLAGS=-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches   -m64 -mtune=generic' 'LDFLAGS=-Wl,-z,relro '  --disable-deprecated  --with-quantum-depth=16  --with-jemalloc=no  --with-umem=no  --with-autotrace=no  --with-dps=no  --with-fontpath=
DOCUMENTATION_PATH /usr/share/doc/ImageMagick-6
EXEC-PREFIX    /usr
EXECUTABLE_PATH /usr/bin
FEATURES       DPC Cipher OpenMP Modules
FILTER_PATH    /usr/lib64/ImageMagick-6.9.10/modules-Q16/filters
GIT_REVISION   14873
HOST           x86_64-redhat-linux-gnu
INCLUDE_PATH   /usr/include/ImageMagick-6
LDFLAGS        -L/usr/lib64 -Wl,-z,relro
LIB_VERSION    0x69A
LIB_VERSION_NUMBER 6,9,10,68
LIBRARY_PATH   /usr/lib64/ImageMagick-6.9.10
LIBS            -llcms2   -lfreetype      -lxml2    -lfontconfig -lfreetype   -lXext   -lSM -lICE -lX11  -lXt -llzma   -lbz2 -lz    -lltdl   -lm      -lgomp
NAME           ImageMagick
PCFLAGS        -fopenmp -DMAGICKCORE_HDRI_ENABLE=0 -DMAGICKCORE_QUANTUM_DEPTH=16
PREFIX         /usr
QuantumDepth   16
RELEASE_DATE   2020-04-01
SHARE_PATH     /usr/share/ImageMagick-6
SHAREARCH_PATH /usr/lib64/ImageMagick-6.9.10/config-Q16
TARGET_CPU     x86_64
TARGET_OS      linux-gnu
TARGET_VENDOR  redhat
VERSION        6.9.10
WEBSITE        https://imagemagick.org

Path: [built-in]

Name           Value
-------------------------------------------------------------------------------
DELEGATES      bzlib cairo fontconfig freetype gslib jng jpeg lcms ltdl lzma openexr pangocairo png ps rsvg tiff wmf x xml zlib
FEATURES       Cipher DPC Modules OpenMP(3.1)
NAME           ImageMagick
QuantumDepth   Q16


Version-Release number of selected component (if applicable):
6.9.10.68-3.el7

How reproducible:
Always

Steps to Reproduce:
1. Install ImageMagick RPM
2. convert whatever.jp2 whatever.png
3. See error about JP2 delegate missing.
4. Alternatively, do "convert -list format" and see no JP2/J2K formats identifiable

Actual results:
convert: no decode delegate for this image format `J2K' @ error/constitute.c/ReadImage/564.

Expected results:
whatever.png file created.

Additional info:
I've had to retrieve an ImageMagick RPM from another repo because this functionality is critical to my company's product.

Comment 2 Karl 2020-06-23 18:28:10 UTC
This was originally submitted to CentOS and was requested to be submitted here instead:
https://bugs.centos.org/view.php?id=17531

This is not the first time this has happened to the ImageMagick package:
https://bugzilla.redhat.com/show_bug.cgi?id=1267391

Comment 6 Henry Paulissen 2020-07-06 07:32:48 UTC
+1

Comment 8 Karl 2020-12-03 16:33:39 UTC
Is this issue "stuck" in some way? 7.9 appears to have gone out without this fix, no?

This has caused customers to move to alternate repos for ImageMagick that don't have this issue and it's complicating their lives.

Comment 9 Tomas Popela 2020-12-03 16:50:09 UTC
(In reply to Karl from comment #8)
> Is this issue "stuck" in some way? 7.9 appears to have gone out without this
> fix, no?

We made the builds, but forgot to add it to to erratum. We will add it to the next batch. Thank you for notifying us!

Comment 16 errata-xmlrpc 2020-12-15 11:24:30 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (ImageMagick bug fix and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2020:5464