diff options
author | Kacper Kowalik (Xarthisius) <xarthisius.kk@gmail.com> | 2012-03-23 14:40:41 +0100 |
---|---|---|
committer | Kacper Kowalik (Xarthisius) <xarthisius.kk@gmail.com> | 2012-03-23 14:40:41 +0100 |
commit | 7328e37580c48c365af256bf36c03b643856d55d (patch) | |
tree | 2f81c1d4eb887084a55c3624740ec163a4fed43f | |
parent | sci-physics/abinit-6.12.1 fortran setup improvement corrected, gui preparatio... (diff) | |
download | sci-7328e37580c48c365af256bf36c03b643856d55d.tar.gz sci-7328e37580c48c365af256bf36c03b643856d55d.tar.bz2 sci-7328e37580c48c365af256bf36c03b643856d55d.zip |
[sci-libs/hdf5] add developement snapshot
-rw-r--r-- | sci-libs/hdf5/Manifest | 1 | ||||
-rw-r--r-- | sci-libs/hdf5/files/hdf5-1.8.8-array_bounds.patch | 22 | ||||
-rw-r--r-- | sci-libs/hdf5/files/hdf5-1.8.8-buildsystem.patch | 33 | ||||
-rw-r--r-- | sci-libs/hdf5/files/hdf5-1.8.9-implicits.patch | 55 | ||||
-rw-r--r-- | sci-libs/hdf5/hdf5-1.8.9_pre13.ebuild | 101 | ||||
-rw-r--r-- | sci-libs/hdf5/metadata.xml | 19 |
6 files changed, 231 insertions, 0 deletions
diff --git a/sci-libs/hdf5/Manifest b/sci-libs/hdf5/Manifest new file mode 100644 index 000000000..412651171 --- /dev/null +++ b/sci-libs/hdf5/Manifest @@ -0,0 +1 @@ +DIST hdf5-1.8.9-snap13.tar.bz2 5835537 SHA256 870465412642e71291ecd94cee998e3b874de0c6fe63197589f744becca94a1f SHA512 1d976e42cef9c6b7f96066bc1e21112e13c6f497c313532cc64afa80c28d4f675176d718d6ffb8ffdd6a88c147a99b108fdaa63fd68736a1d3c049518c433543 WHIRLPOOL c076ab336cbb2aa2638ab3156a4657351b81812d1bc10c45fa0466e7af6b9ec1897638974d0ec5ac2f41e43927b65affd1c860fd462a32a44b20de3754b0623d diff --git a/sci-libs/hdf5/files/hdf5-1.8.8-array_bounds.patch b/sci-libs/hdf5/files/hdf5-1.8.8-array_bounds.patch new file mode 100644 index 000000000..042d012d1 --- /dev/null +++ b/sci-libs/hdf5/files/hdf5-1.8.8-array_bounds.patch @@ -0,0 +1,22 @@ +--- a/perform/pio_engine.c ++++ b/perform/pio_engine.c +@@ -454,7 +454,7 @@ + subdir = (user ? user : login); + + if (subdir) { +- for (i = 0; i < size && prefix[i]; i++) ++ for (i = 0; i < size-1 && prefix[i]; i++) + fullname[i] = prefix[i]; + + fullname[i++] = '/'; +--- a/perform/sio_engine.c ++++ b/perform/sio_engine.c +@@ -353,7 +353,7 @@ + subdir = (user ? user : login); + + if (subdir) { +- for (i = 0; i < size && prefix[i]; i++) ++ for (i = 0; i < size-1 && prefix[i]; i++) + fullname[i] = prefix[i]; + + fullname[i++] = '/'; diff --git a/sci-libs/hdf5/files/hdf5-1.8.8-buildsystem.patch b/sci-libs/hdf5/files/hdf5-1.8.8-buildsystem.patch new file mode 100644 index 000000000..0f85cf5ed --- /dev/null +++ b/sci-libs/hdf5/files/hdf5-1.8.8-buildsystem.patch @@ -0,0 +1,33 @@ +Prevent build system with messing up LD_LIBRARY_PATH + +--- a/configure.in ++++ b/configure.in +@@ -2328,8 +2328,6 @@ + dnl + AC_MSG_CHECKING([how to print long long]) + AC_CACHE_VAL([hdf5_cv_printf_ll], +-LD_LIBRARY_PATH="$LD_LIBRARY_PATH`echo $AM_LDFLAGS $LDFLAGS | sed -e 's/-L/:/g' -e 's/ //g'`" +-export LD_LIBRARY_PATH + + for hdf5_cv_printf_ll in l ll L q unknown; do + AC_TRY_RUN([ +--- a/src/Makefile.am ++++ b/src/Makefile.am +@@ -125,8 +125,6 @@ + # Remove the generated .c file if errors occur unless HDF5_Make_Ignore + # is set to ignore the error. + H5Tinit.c: H5detect$(EXEEXT) +- LD_LIBRARY_PATH="$$LD_LIBRARY_PATH`echo $(LDFLAGS) | \ +- sed -e 's/-L/:/g' -e 's/ //g'`" \ + $(RUNSERIAL) ./H5detect$(EXEEXT) > $@ || \ + (test $$HDF5_Make_Ignore && echo "*** Error ignored") || \ + ($(RM) $@ ; exit 1) +@@ -137,8 +135,6 @@ + # Remove the generated .c file if errors occur unless HDF5_Make_Ignore + # is set to ignore the error. + H5lib_settings.c: H5make_libsettings$(EXEEXT) libhdf5.settings +- LD_LIBRARY_PATH="$$LD_LIBRARY_PATH`echo $(LDFLAGS) | \ +- sed -e 's/-L/:/g' -e 's/ //g'`" \ + $(RUNSERIAL) ./H5make_libsettings$(EXEEXT) > $@ || \ + (test $$HDF5_Make_Ignore && echo "*** Error ignored") || \ + ($(RM) $@ ; exit 1) diff --git a/sci-libs/hdf5/files/hdf5-1.8.9-implicits.patch b/sci-libs/hdf5/files/hdf5-1.8.9-implicits.patch new file mode 100644 index 000000000..43e4f0774 --- /dev/null +++ b/sci-libs/hdf5/files/hdf5-1.8.9-implicits.patch @@ -0,0 +1,55 @@ +--- b/configure.in ++++ a/configure.in +@@ -1499,6 +1499,9 @@ + dnl though we do not do this as it breaks the big test on older versions + dnl of linux (CentOS 4.6) using newer versions of gcc (4.6.2). + AM_CPPFLAGS="-D_BSD_SOURCE $AM_CPPFLAGS" ++ ++ dnl _GNU_SOURCE is needed for vasprintf ++ AM_CPPFLAGS="-D_GNU_SOURCE $AM_CPPFLAGS" + ;; + esac + +--- a/test/cache_common.h ++++ b/test/cache_common.h +@@ -702,5 +702,9 @@ + hbool_t compare_init, + int test_num); + ++hbool_t resize_configs_are_equal(const H5C_auto_size_ctl_t *a, ++ const H5C_auto_size_ctl_t *b, ++ hbool_t compare_init); ++ + #endif /* _CACHE_COMMON_H */ + +--- a/tools/misc/talign.c ++++ b/tools/misc/talign.c +@@ -23,6 +23,7 @@ + + #include "hdf5.h" + #include "H5private.h" ++#include "h5tools.h" + + const char *fname = "talign.h5"; + const char *setname = "align"; +--- a/tools/h5repack/testh5repack_detect_szip.c ++++ b/tools/h5repack/testh5repack_detect_szip.c +@@ -17,6 +17,7 @@ + #include "h5repack.h" + #include "h5tools.h" + #include "h5test.h" ++#include "h5tools_utils.h" + + + /* Name of tool */ +--- a/hl/src/H5LTanalyze.c ++++ b/hl/src/H5LTanalyze.c +@@ -49,7 +49,8 @@ + #define YY_FLEX_MINOR_VERSION 5 + + #include <stdio.h> ++#include "H5pubconf.h" + #ifdef H5_HAVE_UNISTD_H + #include <unistd.h> + #endif + diff --git a/sci-libs/hdf5/hdf5-1.8.9_pre13.ebuild b/sci-libs/hdf5/hdf5-1.8.9_pre13.ebuild new file mode 100644 index 000000000..698acd5f4 --- /dev/null +++ b/sci-libs/hdf5/hdf5-1.8.9_pre13.ebuild @@ -0,0 +1,101 @@ +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sci-libs/hdf5/hdf5-1.8.8.ebuild,v 1.4 2011/12/05 16:56:26 xarthisius Exp $ + +EAPI=4 + +inherit autotools eutils fortran-2 toolchain-funcs versionator + +MY_PV=$(replace_version_separator 3 '-') +MY_PV=${MY_PV/pre/snap} +MYP=${PN}-${MY_PV} +VER=$(get_version_component_range 1-2) +VER=v${VER/./} + +DESCRIPTION="General purpose library and file format for storing scientific data" +HOMEPAGE="http://www.hdfgroup.org/HDF5/" +SRC_URI="http://www.hdfgroup.uiuc.edu/ftp/pub/outgoing/${PN}/snapshots/${VER}/${MYP}.tar.bz2" + +LICENSE="NCSA-HDF" +SLOT="0" +KEYWORDS="" +IUSE="cxx debug examples fortran fortran2003 mpi static-libs szip threads zlib" +REQUIRED_USE="cxx? ( !mpi ) mpi? ( !cxx ) + threads? ( !cxx !mpi !fortran ) + fortran2003? ( fortran )" + +RDEPEND="fortran? ( virtual/fortran ) + mpi? ( virtual/mpi[romio] ) + szip? ( >=sci-libs/szip-2.1 ) + zlib? ( sys-libs/zlib )" + +DEPEND="${RDEPEND} + sys-devel/libtool:2" + +S=${WORKDIR}/${MYP} + +pkg_setup() { + tc-export CXX CC FC # workaround for bug 285148 + if use fortran; then + use fortran2003 && FORTRAN_STANDARD=2003 + fortran-2_pkg_setup + fi + if use mpi; then + if has_version 'sci-libs/hdf5[-mpi]'; then + ewarn "Installing hdf5 with mpi enabled with a previous hdf5 with mpi disabled may fail." + ewarn "Try to uninstall the current hdf5 prior to enabling mpi support." + fi + export CC=mpicc + use fortran && export FC=mpif90 + elif has_version 'sci-libs/hdf5[mpi]'; then + ewarn "Installing hdf5 with mpi disabled while having hdf5 installed with mpi enabled may fail." + ewarn "Try to uninstall the current hdf5 prior to disabling mpi support." + fi +} + +src_prepare() { + epatch "${FILESDIR}"/${PN}-1.8.8-buildsystem.patch \ + "${FILESDIR}"/${PN}-1.8.8-array_bounds.patch \ + "${FILESDIR}"/${PN}-1.8.9-implicits.patch + # respect gentoo examples directory + sed \ + -e "s:hdf5_examples:doc/${PF}/examples:g" \ + -i $(find . -name Makefile.am) $(find . -name "run*.sh.in") || die + sed \ + -e '/docdir/d' \ + -i config/commence.am || die + eautoreconf + # enable shared libs by default for h5cc config utility + sed -i -e "s/SHLIB:-no/SHLIB:-yes/g" tools/misc/h5cc.in || die +} + +src_configure() { + econf \ + --disable-sharedlib-rpath \ + --enable-production \ + --docdir="${EPREFIX}"/usr/share/doc/${PF} \ + --enable-deprecated-symbols \ + --enable-shared \ + --disable-silent-rules \ + $(use_enable static-libs static) \ + $(use_enable debug debug all) \ + $(use_enable debug codestack) \ + $(use_enable cxx) \ + $(use_enable fortran) \ + $(use_enable fortran2003) \ + $(use_enable mpi parallel) \ + $(use_enable threads threadsafe) \ + $(use_with szip szlib) \ + $(use_with threads pthread) \ + $(use_with zlib) \ + ${myconf} +} + +src_install() { + default + use static-libs || find "${ED}" -name '*.la' -exec rm -f {} + + + if use examples; then + emake DESTDIR="${D}" install-examples + fi +} diff --git a/sci-libs/hdf5/metadata.xml b/sci-libs/hdf5/metadata.xml new file mode 100644 index 000000000..6b6f68735 --- /dev/null +++ b/sci-libs/hdf5/metadata.xml @@ -0,0 +1,19 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <herd>sci</herd> + <maintainer> + <email>xarthisius@gentoo.org</email> + <name>Kacper Kowalik</name> + </maintainer> + <longdescription> + HDF5 is a file format and library for storing scientific data. HDF5 + was designed and implemented to address the deficiencies of HDF4.x. It + has a more powerful and flexible data model, supports files larger + than 2 GB, and supports parallel I/O. + </longdescription> + <use> + <flag name="fortran2003">enable new features that require Fortran 2003 + (http://www.hdfgroup.org/HDF5/doc/fortran/NewFeatures_F2003.pdf)</flag> + </use> +</pkgmetadata> |