summaryrefslogtreecommitdiff
path: root/external/poppler
diff options
context:
space:
mode:
authorMichael Stahl <mstahl@redhat.com>2016-11-02 14:13:54 +0100
committerDavid Tardon <dtardon@redhat.com>2016-11-03 09:26:15 +0000
commit206554422b9163fce76c8f44ec8be6c0de230685 (patch)
treee6460ee9f679c1e7bfac1bf3e45543887fc4e5d8 /external/poppler
parentf748f8173c0a7f539a174a09a141e58b468bf92c (diff)
poppler: build against libjpeg
Albert Astals Cid points out that --disable-libjpeg causes poppler to use internal JPEG code instead, which is not actively maintained. Add LIBJPEG_CFLAGS / LIBJPEG_LIBS to config_host.mk and patch poppler to respect LIBJPEG_LIBS. Reviewed-on: https://gerrit.libreoffice.org/30496 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com> (cherry picked from commit eea709f67d91e271e3df37e6c6724b7b5870b1ee) jpeg-turbo: resolve some conflicts to fix poppler build poppler uses both windows.h and jpeg headers, so runs into the conflict between Win32 definitions of boolean, INT16, INT32, and jpeg's. Tweak jpeg-turbo headers so it uses the Win32 definitions. (cherry picked from commit f2761b62b3d0b45a3e57781a16c8c5c6ee94ded0) Change-Id: Id19a62a9bd9dc41fee5e8e43e2798e515aacc299 Reviewed-on: https://gerrit.libreoffice.org/30506 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: David Tardon <dtardon@redhat.com>
Diffstat (limited to 'external/poppler')
-rw-r--r--external/poppler/ExternalProject_poppler.mk2
-rw-r--r--external/poppler/UnpackedTarball_poppler.mk1
-rw-r--r--external/poppler/poppler-libjpeg.patch.123
3 files changed, 25 insertions, 1 deletions
diff --git a/external/poppler/ExternalProject_poppler.mk b/external/poppler/ExternalProject_poppler.mk
index eab1d9181c61..f75dddc114cd 100644
--- a/external/poppler/ExternalProject_poppler.mk
+++ b/external/poppler/ExternalProject_poppler.mk
@@ -26,7 +26,7 @@ $(call gb_ExternalProject_get_state_target,poppler,build) :
--disable-poppler-cpp \
--disable-libopenjpeg \
--disable-libtiff \
- --disable-libjpeg \
+ --enable-libjpeg \
--disable-libpng \
--disable-zlib \
--disable-libcurl \
diff --git a/external/poppler/UnpackedTarball_poppler.mk b/external/poppler/UnpackedTarball_poppler.mk
index 4de2242a56dc..efcbee7c7e0f 100644
--- a/external/poppler/UnpackedTarball_poppler.mk
+++ b/external/poppler/UnpackedTarball_poppler.mk
@@ -19,6 +19,7 @@ $(eval $(call gb_UnpackedTarball_add_patches,poppler,\
external/poppler/poppler-0.46.0-std-max.patch.1 \
external/poppler/poppler-0.46.0-unused-private-field.patch.1 \
external/poppler/ubsan.patch.0 \
+ external/poppler/poppler-libjpeg.patch.1 \
))
# vim: set noet sw=4 ts=4:
diff --git a/external/poppler/poppler-libjpeg.patch.1 b/external/poppler/poppler-libjpeg.patch.1
new file mode 100644
index 000000000000..c8d54beb75ae
--- /dev/null
+++ b/external/poppler/poppler-libjpeg.patch.1
@@ -0,0 +1,23 @@
+do not override user supplied LIBJPEG_LIBS so we can use the one in WORKDIR
+
+--- poppler/configure.orig 2016-11-02 13:58:32.530617038 +0100
++++ poppler/configure 2016-11-02 13:58:06.233617689 +0100
+@@ -21377,8 +21377,9 @@
+ ac_save_USER_INCLUDES="$USER_INCLUDES"
+ ac_save_USER_LDFLAGS="$USER_LDFLAGS"
+ USER_INCLUDES="$USER_INCLUDES $LIBJPEG_CFLAGS"
+- USER_LDFLAGS="$USER_LDFLAGS $LIBJPEG_CFLAGS"
++ USER_LDFLAGS="$USER_LDFLAGS $LIBJPEG_LIBS"
+
++if test -z "$LIBJPEG_LIBS"; then
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libjpeg6b" >&5
+ $as_echo_n "checking for libjpeg6b... " >&6; }
+@@ -21489,6 +21490,7 @@
+
+
+ fi
++fi
+
+
+ ac_save_CPPFLAGS="$CPPFLAGS"