Hi,
Drew Parsons a écrit le 02/10/2021 à 22:17 :
Package: libhdf5-openmpi-dev
Version: 1.10.7+repack-2
Severity: serious
Justification: FTBFS
Control: affects -1 src:fenics-dolfinx
The hdf5 compiler wrappers declare -lcurl as a linked library
e.g.
$ h5cc -showconfig | grep curl
Extra libraries: -lcrypto -lcurl -lpthread -lsz -lz -ldl -lm
$ h5pcc -showconfig | grep curl
Extra libraries: -lcrypto -lcurl -lsz -lz -ldl -lm
But libcurl-dev is not declared as a Dependency for libhdf5-openmpi-dev.
This means that compiling with h5pcc (or h5cc) fails unless [a]
libcurl-dev is installed.
This affects client packages using cmake that check HDF5
configuration using find_package(hdf5),
e.g. a trivial sample CMakeLists.txt
------------------
project(TEST_hdf5)
set(HDF5_PREFER_PARALLEL TRUE)
find_package(HDF5 REQUIRED COMPONENTS C)
------------------
gives the result,
-- HDF5 C compiler wrapper is unable to compile a minimal HDF5 program.
CMake Error at
/usr/share/cmake-3.21/Modules/FindPackageHandleStandardArgs.cmake:230 (message):
Could NOT find HDF5 (missing: HDF5_LIBRARIES HDF5_INCLUDE_DIRS C) (found
version "")
A current example is the broken build of fenics-dolfinx on i386,
https://buildd.debian.org/status/fetch.php?pkg=fenics-dolfinx&arch=i386&ver=1%3A0.3.0-3&stamp=1633198410&raw=0
cmake is desparately opaque, but with enough sweat and tears
(ultimately, by compiling the cmake hdf5 test file manually with
h5pcc) one can eventually discover that the problem is the -lcurl flag
in h5pcc,
CMakeFiles/hdf5$ h5pcc cmake_hdf5_test.c
/usr/bin/ld: cannot find -lcurl
I'm filing this bug against libhdf5-openmpi-dev, providing h5pcc,
since I want to use hdf5-mpi, but the problem also affects libhdf5-dev
(providing h5cc).
Since h5pcc and h5cc invoke -lcurl, libhdf5-openmpi-dev, libhdf5-dev (and
probably libhdf5-mpich-dev also) should declare Depends: libcurl-dev
Finally, since libcurl-dev is virtual, the actual declaration should be
(following hdf5's Build-Depends)
Depends: libcurl4-openssl-dev
or possibly Depends: libcurl4-openssl-dev | libcurl-dev
(the libcurl variants seem to be interchangeable)
Why h5cc needs -lcurl is a separate question! What is it trying to
download?
I guess this is a consequence of enabling access to HDF5 on S3. See #972537.
Best,
_g.