From cfb226b662f6f1c0d2b7ea37d41e3ded8f498edc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= Date: Mon, 7 Jul 2025 15:15:23 +0200 Subject: [PATCH 1/3] Use %_rpmmacrodir It was added in rpm-4.13.0, a long time ago. --- hdf5.spec | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/hdf5.spec b/hdf5.spec index 971b7d4..fc7dcd0 100644 --- a/hdf5.spec +++ b/hdf5.spec @@ -1,5 +1,3 @@ -%global macrosdir %(d=%{_rpmconfigdir}/macros.d; [ -d $d ] || d=%{_sysconfdir}/rpm; echo $d) - # No more Java on i686 %ifarch %{java_arches} %bcond_without java @@ -322,8 +320,8 @@ do done %endif # rpm macro for version checking -mkdir -p %{buildroot}%{macrosdir} -cat > %{buildroot}%{macrosdir}/macros.hdf5 <%{buildroot}%{_rpmmacrodir}/macros.hdf5 < Date: Mon, 7 Jul 2025 15:19:22 +0200 Subject: [PATCH 2/3] Define %_hdf5_plugin_dir for the location of (serial) plugins I'm looking into packaging of hdf5-blosc plugin and currently I'd need to hardcode the plugin path. It'd be nicer to make it available as a macro. The MPI versions use different paths. Maybe those should be exported too, e.g. as %_hdf5_plugin_${mpi}_dir? I'm leaving that out for now, it can always be added later. --- hdf5.spec | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/hdf5.spec b/hdf5.spec index fc7dcd0..823c46f 100644 --- a/hdf5.spec +++ b/hdf5.spec @@ -17,6 +17,7 @@ URL: https://www.hdfgroup.org/solutions/hdf5/ Source0: https://github.com/HDFGroup/hdf5/archive/hdf5_%{version}/hdf5-%{version}.tar.gz %global so_version 310 +%global plugin_dir %{_libdir}/hdf5/plugin Source1: h5comp # For man pages @@ -242,7 +243,7 @@ ln -s ../configure . %if %{with java} --enable-java \ %endif - --with-default-plugindir=%{_libdir}/hdf5/plugin \ + --with-default-plugindir=%{plugin_dir} \ --with-fmoddir=%{_fmoddir} sed -i -e 's| -shared | -Wl,--as-needed\0|g' libtool sed -r -i 's|^prefix=/usr|prefix=%{buildroot}/usr|' java/test/junit.sh @@ -284,7 +285,7 @@ mkdir -p %{buildroot}%{_fmoddir} %make_install -C build rm %{buildroot}%{_libdir}/*.la # Plugin directory -mkdir -p %{buildroot}%{_libdir}/hdf5/plugin +mkdir -p %{buildroot}%{plugin_dir} for mpi in %{?mpi_list} do module load mpi/$mpi-%{_arch} @@ -324,6 +325,7 @@ mkdir -p %{buildroot}%{_rpmmacrodir} cat >%{buildroot}%{_rpmmacrodir}/macros.hdf5 < Date: Thu, 24 Jul 2025 16:56:37 +0000 Subject: [PATCH 3/3] Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild