reehan79 / openjpeg

Automatically exported from code.google.com/p/openjpeg
0 stars 0 forks source link

Bug in libopenjpwl.pc #374

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I have found a bug in the pkg-config file for JPWL
and openjpeg-2.
-----------------------------------------------
Before changing the contents of libopenjpwl.pc:
-----------------------------------------------
prefix=/usr/local/opj2
bindir=${prefix}/bin
mandir=${prefix}/
docdir=${prefix}/
libdir=${prefix}/lib
includedir=${prefix}/include/openjpeg-2.1

Name: openjpwl
Description: JPEG2000 Wireless library (Part 11)
URL: http://www.openjpeg.org/
Version: 2.1.0
Requires: openjp2 <================
Libs: -L${libdir} -lopenjpwl
Libs.private: -lm
Cflags: -I${includedir}

pkg-config --libs libopenjpwl

Package openjp2 was not found in the pkg-config search path.
Perhaps you should add the directory containing `openjp2.pc'
to the PKG_CONFIG_PATH environment variable
Package 'openjp2', required by 'openjpwl', not found

-----------------------------------------------
After changing the contents of libopenjpwl.pc:
-----------------------------------------------
prefix=/usr/local/opj2
bindir=${prefix}/bin
mandir=${prefix}/
docdir=${prefix}/
libdir=${prefix}/lib
includedir=${prefix}/include/openjpeg-2.1

Name: openjpwl
Description: JPEG2000 Wireless library (Part 11)
URL: http://www.openjpeg.org/
Version: 2.1.0
Requires: libopenjp2 <========== CHANGE
Libs: -L${libdir} -lopenjpwl
Libs.private: -lm
Cflags: -I${includedir}

root: pkg-config --libs libopenjpwl
-L/usr/local/opj2/lib -lopenjpwl -lopenjp2

======================================

It seems that JPWL images can be shown only with code from
openjpeg-v1.

openjpeg-2.x-trunk-r2871-1/src/bin/jpwl/opj_jpwl_decompress.c:

 dinfo = opj_create_decompress(codec_format);
 opj_setup_decoder(dinfo, &parameters);
 cio = opj_cio_open((opj_common_ptr)dinfo, buf, buf_size);
 image = opj_decode(dinfo, cio);
 opj_cio_close(cio);

With code from openjpeg-v2 I get:

        opj_read_header failed

Program received signal SIGSEGV, Segmentation fault.
0x0000000000000000 in ?? ()
(gdb) bt
#0  0x0000000000000000 in ?? ()
#1  0x00007ffff5a04c1c in opj_destroy_codec ()
   from /usr/local/opj2/lib/libopenjp2.so.7

winfried

Original issue reported on code.google.com by szukw...@arcor.de on 7 Jul 2014 at 8:15

GoogleCodeExporter commented 9 years ago
no dataset to reproduce. closing as invalid.

Original comment by mathieu.malaterre on 17 Sep 2014 at 9:57