summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Volkov <pva@gentoo.org>2011-05-01 10:11:27 +0000
committerPeter Volkov <pva@gentoo.org>2011-05-01 10:11:27 +0000
commit548b33fb826c5a26c0b7dde2b17030b4d76697b0 (patch)
tree24c65ed58b3c7f08387f3081dbe803260f7ad261 /media-gfx/xfig
parentppc64 stable wrt #360531 (diff)
downloadhistorical-548b33fb826c5a26c0b7dde2b17030b4d76697b0.tar.gz
historical-548b33fb826c5a26c0b7dde2b17030b4d76697b0.tar.bz2
historical-548b33fb826c5a26c0b7dde2b17030b4d76697b0.zip
Fix build issue with libpng-1.5, bug #356753 thank Alexis Ballier for this patch. Drop old.
Package-Manager: portage-2.1.9.46/cvs/Linux x86_64
Diffstat (limited to 'media-gfx/xfig')
-rw-r--r--media-gfx/xfig/ChangeLog7
-rw-r--r--media-gfx/xfig/Manifest6
-rw-r--r--media-gfx/xfig/files/xfig-3.2.5b-libpng-1.5.patch70
-rw-r--r--media-gfx/xfig/xfig-3.2.5b-r1.ebuild4
-rw-r--r--media-gfx/xfig/xfig-3.2.5b.ebuild94
5 files changed, 82 insertions, 99 deletions
diff --git a/media-gfx/xfig/ChangeLog b/media-gfx/xfig/ChangeLog
index 2e7bff1aaed7..21c178c92bc7 100644
--- a/media-gfx/xfig/ChangeLog
+++ b/media-gfx/xfig/ChangeLog
@@ -1,6 +1,11 @@
# ChangeLog for media-gfx/xfig
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/media-gfx/xfig/ChangeLog,v 1.73 2011/01/09 13:57:52 ranger Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-gfx/xfig/ChangeLog,v 1.74 2011/05/01 10:11:26 pva Exp $
+
+ 01 May 2011; Peter Volkov <pva@gentoo.org> -xfig-3.2.5b.ebuild,
+ xfig-3.2.5b-r1.ebuild, +files/xfig-3.2.5b-libpng-1.5.patch:
+ Fix build issue with libpng-1.5, bug #356753 thank Alexis Ballier for this
+ patch. Drop old.
09 Jan 2011; Brent Baude <ranger@gentoo.org> xfig-3.2.5b-r1.ebuild:
Marking xfig-3.2.5b-r1 ppc for bug 348344
diff --git a/media-gfx/xfig/Manifest b/media-gfx/xfig/Manifest
index d45693f0f633..0f2d89def429 100644
--- a/media-gfx/xfig/Manifest
+++ b/media-gfx/xfig/Manifest
@@ -1,6 +1,7 @@
AUX xfig-3.2.5b-CVE-2010-4262.patch 619 RMD160 12bdb2b859d2fe21f95a3c9fc3f74141191b3344 SHA1 4620fd44f6231038c3bb66fde33a793437fe82ca SHA256 694ea1b3bfd73272c861cb51a0180bfa8915166302636684e8b4561a8b1afb3b
AUX xfig-3.2.5b-app-defaults.patch 601 RMD160 1f7b5998decfe729a266ac0e6a1219708cd9cc28 SHA1 ddb1afddb568aa8df602b55387fcf12080b67420 SHA256 e475edf793fb74ccf07c52d864c7d8e1f89fcc5c8204b69b60b1e7431d13311b
AUX xfig-3.2.5b-figparserstack.patch 1787 RMD160 1885fdc4f9955a8658c8895f8df37beb7cc86d17 SHA1 55e9d2b4ee43965b9469015adbf213d8239f0064 SHA256 334ccd66978934defed3e060b324db1fd729fb2fc02e6606149a3ec28f12c71d
+AUX xfig-3.2.5b-libpng-1.5.patch 2524 RMD160 891a31f2286869aa6e8922bcc20bd6a7d8e474aa SHA1 83032eb61c8dc96d5fc509a1ce632528457d4598 SHA256 f3b17684e360fe3c0f0b9836e6d05ca5c707297e1f21e7898a83a56bb988dad5
AUX xfig-3.2.5b-mkstemp.patch 979 RMD160 1c49878335af15a0d40db55ac38112ddf9923f78 SHA1 8ac04a8ae496dceb988c8dff582a03036baa76d4 SHA256 0881185381976aaad5b62d54baf7df96981b41a54a74c24710971b175e9e520c
AUX xfig-3.2.5b-network_images.patch 11918 RMD160 586d778f3de077bc5cc4c8a4ea174869078ab157 SHA1 331641aec1151f99995d4441204f77711aa140ee SHA256 08d983eea753008d3a2a9c7bebf0f9035e795ad3038dbbb05c2a512d86163695
AUX xfig-3.2.5b-papersize_b1.patch 1127 RMD160 36b12cf4cd5cfc52dc6756befea2fd9fb9b4b97c SHA1 43e5f9cae86bbe2bad1ccff3aad05b85962002a3 SHA256 36bed2e9bfe46868d5b750a12b892a7e20dbf7189d9fbbe4b0066411946d6f01
@@ -9,7 +10,6 @@ AUX xfig-3.2.5b-spelling.patch 898 RMD160 e34cf50c1cc0bf8c3395999366fb990713a465
AUX xfig-3.2.5b-urwfonts.patch 4921 RMD160 0f706460c4bbdfa3ad9c766423f72d74d1ca491c SHA1 4630587f030e05eb5a4a384fb593bb006dc630c5 SHA256 84d4d179088b5384c848acbf34e3b040e9648e838b080df8af54d73161a13f19
AUX xfig-3.2.5b-zoom-during-edit.patch 691 RMD160 8f12f1b632a57c74ab6d05a159dbcfe30f434f9e SHA1 6881b529345b655d5cf8b8087c3f7ae2de36e082 SHA256 922c8dd8d3949caca71be28043889db6359eb7ecd4509ce339f216df11b41e5b
DIST xfig.3.2.5b.full.tar.gz 5821049 RMD160 aad4cfd808c116d34218e9890a898652e4f52ab6 SHA1 0730d7e6bc217c0de02682efb0078821512bb542 SHA256 5c01cf6d79f4de04e3d9efc9f3e4ea046e880d6610f210c8551bb0a713e985c2
-EBUILD xfig-3.2.5b-r1.ebuild 2724 RMD160 ce7318778d8038016aa4f132a3afee6d690eb237 SHA1 3579a4c9022a305a366a66b5d228977b957acf09 SHA256 b829898509398ca95739b9090b1969f790a27b74f2add48dbad64923235f66ac
-EBUILD xfig-3.2.5b.ebuild 2663 RMD160 65362ad025c625c72eb44cda387a2a6f10627cf8 SHA1 b0663ca61650046c97953c1c81683dd07946dec3 SHA256 3effe6196ac021d45be2c517e039ae4dc3920e1c78491bfdc06bb2c2c02807e1
-MISC ChangeLog 10958 RMD160 c8437d38da6cd2c6e0b04314a9d4dad1aba54c8f SHA1 95e5a4b56e95b7137e7649e89a9aa06f13b9517f SHA256 e2166e3d832aa905a813583a71c75c4743b9388ee902e10120e81eb22b05e87b
+EBUILD xfig-3.2.5b-r1.ebuild 2774 RMD160 2eefb7e0ab6edba4e2ce5dd943f337389cd2e020 SHA1 97a87e2179bfec880e01c1f8ee30141bf84f2891 SHA256 76d8a95ddf25a3bdd4bed3fb09bb1ed578be5fc4e816617f7e9346b007f4b18e
+MISC ChangeLog 11180 RMD160 61e840eead3d7a226027e76bcd445efd6073334d SHA1 deaa10834f042505f21d1dde498e20ebe106222c SHA256 c30c8fa46326cd11a61be753c9dd4cd321ed6e1e8ba5e955812823ae678b8fd5
MISC metadata.xml 250 RMD160 f27bc8272125f15d03c2bfc87e961842bdb303ae SHA1 c4991bbfca89085d81f56ed53f8b0c827a35a4f1 SHA256 68999dde540491efec63a8f47366dbc2d5f2c9f2c1211709d92366a56b6cd27d
diff --git a/media-gfx/xfig/files/xfig-3.2.5b-libpng-1.5.patch b/media-gfx/xfig/files/xfig-3.2.5b-libpng-1.5.patch
new file mode 100644
index 000000000000..7d9c3f15efb9
--- /dev/null
+++ b/media-gfx/xfig/files/xfig-3.2.5b-libpng-1.5.patch
@@ -0,0 +1,70 @@
+Index: xfig.3.2.5b/f_readpng.c
+===================================================================
+--- xfig.3.2.5b.orig/f_readpng.c
++++ xfig.3.2.5b/f_readpng.c
+@@ -73,7 +73,7 @@ read_png(FILE *file, int filetype, F_pic
+ }
+
+ /* set long jump recovery here */
+- if (setjmp(png_ptr->jmpbuf)) {
++ if (setjmp(png_jmpbuf(png_ptr))) {
+ /* if we get here there was a problem reading the file */
+ png_destroy_read_struct(&png_ptr, &info_ptr, &end_info);
+ close_picfile(file,filetype);
+@@ -90,15 +90,17 @@ read_png(FILE *file, int filetype, F_pic
+ png_get_IHDR(png_ptr, info_ptr, &w, &h, &bit_depth, &color_type,
+ &interlace_type, &compression_type, &filter_type);
+
+- if (info_ptr->valid & PNG_INFO_gAMA)
+- png_set_gamma(png_ptr, 2.2, info_ptr->gamma);
+- else
+- png_set_gamma(png_ptr, 2.2, 0.45);
++ png_fixed_point gamma = 0.45;
++ png_get_gAMA_fixed(png_ptr,info_ptr,&gamma);
++ png_set_gamma(png_ptr, 2.2, gamma);
+
+- if (info_ptr->valid & PNG_INFO_bKGD)
++ if (png_get_valid(png_ptr,info_ptr,PNG_INFO_bKGD)) {
+ /* set the background to the one supplied */
+- png_set_background(png_ptr, &info_ptr->background,
++ png_color_16p background;
++ png_get_bKGD(png_ptr,info_ptr,&background);
++ png_set_background(png_ptr, background,
+ PNG_BACKGROUND_GAMMA_FILE, 1, 1.0);
++ }
+ else {
+ /* blend the canvas background using the alpha channel */
+ background.red = x_bg_color.red >> 8;
+@@ -136,7 +138,11 @@ read_png(FILE *file, int filetype, F_pic
+
+ if (png_get_PLTE(png_ptr, info_ptr, &palette, &num_palette)) {
+ png_get_hIST(png_ptr, info_ptr, &histogram);
++#if PNG_LIBPNG_VER_MAJOR <= 1 && PNG_LIBPNG_VER_MINOR < 5
+ png_set_dither(png_ptr, palette, num_palette, 256, histogram, 0);
++#else
++ png_set_quantize(png_ptr, palette, num_palette, 256, histogram, 0);
++#endif
+ }
+ }
+ if (color_type == PNG_COLOR_TYPE_GRAY || color_type == PNG_COLOR_TYPE_GRAY_ALPHA) {
+Index: xfig.3.2.5b/f_wrpng.c
+===================================================================
+--- xfig.3.2.5b.orig/f_wrpng.c
++++ xfig.3.2.5b/f_wrpng.c
+@@ -20,6 +20,7 @@
+ #include "w_msgpanel.h"
+ #include "w_setup.h"
+ #include <png.h>
++#include <zlib.h>
+
+ /*
+ * Write PNG file from rgb data
+@@ -59,7 +60,7 @@ write_png(FILE *file, unsigned char *dat
+ }
+
+ /* set long jump recovery here */
+- if (setjmp(png_ptr->jmpbuf)) {
++ if (setjmp(png_jmpbuf(png_ptr))) {
+ /* if we get here there was a problem reading the file */
+ png_destroy_write_struct(&png_ptr, &info_ptr);
+ return False;
diff --git a/media-gfx/xfig/xfig-3.2.5b-r1.ebuild b/media-gfx/xfig/xfig-3.2.5b-r1.ebuild
index 091448315e1a..f6cdc3bab089 100644
--- a/media-gfx/xfig/xfig-3.2.5b-r1.ebuild
+++ b/media-gfx/xfig/xfig-3.2.5b-r1.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/media-gfx/xfig/xfig-3.2.5b-r1.ebuild,v 1.7 2011/01/09 13:57:52 ranger Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-gfx/xfig/xfig-3.2.5b-r1.ebuild,v 1.8 2011/05/01 10:11:26 pva Exp $
EAPI="2"
inherit eutils multilib
@@ -73,6 +73,8 @@ src_prepare() {
epatch "${FILESDIR}/${P}-urwfonts.patch"
epatch "${FILESDIR}/${P}-mkstemp.patch" #264575
epatch "${FILESDIR}/${P}-CVE-2010-4262.patch" #348344
+ epatch "${FILESDIR}/${P}-libpng-1.5.patch" #356753
+
sed_Imakefile Imakefile
sed -e "s:/usr/lib/X11/xfig:/usr/share/doc/${PF}:" \
-i Doc/xfig.man -i Doc/xfig_man.html || die
diff --git a/media-gfx/xfig/xfig-3.2.5b.ebuild b/media-gfx/xfig/xfig-3.2.5b.ebuild
deleted file mode 100644
index 5b85c19987c2..000000000000
--- a/media-gfx/xfig/xfig-3.2.5b.ebuild
+++ /dev/null
@@ -1,94 +0,0 @@
-# Copyright 1999-2010 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/media-gfx/xfig/xfig-3.2.5b.ebuild,v 1.9 2010/11/24 12:16:59 pva Exp $
-
-EAPI="2"
-inherit eutils multilib
-
-MY_P=${PN}.${PV}
-
-DESCRIPTION="A menu-driven tool to draw and manipulate objects interactively in an X window."
-HOMEPAGE="http://www.xfig.org"
-SRC_URI="mirror://sourceforge/mcj/${MY_P}.full.tar.gz"
-
-LICENSE="BSD"
-SLOT="0"
-KEYWORDS="alpha amd64 hppa ppc ppc64 sparc x86"
-IUSE=""
-
-RDEPEND="x11-libs/libXaw
- x11-libs/libXp
- x11-libs/Xaw3d
- x11-libs/libXi
- virtual/jpeg
- media-libs/libpng
- media-fonts/font-misc-misc
- media-fonts/urw-fonts
- >=media-gfx/transfig-3.2.5-r1
- media-libs/netpbm"
-DEPEND="${RDEPEND}
- x11-misc/imake
- x11-proto/xproto
- x11-proto/inputproto"
-
-S=${WORKDIR}/${MY_P}
-
-sed_Imakefile() {
- # see Imakefile for details
- vars2subs=( BINDIR=/usr/bin
- PNGINC=-I/usr/include
- JPEGLIBDIR="/usr/$(get_libdir)"
- JPEGINC=-I/usr/include
- XPMLIBDIR="/usr/$(get_libdir)"
- XPMINC=-I/usr/include/X11
- "USEINLINE = -DUSE_INLINE"
- XFIGLIBDIR=/usr/share/xfig
- XFIGDOCDIR="/usr/share/doc/${PF}"
- MANDIR="/usr/share/man/man\$\(MANSUFFIX\)"
- "CC=$(tc-getCC)" )
-
- for variable in "${vars2subs[@]}" ; do
- varname=${variable%%=*}
- varval=${variable##*=}
- sed -i "s:^\(XCOMM\)*[[:space:]]*${varname}[[:space:]]*=.*$:${varname} = ${varval}:" "$@"
- done
- sed -i "s:^\(XCOMM\)*[[:space:]]*\(#define I18N\).*$:\2:" "$@"
- if has_version '>=x11-libs/Xaw3d-1.5e'; then
- einfo "x11-libs/Xaw3d 1.5e and abover installed"
- sed -i "s:^\(XCOMM\)*[[:space:]]*\(#define XAW3D1_5E\).*$:\2:" "$@"
- fi
-}
-
-src_prepare() {
- # Permissions are really crazy here
- chmod -R go+rX .
- find . -type f -exec chmod a-x '{}' \;
- epatch "${FILESDIR}/${P}-figparserstack.patch" #297379
- epatch "${FILESDIR}/${P}-spelling.patch"
- epatch "${FILESDIR}/${P}-papersize_b1.patch"
- epatch "${FILESDIR}/${P}-pdfimport_mediabox.patch"
- epatch "${FILESDIR}/${P}-network_images.patch"
- epatch "${FILESDIR}/${P}-app-defaults.patch"
- epatch "${FILESDIR}/${P}-zoom-during-edit.patch"
- epatch "${FILESDIR}/${P}-urwfonts.patch"
- epatch "${FILESDIR}/${P}-mkstemp.patch" #264575
- sed_Imakefile Imakefile
- sed -e "s:/usr/lib/X11/xfig:/usr/share/doc/${PF}:" \
- -i Doc/xfig.man -i Doc/xfig_man.html || die
-}
-
-src_compile() {
- xmkmf || die
- emake CC="$(tc-getCC)" LOCAL_LDFLAGS="${LDFLAGS}" CDEBUGFLAGS="${CFLAGS}" \
- USRLIBDIR=/usr/$(get_libdir) || die
-}
-
-src_install() {
- emake -j1 DESTDIR="${D}" install.all || die
-
- insinto /usr/share/doc/${PF}
- doins README FIGAPPS CHANGES LATEX.AND.XFIG
-
- doicon xfig.png
- make_desktop_entry xfig Xfig xfig
-}