#1140089 cctbx: FTBFS against HDF5 2.1.0 - cannot find -lhdf5: No such file or directory

Package:
src:cctbx
Source:
src:cctbx
Submitter:
Gilles Filippini
Date:
2026-06-15 16:03:01 UTC
Severity:
normal
Tags:
#1140089#5
Date:
2026-06-15 15:53:37 UTC
From:
To:
Hi,

During a test rebuild of HDF5's reverse dependcies against HDF5 2.1.0
currently in experimental, cctbx FTBFS with:

g++ -o lib/dxtbx_format_image_ext.so.0.0.1 -shared -rdynamic -std=c++14 -Wl,-soname=dxtbx_format_image_ext.so.0 dxtbx/src/dxtbx/format/boost_python/image_ext.o dxtbx/src/dxtbx/format/boost_python/cbf_read_buffer.o -L/usr/lib -L/usr/lib64 -L/usr/lib/x86_64-linux-gnu -Llib -L/build/cctbx-TF7EYi/cctbx-2026.4+ds2+~3.28.0+ds1/lib -Llib -L/build/cctbx-TF7EYi/cctbx-2026.4+ds2+~3.28.0+ds1/lib -L/build/cctbx-TF7EYi/cctbx-2026.4+ds2+~3.28.0+ds1/.pybuild/cpython3_3.13_cctbx/base/lib -Llib -L/build/cctbx-TF7EYi/cctbx-2026.4+ds2+~3.28.0+ds1/lib -L/usr/lib -lm -ltiff -lboost_python313 -lcbf -lhdf5
/usr/bin/x86_64-linux-gnu-ld.bfd: cannot find -lhdf5: No such file or directory
collect2: error: ld returned 1 exit status
scons: *** [lib/dxtbx_format_image_ext.so.0.0.1] Error 1


Tha attached patch has a workaround for this issue and works with both
HDF5 1.14.6 in unstable and HDF5 2.1.0 in experimental.

But ideally the same technique should be use in dxtbx/SConscript than
in cbflib_adaptbx/SConscript, using pkg-config on the hdf5 module to
retrieve the correct build flags for building against HDF5.

Best,
_g.

- -- System Information:
Debian Release: 12.0
Architecture: amd64 (x86_64)

Kernel: Linux 6.1.0-44-amd64 (SMP w/12 CPU threads; PREEMPT)
Kernel taint flags: TAINT_OOT_MODULE, TAINT_UNSIGNED_MODULE
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8), LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled
-----BEGIN PGP SIGNATURE-----

iQEzBAEBCgAdFiEEoJObzArDE05WtIyR7+hsbH/+z4MFAmowH/gACgkQ7+hsbH/+
z4OaZAf+Ko23TNIX1c4Ux7d1GVm79niSFA6x24mw3dV5no+xbnYppenVC7GzHGzR
G9Zy5aCJZm6b3LPXNo7NeAUhoa2CIcgVhb457lkPRSTAjfFbDAmlPTwRvafAxL3p
LAK3hu6AUmyqBC/WHTVsRktehXOVL0gKF2LzaRyxCXyz8KFbGdS5EN7BbC48wKMM
O+ltl/WfAt8uTW5R+3WYmJhYs8KC70QjOK4yYQ+96TsBPXAbGatD/0YbjGodsxnW
v4nDiEFUdm9Bu9PwVz1mEslt0hZYBQjwjRAbx1BBi8Tvg35S4zh+Z5ojGUM9iJ9B
U/dkXXQhD6m48h1pH6Xw+hEbMvInqQ==
=NfcT
-----END PGP SIGNATURE-----