dev-tcltk/tkimg: Fix build with jpeg-9
authorAndreas Sturmlechner <asturm@gentoo.org>
Wed, 7 Feb 2018 22:35:15 +0000 (23:35 +0100)
committerAndreas Sturmlechner <asturm@gentoo.org>
Sat, 10 Feb 2018 12:45:12 +0000 (13:45 +0100)
Closes: https://bugs.gentoo.org/520886
Package-Manager: Portage-2.3.24, Repoman-2.3.6

dev-tcltk/tkimg/files/tkimg-1.4-jpeg-9.patch [new file with mode: 0644]
dev-tcltk/tkimg/tkimg-1.4-r9.ebuild

diff --git a/dev-tcltk/tkimg/files/tkimg-1.4-jpeg-9.patch b/dev-tcltk/tkimg/files/tkimg-1.4-jpeg-9.patch
new file mode 100644 (file)
index 0000000..23000ac
--- /dev/null
@@ -0,0 +1,18 @@
+Fix build with jpeg-9, bug #520886
+
+--- a/jpeg/jpeg.c      2010-06-17 15:40:24.000000000 +0200
++++ b/jpeg/jpeg.c      2018-02-07 23:26:38.050073397 +0100
+@@ -53,6 +53,13 @@
+  */
+ 
+ #include "tkimg.h"
++#ifndef FALSE
++#define FALSE 0
++#endif
++#ifndef TRUE
++#define TRUE 1
++#endif
++#define HAVE_BOOLEAN
+ #include "jpegtcl.h"
+ 
+ static int SetupJPegLibrary(Tcl_Interp *interp);
index 9b621a465ef73ec2cc8125e17e11af8b9629868d..155c4483e327f8cce78825d8a82c4fb5359ef64e 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 1999-2015 Gentoo Foundation
+# Copyright 1999-2018 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=5
@@ -40,6 +40,7 @@ S="${WORKDIR}/${MYP}"
 src_prepare() {
        epatch \
                "${WORKDIR}"/${P}-jpeg.patch \
+               "${FILESDIR}"/${P}-jpeg-9.patch \
                "${WORKDIR}"/${P}-tiff.patch \
                "${WORKDIR}"/${P}-png.patch \
                "${FILESDIR}"/${P}-png2.patch \