http://sourceware.org/cgi-bin/cvsweb.cgi/libc/resolv/netdb.h.diff?r1=1.47&r2=1.48&cvsroot=glibc&f=h started to define NI_MAXHOST only if _GNU_SOURCE is defined. This is wrong because NI_MAXHOST is also used on BSD systems and this change breaks lots of applications.
These seem to be defined on at least Tru64 and Solaris, too: https://www.redhat.com/archives/fedora-devel-list/2008-February/msg01231.html Perhaps they could just be undefined in strict SUSv3 case, but left defined for the common case.
Just to follow up, here is a complete list from yesterday's complete Fedora devel rebuild that failed with "error: 'NI_MAXHOST' undeclared" alpine-1.00-2.fc9.src.rpm brltty-3.9-1.1.fc9.src.rpm curl-7.18.0-1.fc9.src.rpm cyrus-imapd-2.3.9-8.fc9.src.rpm cyrus-sasl-2.1.22-11.fc9.src.rpm ghc-6.8.2-2.fc9.src.rpm gkrellm-2.3.1-2.fc9.src.rpm gnet2-2.0.7-10.fc8.src.rpm irssi-0.8.12-4.fc9.src.rpm krb5-1.6.3-4.fc9.src.rpm lash-0.5.3-3.fc8.src.rpm libevent-1.3e-1.fc9.src.rpm libident-0.32-1.fc9.src.rpm lksctp-tools-1.0.7-2.fc8.src.rpm loudmouth-1.3.3-2.fc9.src.rpm mail-notification-5.0-2.fc9.src.rpm nc6-1.0-5.fc8.src.rpm nfs-utils-lib-1.1.1-1.fc9.src.rpm openssl-0.9.8g-4.fc9.src.rpm pioneers-0.11.3-3.fc9.src.rpm rbldnsd-0.996a-4.fc8.src.rpm rsh-0.17-45.fc9.src.rpm ruby-1.8.6.111-7.fc9.src.rpm slrn-0.9.8.1pl1-7.20070716cvs.fc9.src.rpm tcp_wrappers-7.6-50.fc8.src.rpm tcpdump-3.9.8-3.fc9.src.rpm telepathy-salut-0.2.2-1.fc9.src.rpm ttcp-1.12-16.fc8.src.rpm xorg-x11-server-utils-7.3-2.fc9.src.rpm This will be a lot of patching if NI_MAXHOST is going to stay _GNU_SOURCE .
Would they work if the guard was changed to __USE_BSD?
I changed the header to define the macro when __USE_MISC is defined.