To get coreutils 6.1 to build on Tru64 Unix, in addition to the minor
typo reported earlier, I had to change the prototype used for
getnameinfo() to match the on in /usr/include/netdb.h.  This ugly
patch solved the issue:


diff -ur src-6.1/lib/getaddrinfo.c src-6.1-local/lib/getaddrinfo.c
--- src-6.1/lib/getaddrinfo.c   2006-08-10 09:17:38.000000000 +0200
+++ src-6.1-local/lib/getaddrinfo.c     2006-09-18 18:28:00.000000000 +0200
@@ -322,10 +322,17 @@
     }
 }
 
+#ifdef __alpha
+int getnameinfo(const struct sockaddr *restrict sa, size_t salen,
+               char *restrict node, size_t nodelen,
+               char *restrict service, size_t servicelen,
+               int flags)
+#else
 int getnameinfo(const struct sockaddr *restrict sa, socklen_t salen,
                char *restrict node, socklen_t nodelen,
                char *restrict service, socklen_t servicelen,
                int flags)
+#endif
 {
 #ifdef WIN32_NATIVE
   if (use_win32_p ())

The problem was that the selected prototype used size_t instead of
socklen_t for salen, nodelen and servicelen.  An alternative prototype
in the header (not used in this build) used socklen for salen, and
size_t for nodelen and servicelen.

Anyway, with these patches applied, I got coreutil 6.1 building on
Tru64 Unix. :)

Friendly,
-- 
Petter Reinholdtsen


_______________________________________________
Bug-coreutils mailing list
Bug-coreutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-coreutils

Reply via email to