Commit 7cf3ab49 authored by Kan-Ru Chen's avatar Kan-Ru Chen

Fix build with openjpeg 1.3

parent c83cd0f3
mupdf (1.2-2) unstable; urgency=low
* Upload to unstable
* Fix build with openjpeg 1.3.
-- Kan-Ru Chen (陳侃如) <koster@debian.org> Thu, 20 Jun 2013 22:54:51 +0800
mupdf (1.2-1) experimental; urgency=low
[ Quoc-Viet Nguyen ]
......
......@@ -5,7 +5,7 @@ Maintainer: Kan-Ru Chen (陳侃如) <koster@debian.org>
Uploaders: Quoc-Viet Nguyen <afelion@gmail.com>
Build-Depends: debhelper (>= 7.0.50~), dpkg-dev (>= 1.16.1.1~),
libfreetype6-dev, pkg-config, libjpeg-dev, libjbig2dec-dev,
libopenjpeg-dev (>= 1.5), libx11-dev, libxext-dev, zlib1g-dev
libopenjpeg-dev, libx11-dev, libxext-dev, zlib1g-dev
Standards-Version: 3.9.4
Homepage: http://mupdf.com/
Vcs-Git: git://git.debian.org/git/users/koster/mupdf.git
......
---
Makefile | 2 +-
Makerules | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
Makefile | 2 +-
Makerules | 2 +-
fitz/image_jpx.c | 3 +++
3 files changed, 5 insertions(+), 2 deletions(-)
--- a/Makefile
+++ b/Makefile
......@@ -21,7 +22,21 @@
ifeq "$(OS)" "Linux"
SYS_FREETYPE_INC := `pkg-config --cflags freetype2`
-SYS_OPENJPEG_INC := `pkg-config --cflags libopenjpeg`
+SYS_OPENJPEG_INC := `pkg-config --cflags libopenjpeg1`
+SYS_OPENJPEG_INC := `if pkg-config --exists libopenjpeg1; then pkg-config --cflags libopenjpeg1; else echo "-L/usr/include"; fi`
X11_LIBS := -lX11 -lXext
endif
--- a/fitz/image_jpx.c
+++ b/fitz/image_jpx.c
@@ -50,8 +50,11 @@
evtmgr.info_handler = fz_opj_info_callback;
opj_set_default_decoder_parameters(&params);
+#ifdef OPJ_DPARAMETERS_IGNORE_PCLR_CMAP_CDEF_FLAG
+ /* Only openjpeg 1.5 support this */
if (indexed)
params.flags |= OPJ_DPARAMETERS_IGNORE_PCLR_CMAP_CDEF_FLAG;
+#endif
info = opj_create_decompress(format);
opj_set_event_mgr((opj_common_ptr)info, &evtmgr, ctx);
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment