diff options
-rw-r--r-- | sci-libs/vtk/ChangeLog | 226 | ||||
-rw-r--r-- | sci-libs/vtk/Manifest | 8 | ||||
-rw-r--r-- | sci-libs/vtk/files/vtk-5.0.3-mpi.patch | 74 | ||||
-rw-r--r-- | sci-libs/vtk/files/vtk-5.0.4-gcc4.3.patch | 33 | ||||
-rw-r--r-- | sci-libs/vtk/files/vtk-5.2.0-tcl-install.patch | 12 | ||||
-rw-r--r-- | sci-libs/vtk/metadata.xml | 15 | ||||
-rw-r--r-- | sci-libs/vtk/vtk-5.4.0.ebuild | 276 |
7 files changed, 644 insertions, 0 deletions
diff --git a/sci-libs/vtk/ChangeLog b/sci-libs/vtk/ChangeLog new file mode 100644 index 0000000..df63203 --- /dev/null +++ b/sci-libs/vtk/ChangeLog @@ -0,0 +1,226 @@ +# ChangeLog for sci-libs/vtk +# Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/sci-libs/vtk/ChangeLog,v 1.52 2008/10/27 14:00:55 markusle Exp $ + + 27 Oct 2008; Markus Dittrich <markusle@gentoo.org> vtk-5.2.0-r1.ebuild: + Attempt to fix sandbox violations (see bug #244378). + +*vtk-5.2.0-r1 (05 Oct 2008) + + 05 Oct 2008; Markus Dittrich <markusle@gentoo.org> + +files/vtk-5.2.0-tcl-install.patch, -vtk-5.2.0.ebuild, + +vtk-5.2.0-r1.ebuild: + Fixed improper install location of support files (see bug #239553). + +*vtk-5.2.0 (01 Oct 2008) + + 01 Oct 2008; Markus Dittrich <markusle@gentoo.org> +vtk-5.2.0.ebuild: + Version bump (fixes bug #238883). Thanks much to Steve Yin + <steve@chinavfx.net> for his ebuild. + + 07 Aug 2008; Ulrich Mueller <ulm@gentoo.org> metadata.xml: + Add USE flag description to metadata wrt GLEP 56. + + 28 Jul 2008; Carsten Lohrke <carlo@gentoo.org> vtk-5.0.3.ebuild: + QA: Get rid of deprecated qt?_min_version(). + + 27 Jul 2008; Carsten Lohrke <carlo@gentoo.org> vtk-5.0.4.ebuild: + Fix broken split Qt 4.4 dependencies, cf. bug 217161 comment 11. + + 08 Jul 2008; Thomas Anderson <gentoofan23@gentoo.org> vtk-5.0.4.ebuild: + Add a qt-gui dependency, it really is needed. + + 03 Jul 2008; Thomas Anderson <gentoofan23@gentoo.org> vtk-5.0.4.ebuild: + Migrate Dependencies to permit Split QT 4.4 to satisfy dependencies, bug + #217189 + + 24 May 2008; Markus Dittrich <markusle@gentoo.org> + +files/vtk-5.0.4-gcc4.3.patch, vtk-5.0.4.ebuild: + Added gcc-4.3 compatibility patch (see bug #223383). Thanks much to + Bert Karwatzki <spasswolf@web.de> for his patch. + + 09 Mar 2008; Markus Dittrich <markusle@gentoo.org> vtk-5.0.4.ebuild: + Backported support for tcl/tk-8.5 from cvs head (fixes bug 212700). + Thanks much to Pacho Ramos <pacho@condmat1.ciencias.uniovi.es> for + his patch. + +*vtk-5.0.4 (06 Mar 2008) + + 06 Mar 2008; Markus Dittrich <markusle@gentoo.org> +vtk-5.0.4.ebuild: + Version bump. + + 29 Feb 2008; Markus Dittrich <markusle@gentoo.org> vtk-5.0.3.ebuild: + Fixed bogus install location (see bug #211819). Thanks much to + Matthias Langer <mlangc@gmx.at> for his patch. + + 21 Feb 2008; Markus Dittrich <markusle@gentoo.org> + -files/vtk-5.0.1-python2.5-gentoo.patch, -files/vtk-5.0.3-lammpi.patch, + +files/vtk-5.0.3-mpi.patch, vtk-5.0.3.ebuild: + Removed support for mpich and added support for mpich2, openmpi, and + lam-mpi. Also fixed some QA issues and added qt4 eclass. + + 19 Aug 2007; Markus Dittrich <markusle@gentoo.org> vtk-5.0.3.ebuild: + Fixed incomplete RDEPEND. + + 01 Aug 2007; Markus Dittrich <markusle@gentoo.org> vtk-5.0.3.ebuild: + Added LGPL-2 to LICENSE since it is needed for gl2ps (see bug 146019). + + 22 Jul 2007; Donnie Berkholz <dberkholz@gentoo.org>; vtk-5.0.3.ebuild: + Drop virtual/x11 references. + + 11 Jun 2007; Petteri Räty <betelgeuse@gentoo.org> -vtk-5.0.2.ebuild: + Remove old version. + + 11 Jun 2007; Petteri Räty <betelgeuse@gentoo.org> vtk-5.0.3.ebuild: + Add java? ( >=virtual/jre-1.5 ) to RDEPEND. + + 28 May 2007; Markus Dittrich <markusle@gentoo.org> vtk-5.0.3.ebuild: + Added VTKHOME as exported environmental variable. + + 08 May 2007; Markus Dittrich <markusle@gentoo.org> vtk-5.0.3.ebuild: + Re-added compile flag for javac needed on amd64 (see bug #177506). + + 06 May 2007; Markus Dittrich <markusle@gentoo.org> + +files/vtk-5.0.3-lammpi.patch, vtk-5.0.3.ebuild: + Added patch fixing cmake files to properly detect and add lam-mpi + libraries. + + 04 May 2007; Markus Dittrich <markusle@gentoo.org> vtk-5.0.3.ebuild: + Check for qt3support useflag when building the examples under qt4 + (see bug #176847). + + 01 May 2007; Markus Dittrich <markusle@gentoo.org> metadata.xml, + vtk-5.0.3.ebuild: + Removed explicit java CLASSPATH and added the friendly java folks + to metadata (see bug #176547). + +*vtk-5.0.3 (23 Apr 2007) + + 23 Apr 2007; Markus Dittrich <markusle@gentoo.org> + -files/vtk-qt-gentoo.patch, -vtk-5.0.0.ebuild, -vtk-5.0.1.ebuild, + +vtk-5.0.3.ebuild: + Version bump and removed old versions. Thanks much to Sebastien + Fabbro <bicatali@gentoo.org> for his ebuild. + + 16 Apr 2007; Christian Faulhammer <opfer@gentoo.org> vtk-5.0.0.ebuild: + moved from USE tcltk to tk, see bug 17808 + +*vtk-5.0.2 (02 Dec 2006) + + 02 Dec 2006; Markus Dittrich <markusle@gentoo.org> +vtk-5.0.2.ebuild: + Version bump. + + 18 Nov 2006; Markus Dittrich <markusle@gentoo.org> vtk-5.0.1.ebuild: + Added -j1 back to ebuild since some people still experience problems + with parallel builds (see discussion on bug #146767). + + 14 Oct 2006; Joshua Nichols <nichoj@gentoo.org> vtk-5.0.0.ebuild: + Added call to java-pkg_pkg_setup, for bug #142708 + + 23 Sep 2006; Markus Dittrich <markusle@gentoo.org> + +files/vtk-5.0.1-python2.5-gentoo.patch, vtk-5.0.1.ebuild: + Added patch to fix compile problems with python-2.5 + (see bug #148727). + + 08 Sep 2006; Markus Dittrich <markusle@gentoo.org> + +files/vtk-qt-gentoo.patch, -files/vtk-qt3-qt4-gentoo.patch, + vtk-5.0.0.ebuild, vtk-5.0.1.ebuild: + Renamed the qt patch in an effort to get rid of the executable + permissions. Also cleaned up the ebuilds some. + + 08 Sep 2006; Markus Dittrich <markusle@gentoo.org> + files/vtk-qt3-qt4-gentoo.patch, -files/vtk-4.2.6-gcc34.patch, + -vtk-4.2.6.ebuild: + Removed old version since it doesn't build any more. Also fixed + permissions for the vtk-qt patch (see bug #146826). + + 20 Jul 2006; Markus Dittrich <markusle@gentoo.org> vtk-5.0.1.ebuild: + Moved to new java system. Removed -j1 from emake since it works + fine here with -j2. + +*vtk-5.0.1 (09 Jul 2006) + + 09 Jul 2006; Markus Dittrich <markusle@gentoo.org> vtk-4.2.6.ebuild, + vtk-5.0.0.ebuild, +vtk-5.0.1.ebuild: + Version bump. Also, split tcltk USE flag into tcl and tk and moved + to new style virtual/jdk. + + 23 Jun 2006; Markus Dittrich <markusle@gentoo.org> vtk-5.0.0.ebuild: + Added a warning to the ebuild that qt4 is the default in case both + qt3 and qt4 are selected as use flags (see bug #137658). + + 11 Jun 2006; Markus Dittrich <markusle@gentoo.org> vtk-5.0.0.ebuild: + Fix RDEPEND and cmake configuration such that tcl/tk is only + pulled in and used if USE=tcltk. This closes bug #136324. + + 27 Apr 2006; Alec Warner <antarus@gentoo.org> Manifest: + Fixing SHA256 digest, pass four + + 21 Apr 2006; Markus Dittrich <markusle@gentoo.org> vtk-5.0.0.ebuild: + Depend on cmake-2.2.x to be able to properly compile against QT4. + This fixes bug #130471. + + 07 Apr 2006; Markus Dittrich <markusle@gentoo.org> ChangeLog: + Removed from package.mask after testing. + + 27 Mar 2006; Markus Dittrich <markusle@gentoo.org> vtk-5.0.0.ebuild: + Added proper JAVA_AWT_LIBRARY cmake variable for amd64 platform. + Thanks to Sebastiaan <s.breedveld@erasmusmc.nl> for pointing this + out (c.f. bug #123178). + + 26 Mar 2006; Markus Dittrich <markusle@gentoo.org> + +files/vtk-qt3-qt4-gentoo.patch, vtk-5.0.0.ebuild: + Added a small fix for java compilation on amd64 as detailed + in bug #123178. Thanks to Sebastiaan <s.breedveld@erasmusmc.nl> for + the fix. Also enabled compilation of vtk against either QT3 or QT4. + + 06 Mar 2006; Markus Dittrich <markusle@gentoo.org> vtk-5.0.0.ebuild: + Fixed some QT3 issues and forced -j1 during emake. Thanks + much to Sebastiaan <s.breedveld@erasmusmc.nl> for his fixes + and testing. + +*vtk-5.0.0 (05 Mar 2006) + + 05 Mar 2006; Markus Dittrich <markusle@gentoo.org> +vtk-5.0.0.ebuild: + Version bump. Many thanks to Toon Verstraelen + <Toon.Verstraelen@UGent.be> and Sebastiaan + <s.breedveld@erasmusmc.nl> for their ebuilds and patches. + This fixes bug #123178. + + 26 Feb 2006; Markus Dittrich <markusle@gentoo.org> vtk-4.2.6.ebuild: + Added cmake command line flag to prevent insecure RUNPATHS + (c.f. bug #122875). + + 22 Jan 2006; Markus Dittrich <markusle@gentoo.org> vtk-4.2.6.ebuild: + Fix dependencies for modular X and replace instances of lib with + $(get_libdir). + + 17 Jan 2006; Markus Dittrich <markusle@gentoo.org> metadata.xml: + Changed maintainer to Markus Dittrich <markusle@gentoo.org>. + + 19 Dec 2005; Markus Dittrich <markusle@gentoo.org> vtk-4.2.6.ebuild: + Use python eclass functions to determine installed python version. + + 18 Dec 2005; Markus Dittrich <markusle@gentoo.org> vtk-4.2.6.ebuild: + Fixed compilation problems when using cmake-2.2.x and when compiling against + python 2.4.x. Also corrected installation path of vtk jar file. This fixes + bugs #112119, #103343, #113597. + + 08 Oct 2005; Thomas Matthijs <axxo@gentoo.org> vtk-4.2.6.ebuild: + use java-pkg_dojar not dojar + + 24 Aug 2005; Patrick Kursawe <phosphan@gentoo.org> vtk-4.2.6.ebuild: + No longer using cp -a (bug #103487) + + 20 Aug 2005; Olivier Fisette <ribosome@gentoo.org> vtk-4.2.6.ebuild: + Removed unused "data" USE flag (fixes bug #100418). + + 03 Jun 2005; Patrick Dawson <pkdawson@gentoo.org> vtk-4.2.6.ebuild: + Typo fix. + +*vtk-4.2.6 (10 May 2005) + + 10 May 2005; Patrick Dawson <pkdawson@gentoo.org> + +files/vtk-4.2.6-gcc34.patch, +vtk-4.2.6.ebuild: + Initial import. See bug #25335. + diff --git a/sci-libs/vtk/Manifest b/sci-libs/vtk/Manifest new file mode 100644 index 0000000..980af8e --- /dev/null +++ b/sci-libs/vtk/Manifest @@ -0,0 +1,8 @@ +AUX vtk-5.0.3-mpi.patch 2653 RMD160 16c80c11c88cd4a671968da9ef3a29c67a979648 SHA1 c1979686901883aa05091845c05235ce8e24e89f SHA256 dd03a1e55674e6f0c3740b996e6a81a68a6e253c5dac60cf0f2fd2e3ead1dcf3 +AUX vtk-5.0.4-gcc4.3.patch 1222 RMD160 28a724ce4e999e68482bfcadc3e776ef37a1e6a6 SHA1 5db37dabd42dca1d93e483e2fd3356fb5a2c653e SHA256 66627b05fd0f71a51b1f5645edaaa369d11896245598acdb3a30818ec716806f +AUX vtk-5.2.0-tcl-install.patch 580 RMD160 e3654b90212a4f48f707cd4cfaf6069b9cbc4d49 SHA1 94269da0a6d83312d0fc00c3f7adf964531a7d20 SHA256 7373a02d9408f59546486b50efb8934fc2fa14067928e27bd46b2691b80d2fc6 +DIST vtk-5.4.0.tar.gz 18264488 RMD160 e2140fc35ed974f5fde6b418089554904e197c21 SHA1 a227caf932315d944cf72008d75df90dd4c554e7 SHA256 8fd2b8950ada87103fb767c14fc78b09507c2d82ec6a8b2e3d8ce611649f4a61 +DIST vtkdata-5.4.0.tar.gz 52810010 RMD160 160129a0580bd7b70b40d3f7fa61bbd78b586ad8 SHA1 a710227e7f7f25f481a36d2fa14bda49756bd39d SHA256 4097028589bf14742ac7468cf2a1fe731d10b28e46407890fb497cc6d236d84f +EBUILD vtk-5.4.0.ebuild 9951 RMD160 849cdef2dbcf7e7ea73021369f0d7b9aa9a920c4 SHA1 aaab147634a4427215fa78b972c20826db51e9ee SHA256 cb6222e12e8ea884203d174f9d0732f8833aabdb512c9da14a51548ace6bf426 +MISC ChangeLog 9009 RMD160 ac6570dc6590eee771ce024eef0034cbe41c4eaa SHA1 208caf18dd386b1465bdbdfdc5fb364c847e77b9 SHA256 386426f1d136280b34a788f0af071764bc794f93458086d1e3cf1edaa25976ac +MISC metadata.xml 432 RMD160 2b5009d16ed172daa9ae089e59ceadabeaab5884 SHA1 4163aa67aa3d1d46b8efc21d2af85a2105f6a77c SHA256 8dadae25a4cdeedb63f94cbaf7fc6a8ce7a1950feae7047e859839d2eee30747 diff --git a/sci-libs/vtk/files/vtk-5.0.3-mpi.patch b/sci-libs/vtk/files/vtk-5.0.3-mpi.patch new file mode 100644 index 0000000..fec1d67 --- /dev/null +++ b/sci-libs/vtk/files/vtk-5.0.3-mpi.patch @@ -0,0 +1,74 @@ +diff -Naur VTK/Parallel/CMakeLists.txt VTK.new/Parallel/CMakeLists.txt +--- VTK/Parallel/CMakeLists.txt 2007-03-28 15:38:46.000000000 -0500 ++++ VTK.new/Parallel/CMakeLists.txt 2008-02-21 15:16:04.000000000 -0500 +@@ -78,6 +78,8 @@ + + IF (VTK_USE_MPI) + INCLUDE (${CMAKE_ROOT}/Modules/FindMPI.cmake) ++ INCLUDE(${VTK_SOURCE_DIR}/Parallel/FindLAMMPI.cmake) ++ INCLUDE(${VTK_SOURCE_DIR}/Parallel/FindOpenmpi.cmake) + SET ( Kit_SRCS + ${Kit_SRCS} + vtkMPICommunicator.cxx +@@ -94,6 +96,18 @@ + IF (MPI_EXTRA_LIBRARY) + SET(KIT_LIBS ${KIT_LIBS} "${MPI_EXTRA_LIBRARY}") + ENDIF (MPI_EXTRA_LIBRARY) ++ IF (LAMMPI_LIBRARY) ++ SET(KIT_LIBS ${KIT_LIBS} "${LAMMPI_LIBRARY}") ++ ENDIF (LAMMPI_LIBRARY) ++ IF (LAMMPI_EXTRA_LIBRARY) ++ SET(KIT_LIBS ${KIT_LIBS} "${LAMMPI_EXTRA_LIBRARY}") ++ ENDIF (LAMMPI_EXTRA_LIBRARY) ++ IF (OPENMPI_LIBRARY) ++ SET(KIT_LIBS ${KIT_LIBS} "${OPENMPI_LIBRARY}") ++ ENDIF (OPENMPI_LIBRARY) ++ IF (OPENMPI_EXTRA_LIBRARY) ++ SET(KIT_LIBS ${KIT_LIBS} "${OPENMPI_EXTRA_LIBRARY}") ++ ENDIF (OPENMPI_EXTRA_LIBRARY) + ENDIF (VTK_USE_MPI) + + SET(Kit_EXTRA_SRCS) +diff -Naur VTK/Parallel/FindLAMMPI.cmake VTK.new/Parallel/FindLAMMPI.cmake +--- VTK/Parallel/FindLAMMPI.cmake 1969-12-31 19:00:00.000000000 -0500 ++++ VTK.new/Parallel/FindLAMMPI.cmake 2008-02-21 15:13:38.000000000 -0500 +@@ -0,0 +1,17 @@ ++# - Find LamMPI ++FIND_LIBRARY(LAMMPI_LIBRARY ++ NAMES lam ++ PATHS /usr/lib /usr/lib64 ++ "$ENV{ProgramFiles}/MPICH/SDK/Lib" ++ "$ENV{ProgramFiles}/MPICH2/Lib" ++ "C:/Program Files/MPICH/SDK/Lib" ++) ++ ++FIND_LIBRARY(LAMMPI_EXTRA_LIBRARY ++ NAMES lammpi++ ++ PATHS /usr/lib /usr/lib64 ++ "$ENV{ProgramFiles}/MPICH/SDK/Lib" ++ "C:/Program Files/MPICH/SDK/Lib" ++ DOC "If a second mpi library is necessary, specify it here.") ++ ++MARK_AS_ADVANCED(LAMMPI_LIBRARY LAMMPI_EXTRA_LIBRARY) +diff -Naur VTK/Parallel/FindOpenmpi.cmake VTK.new/Parallel/FindOpenmpi.cmake +--- VTK/Parallel/FindOpenmpi.cmake 1969-12-31 19:00:00.000000000 -0500 ++++ VTK.new/Parallel/FindOpenmpi.cmake 2008-02-21 15:14:23.000000000 -0500 +@@ -0,0 +1,18 @@ ++# - Find openmpi ++FIND_PATH(MPI_INCLUDE_PATH mpi.h ++ /usr/include ++ /usr/include/openmpi ++) ++ ++FIND_LIBRARY(OPENMPI_LIBRARY ++ NAMES mpi ++ PATHS /usr/lib /usr/lib64 ++) ++ ++FIND_LIBRARY(OPENMPI_EXTRA_LIBRARY ++ NAMES mpi_cxx ++ PATHS /usr/lib /usr/lib64 ++ DOC "If a second mpi library is necessary, specify it here.") ++ ++MARK_AS_ADVANCED(OPENMPI_LIBRARY OPENMPI_EXTRA_LIBRARY) ++ diff --git a/sci-libs/vtk/files/vtk-5.0.4-gcc4.3.patch b/sci-libs/vtk/files/vtk-5.0.4-gcc4.3.patch new file mode 100644 index 0000000..f921ee3 --- /dev/null +++ b/sci-libs/vtk/files/vtk-5.0.4-gcc4.3.patch @@ -0,0 +1,33 @@ +diff -Naur VTK/Utilities/DICOMParser/DICOMAppHelper.cxx VTK.new/Utilities/DICOMParser/DICOMAppHelper.cxx +--- VTK/Utilities/DICOMParser/DICOMAppHelper.cxx 2007-05-03 13:12:13.000000000 -0400 ++++ VTK.new/Utilities/DICOMParser/DICOMAppHelper.cxx 2008-05-24 13:44:18.000000000 -0400 +@@ -34,6 +34,7 @@ + #include <string> + #include <math.h> + #include <algorithm> ++#include <cstring> + #if defined(__BORLANDC__) + #include <mem.h> // for memcpy + #endif +diff -Naur VTK/Utilities/DICOMParser/DICOMFile.cxx VTK.new/Utilities/DICOMParser/DICOMFile.cxx +--- VTK/Utilities/DICOMParser/DICOMFile.cxx 2005-07-26 16:02:22.000000000 -0400 ++++ VTK.new/Utilities/DICOMParser/DICOMFile.cxx 2008-05-24 13:44:18.000000000 -0400 +@@ -24,6 +24,7 @@ + + #include <stdio.h> + #include <string> ++#include <cstring> + + #include "DICOMConfig.h" + #include "DICOMFile.h" +diff -Naur VTK/Utilities/DICOMParser/DICOMParser.cxx VTK.new/Utilities/DICOMParser/DICOMParser.cxx +--- VTK/Utilities/DICOMParser/DICOMParser.cxx 2006-03-24 10:59:50.000000000 -0500 ++++ VTK.new/Utilities/DICOMParser/DICOMParser.cxx 2008-05-24 13:44:19.000000000 -0400 +@@ -37,6 +37,7 @@ + #endif + + #include <string> ++#include <cstring> + + #include "DICOMConfig.h" + #include "DICOMParser.h" diff --git a/sci-libs/vtk/files/vtk-5.2.0-tcl-install.patch b/sci-libs/vtk/files/vtk-5.2.0-tcl-install.patch new file mode 100644 index 0000000..c7da786 --- /dev/null +++ b/sci-libs/vtk/files/vtk-5.2.0-tcl-install.patch @@ -0,0 +1,12 @@ +diff -Naur VTK/CMakeLists.txt VTK.new/CMakeLists.txt +--- VTK/CMakeLists.txt 2008-05-13 17:50:09.000000000 -0400 ++++ VTK.new/CMakeLists.txt 2008-10-05 10:34:42.000000000 -0400 +@@ -182,7 +182,7 @@ + # Compute the proper location for installing the Tcl package. This + # must be a fixed relative path below the library install location and + # is therefore not settable by parent projects. +-SET(VTK_INSTALL_TCL_DIR ${VTK_INSTALL_LIB_DIR}) ++SET(VTK_INSTALL_TCL_DIR ${VTK_INSTALL_PACKAGE_DIR}) + + IF(NOT VTK_INSTALL_JAVA_DIR) + SET(VTK_INSTALL_JAVA_DIR ${VTK_INSTALL_PACKAGE_DIR}/java) diff --git a/sci-libs/vtk/metadata.xml b/sci-libs/vtk/metadata.xml new file mode 100644 index 0000000..c3f4828 --- /dev/null +++ b/sci-libs/vtk/metadata.xml @@ -0,0 +1,15 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<herd>sci</herd> +<herd>java</herd> +<maintainer> + <email>markusle@gentoo.org</email> + <name>Markus Dittrich</name> +</maintainer> +<use> + <flag name='patented'>Build patented classes</flag> + <flag name='boost'>Add support for boost</flag> + <flag name='cg'>Use nvidia's cg shaders</flag> +</use> +</pkgmetadata> diff --git a/sci-libs/vtk/vtk-5.4.0.ebuild b/sci-libs/vtk/vtk-5.4.0.ebuild new file mode 100644 index 0000000..2784a77 --- /dev/null +++ b/sci-libs/vtk/vtk-5.4.0.ebuild @@ -0,0 +1,276 @@ +# Copyright 1999-2008 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sci-libs/vtk/vtk-5.2.0-r1.ebuild,v 1.2 2008/10/27 14:00:55 markusle Exp $ + +EAPI="1" +inherit distutils eutils flag-o-matic toolchain-funcs versionator java-pkg-opt-2 python qt3 qt4 + +# Short package version +SPV="$(get_version_component_range 1-2)" + +DESCRIPTION="The Visualization Toolkit" +HOMEPAGE="http://www.vtk.org" +SRC_URI="http://www.${PN}.org/files/release/${SPV}/${P}.tar.gz + examples? ( http://www.${PN}.org/files/release/${SPV}/${PN}data-${PV}.tar.gz )" + +LICENSE="BSD LGPL-2" +KEYWORDS="~amd64 ~x86" +SLOT="0" +IUSE="boost cg examples mpi patented python tcl tk threads qt3 qt4" +RDEPEND="mpi? ( || ( + sys-cluster/openmpi + sys-cluster/lam-mpi + sys-cluster/mpich2 ) ) + python? ( >=dev-lang/python-2.0 ) + boost? ( dev-libs/boost ) + cg? ( media-gfx/nvidia-cg-toolkit ) + tcl? ( >=dev-lang/tcl-8.2.3 ) + tk? ( >=dev-lang/tk-8.2.3 ) + java? ( >=virtual/jre-1.5 ) + !qt4? ( qt3? ( >=x11-libs/qt-3.3.4:3 ) ) + qt4? ( + || ( ( x11-libs/qt-core:4 x11-libs/qt-gui:4 ) =x11-libs/qt-4.3*:4 ) ) + dev-libs/expat + dev-libs/libxml2 + media-libs/freetype + media-libs/jpeg + media-libs/libpng + media-libs/tiff + virtual/opengl + x11-libs/libXmu" + +DEPEND="${RDEPEND} + java? ( >=virtual/jdk-1.5 ) + >=dev-util/cmake-2.2.3" + +S="${WORKDIR}"/VTK + +pkg_setup() { + java-pkg-opt-2_pkg_setup + if use qt3 && use qt4; then + echo + ewarn "qt3 and qt4 support for vtk are mutually exclusive and" + ewarn "qt4 support has therefore been enabled by default." + echo + fi + + if use mpi && has_version sys-cluster/mpich2; then + append-flags -DMPICH_IGNORE_CXX_SEEK + if ! built_with_use sys-cluster/mpich2 cxx; then + die "Please re-emerge sys-cluster/mpich2 with USE=\"cxx\"" + fi + fi + + if use qt4 && use examples; then + QT4_BUILT_WITH_USE_CHECK="qt3support" + qt4_pkg_setup + fi +} + +src_unpack() { + unpack ${A} + cd "${S}" +# epatch "${FILESDIR}"/${P}-tcl-install.patch + sed -e "s:@VTK_TCL_LIBRARY_DIR@:/usr/$(get_libdir):" \ + -i Wrapping/Tcl/pkgIndex.tcl.in \ + || die "Failed to fix tcl pkgIndex file" +} + +src_compile() { + # gcc versions 3.2.x seem to have sse-related bugs that are + # triggered by VTK when compiling for pentium3/4 + if [ "$(gcc-major-version)" -eq 3 -a "$(gcc-minor-version)" -eq 2 -a \ + "$(get-flag -march)" == "-march=pentium4" ]; then + filter-mfpmath sse + filter-flags "-msse -msse2" + echo "$(get-flag -march)" + fi + + # Fix Examples cmake file + sed -e "s/MAKEPROGRAM/CMAKE_MAKE_PROGRAM/g" \ + -i "${S}"/Examples/CMakeLists.txt || \ + die "Failed to fix examples CMakeList.txt" + + # build list of config variable define's to pass to cmake + local CMAKE_VARIABLES="" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_INSTALL_PACKAGE_DIR:PATH=/$(get_libdir)/${PN}-${SPV}" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DCMAKE_SKIP_RPATH:BOOL=YES" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_DIR:PATH=${S}" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_INSTALL_LIB_DIR:PATH=/$(get_libdir)/" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DCMAKE_INSTALL_PREFIX:PATH=/usr" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DBUILD_SHARED_LIBS:BOOL=ON" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_USE_SYSTEM_FREETYPE:BOOL=ON" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_USE_SYSTEM_JPEG:BOOL=ON" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_USE_SYSTEM_PNG:BOOL=ON" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_USE_SYSTEM_TIFF:BOOL=ON" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_USE_SYSTEM_ZLIB:BOOL=ON" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_USE_SYSTEM_EXPAT:BOOL=ON" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_USE_SYSTEM_LIBXML2:BOOL=ON" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DBUILD_TESTING:BOOL=OFF" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_USE_HYBRID:BOOL=ON" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_USE_GL2PS:BOOL=ON" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_USE_RENDERING:BOOL=ON" + + use boost && CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_USE_BOOST:BOOL=ON" + use cg && CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_USE_CG_SHADERS:BOOL=ON" + + use examples && CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_DATA_ROOT:PATH=/usr/share/${PN}/data -DBUILD_EXAMPLES:BOOL=ON" + if use java; then + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_WRAP_JAVA:BOOL=ON" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DJAVA_AWT_INCLUDE_PATH:PATH=`java-config -O`/include" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DJAVA_INCLUDE_PATH:PATH=`java-config -O`/include" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DJAVA_INCLUDE_PATH2:PATH=`java-config -O`/include/linux" + if [ "${ARCH}" == "amd64" ]; then + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DJAVA_AWT_LIBRARY:PATH=`java-config -O`/jre/lib/${ARCH}/libjawt.so" + else + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DJAVA_AWT_LIBRARY:PATH=`java-config -O`/jre/lib/i386/libjawt.so" + fi + fi + + if use mpi; then + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_USE_MPI:BOOL=ON" + use !threads && CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_USE_PARALLEL:BOOL=ON" + fi + + if use python; then + python_version + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_WRAP_PYTHON:BOOL=ON" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DPYTHON_INCLUDE_PATH:PATH=/usr/include/python${PYVER}" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DPYTHON_LIBRARY:PATH=/usr/$(get_libdir)/libpython${PYVER}.so" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_PYTHON_SETUP_ARGS:STRING=\"--prefix=${D}/usr\"" + fi + + if use qt3 || use qt4 ; then + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_USE_GUISUPPORT:BOOL=ON" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_USE_QVTK:BOOL=ON" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DQT_WRAP_CPP:BOOL=ON" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DQT_WRAP_UI:BOOL=ON" + fi + + if use qt3; then + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_INSTALL_QT_DIR:PATH=/qt/3/plugins/${PN}" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DDESIRED_QT_VERSION:STRING=3" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DQT_MOC_EXECUTABLE:FILEPATH=/usr/qt/3/bin/moc" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DQT_UIC_EXECUTABLE:FILEPATH=/usr/qt/3/bin/uic" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DQT_INCLUDE_DIR:PATH=/usr/qt/3/include" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DQT_QMAKE_EXECUTABLE:PATH=/usr/qt/3/bin/qmake" + fi + + if use qt4; then + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_INSTALL_QT_DIR:PATH=/$(get_libdir)/qt4/plugins/${PN}" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DDESIRED_QT_VERSION:STRING=4" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DQT_MOC_EXECUTABLE:FILEPATH=/usr/bin/moc" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DQT_UIC_EXECUTABLE:FILEPATH=/usr/bin/uic" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DQT_INCLUDE_DIR:PATH=/usr/include/qt4" + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DQT_QMAKE_EXECUTABLE:PATH=/usr/bin/qmake" + fi + + if use tcl; then + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_WRAP_TCL:BOOL=ON" + else + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_WRAP_TCL:BOOL=OFF" + fi + + if use tk; then + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_USE_TK:BOOL=ON" + else + CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_USE_TK:BOOL=OFF" + fi + + use threads && CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_USE_PARALLEL:BOOL=ON" + use patented && CMAKE_VARIABLES="${CMAKE_VARIABLES} -DVTK_USE_PATENTED:BOOL=ON" + #use doc && CMAKE_VARIABLES="${CMAKE_VARIABLES} -DDOCUMENTATION_HTML_HELP:BOOL=ON -DBUILD_DOCUMENTATION:BOOL=ON" + + # run cmake twice to achieve proper + # configuration with cmake 2.2.x + cmake ${CMAKE_VARIABLES} . && cmake ${CMAKE_VARIABLES} . \ + || die "cmake configuration failed" + + # fix java.lang.OutOfMemoryError on amd64 (see bug #123178) + if use java && [ "${ARCH}" == "amd64" ]; then + sed -e "s/javac/javac -J-Xmx256m/" \ + -i "${S}"/Wrapping/Java/CMakeFiles/VTKBuildAll.dir/build.make \ + || die "Failed to patch javac" + fi + + emake || die "emake failed" +} + +src_install() { + # remove portage paths from dynamically created Type + # headers + sed -e "s:${S}/Common/::" \ + -e "s:${S}/Rendering/::" \ + -i "${S}"/Utilities/InstallOnly/*.cmake || \ + die "Failed to fix cmake files" + + make DESTDIR="${D}" install || die "make install failed" + + # install docs + dohtml "${S}"/README.html || die "Failed to install docs" + + # install python modules + if use python; then + cd "${S}"/Wrapping/Python + docinto vtk_python + distutils_src_install + fi + + # install jar + use java && java-pkg_dojar "${S}"/bin/vtk.jar + + # install Tcl docs + docinto vtk_tcl + dodoc "${S}"/Wrapping/Tcl/README || \ + die "Failed to install Tcl docs" + + # install examples + if use examples; then + dodir /usr/share/${PN} || \ + die "Failed to create examples directory" + cp -pPR "${S}"/Examples "${D}"/usr/share/${PN}/examples || \ + die "Failed to copy example files" + + # fix example's permissions + find "${D}"/usr/share/${PN}/examples -type d -exec \ + chmod 0755 {} \; || \ + die "Failed to fix example directories permissions" + find "${D}"/usr/share/${PN}/examples -type f -exec \ + chmod 0644 {} \; || \ + die "Failed to fix example files permissions" + + cp -pPR "${WORKDIR}"/VTKData "${D}"/usr/share/${PN}/data || \ + die "Failed to copy data files" + + # fix data's permissions + find "${D}"/usr/share/${PN}/data -type d -exec \ + chmod 0755 {} \; || \ + die "Failed to fix data directories permissions" + find "${D}"/usr/share/${PN}/data -type f -exec \ + chmod 0644 {} \; || \ + die "Failed to fix data files permissions" + fi + + #install big docs +# if use doc; then +# cd "${WORKDIR}"/html +# rm -f *.md5 || die "Failed to remove superfluous hashes" +# einfo "Installing API docs. This may take some time." +# insinto "/usr/share/doc/${PF}/api-docs" +# doins -r ./* || die "Failed to install docs" +# fi + + # environment + echo "VTK_DATA_ROOT=/usr/share/${PN}/data" >> "${T}"/40${PN} + echo "VTK_DIR=/usr/$(get_libdir)/${PN}-${SPV}" >> "${T}"/40${PN} + echo "VTKHOME=/usr" >> "${T}"/40${PN} + doenvd "${T}"/40${PN} +} + +pkg_postinst() { + if use patented; then + ewarn "Using patented code in VTK may require a license." + ewarn "For more information, please read:" + ewarn "http://public.kitware.com/cgi-bin/vtkfaq?req=show&file=faq07.005.htp" + fi +} |