# Distributed under the terms of the GNU General Public License v2
# $Id$
-EAPI=5
-inherit autotools eutils
+EAPI=6
+
+inherit autotools
MY_P=DevIL-${PV}
LICENSE="LGPL-2.1"
SLOT="0"
KEYWORDS="amd64 ~arm ~mips ppc ppc64 x86"
-IUSE="allegro gif glut jpeg jpeg2k mng nvtt openexr opengl png sdl cpu_flags_x86_sse cpu_flags_x86_sse2 cpu_flags_x86_sse3 static-libs tiff xpm X"
+IUSE="allegro cpu_flags_x86_sse cpu_flags_x86_sse2 cpu_flags_x86_sse3 gif glut jpeg jpeg2k mng nvtt openexr opengl png sdl static-libs tiff X xpm"
-RDEPEND="allegro? ( media-libs/allegro:0 )
+RDEPEND="
+ allegro? ( media-libs/allegro:0 )
gif? ( media-libs/giflib:= )
glut? ( media-libs/freeglut )
jpeg? ( virtual/jpeg:0 )
png? ( media-libs/libpng:0= )
sdl? ( media-libs/libsdl )
tiff? ( media-libs/tiff:0 )
- xpm? ( x11-libs/libXpm )
X? ( x11-libs/libXext
x11-libs/libX11
- x11-libs/libXrender )"
+ x11-libs/libXrender )
+ xpm? ( x11-libs/libXpm )"
DEPEND="${RDEPEND}
virtual/pkgconfig
X? ( x11-proto/xextproto )"
+PATCHES=(
+ "${FILESDIR}/${P}"-CVE-2009-3994.patch
+ "${FILESDIR}/${P}"-libpng14.patch
+ "${FILESDIR}/${P}"-nvtt-glut.patch
+ "${FILESDIR}/${P}"-ILUT.patch
+ "${FILESDIR}/${P}"-restrict.patch
+ "${FILESDIR}/${P}"-fix-test.patch
+)
+
src_prepare() {
- epatch "${FILESDIR}"/${P}-{CVE-2009-3994,libpng14,nvtt-glut,ILUT,restrict,fix-test}.patch
+ default
eautoreconf
}
src_install() {
default
- use static-libs || prune_libtool_files
+
+ # package provides .pc files
+ find "${D}" -name '*.la' -delete || die
}
http://bugs.gentoo.org/297760
---- src-IL/src/il_dicom.c
-+++ src-IL/src/il_dicom.c
+--- a/src-IL/src/il_dicom.c
++++ b/src-IL/src/il_dicom.c
@@ -427,9 +427,11 @@ ILboolean GetUID(ILubyte *UID)
return IL_FALSE;
use_x11=no was not set when --disable-x11 was
---- m4/devil-api_checks.m4
-+++ m4/devil-api_checks.m4
+--- a/m4/devil-api_checks.m4
++++ b/m4/devil-api_checks.m4
@@ -137,7 +137,8 @@
[main],
[dnl The use_x11 var is either "yes" already, or we don't want "no" to be overwritten
remove automagic handling of glut and add configure option
fix "header present but cannot be compiled" warning for nvtt
---- m4/ax_check_glut.m4
-+++ m4/ax_check_glut.m4
+--- a/m4/ax_check_glut.m4
++++ b/m4/ax_check_glut.m4
@@ -114,4 +114,11 @@
AC_SUBST([GLUT_CFLAGS])
+ [enable_glut="yes"])
+
])dnl
---- m4/devil-api_checks.m4
-+++ m4/devil-api_checks.m4
+--- a/m4/devil-api_checks.m4
++++ b/m4/devil-api_checks.m4
@@ -31,8 +31,8 @@
AS_IF([test "x$no_gl" != "xyes" -a "x$no_glu" != "xyes"],
[use_ogl="yes"
ILUT_LIBS="$GLUT_LIBS $ILUT_LIBS"])
AC_DEFINE([ILUT_USE_OPENGL],
[1],
---- configure.ac
-+++ configure.ac
+--- a/configure.ac
++++ b/configure.ac
@@ -343,8 +343,10 @@
[Do you want to use the Nvidia texture tools if possible? (enables GPU accelerated image manipulation, default="yes")]) ],
[],
[EXAMPLES_TO_BUILD="$EXAMPLES_TO_BUILD ILUT_gl ILUT_volume"])
dnl Win32
---- bin/Makefile.am
-+++ bin/Makefile.am
+--- a/bin/Makefile.am
++++ b/bin/Makefile.am
@@ -45,11 +45,11 @@
examples_PROGRAMS += ILUT_animation
endif #USE_W32