diff options
-rw-r--r-- | media-gfx/xli/ChangeLog | 15 | ||||
-rw-r--r-- | media-gfx/xli/Manifest | 4 | ||||
-rw-r--r-- | media-gfx/xli/files/xli-1.17.0-fix-scale-zoom.patch | 61 | ||||
-rw-r--r-- | media-gfx/xli/xli-1.17.0-r4.ebuild | 74 |
4 files changed, 151 insertions, 3 deletions
diff --git a/media-gfx/xli/ChangeLog b/media-gfx/xli/ChangeLog index 68ba7d502398..ec4edbb154fa 100644 --- a/media-gfx/xli/ChangeLog +++ b/media-gfx/xli/ChangeLog @@ -1,6 +1,17 @@ # ChangeLog for media-gfx/xli -# Copyright 2002-2008 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/media-gfx/xli/ChangeLog,v 1.42 2008/04/21 17:34:38 phreak Exp $ +# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/media-gfx/xli/ChangeLog,v 1.43 2009/09/05 22:11:45 robbat2 Exp $ + + 05 Sep 2009; Robin H. Johnson <robbat2@gentoo.org> +xli-1.17.0-r4.ebuild, + +files/xli-1.17.0-fix-scale-zoom.patch: + Fix bug 282979: Broken -zoom in jpeg-7, so that we can stop restricting + the jpeg-6 version. + +*xli-1.17.0-r4 (05 Sep 2009) + + 05 Sep 2009; Robin H. Johnson <robbat2@gentoo.org> +xli-1.17.0-r4.ebuild: + Xli works fine with media-libs/jpeg-7, revbump to remove it from being a + blocker on anybodies systems for the upgrade. 21 Apr 2008; Christian Heim <phreak@gentoo.org> metadata.xml: Fix up metadata.xml. If there's no maintainer for the package, the metadata diff --git a/media-gfx/xli/Manifest b/media-gfx/xli/Manifest index 5f6e74f13397..b7d91cef75a7 100644 --- a/media-gfx/xli/Manifest +++ b/media-gfx/xli/Manifest @@ -1,7 +1,9 @@ AUX Xli.ad 123 RMD160 c4770e6a5d941e42956eb934bf3774efcb546cc8 SHA1 312c18bbd45bdec7ec1d95f95aaa1120fe6d2599 SHA256 a26e3c36c81d124a08d143e9ebfabfbd2507ffb9e48f077ea3e837eacd3f3bd9 +AUX xli-1.17.0-fix-scale-zoom.patch 1942 RMD160 59551f074cdc96eda6fc2d44e56e5cdbe62f494e SHA1 bb02a78213bc9c8996dd0906c850b35c3dad499e SHA256 109af5c20d234650b99411fcd94c329cb7162e60e0349e46ee4fc5148bb1a67f AUX xli-security-gentoo.diff 6940 RMD160 fbc25a1d43cba52ba1fe5444d2b74891a0927271 SHA1 d87139cb2f84574ec7722a2513b7ef9a7a530447 SHA256 d2d427f4eb0659786e18fb70aebb312e980e638a0034a24073e21c2e7b58e90a DIST xli-2005-02-27.tar.gz 201011 RMD160 fc83fa5173befa73a0eeb56ad323dad148ef1426 SHA1 977d8ece0edd41f3ec606310496cf3231f046d88 SHA256 442dcf5ac75841e648c3bffed795d9301a6a485dc55f7998d0acfc2b8daad2bc EBUILD xli-1.17.0-r2.ebuild 2210 RMD160 5a2bed7541969784c37bb5a548aa4f766ba8f9df SHA1 7df7383992bba4789562f3b874cdc6868523a394 SHA256 a9178007776245856c16379bba233acf75988003dbe8a886b0d0a23beb427359 EBUILD xli-1.17.0-r3.ebuild 1800 RMD160 094b87a9e62510e71cd5c45eb0230bd61561208f SHA1 334a02516258542460b35e8f918404489f429049 SHA256 239a1d908397d8bc88e1344892d2cfaebc6f5e9664794c2a13f9f1e6fe2b07b6 -MISC ChangeLog 4693 RMD160 989e4ece3bb13f4912668008329e3718333114ab SHA1 45f6a799709f6c14a04929c022158f31b8cfc146 SHA256 5af5016b79e0aef1d8e6d2d7f1a8b33ec2464a1a87f47770bd55e06dd8cdb4e8 +EBUILD xli-1.17.0-r4.ebuild 1875 RMD160 f6ad7226c1fbb2c7d4dafe2f148d47c28c4b46d5 SHA1 4ccec4ba3a5cb75422bfd82bee573f72fd518e98 SHA256 7815db502cc7f241d91e536592d543c1aca1859a607b6caa5f659b90dd111742 +MISC ChangeLog 5139 RMD160 b5ff3b98e16bd38c831bdec5c52d8cb7d3c12c52 SHA1 48781e511cf40fb81c479e366f19356612e33aad SHA256 b655145b96e4c71666621d5447c8f0aac9ad9278296c985f90272d2b70a21a51 MISC metadata.xml 163 RMD160 9cdda004bed83a887f4a756cb1550fab6ce563ce SHA1 bfc4f31690e338a159152dcd46d56ff7fd6b6e1b SHA256 212655100c50c4193072996553f15984b9788fb20fb4175efd2418b80d428564 diff --git a/media-gfx/xli/files/xli-1.17.0-fix-scale-zoom.patch b/media-gfx/xli/files/xli-1.17.0-fix-scale-zoom.patch new file mode 100644 index 000000000000..44ee262aee25 --- /dev/null +++ b/media-gfx/xli/files/xli-1.17.0-fix-scale-zoom.patch @@ -0,0 +1,61 @@ +As of jpeg-7, the scale coefficents may be set to non-unitary values by the +initial DCT transform. This caused the original already-scale detection +algorithm in xli to break. + +To avoid this, set the already-scaled marker when we adjust the scale fraction +(that gets passed into the DCT). + +Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> + +diff -Nuar -X x xli-2005-02-27.orig/jpeg.c xli-2005-02-27/jpeg.c +--- xli-2005-02-27.orig/jpeg.c 2005-02-27 16:42:39.000000000 -0800 ++++ xli-2005-02-27/jpeg.c 2009-09-05 15:02:12.462635389 -0700 +@@ -211,7 +211,7 @@ + xli_jpg_err jerr; + Image *image = 0; + byte **rows = 0; +- int i, rowbytes; ++ int i, rowbytes, flags; + + CURRFUNC("jpegLoad"); + zfp = zopen(fullname); +@@ -248,9 +248,13 @@ + if (verbose) + describe_jpeg(&cinfo, fullname); + ++ flags = 0; + if (image_ops->iscale > 0 && image_ops->iscale < 4) { +- cinfo.scale_num = 1; +- cinfo.scale_denom = 1 << image_ops->iscale; ++ flags |= FLAG_ISCALE; ++ //cinfo.scale_num = 1; ++ cinfo.scale_denom *= 1 << image_ops->iscale; ++ if (verbose) ++ printf("scaling to %d/%d\n", cinfo.scale_num, cinfo.scale_denom); + } else if (image_ops->iscale_auto) { + image_ops->iscale = 0; + while (image_ops->iscale < 3 && (cinfo.image_width >> +@@ -258,9 +262,11 @@ + cinfo.image_height >> image_ops->iscale > + globals.dinfo.height * .9)) + image_ops->iscale += 1; +- cinfo.scale_denom = 1 << image_ops->iscale; ++ cinfo.scale_denom *= 1 << image_ops->iscale; ++ if(image_ops->iscale > 0) ++ flags |= FLAG_ISCALE; + if (verbose) +- printf("auto-scaling to 1/%d\n", cinfo.scale_denom); ++ printf("auto-scaling to %d/%d\n", cinfo.scale_num, cinfo.scale_denom); + } + znocache(zfp); + +@@ -288,8 +294,7 @@ + } + + image->gamma = RETURN_GAMMA; +- if (cinfo.scale_denom > 1) +- image->flags |= FLAG_ISCALE; ++ image->flags |= flags; + + rowbytes = cinfo.output_width * cinfo.output_components; + assert(image->pixlen * image->width == rowbytes); diff --git a/media-gfx/xli/xli-1.17.0-r4.ebuild b/media-gfx/xli/xli-1.17.0-r4.ebuild new file mode 100644 index 000000000000..0083186abb81 --- /dev/null +++ b/media-gfx/xli/xli-1.17.0-r4.ebuild @@ -0,0 +1,74 @@ +# Copyright 1999-2009 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/media-gfx/xli/xli-1.17.0-r4.ebuild,v 1.1 2009/09/05 22:11:45 robbat2 Exp $ + +inherit eutils + +SNAPSHOT="2005-02-27" +DESCRIPTION="X Load Image: view images or load them to root window" +HOMEPAGE="http://pantransit.reptiles.org/prog/" +SRC_URI="http://pantransit.reptiles.org/prog/xli/xli-${SNAPSHOT}.tar.gz" + +LICENSE="X11" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86" +IUSE="" + +RDEPEND="x11-libs/libXext + >=sys-libs/zlib-1.1.4 + >=media-libs/libpng-1.0.5 + >=media-libs/jpeg-6b + app-arch/bzip2" +DEPEND="${RDEPEND} + x11-proto/xextproto + x11-misc/imake + app-text/rman + !media-gfx/xloadimage + !<media-gfx/xli-1.17.0-r3" + +S=${WORKDIR}/${PN}-${SNAPSHOT} + +src_unpack() { + unpack ${A} + cd "${S}" + + sed -i Imakefile \ + -e '/^DEFINES =/s/$/ -DHAVE_GUNZIP -DHAVE_BUNZIP2 /' \ + -e '/CCOPTIONS =/s/=.*/=/' + + # This is a hack to avoid a parse error on /usr/include/string.h + # when _BSD_SOURCE is defined. This may be a bug in that header. + sed -i png.c \ + -e '/^#include "xli.h"/i#undef _BSD_SOURCE' + + # This hack will allow xli to compile using gcc-3.3 + sed -i rlelib.c \ + -e 's/#include <varargs.h>//' + + # fix potential security issues. + EPATCH_OPTS="-F3 -l" epatch "${FILESDIR}"/xli-security-gentoo.diff + + # Fix scale per bug 282979 + epatch "${FILESDIR}"/${P}-fix-scale-zoom.patch +} + +src_compile() { + xmkmf || die + emake CDEBUGFLAGS="${CFLAGS}" || die +} + +src_install() { + dobin xli xlito || die + + dosym xli /usr/bin/xsetbg || die + dosym xli /usr/bin/xview || die + + dodoc README README.xloadimage ABOUTGAMMA TODO chkgamma.jpg + newman xli.man xli.1 + newman xliguide.man xliguide.1 + newman xlito.man xlito.1 + + insinto /etc/X11/app-defaults + newins "${FILESDIR}"/Xli.ad Xli + fperms a+r /etc/X11/app-defaults/Xli +} |