summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergei Trofimovich <slyfox@gentoo.org>2019-01-30 21:21:27 +0000
committerSergei Trofimovich <slyfox@gentoo.org>2019-01-30 21:21:27 +0000
commitecdea30cd4b1c5df9e7642921f0004f5137607a5 (patch)
tree4b99a9b9647dbdeb6ca189c32cc35a276f399cd4
parentnet-misc/electrum: version bump to 3.3.3 (diff)
downloadgentoo-ecdea30cd4b1c5df9e7642921f0004f5137607a5.tar.gz
gentoo-ecdea30cd4b1c5df9e7642921f0004f5137607a5.tar.bz2
gentoo-ecdea30cd4b1c5df9e7642921f0004f5137607a5.zip
app-text/poppler: backport jpeg buildfix, bug #670252
jpeg-9c defines TRUE and FALSE as 'enum' values not compatible to bool. Reported-by: Toralf Förster Closes: https://bugs.gentoo.org/670252 Package-Manager: Portage-2.3.59, Repoman-2.3.12 Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
-rw-r--r--app-text/poppler/files/poppler-0.68.0-bool.patch36
-rw-r--r--app-text/poppler/poppler-0.68.0.ebuild1
2 files changed, 37 insertions, 0 deletions
diff --git a/app-text/poppler/files/poppler-0.68.0-bool.patch b/app-text/poppler/files/poppler-0.68.0-bool.patch
new file mode 100644
index 000000000000..a2d8ba7bd402
--- /dev/null
+++ b/app-text/poppler/files/poppler-0.68.0-bool.patch
@@ -0,0 +1,36 @@
+https://bugs.gentoo.org/670252
+
+From de34900993bff73c8da651319027b2fa8c490172 Mon Sep 17 00:00:00 2001
+From: Ed Porras <ed@motologic.com>
+Date: Sun, 26 Aug 2018 20:24:23 +0200
+Subject: [PATCH] fix macOS compilation due to boolean define in jpeglib
+
+typedef enum { FALSE = 0, TRUE = 1 } boolean;
+---
+ goo/JpegWriter.cc | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/goo/JpegWriter.cc b/goo/JpegWriter.cc
+index 16c97afe..26fa77a7 100644
+--- a/goo/JpegWriter.cc
++++ b/goo/JpegWriter.cc
+@@ -11,6 +11,7 @@
+ // Copyright (C) 2013 Peter Breitenlohner <peb@mppmu.mpg.de>
+ // Copyright (C) 2017, 2018 Albert Astals Cid <aacid@kde.org>
+ // Copyright (C) 2018 Martin Packman <gzlist@googlemail.com>
++// Copyright (C) 2018 Ed Porras <ed@motologic.com>
+ //
+ //========================================================================
+
+@@ -143,7 +144,7 @@ bool JpegWriter::init(FILE *f, int width, int height, int hDPI, int vDPI)
+ }
+
+ // Set whether to compute optimal Huffman coding tables
+- priv->cinfo.optimize_coding = priv->optimize;
++ priv->cinfo.optimize_coding = static_cast<boolean>(priv->optimize);
+
+ // Get ready for data
+ jpeg_start_compress(&priv->cinfo, TRUE);
+--
+2.20.1
+
diff --git a/app-text/poppler/poppler-0.68.0.ebuild b/app-text/poppler/poppler-0.68.0.ebuild
index 16588ae074df..e2839fc0c540 100644
--- a/app-text/poppler/poppler-0.68.0.ebuild
+++ b/app-text/poppler/poppler-0.68.0.ebuild
@@ -61,6 +61,7 @@ PATCHES=(
"${FILESDIR}/${PN}-0.28.1-fix-multilib-configuration.patch"
"${FILESDIR}/${PN}-0.61.0-respect-cflags.patch"
"${FILESDIR}/${PN}-0.57.0-disable-internal-jpx.patch"
+ "${FILESDIR}/${PN}-0.68.0-bool.patch"
)
src_prepare() {