# - check missing file
#
# Conditional build:
-%bcond_without fortran2003 # Fortran 2003 interface
+%bcond_with hdfs # HDFS driver (requires libhdfs, hdfs.h)
+%bcond_without java # Java wrappers
+%bcond_without s3 # R/O S3 driver
%bcond_without szip # SZIP compression support
%bcond_with mpi # parallel version of library using MPI
#
Summary: Hierarchical Data Format 5 library
Summary(pl.UTF-8): Biblioteka HDF5 (Hierarchical Data Format 5)
Name: hdf5
-Version: 1.8.20
-Release: 2
+Version: 1.10.9
+Release: 3
License: Nearly BSD, but changed sources must be marked
Group: Libraries
-Source0: https://support.hdfgroup.org/ftp/HDF5/releases/hdf5-1.8/hdf5-%{version}/src/%{name}-%{version}.tar.bz2
-# Source0-md5: 23078d57975903e9536d1e7b299cc39c
-Patch0: %{name}-config.patch
-Patch1: %{name}-sig.patch
-Patch2: %{name}-cmake.patch
+Source0: https://support.hdfgroup.org/ftp/HDF5/releases/hdf5-1.10/hdf5-%{version}/src/%{name}-%{version}.tar.bz2
+# Source0-md5: 8f9eac14d3ee4719c3e4b52863ea42e9
+Patch0: %{name}-sig.patch
+Patch1: %{name}-cmake.patch
+Patch2: %{name}-sh.patch
URL: https://support.hdfgroup.org/HDF5/
BuildRequires: autoconf >= 2.69
BuildRequires: automake >= 1:1.11
-BuildRequires: gcc-fortran >= %{?with_fortran2003:6:4.2}%{!?with_fortran2003:5:4.0}
+%{?with_s3:BuildRequires: curl-devel}
+BuildRequires: gcc-fortran >= 6:4.2
+%{?with_java:BuildRequires: jdk}
BuildRequires: libjpeg-devel >= 6b
BuildRequires: libstdc++-devel
BuildRequires: libtool >= 2:2.2
%{?with_mpi:BuildRequires: mpi-devel}
+%{?with_s3:BuildRequires: openssl-devel}
%{?with_szip:BuildRequires: szip-devel >= 2.0}
BuildRequires: zlib-devel >= 1.1.3
-Obsoletes: hdf5_hl
+Obsoletes: hdf5_hl < 5180
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%description
Summary(pl.UTF-8): Pliki nagłówkowe biblioteki HDF5
Group: Development/Libraries
Requires: %{name} = %{version}-%{release}
+%{?with_s3:Requires: curl-devel}
+%{?with_s3:Requires: openssl-devel}
%{?with_szip:Requires: szip-devel >= 2.0}
Requires: zlib-devel
-Obsoletes: hdf5_hl-devel
-Obsoletes: hdf5_hl-tutor
+Obsoletes: hdf5_hl-devel < 5180
+Obsoletes: hdf5_hl-tutor < 5180
%description devel
Header files for HDF5 library and HDF5 documentation.
Summary(pl.UTF-8): Statyczna biblioteka HDF5
Group: Development/Libraries
Requires: %{name}-devel = %{version}-%{release}
-Obsoletes: hdf5_hl-static
+Obsoletes: hdf5_hl-static < 5180
%description static
Static version of HDF5 library.
Group: Development/Libraries
Requires: %{name}-devel = %{version}-%{release}
Requires: %{name}-fortran = %{version}-%{release}
-Requires: gcc-fortran >= %{?with_fortran2003:6:4.2}%{!?with_fortran2003:5:4.0}
+Requires: gcc-fortran >= 6:4.2
%description fortran-devel
Module and header files for HDF5 Fortran APIs (both base hdf5 and
%description progs -l pl.UTF-8
Narzędzia do konwersji z i to formatu HDF5.
+%package -n java-hdf5
+Summary: Java HDF5 Interface (JHI5)
+Summary(pl.UTF-8): Interfejs HDF5 do Javy (JHI5)
+# to replace java-hdf5 [0:]2.11/3.3.1 from hdf-java.spec
+Epoch: 1
+Group: Libraries/Java
+URL: http://portal.hdfgroup.org/display/HDFVIEW/JHI5+Design+Notes
+Requires: %{name} = %{version}-%{release}
+Requires: java-slf4j >= 1.7.25
+
+%description -n java-hdf5
+The Java Native Interface to the standard HDF5 library.
+
+%description -n java-hdf5 -l pl.UTF-8
+Natywny interfejs Javy (JNI) do biblioteki standardowej HDF5.
+
+%package -n java-hdf5-javadoc
+Summary: Javadoc documentation for Java HDF5 Interface (JHI5)
+Summary(pl.UTF-8): Dokumentacja javadoc do interfejsu HDF5 do Javy (JHI5)
+Epoch: 1
+Group: Documentation
+URL: http://portal.hdfgroup.org/display/HDFVIEW/JHI5+Design+Notes
+
+%description -n java-hdf5-javadoc
+Javadoc documentation for Java HDF5 Interface (JHI5).
+
+%description -n java-hdf5-javadoc -l pl.UTF-8
+Dokumentacja javadoc do interfejsu HDF5 do Javy (JHI5).
+
%prep
%setup -q
%patch0 -p1
--docdir=%{_docdir} \
--disable-silent-rules \
--enable-cxx \
+ --enable-direct-vfd \
--enable-fortran \
- %{?with_fortran2003:--enable-fortran2003} \
+ %{?with_java:--enable-java} \
%{?with_mpi:--enable-parallel --enable-unsupported} \
- --enable-production \
+ %{?with_s3:--enable-ros3-vfd} \
--enable-shared \
+ %{?with_hdfs:--with-libhdfs=%{_includedir},%{_libdir}} \
--with-pthread \
%{?with_szip:--with-szlib}
-# --enable-threadsafe is incompatible with cxx/fortran
+# --enable-threadsafe is unspported with cxx/fortran/java/hl
%{__make}
install -d $RPM_BUILD_ROOT%{_includedir}
%{__make} install-recursive \
- DESTDIR=$RPM_BUILD_ROOT
+ DESTDIR=$RPM_BUILD_ROOT \
+ hdf5_javadir=%{_javadir}
+
+%if %{with java}
+%{__rm} $RPM_BUILD_ROOT%{_libdir}/libhdf5_java.la
+ln -sf jarhdf5-%{version}.jar $RPM_BUILD_ROOT%{_javadir}/jarhdf5.jar
+install -d $RPM_BUILD_ROOT%{_javadocdir}
+cp -pr java/src/javadoc $RPM_BUILD_ROOT%{_javadocdir}/hdf5lib
+%endif
install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}/hl
%{__make} -C examples install-examples \
%{__make} -C hl/c++/examples install-examples \
EXAMPLEDIR=$RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}/hl/c++
-install -d $RPM_BUILD_ROOT%{_datadir}/cmake/hdf5
+install -d $RPM_BUILD_ROOT%{_libdir}/cmake/hdf5
vmajor=$(sed -ne 's/^#define H5_VERS_MAJOR\s*\([0-9]\+\).*/\1/p' src/H5public.h)
vminor=$(sed -ne 's/^#define H5_VERS_MINOR\s*\([0-9]\+\).*/\1/p' src/H5public.h)
vrel=$(sed -ne 's/^#define H5_VERS_RELEASE\s*\([0-9]\+\).*/\1/p' src/H5public.h)
-e "s,@H5_VERS_SUBRELEASE@,$vsubr," \
-e 's,@HDF5_ENABLE_PARALLEL@,OFF,' \
-e 's,@HDF5_BUILD_FORTRAN@,ON,' \
- -e 's,@HDF5_ENABLE_F2003@,%{?with_fortran2003:ON}%{!?with_fortran2003:OFF},' \
-e 's,@HDF5_BUILD_CPP_LIB@,ON,' \
-e 's,@HDF5_BUILD_TOOLS@,ON,' \
-e 's,@HDF5_BUILD_HL_LIB@,ON,' \
%{?with_mpi:-e 's,@MPI_C_INCLUDE_PATH@,%{_includedir},'} \
%{?with_mpi:-e 's,@MPI_C_LIBRARIES@,%{_libdir},'} \
-e 's,@PACKAGE_INCLUDE_INSTALL_DIR@,%{_includedir},' \
- -e 's,@PACKAGE_SHARE_INSTALL_DIR@,%{_datadir}/cmake/hdf5,' \
+ -e 's,@PACKAGE_SHARE_INSTALL_DIR@,%{_libdir}/cmake,' \
-e 's,@PACKAGE_CURRENT_BUILD_DIR@,%{_prefix},' \
- config/cmake/${f}.in > $RPM_BUILD_ROOT%{_datadir}/cmake/hdf5/$f
+ config/cmake/${f}.in > $RPM_BUILD_ROOT%{_libdir}/cmake/hdf5/$f
done
%clean
%post fortran -p /sbin/ldconfig
%postun fortran -p /sbin/ldconfig
+%post -n java-hdf5 -p /sbin/ldconfig
+%postun -n java-hdf5 -p /sbin/ldconfig
+
%files
%defattr(644,root,root,755)
-%doc COPYING README.txt release_docs/{HISTORY*.txt,RELEASE.txt}
+%doc COPYING README.md release_docs/{HISTORY*.txt,RELEASE.txt}
%attr(755,root,root) %{_libdir}/libhdf5.so.*.*.*
-%attr(755,root,root) %ghost %{_libdir}/libhdf5.so.10
+%attr(755,root,root) %ghost %{_libdir}/libhdf5.so.103
%attr(755,root,root) %{_libdir}/libhdf5_hl.so.*.*.*
-%attr(755,root,root) %ghost %{_libdir}/libhdf5_hl.so.10
+%attr(755,root,root) %ghost %{_libdir}/libhdf5_hl.so.100
# used to show configuration at runtime
%{_libdir}/libhdf5.settings
%{_includedir}/H5FDcore.h
%{_includedir}/H5FDdirect.h
%{_includedir}/H5FDfamily.h
+%{_includedir}/H5FDhdfs.h
%{_includedir}/H5FDlog.h
+%{_includedir}/H5FDmirror.h
%{_includedir}/H5FDmpi.h
%{_includedir}/H5FDmpio.h
%{_includedir}/H5FDmulti.h
%{_includedir}/H5FDpublic.h
+%{_includedir}/H5FDros3.h
%{_includedir}/H5FDsec2.h
+%{_includedir}/H5FDsplitter.h
%{_includedir}/H5FDstdio.h
+%{_includedir}/H5FDwindows.h
%{_includedir}/H5Fpublic.h
%{_includedir}/H5Gpublic.h
%{_includedir}/H5IMpublic.h
%{_includedir}/H5Include.h
%{_includedir}/H5Ipublic.h
+%{_includedir}/H5LDpublic.h
%{_includedir}/H5LTpublic.h
%{_includedir}/H5Lpublic.h
%{_includedir}/H5MMpublic.h
%{_includedir}/hdf5.h
%{_includedir}/hdf5_hl.h
-%{_datadir}/cmake/hdf5
+%{_libdir}/cmake/hdf5
%dir %{_examplesdir}/%{name}-%{version}
%{_examplesdir}/%{name}-%{version}/README
%{_examplesdir}/%{name}-%{version}/run-all-ex.sh
%files c++
%defattr(644,root,root,755)
%attr(755,root,root) %{_libdir}/libhdf5_cpp.so.*.*.*
-%attr(755,root,root) %ghost %{_libdir}/libhdf5_cpp.so.15
+%attr(755,root,root) %ghost %{_libdir}/libhdf5_cpp.so.103
%attr(755,root,root) %{_libdir}/libhdf5_hl_cpp.so.*.*.*
-%attr(755,root,root) %ghost %{_libdir}/libhdf5_hl_cpp.so.11
+%attr(755,root,root) %ghost %{_libdir}/libhdf5_hl_cpp.so.100
%files c++-devel
%defattr(644,root,root,755)
%{_includedir}/H5CompType.h
%{_includedir}/H5Cpp.h
%{_includedir}/H5CppDoc.h
+%{_includedir}/H5DaccProp.h
%{_includedir}/H5DataSet.h
%{_includedir}/H5DataSpace.h
%{_includedir}/H5DataType.h
%{_includedir}/H5IdComponent.h
%{_includedir}/H5IntType.h
%{_includedir}/H5LaccProp.h
+%{_includedir}/H5LcreatProp.h
%{_includedir}/H5Library.h
%{_includedir}/H5Location.h
%{_includedir}/H5Object.h
%files fortran
%defattr(644,root,root,755)
%attr(755,root,root) %{_libdir}/libhdf5_fortran.so.*.*.*
-%attr(755,root,root) %ghost %{_libdir}/libhdf5_fortran.so.10
+%attr(755,root,root) %ghost %{_libdir}/libhdf5_fortran.so.102
%attr(755,root,root) %{_libdir}/libhdf5hl_fortran.so.*.*.*
-%attr(755,root,root) %ghost %{_libdir}/libhdf5hl_fortran.so.10
+%attr(755,root,root) %ghost %{_libdir}/libhdf5hl_fortran.so.100
%files fortran-devel
%defattr(644,root,root,755)
%attr(755,root,root) %{_bindir}/h5fc
%attr(755,root,root) %{_libdir}/libhdf5_fortran.so
+%attr(755,root,root) %{_libdir}/libhdf5_hl_fortran.so
%attr(755,root,root) %{_libdir}/libhdf5hl_fortran.so
%{_libdir}/libhdf5_fortran.la
%{_libdir}/libhdf5hl_fortran.la
%{_includedir}/H5f90i.h
%{_includedir}/H5f90i_gen.h
-%{_includedir}/h5_dble_interface.mod
+%{_includedir}/h5_gen.mod
%{_includedir}/h5a.mod
-%{_includedir}/h5a_provisional.mod
%{_includedir}/h5d.mod
-%{_includedir}/h5d_provisional.mod
%{_includedir}/h5ds.mod
%{_includedir}/h5e.mod
-%{_includedir}/h5e_provisional.mod
%{_includedir}/h5f.mod
-%{_includedir}/h5f_provisional.mod
+%{_includedir}/h5fortkit.mod
%{_includedir}/h5fortran_types.mod
%{_includedir}/h5g.mod
%{_includedir}/h5global.mod
%{_includedir}/h5i.mod
%{_includedir}/h5im.mod
%{_includedir}/h5l.mod
-%{_includedir}/h5l_provisional.mod
%{_includedir}/h5lib.mod
-%{_includedir}/h5lib_provisional.mod
%{_includedir}/h5lt.mod
+%{_includedir}/h5lt_const.mod
%{_includedir}/h5o.mod
-%{_includedir}/h5o_provisional.mod
%{_includedir}/h5p.mod
-%{_includedir}/h5p_provisional.mod
%{_includedir}/h5r.mod
-%{_includedir}/h5r_provisional.mod
%{_includedir}/h5s.mod
%{_includedir}/h5t.mod
-%{_includedir}/h5t_provisional.mod
%{_includedir}/h5tb.mod
-%{_includedir}/h5test_kind_storage_size_mod.mod
+%{_includedir}/h5tb_const.mod
%{_includedir}/h5z.mod
%{_includedir}/hdf5.mod
%files fortran-static
%defattr(644,root,root,755)
%{_libdir}/libhdf5_fortran.a
+%{_libdir}/libhdf5_hl_fortran.a
%{_libdir}/libhdf5hl_fortran.a
%files progs
%defattr(644,root,root,755)
%attr(755,root,root) %{_bindir}/gif2h5
%attr(755,root,root) %{_bindir}/h52gif
+%attr(755,root,root) %{_bindir}/h5clear
%attr(755,root,root) %{_bindir}/h5copy
%attr(755,root,root) %{_bindir}/h5debug
%attr(755,root,root) %{_bindir}/h5diff
%attr(755,root,root) %{_bindir}/h5dump
+%attr(755,root,root) %{_bindir}/h5format_convert
%attr(755,root,root) %{_bindir}/h5import
%attr(755,root,root) %{_bindir}/h5jam
%attr(755,root,root) %{_bindir}/h5ls
%attr(755,root,root) %{_bindir}/h5repart
%attr(755,root,root) %{_bindir}/h5stat
%attr(755,root,root) %{_bindir}/h5unjam
+%attr(755,root,root) %{_bindir}/h5watch
+
+%if %{with java}
+%files -n java-hdf5
+%defattr(644,root,root,755)
+%attr(755,root,root) %{_libdir}/libhdf5_java.so.100.7.0
+%attr(755,root,root) %ghost %{_libdir}/libhdf5_java.so.100
+%attr(755,root,root) %{_libdir}/libhdf5_java.so
+%{_javadir}/jarhdf5-%{version}.jar
+%{_javadir}/jarhdf5.jar
+
+%files -n java-hdf5-javadoc
+%defattr(644,root,root,755)
+%{_javadocdir}/hdf5lib
+%endif