--- Begin Message ---
Package: libhdf4
Version: 4.2r4-12
Severity: important
Tags: patch
User: debian-h...@lists.debian.org
Usertags: hurd
The attached patch fixes the FTBFS problem of libhdf4-4.2r4-12 for
GNU/Hurd. It adds support for this architecture by modifying the
already existing patches autotools, shared_fortran and kfreebsd. The
patch has been built and tested on GNU/Hurd and build tested on
GNU/Linux. To, apply it the best approach would be to create new
patches and replace the existing ones with the new ones. Otherwise
debian/rules has to change. Please let me know if this is needed.
Among packages now building OK on GNU/Hurd depending on
libhdf4-dev is mathgl (when #638834 is resolved)
Thanks!
diff -ur libhdf4-4.2r4.orig//debian/patches/autotools libhdf4-4.2r4.modified//debian/patches/autotools
--- libhdf4-4.2r4.orig//debian/patches/autotools 2011-08-24 19:18:50.000000000 +0200
+++ libhdf4-4.2r4.modified//debian/patches/autotools 2011-08-25 11:48:36.000000000 +0200
@@ -2679,7 +2679,7 @@
-_LT_LIBTOOL_TAG_VARS
-# ### END LIBTOOL CONFIG
+x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
-+s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
++s390*-*linux*|s390*-*tpf*|sparc*-*linux*|*-gnu*)
+ # Find out which ABI we are using.
+ echo 'int i;' > conftest.$ac_ext
+ if AC_TRY_EVAL(ac_compile); then
@@ -2689,7 +2689,7 @@
+ x86_64-*kfreebsd*-gnu)
+ LD="${LD-ld} -m elf_i386_fbsd"
+ ;;
-+ x86_64-*linux*)
++ x86_64-*linux*|*-gnu*)
+ LD="${LD-ld} -m elf_i386"
+ ;;
+ ppc64-*linux*|powerpc64-*linux*)
@@ -4679,7 +4679,7 @@
+ ;;
+# This must be Linux ELF.
-+linux* | k*bsd*-gnu | kopensolaris*-gnu)
++linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
+ version_type=linux
+ need_lib_prefix=no
+ need_version=no
@@ -6079,7 +6079,7 @@
- # people can always --disable-shared, the test was removed, and we
- # assume the GNU/Linux dynamic linker is in use.
- dynamic_linker='GNU/Linux ld.so'
-+linux* | k*bsd*-gnu | kopensolaris*-gnu)
++linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
+ lt_cv_deplibs_check_method=pass_all
;;
@@ -7561,7 +7561,7 @@
esac
;;
- linux* | k*bsd*-gnu)
-+ linux* | k*bsd*-gnu | kopensolaris*-gnu)
++ linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
case $cc_basename in
KCC*)
# KAI C++ Compiler
@@ -7579,7 +7579,7 @@
;;
- linux* | k*bsd*-gnu)
-+ linux* | k*bsd*-gnu | kopensolaris*-gnu)
++ linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
case $cc_basename in
# old Intel for x86_64 which still supported -KPIC.
ecc*)
@@ -7587,7 +7587,7 @@
cygwin* | mingw* | cegcc*)
_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
;;
-+ linux* | k*bsd*-gnu)
++ linux* | k*bsd*-gnu | *-gnu*)
+ _LT_TAGVAR(link_all_deplibs, $1)=no
+ ;;
*)
@@ -7597,7 +7597,7 @@
openbsd*)
with_gnu_ld=no
;;
-+ linux* | k*bsd*-gnu)
++ linux* | k*bsd*-gnu | *-gnu*)
+ _LT_TAGVAR(link_all_deplibs, $1)=no
+ ;;
esac
@@ -7616,7 +7616,7 @@
;;
- gnu* | linux* | tpf* | k*bsd*-gnu)
-+ gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
++ gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
tmp_diet=no
if test "$host_os" = linux-dietlibc; then
case $cc_basename in
@@ -8340,7 +8340,7 @@
- if test "$GXX" = yes; then
- # Set up default GNU C++ configuration
-+ linux* | k*bsd*-gnu | kopensolaris*-gnu)
++ linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
+ case $cc_basename in
+ KCC*)
+ # Kuck and Associates, Inc. (KAI) C++ Compiler
@@ -29492,7 +29492,7 @@
# This must be Linux ELF.
-linux* | k*bsd*-gnu)
-+linux* | k*bsd*-gnu | kopensolaris*-gnu)
++linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
lt_cv_deplibs_check_method=pass_all
;;
@@ -31960,7 +31960,7 @@
;;
- linux* | k*bsd*-gnu)
-+ linux* | k*bsd*-gnu | kopensolaris*-gnu)
++ linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
case $cc_basename in
# old Intel for x86_64 which still supported -KPIC.
ecc*)
@@ -32161,7 +32161,7 @@
openbsd*)
with_gnu_ld=no
;;
-+ linux* | k*bsd*-gnu)
++ linux* | k*bsd*-gnu | *-gnu*)
+ link_all_deplibs=no
+ ;;
esac
@@ -32180,7 +32180,7 @@
;;
- gnu* | linux* | tpf* | k*bsd*-gnu)
-+ gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
++ gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
tmp_diet=no
if test "$host_os" = linux-dietlibc; then
case $cc_basename in
@@ -32443,7 +32443,7 @@
# This must be Linux ELF.
-linux* | k*bsd*-gnu)
-+linux* | k*bsd*-gnu | kopensolaris*-gnu)
++linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
version_type=linux
need_lib_prefix=no
need_version=no
@@ -33494,7 +33494,7 @@
;;
- linux* | k*bsd*-gnu)
-+ linux* | k*bsd*-gnu | kopensolaris*-gnu)
++ linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
case $cc_basename in
KCC*)
# Kuck and Associates, Inc. (KAI) C++ Compiler
@@ -33540,7 +33540,7 @@
esac
;;
- linux* | k*bsd*-gnu)
-+ linux* | k*bsd*-gnu | kopensolaris*-gnu)
++ linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
case $cc_basename in
KCC*)
# KAI C++ Compiler
@@ -33747,7 +33747,7 @@
cygwin* | mingw* | cegcc*)
export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;/^.*[ ]__nm__/s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
;;
-+ linux* | k*bsd*-gnu)
++ linux* | k*bsd*-gnu | *-gnu*)
+ link_all_deplibs_CXX=no
+ ;;
*)
@@ -33827,7 +33827,7 @@
# This must be Linux ELF.
-linux* | k*bsd*-gnu)
-+linux* | k*bsd*-gnu | kopensolaris*-gnu)
++linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
version_type=linux
need_lib_prefix=no
need_version=no
@@ -33996,7 +33996,7 @@
;;
- linux* | k*bsd*-gnu)
-+ linux* | k*bsd*-gnu | kopensolaris*-gnu)
++ linux* | k*bsd*-gnu | kopensolaris*-gnu| *-gnu*)
case $cc_basename in
# old Intel for x86_64 which still supported -KPIC.
ecc*)
@@ -34194,7 +34194,7 @@
openbsd*)
with_gnu_ld=no
;;
-+ linux* | k*bsd*-gnu)
++ linux* | k*bsd*-gnu | *-gnu*)
+ link_all_deplibs_F77=no
+ ;;
esac
@@ -34213,7 +34213,7 @@
;;
- gnu* | linux* | tpf* | k*bsd*-gnu)
-+ gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
++ gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
tmp_diet=no
if test "$host_os" = linux-dietlibc; then
case $cc_basename in
@@ -34461,7 +34461,7 @@
# This must be Linux ELF.
-linux* | k*bsd*-gnu)
-+linux* | k*bsd*-gnu | kopensolaris*-gnu)
++linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
version_type=linux
need_lib_prefix=no
need_version=no
@@ -35121,7 +35121,7 @@
mips*-sgi-irix5*) BAR="irix5" ;;
mips*-sgi-irix4*) BAR="irix4" ;;
- *-linux*) BAR="linux" ;;
-+ *-linux*|*-k*bsd*-gnu)BAR="linux" ;;
++ *-linux*|*-k*bsd*-gnu|*-gnu*)BAR="linux" ;;
*-freebsd*) BAR="fbsd" ;;
ia64-*-*) BAR="ia64" ;;
*-ibm-aix*) BAR="aix" ;;
diff -ur libhdf4-4.2r4.orig//debian/patches/kfreebsd libhdf4-4.2r4.modified//debian/patches/kfreebsd
--- libhdf4-4.2r4.orig//debian/patches/kfreebsd 2011-08-24 19:18:50.000000000 +0200
+++ libhdf4-4.2r4.modified//debian/patches/kfreebsd 2011-08-25 11:49:19.000000000 +0200
@@ -7,7 +7,7 @@
mips*-sgi-irix5*) BAR="irix5" ;;
mips*-sgi-irix4*) BAR="irix4" ;;
- *-linux*) BAR="linux" ;;
-+ *-linux*|*-k*bsd*-gnu)BAR="linux" ;;
++ *-linux*|*-k*bsd*-gnu|*-gnu*)BAR="linux" ;;
*-freebsd*) BAR="fbsd" ;;
ia64-*-*) BAR="ia64" ;;
*-ibm-aix*) BAR="aix" ;;
diff -ur libhdf4-4.2r4.orig//debian/patches/shared_fortran libhdf4-4.2r4.modified//debian/patches/shared_fortran
--- libhdf4-4.2r4.orig//debian/patches/shared_fortran 2011-08-24 19:18:50.000000000 +0200
+++ libhdf4-4.2r4.modified//debian/patches/shared_fortran 2011-08-25 11:53:34.000000000 +0200
@@ -4679,7 +4679,7 @@
+ ;;
+# This must be Linux ELF.
-+linux* | k*bsd*-gnu | kopensolaris*-gnu)
++linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
+ version_type=linux
+ need_lib_prefix=no
+ need_version=no
@@ -6079,7 +6079,7 @@
- # people can always --disable-shared, the test was removed, and we
- # assume the GNU/Linux dynamic linker is in use.
- dynamic_linker='GNU/Linux ld.so'
-+linux* | k*bsd*-gnu | kopensolaris*-gnu)
++linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
+ lt_cv_deplibs_check_method=pass_all
;;
@@ -7561,7 +7561,7 @@
esac
;;
- linux* | k*bsd*-gnu)
-+ linux* | k*bsd*-gnu | kopensolaris*-gnu)
++ linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
case $cc_basename in
KCC*)
# KAI C++ Compiler
@@ -7579,7 +7579,7 @@
;;
- linux* | k*bsd*-gnu)
-+ linux* | k*bsd*-gnu | kopensolaris*-gnu)
++ linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
case $cc_basename in
# old Intel for x86_64 which still supported -KPIC.
ecc*)
@@ -7587,7 +7587,7 @@
cygwin* | mingw* | cegcc*)
_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
;;
-+ linux* | k*bsd*-gnu)
++ linux* | k*bsd*-gnu | *-gnu*)
+ _LT_TAGVAR(link_all_deplibs, $1)=no
+ ;;
*)
@@ -7597,7 +7597,7 @@
openbsd*)
with_gnu_ld=no
;;
-+ linux* | k*bsd*-gnu)
++ linux* | k*bsd*-gnu | *-gnu*)
+ _LT_TAGVAR(link_all_deplibs, $1)=no
+ ;;
esac
@@ -7616,7 +7616,7 @@
;;
- gnu* | linux* | tpf* | k*bsd*-gnu)
-+ gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
++ gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
tmp_diet=no
if test "$host_os" = linux-dietlibc; then
case $cc_basename in
@@ -8340,7 +8340,7 @@
- if test "$GXX" = yes; then
- # Set up default GNU C++ configuration
-+ linux* | k*bsd*-gnu | kopensolaris*-gnu)
++ linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
+ case $cc_basename in
+ KCC*)
+ # Kuck and Associates, Inc. (KAI) C++ Compiler
@@ -29522,7 +29522,7 @@
# This must be Linux ELF.
-linux* | k*bsd*-gnu)
-+linux* | k*bsd*-gnu | kopensolaris*-gnu)
++linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
lt_cv_deplibs_check_method=pass_all
;;
@@ -31990,7 +31990,7 @@
;;
- linux* | k*bsd*-gnu)
-+ linux* | k*bsd*-gnu | kopensolaris*-gnu)
++ linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
case $cc_basename in
# old Intel for x86_64 which still supported -KPIC.
ecc*)
@@ -32191,7 +32191,7 @@
openbsd*)
with_gnu_ld=no
;;
-+ linux* | k*bsd*-gnu)
++ linux* | k*bsd*-gnu | *-gnu*)
+ link_all_deplibs=no
+ ;;
esac
@@ -32210,7 +32210,7 @@
;;
- gnu* | linux* | tpf* | k*bsd*-gnu)
-+ gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
++ gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
tmp_diet=no
if test "$host_os" = linux-dietlibc; then
case $cc_basename in
@@ -32473,7 +32473,7 @@
# This must be Linux ELF.
-linux* | k*bsd*-gnu)
-+linux* | k*bsd*-gnu | kopensolaris*-gnu)
++linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
version_type=linux
need_lib_prefix=no
need_version=no
@@ -33524,7 +33524,7 @@
;;
- linux* | k*bsd*-gnu)
-+ linux* | k*bsd*-gnu | kopensolaris*-gnu)
++ linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
case $cc_basename in
KCC*)
# Kuck and Associates, Inc. (KAI) C++ Compiler
@@ -33570,7 +33570,7 @@
esac
;;
- linux* | k*bsd*-gnu)
-+ linux* | k*bsd*-gnu | kopensolaris*-gnu)
++ linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
case $cc_basename in
KCC*)
# KAI C++ Compiler
@@ -33777,7 +33777,7 @@
cygwin* | mingw* | cegcc*)
export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;/^.*[ ]__nm__/s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
;;
-+ linux* | k*bsd*-gnu)
++ linux* | k*bsd*-gnu | *-gnu*)
+ link_all_deplibs_CXX=no
+ ;;
*)
@@ -33857,7 +33857,7 @@
# This must be Linux ELF.
-linux* | k*bsd*-gnu)
-+linux* | k*bsd*-gnu | kopensolaris*-gnu)
++linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
version_type=linux
need_lib_prefix=no
need_version=no
@@ -34026,7 +34026,7 @@
;;
- linux* | k*bsd*-gnu)
-+ linux* | k*bsd*-gnu | kopensolaris*-gnu)
++ linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
case $cc_basename in
# old Intel for x86_64 which still supported -KPIC.
ecc*)
@@ -34224,7 +34224,7 @@
openbsd*)
with_gnu_ld=no
;;
-+ linux* | k*bsd*-gnu)
++ linux* | k*bsd*-gnu | *-gnu*)
+ link_all_deplibs_F77=no
+ ;;
esac
@@ -34243,7 +34243,7 @@
;;
- gnu* | linux* | tpf* | k*bsd*-gnu)
-+ gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
++ gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
tmp_diet=no
if test "$host_os" = linux-dietlibc; then
case $cc_basename in
@@ -34491,7 +34491,7 @@
# This must be Linux ELF.
-linux* | k*bsd*-gnu)
-+linux* | k*bsd*-gnu | kopensolaris*-gnu)
++linux* | k*bsd*-gnu | kopensolaris*-gnu | *-gnu*)
version_type=linux
need_lib_prefix=no
need_version=no
@@ -35151,7 +35151,7 @@
mips*-sgi-irix5*) BAR="irix5" ;;
mips*-sgi-irix4*) BAR="irix4" ;;
- *-linux*) BAR="linux" ;;
-+ *-linux*|*-k*bsd*-gnu)BAR="linux" ;;
++ *-linux*|*-k*bsd*-gnu|*-gnu*)BAR="linux" ;;
*-freebsd*) BAR="fbsd" ;;
ia64-*-*) BAR="ia64" ;;
*-ibm-aix*) BAR="aix" ;;
--- End Message ---