From 246a01f769905cce31f3f57be90ddedf9a7c8d82 Mon Sep 17 00:00:00 2001 From: Tim Jenness Date: Thu, 23 Oct 2014 10:53:05 -0700 Subject: [PATCH] hdf5: Add HDF5 to thirdparty/hdfgroup/hdf5 Currently v1.8.13. Required for HDS version 5. --- .gitmodules | 3 + Makefile.dependencies | 4 + componentset.xml | 18 +++ thirdparty/hdfgroup/Makefile.am | 3 + thirdparty/hdfgroup/bootstrap | 49 ++++++++ thirdparty/hdfgroup/configure.ac | 21 ++++ thirdparty/hdfgroup/hdf5/Makefile.am | 24 ++++ thirdparty/hdfgroup/hdf5/bootstrap | 134 ++++++++++++++++++++++ thirdparty/hdfgroup/hdf5/component.xml | 25 ++++ thirdparty/hdfgroup/hdf5/component.xml.in | 25 ++++ thirdparty/hdfgroup/hdf5/configure.ac | 43 +++++++ thirdparty/hdfgroup/hdf5/hdf5 | 1 + 12 files changed, 350 insertions(+) create mode 100644 thirdparty/hdfgroup/Makefile.am create mode 100755 thirdparty/hdfgroup/bootstrap create mode 100644 thirdparty/hdfgroup/configure.ac create mode 100644 thirdparty/hdfgroup/hdf5/Makefile.am create mode 100755 thirdparty/hdfgroup/hdf5/bootstrap create mode 100644 thirdparty/hdfgroup/hdf5/component.xml create mode 100644 thirdparty/hdfgroup/hdf5/component.xml.in create mode 100644 thirdparty/hdfgroup/hdf5/configure.ac create mode 160000 thirdparty/hdfgroup/hdf5/hdf5 diff --git a/.gitmodules b/.gitmodules index ae5779f8959..1f17e6636f0 100644 --- a/.gitmodules +++ b/.gitmodules @@ -163,3 +163,6 @@ [submodule "thirdparty/erfa/erfa"] path = thirdparty/erfa/erfa url = git://github.com/liberfa/erfa.git +[submodule "thirdparty/hdfgroup/hdf5/hdf5"] + path = thirdparty/hdfgroup/hdf5/hdf5 + url = https://github.com/Starlink/hdf5.git diff --git a/Makefile.dependencies b/Makefile.dependencies index e3e9e0a5d2f..cfc532b472c 100644 --- a/Makefile.dependencies +++ b/Makefile.dependencies @@ -1138,6 +1138,10 @@ $(MANIFESTS)/gwm: \ cd libraries/gwm \ && $(MAKE_CPT) +$(MANIFESTS)/hdf5: + cd thirdparty/hdfgroup/hdf5 \ + && $(MAKE_CPT) + $(MANIFESTS)/hds: \ $(MANIFESTS)/chr \ $(MANIFESTS)/cnf \ diff --git a/componentset.xml b/componentset.xml index 630a011c4a7..604b8e9d5e4 100644 --- a/componentset.xml +++ b/componentset.xml @@ -6732,6 +6732,24 @@ Ultrix and for SunOS and may still work for them. starlink@jiscmail.ac.uk + + 1.8.13 + thirdparty/hdfgroup/hdf5 + Hierarchical Data Format version 5 + + + + + + Tim Jenness + timj + stardev@jiscmail.ac.uk + owner + + + starlink@jiscmail.ac.uk + + 3.37 thirdparty/heasarc/cfitsio diff --git a/thirdparty/hdfgroup/Makefile.am b/thirdparty/hdfgroup/Makefile.am new file mode 100644 index 00000000000..ef96995e1f3 --- /dev/null +++ b/thirdparty/hdfgroup/Makefile.am @@ -0,0 +1,3 @@ +## Process this file with automake to produce Makefile.in + +SUBDIRS = @subdirs@ diff --git a/thirdparty/hdfgroup/bootstrap b/thirdparty/hdfgroup/bootstrap new file mode 100755 index 00000000000..89c548c4e61 --- /dev/null +++ b/thirdparty/hdfgroup/bootstrap @@ -0,0 +1,49 @@ +#! /bin/sh - +# This is not a starconf component bootstrap file; it should be maintained +# as a copy of buildsupport/starconf/bootstrap.bridging: +# $Source: /cvs/buildsupport/starconf/bootstrap.bridging,v $ +# $Revision: 1.1 $ +# (check this in to CVS using -ko to preserve above RCS info). +# +# Instead, it is a bootstrap script used for `bridging' directories, +# such as applications/ and libraries/, which group together related +# components and, when they are bootstrapped, bridge between the parent +# and the various children listed in the AC_CONFIG_SUBDIRS macro in the +# configure.ac in this directory. That is, it is for directories which +# are traversed by the top-level bootstrap, but which are not components. + + +# If STAR_SUPPRESS_AUTORECONF is true in the environment, then we +# suppress the call of `autoreconf', and simply invoke ./bootstrap in +# the children. This is here _only_ so that the top-level bootstrap +# file can suppress multiple calls of this in bootstrap scripts in its +# children, and as an optimisation. As such, it makes sense ONLY when +# invoked from a top-level bootstrap. This mechanism must not be used +# by users, as it is liable to change without warning. +: ${STAR_SUPPRESS_AUTORECONF=false} + +if $STAR_SUPPRESS_AUTORECONF; then + echo "Suppressing autoreconf" + + thisdir=`basename $PWD` + for d in `autoconf --trace=AC_CONFIG_SUBDIRS:$% configure.ac` DUMMY + do + if test -n "$d" -a -d "$d"; then + echo "Bootstrapping $thisdir/$d..." + (cd $d && ./bootstrap) + fi + done + +else + + echo "autoreconf --install --symlink" || exit 1 + autoreconf --install --symlink + + if test ! -f configure; then + echo "Ooooh dear, autoreconf didn't work -- I can't find ./configure" + exit 1 + fi + +fi + +exit 0 diff --git a/thirdparty/hdfgroup/configure.ac b/thirdparty/hdfgroup/configure.ac new file mode 100644 index 00000000000..2795ad0ca26 --- /dev/null +++ b/thirdparty/hdfgroup/configure.ac @@ -0,0 +1,21 @@ +dnl Process this file with autoconf to produce a configure script + +dnl This is not a package, so the first two arguments are fake. +AC_INIT(star-thirdparty-hdfgroup, 1.0, starlink@jiscmail.ac.uk) +AM_INIT_AUTOMAKE(1.8.2-starlink) + +dnl Following sanity-check isn't terribly helpful... +AC_CONFIG_SRCDIR(bootstrap) + +STAR_DEFAULTS + +AC_PROG_MAKE_SET + +dnl The following list must be kept up-to-date by hand. +dnl The list is available as the substitution variable @subdirs@. +dnl (must be kept on one line). +AC_CONFIG_SUBDIRS([hdf5]) + +AC_CONFIG_FILES([Makefile]) + +AC_OUTPUT diff --git a/thirdparty/hdfgroup/hdf5/Makefile.am b/thirdparty/hdfgroup/hdf5/Makefile.am new file mode 100644 index 00000000000..35069bb6cd9 --- /dev/null +++ b/thirdparty/hdfgroup/hdf5/Makefile.am @@ -0,0 +1,24 @@ +## Process this file with automake to produce Makefile.in + +@SET_MAKE@ + +RECURSIVE_TARGETS = all check + +$(RECURSIVE_TARGETS): + ( cd hdf5; $(MAKE) $@; ) + +## Automake really requires local versions for these targets. +distclean-local: + ( cd hdf5; $(MAKE) distclean ) + +clean-local: + ( cd hdf5; $(MAKE) clean ) + +EXTRA_DIST = hdf5 + +## Before distributing subdirectories we need to clean up and remove any +## softlinks. +dist-hook: + rm -rf `find $(distdir) -type l` + (cd $(distdir)/hdf5; make distclean) + diff --git a/thirdparty/hdfgroup/hdf5/bootstrap b/thirdparty/hdfgroup/hdf5/bootstrap new file mode 100755 index 00000000000..b1b79e9efd6 --- /dev/null +++ b/thirdparty/hdfgroup/hdf5/bootstrap @@ -0,0 +1,134 @@ +#! /bin/sh - +# original bootstrap file, installed by starconf 1.3, rnum=1003000 +# If you _need_ to change this file, delete `original' in the line above, +# or else starconf may overwrite it with an updated version. +# +# bootstrap.installed. Generated from bootstrap.installed.in by configure. +# +# Bootstrap a checked-out component of the Starlink software tree. +# Run this script in a freshly checked-out directory to bring the +# system to the point where you can just type ./configure;make +# +# Usage: +# ./bootstrap + + +# This script should be installed, by starconf, in all `component +# directories'. A `component directory' is a directory which has a +# component.xml.in file in it. All component directories will have a +# manifest file created and installed in .../manifests; non-component +# directories will not have manifest files. Everything that's +# installed should be installed as part of some component +# or other. +# +# The ./bootstrap scripts will stop recursing when they find a +# component.xml.in file. They'll warn if they find a component.xml.in +# file in any AC_CONFIG_SUBDIRS directory, but ignore it, and exit +# with an error if they do not find a component.xml.in file and there +# are no AC_CONFIG_SUBDIRS directories in which to search further. +# That is, the tree of directories which the top-level bootstrap +# traverses should have component.xml.in files at or above all its +# leaves. + + +# The starconf below might update bootstrap, if a newer version is +# available. Unfortunately, this confuses sh, which appears _not_ to +# keep open the script it's reading, but to reopen it afresh, or reseek +# within the file, for each line (or something like that!?). +# So rewrite this script to a temporary file and exec it. +tempfile="${TMP-/tmp}/$0-$$.tmp" +rm -f $tempfile +echo "trap 'rm -f $tempfile' 0" >$tempfile # remove temporary at exit +sed '1,/^--TRAMPOLINE--/d' $0 >>$tempfile # strip out the trampoline +exec /bin/sh $tempfile # exec the temporary +--TRAMPOLINE-- + + +echo "Bootstrapping `pwd` ..." + +if test ! -f configure.ac; then + echo "bootstrap: No configure.ac in directory `pwd`" >&2 + exit 1 +fi + +subdirs=`autoconf --trace=AC_CONFIG_SUBDIRS:$% configure.ac` + +if test -f component.xml.in; then + + if starconf --show buildsupport >/dev/null 2>&1; then + + # starconf is in the path + echo "...using starconf in " `starconf --show buildsupport` + starconf || exit 1 + + else + + # The temptation here is to use ./starconf.status to find the + # starconf that it came from and invoke that explicitly. Don't do + # this, however: we don't want to be too clever, and it's better + # to be consistent with the way the autotools behave (the first + # one in your path is the one that works, and they don't have this + # sort of `phone home' cleverness in them). + + echo "bootstrap error: The starconf application is not in your path" + + # This doesn't stop us being helpful, however. + if test -f ./starconf.status; then + starconf_home=`./starconf.status --show buildsupport` + echo "This directory was last bootstrapped with $starconf_home/bin/starconf" + fi + + exit 1 + fi + + # Check that there are no component.xml.in files in any subdirectories + if test -n "$subdirs"; then + for d in $subdirs + do + if test -d "$d" && test -f "$d/component.xml.in"; then + echo "bootstrap: warning: ignoring child $d/component.xml.in" >&2 + fi + done + fi + + # If STAR_SUPPRESS_AUTORECONF is true in the environment, then we + # suppress the call of `autoreconf'. This is here _only_ so that + # the top-level bootstrap file can suppress multiple calls of this + # in bootstrap scripts in its children. This mechanism must not + # be used by users, as it is likely to change without warning. + if ${STAR_SUPPRESS_AUTORECONF-false}; then + echo "Suppressing autoreconf in" `pwd` + else + echo autoreconf --install --symlink + autoreconf --install --symlink || exit 1 + fi + +else + + # This is not a component directory, so simply recurse into the children. + + # ...if there are any, that is. + if test -z "$subdirs"; then + echo "bootstrap: error: non-component directory `pwd` has no subdirs" >&2 + exit 1 + fi + + # Bootstrap the child directories mentioned in AC_CONFIG_SUBDIRS. + # These bootstrap files must exist. + for d in $subdirs + do + if test -d "$d"; then + echo "Bootstrapping $d..." + if test -f $d/bootstrap; then + # good... + (cd $d; /bin/sh ./bootstrap) + else + echo "bootstrap: no file $d/bootstrap" >&2 + exit 1 + fi + fi + done + +fi + +exit 0 diff --git a/thirdparty/hdfgroup/hdf5/component.xml b/thirdparty/hdfgroup/hdf5/component.xml new file mode 100644 index 00000000000..0486ef96dec --- /dev/null +++ b/thirdparty/hdfgroup/hdf5/component.xml @@ -0,0 +1,25 @@ + + + + + + 1.8.13 + thirdparty/hdfgroup/hdf5 + Hierarchical Data Format version 5 + + + + + + + + Tim Jenness + timj + stardev@jiscmail.ac.uk + owner + + + + starlink@jiscmail.ac.uk + + diff --git a/thirdparty/hdfgroup/hdf5/component.xml.in b/thirdparty/hdfgroup/hdf5/component.xml.in new file mode 100644 index 00000000000..53c1f6734cc --- /dev/null +++ b/thirdparty/hdfgroup/hdf5/component.xml.in @@ -0,0 +1,25 @@ + + + + + + @PACKAGE_VERSION@ + thirdparty/hdfgroup/hdf5 + Hierarchical Data Format version 5 + + + @STAR_DEPENDENCIES_CHILDREN@ + + + + + Tim Jenness + timj + stardev@jiscmail.ac.uk + owner + + + + @PACKAGE_BUGREPORT@ + + diff --git a/thirdparty/hdfgroup/hdf5/configure.ac b/thirdparty/hdfgroup/hdf5/configure.ac new file mode 100644 index 00000000000..170276c6814 --- /dev/null +++ b/thirdparty/hdfgroup/hdf5/configure.ac @@ -0,0 +1,43 @@ +dnl Process this file with autoconf to produce a configure script + +dnl Initialisation: package name and version number +AC_INIT([hdf5],[1.8.13],[starlink@jiscmail.ac.uk]) +AC_CONFIG_AUX_DIR([.]) + +dnl Require autoconf-2.50 at least +AC_PREREQ([2.69]) +dnl Require Starlink automake +AM_INIT_AUTOMAKE(1.8.2-starlink) + +dnl Sanity-check: name a file in the source directory -- if this +dnl isn't found then configure will complain +AC_CONFIG_SRCDIR([configure.ac]) + +dnl Include defaults for Starlink configurations +STAR_DEFAULTS + +dnl To configure HDF5 proper we just run ./configure in the +dnl hdf5 sub-directory. Do not invoke AC_CONFIG_SUBDIRS, +dnl since that prompts autoreconf to try to reconfigure that directory, and +dnl automake to assume it's allowed to play there, too. +( + cd hdf5 + ./configure --prefix=$prefix +) + +dnl Find required versions of the programs we need for configuration +LT_INIT +AC_PROG_MAKE_SET + +dnl Install using a staging area to get all files listed in +dnl in the manifest. Also install "starperl" script. +STAR_SPECIAL_INSTALL_COMMAND([ + ( cd hdf5; $(MAKE) DESTDIR=$$DESTDIR install ); +]) + +dnl If you wish to configure extra files, you can add them to this +dnl declaration. +AC_CONFIG_FILES([Makefile component.xml]) + +dnl This is the bit that does the actual work +AC_OUTPUT diff --git a/thirdparty/hdfgroup/hdf5/hdf5 b/thirdparty/hdfgroup/hdf5/hdf5 new file mode 160000 index 00000000000..5bdd46184f1 --- /dev/null +++ b/thirdparty/hdfgroup/hdf5/hdf5 @@ -0,0 +1 @@ +Subproject commit 5bdd46184f1878701a492002afca02deaeff6c14