Your message dated Tue, 28 Jul 2026 12:18:43 +0000
with message-id <[email protected]>
and subject line Bug#1121629: fixed in libhdf4 4.3.1-3
has caused the Debian Bug report #1121629,
regarding libhdf4 FTCBFS: multiple reasons
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
1121629: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1121629
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Source: libhdf4
Version: 4.3.1-2
Tags: patch
User: [email protected]
Usertags: ftcbfs

libhdf4 fails to cross build from source for multiple reasons. When not
building for armhf, the failure is selecting a build architecture
compiler. This is due to the upstream build system using its own
compiler detection rather than relying on the one provided by autoconf.
I am aware that you mentioned switching to CMake, but it seems like
exporting suitable CC+CXX would still be a worthwhile change in the mean
time. You can drop that once switching to CMake.

When it comes to armhf, the use of gcc-14 is implemented in a way
breaking cross builds. Toolchain build dependencies should be annotated
with -for-build or -for-host (depending on what is appropriate). The
conditional in debian/rules branches on the build architecture when it
should be branching on the host architecture and the assigned compilers
fail to account for the triplet. All of these changes apply beyond the
switch to CMake.

Once fixing these, the next build failure arises from running the built
ncgen. I am not familiar with this tool, but it ends up getting
installed into hdf4-tools, which is marked as Multi-Arch: foreign. This
suggests that we should likely be using the installed version for cross
builds only. Do you concur here?

In any case, I think we should defer the surgery about ncgen until after
the migration to CMake has proceeded. This bug report is not meant to
cover the ncgen aspect.

Helmut
diff -Nru libhdf4-4.3.1/debian/changelog libhdf4-4.3.1/debian/changelog
--- libhdf4-4.3.1/debian/changelog      2025-11-28 10:31:02.000000000 +0100
+++ libhdf4-4.3.1/debian/changelog      2025-11-29 13:05:43.000000000 +0100
@@ -1,3 +1,13 @@
+libhdf4 (4.3.1-2.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Improve cross building. (Closes: #-1)
+    + Build depend on -for-host variants of the toolchain.
+    + Fix build vs host confusion.
+    + Always export CC and CXX as the upstream build system wrongly guesses it.
+
+ -- Helmut Grohne <[email protected]>  Sat, 29 Nov 2025 13:05:43 +0100
+
 libhdf4 (4.3.1-2) unstable; urgency=medium
 
   * Team upload.
diff -Nru libhdf4-4.3.1/debian/control libhdf4-4.3.1/debian/control
--- libhdf4-4.3.1/debian/control        2025-11-28 10:30:24.000000000 +0100
+++ libhdf4-4.3.1/debian/control        2025-11-29 13:01:26.000000000 +0100
@@ -8,8 +8,8 @@
                chrpath,
                debhelper-compat (= 13),
                flex,
-               gcc-14 [armhf],
-               g++-14 [armhf],
+               gcc-14-for-host [armhf],
+               g++-14-for-host [armhf],
                libaec-dev,
                libjpeg-dev,
                libtirpc-dev,
diff -Nru libhdf4-4.3.1/debian/rules libhdf4-4.3.1/debian/rules
--- libhdf4-4.3.1/debian/rules  2025-11-28 10:30:12.000000000 +0100
+++ libhdf4-4.3.1/debian/rules  2025-11-29 13:05:30.000000000 +0100
@@ -13,16 +13,19 @@
 
 UPSTREAM_VERSION = $(shell echo $(DEB_VERSION_UPSTREAM) | sed -e 's/\+.*//')
 
-DEB_BUILD_ARCH ?= $(shell dpkg-architecture -qDEB_BUILD_ARCH)
-
 export DEB_CPPFLAGS_MAINT_APPEND = -I/usr/include/tirpc/
 export DEB_LDFLAGS_MAINT_APPEND = -ltirpc
 
-ifneq (,$(filter $(DEB_BUILD_ARCH),armhf))
-export CC=gcc-14
-export CXX=g++-14
+ifneq (,$(filter $(DEB_HOST_ARCH),armhf))
+CC=$(DEB_HOST_GNU_TYPE)-gcc-14
+CXX=$(DEB_HOST_GNU_TYPE)-g++-14
 endif
 
+# The upstream buildsystem defaults to CC=gcc in cross builds.
+include /usr/share/dpkg/buildtools.mk
+export CC
+export CXX
+
 ifneq (,$(findstring verbose,$(DEB_BUILD_OPTIONS)))
    DH_VERBOSE=1
    export DH_VERBOSE

--- End Message ---
--- Begin Message ---
Source: libhdf4
Source-Version: 4.3.1-3
Done: Bas Couwenberg <[email protected]>

We believe that the bug you reported is fixed in the latest version of
libhdf4, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Bas Couwenberg <[email protected]> (supplier of updated libhdf4 package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

Format: 1.8
Date: Tue, 28 Jul 2026 13:03:33 +0200
Source: libhdf4
Architecture: source
Version: 4.3.1-3
Distribution: unstable
Urgency: medium
Maintainer: Debian GIS Project <[email protected]>
Changed-By: Bas Couwenberg <[email protected]>
Closes: 1121629 1129510
Changes:
 libhdf4 (4.3.1-3) unstable; urgency=medium
 .
   * Team upload.
 .
   [ Helmut Grohne ]
   * Improve cross building. (Closes: #1121629)
     + Fix build vs host confusion.
     + Always export CC and CXX as the upstream build system wrongly guesses it.
 .
   [ Bas Couwenberg ]
   * Drop Priority: optional, default since dpkg 1.22.13.
   * Bump Standards-Version to 4.7.4, changes: priority.
   * Use -std=c17 on armhf to fix FTBFS with GCC 15.
     Thanks to Emanuele Rocca.
     (closes: #1129510)
Checksums-Sha1:
 ac57b28cdf39c7f6414c3b440c7d975404e1bfb1 2139 libhdf4_4.3.1-3.dsc
 f63c95da8f000f2adad5c3a11d4fbc833776e6ce 38216 libhdf4_4.3.1-3.debian.tar.xz
 c4f6c5a06ed3e58df7d8d124f7107f8d46036b16 8836 libhdf4_4.3.1-3_amd64.buildinfo
Checksums-Sha256:
 d693728d34323ae3403c6cd27b25596649a78558423e020bb6a306f5c5d37886 2139 
libhdf4_4.3.1-3.dsc
 d2b557ba3535b66850384f114873c8703ab585fa0446211f68105b2da494d060 38216 
libhdf4_4.3.1-3.debian.tar.xz
 8aae7ab7eda8d80ffce88548991439632a495411785fc09516a0c080d07fe6dc 8836 
libhdf4_4.3.1-3_amd64.buildinfo
Files:
 77a145969297b2c7f8ed1b21173d0c0d 2139 graphics optional libhdf4_4.3.1-3.dsc
 d0b7be650b0a732ed5d2fa93938c2f37 38216 graphics optional 
libhdf4_4.3.1-3.debian.tar.xz
 0f9d176fc4dc7c7129481b5cf579b972 8836 graphics optional 
libhdf4_4.3.1-3_amd64.buildinfo

-----BEGIN PGP SIGNATURE-----

iQIzBAEBCgAdFiEEgYLeQXBWQI1hRlDRZ1DxCuiNSvEFAmpomm8ACgkQZ1DxCuiN
SvHq5RAArqbR/f4jA7hR3CIv6cXAwkrXGTZsk0QnlmsGxy6ldfAwOYj+7BkfhQcR
XGJVccVZpAhZBEYL68q6AZh8KTXoltwM+4AcIPt5Fv3HB3fXNiVrm269d6GJNGSM
2MT7kqKiue9j9ebpHD9ctePbxiD8n4dNRGaFpmUhoLQZoTXkWme0vdSU0JTVPiHG
gQ0Cwoq8b27oH62D2Abh6g3Uw7lpQ3TxsWIwsbb/zNdvJ21z7aStJErUTnXMGv57
+N5kY2A98LzlRYhoAiqG8tcIGPxYTe2v2BE3KJk6nNWjuhDcTG3FkpAas9+ysNEo
9IhrV7J4NEgvlsUSjpIk8UCe52wgF6yM29/cGe22x6g/E8GgLlrP8Bwesw/1wIQ+
Y2VngMV4CUdwA6V6/yQCnaht9gw59g+ZVh9sGzWCq6UJiuE4vNnrd8CDbPeGhNIB
uYfG0K7aTxlydhiJ43FkoPMJwKvG17tLi1nJbqXZWF4tYADopoc6HSj0p7zE9Y36
uF9ebWe7o4enCvmKn79QF63vwvcM7e8lulixKCcb+MQyxbv7fdJHItit3sL+2TV8
PyQWoOS+cuyhdt9yY7AM+VK1pGbTI4t8LZK6NdOU/0V6q/fREj6s9BL4Tb5NmnJf
eq16OaqYxiK8M8ghFMPjvx6ZiIsHBdWdShfAcTdLZn0OZRfg1m4=
=ypbO
-----END PGP SIGNATURE-----

Attachment: pgpUW8sl5qjay.pgp
Description: PGP signature


--- End Message ---

Reply via email to