summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Alfredsen <loki_val@gentoo.org>2009-05-17 13:26:46 +0000
committerPeter Alfredsen <loki_val@gentoo.org>2009-05-17 13:26:46 +0000
commitbaceb867b650d24bd8814ae94bb44cbae253d7a5 (patch)
treeb6a50538ec57d00ac69f8bf8aafa1443451599e0
parentUpdate dependency on libusb. (diff)
downloadgentoo-2-baceb867b650d24bd8814ae94bb44cbae253d7a5.tar.gz
gentoo-2-baceb867b650d24bd8814ae94bb44cbae253d7a5.tar.bz2
gentoo-2-baceb867b650d24bd8814ae94bb44cbae253d7a5.zip
Fix tests with gcc-4.4. Tests need all use-flags enabled to succeed. Use EAPI=2.
(Portage version: 2.2_rc28/cvs/Linux x86_64)
-rw-r--r--media-libs/vigra/ChangeLog9
-rw-r--r--media-libs/vigra/files/vigra-1.6.0-gcc44.patch15
-rw-r--r--media-libs/vigra/vigra-1.6.0.ebuild47
3 files changed, 61 insertions, 10 deletions
diff --git a/media-libs/vigra/ChangeLog b/media-libs/vigra/ChangeLog
index ba1152342aee..91dd0224123b 100644
--- a/media-libs/vigra/ChangeLog
+++ b/media-libs/vigra/ChangeLog
@@ -1,6 +1,11 @@
# ChangeLog for media-libs/vigra
-# Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/media-libs/vigra/ChangeLog,v 1.18 2008/09/28 20:10:05 vapier Exp $
+# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/media-libs/vigra/ChangeLog,v 1.19 2009/05/17 13:26:46 loki_val Exp $
+
+ 17 May 2009; Peter Alfredsen <loki_val@gentoo.org> vigra-1.6.0.ebuild,
+ +files/vigra-1.6.0-gcc44.patch:
+ Fix tests with gcc-4.4. Tests need all use-flags enabled to succeed. Use
+ EAPI=2.
28 Sep 2008; Mike Frysinger <vapier@gentoo.org> vigra-1.6.0.ebuild:
Add ~ppc64 love.
diff --git a/media-libs/vigra/files/vigra-1.6.0-gcc44.patch b/media-libs/vigra/files/vigra-1.6.0-gcc44.patch
new file mode 100644
index 000000000000..72c7fee3fd97
--- /dev/null
+++ b/media-libs/vigra/files/vigra-1.6.0-gcc44.patch
@@ -0,0 +1,15 @@
+diff -NrU5 vigra1.6.0.orig/test/convolution/test.cxx vigra1.6.0/test/convolution/test.cxx
+--- vigra1.6.0.orig/test/convolution/test.cxx 2009-05-17 14:30:10.674673754 +0200
++++ vigra1.6.0/test/convolution/test.cxx 2009-05-17 14:31:45.388542661 +0200
+@@ -35,10 +35,11 @@
+ /* */
+ /************************************************************************/
+
+ #include <iostream>
+ #include <cmath>
++#include <cstdio>
+ #include "vigra/convolution.hxx"
+ #include "unittest.hxx"
+ #include "vigra/stdimage.hxx"
+ #include "vigra/impex.hxx"
+ #include "vigra/combineimages.hxx"
diff --git a/media-libs/vigra/vigra-1.6.0.ebuild b/media-libs/vigra/vigra-1.6.0.ebuild
index c0b124711961..dc29ebc849ce 100644
--- a/media-libs/vigra/vigra-1.6.0.ebuild
+++ b/media-libs/vigra/vigra-1.6.0.ebuild
@@ -1,8 +1,10 @@
-# Copyright 1999-2008 Gentoo Foundation
+# Copyright 1999-2009 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/media-libs/vigra/vigra-1.6.0.ebuild,v 1.2 2008/09/28 20:10:05 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-libs/vigra/vigra-1.6.0.ebuild,v 1.3 2009/05/17 13:26:46 loki_val Exp $
-inherit multilib
+EAPI=2
+
+inherit eutils multilib
DESCRIPTION="C++ computer vision library with emphasize on customizable algorithms and data structures"
HOMEPAGE="http://kogs-www.informatik.uni-hamburg.de/~koethe/vigra/"
@@ -11,7 +13,7 @@ SRC_URI="http://kogs-www.informatik.uni-hamburg.de/~koethe/vigra/${P/-}.tar.gz"
LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64 ~ppc ~ppc64 ~sparc ~x86"
-IUSE="doc fftw jpeg png tiff zlib"
+IUSE="doc fftw jpeg png tiff zlib test"
RDEPEND="png? ( media-libs/libpng )
tiff? ( media-libs/tiff )
@@ -24,17 +26,46 @@ S="${WORKDIR}/${P/-}"
MY_DOCDIR="usr/share/doc/${PF}"
-src_compile() {
+pkg_setup() {
+ local flag
+ export usefail=""
+ if use test
+ then
+ for flag in png tiff jpeg fftw
+ do
+ use $flag || usefail="$usefail $flag"
+ done
+
+ if [[ -n "$usefail" ]]
+ then
+ elog "USE=test enabled but the following use-flags are disabled:"
+ elog "${usefail# }"
+ elog "Tests will be skipped, please enable the other use-flags."
+ fi
+ fi
+}
+
+src_prepare() {
+ epatch "${FILESDIR}/${P}-gcc44.patch"
+}
+
+src_configure() {
./configure \
- --prefix="/usr/" \
--docdir="${D}/${MY_DOCDIR}" \
+ --prefix=/usr \
$(use_with png) \
$(use_with tiff) \
$(use_with jpeg) \
$(use_with zlib) \
$(use_with fftw) \
- || die "configure failed"
- emake || die "emake failed"
+ || die "configure failed"
+}
+
+src_test() {
+ if [[ -z "${usefail}" ]]
+ then
+ default
+ fi
}
src_install() {