summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2013-01-06 19:16:58 +0000
committerMike Frysinger <vapier@gentoo.org>2013-01-06 19:16:58 +0000
commit24e28b69eb9cf5f57ab884970da245ebf614d096 (patch)
tree2ab268e2a916b46318326661a6191c7cd7bf7aa8 /media-libs/netpbm
parentChange 1.9.3 depends to make it build, bug #450226. Thanks to slepnoga. (diff)
downloadgentoo-2-24e28b69eb9cf5f57ab884970da245ebf614d096.tar.gz
gentoo-2-24e28b69eb9cf5f57ab884970da245ebf614d096.tar.bz2
gentoo-2-24e28b69eb9cf5f57ab884970da245ebf614d096.zip
Set up environment for src_test to run properly #450530 by Michael Palimaka.
(Portage version: 2.2.0_alpha144/cvs/Linux x86_64, signed Manifest commit with key FB7C4156)
Diffstat (limited to 'media-libs/netpbm')
-rw-r--r--media-libs/netpbm/ChangeLog5
-rw-r--r--media-libs/netpbm/netpbm-10.61.00.ebuild27
2 files changed, 30 insertions, 2 deletions
diff --git a/media-libs/netpbm/ChangeLog b/media-libs/netpbm/ChangeLog
index b544140def50..1bed17d1a41b 100644
--- a/media-libs/netpbm/ChangeLog
+++ b/media-libs/netpbm/ChangeLog
@@ -1,6 +1,9 @@
# ChangeLog for media-libs/netpbm
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/media-libs/netpbm/ChangeLog,v 1.266 2013/01/06 02:00:17 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-libs/netpbm/ChangeLog,v 1.267 2013/01/06 19:16:58 vapier Exp $
+
+ 06 Jan 2013; Mike Frysinger <vapier@gentoo.org> netpbm-10.61.00.ebuild:
+ Set up environment for src_test to run properly #450530 by Michael Palimaka.
*netpbm-10.61.00 (06 Jan 2013)
diff --git a/media-libs/netpbm/netpbm-10.61.00.ebuild b/media-libs/netpbm/netpbm-10.61.00.ebuild
index 1ef0d6e9d903..3eac8e0b7f9e 100644
--- a/media-libs/netpbm/netpbm-10.61.00.ebuild
+++ b/media-libs/netpbm/netpbm-10.61.00.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/media-libs/netpbm/netpbm-10.61.00.ebuild,v 1.1 2013/01/06 02:00:17 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-libs/netpbm/netpbm-10.61.00.ebuild,v 1.2 2013/01/06 19:16:58 vapier Exp $
EAPI="4"
@@ -60,6 +60,21 @@ src_prepare() {
sed -i '/SUPPORT_SUBDIRS/s:urt::' GNUmakefile || die
rm -rf urt
+ # disable certain tests based on active USE flags
+ local del=(
+ $(usex rle '' utahrle-roundtrip)
+ )
+ if [[ ${#del[@]} -gt 0 ]] ; then
+ sed -i -r $(printf -- ' -e /%s.test/d' "${del[@]}") test/Test-Order || die
+ fi
+ del=(
+ pnmtofiasco # We always disable fiasco
+ $(usex rle '' 'pnmtorle rletopnm')
+ )
+ if [[ ${#del[@]} -gt 0 ]] ; then
+ sed -i -r $(printf -- ' -e s/\<%s\>(:.ok)?//' "${del[@]}") test/all-in-place.{ok,test} || die
+ fi
+
# take care of the importinc stuff ourselves by only doing it once
# at the top level and having all subdirs use that one set #149843
sed -i \
@@ -80,6 +95,10 @@ src_configure() {
BUILD_FIASCO = N
SYMLINK = ln -sf
+ # These vars let src_test work by default
+ PKGDIR_DEFAULT = ${T}/netpbm
+ RESULTDIR_DEFAULT = ${T}/netpbm-test
+
# Toolchain options
CC = $(tc-getCC) -Wall
LD = \$(CC)
@@ -127,6 +146,12 @@ src_compile() {
emake
}
+src_test() {
+ # The code wants to install everything first and then test the result.
+ emake install.bin
+ emake check
+}
+
src_install() {
# Subdir make targets like to use `mkdir` all over the place
# without any actual dependencies, thus the -j1.