    AC_DEFINE(HAVE_CONNECT, 1,
  [Define if you have the connect function.]))
  dnl no need to search nsl for gethostbyname here since we should have
+diff -urN cvs-1.12.13/lib/getaddrinfo.h cvs-1.12.13-haiku/lib/getaddrinfo.h
+--- cvs-1.12.13/lib/getaddrinfo.h	2005-09-08 15:55:53.000000000 +0000
++++ cvs-1.12.13-haiku/lib/getaddrinfo.h	2008-09-30 19:33:49.000000000 +0000
+@@ -26,7 +26,7 @@
+ # include <netdb.h>
+ 
+ # if !HAVE_GETADDRINFO
+-
++#ifndef __HAIKU__
+ /* Structure to contain information about address of a service provider.  */
+ struct addrinfo
+ {
+@@ -61,6 +61,8 @@
+ # define EAI_ADDRFAMILY	  -9	/* Address family for NAME not supported.  */
+ # define EAI_MEMORY	  -10	/* Memory allocation failure.  */
+ # define EAI_SYSTEM	  -11	/* System error returned in `errno'.  */
++#endif
++
+ # define EAI_OVERFLOW	  -12	/* Argument buffer overflow.  */
+ # ifdef __USE_GNU
+ #  define EAI_INPROGRESS  -100	/* Processing request in progress.  */
 diff -urN cvs-1.12.13/lib/getpass.c cvs-1.12.13-haiku/lib/getpass.c
 --- cvs-1.12.13/lib/getpass.c	2005-09-19 21:12:21.000000000 +0000
-+++ cvs-1.12.13-haiku/lib/getpass.c	2008-09-29 12:14:49.000000000 +0000
-@@ -104,7 +104,7 @@
++++ cvs-1.12.13-haiku/lib/getpass.c	2008-09-30 19:53:05.000000000 +0000
+@@ -104,8 +104,9 @@
    else
      {
        /* We do the locking ourselves.  */
--      __fsetlocking (tty, FSETLOCKING_BYCALLER);
-+//      __fsetlocking (tty, FSETLOCKING_BYCALLER);
- 
++#ifdef __HAIKU__
+       __fsetlocking (tty, FSETLOCKING_BYCALLER);
+-
++#endif
        out = in = tty;
      }
+ 
 diff -urN cvs-1.12.13/lib/stdbool_.h cvs-1.12.13-haiku/lib/stdbool_.h
 --- cvs-1.12.13/lib/stdbool_.h	2005-05-23 17:44:32.000000000 +0000
-+++ cvs-1.12.13-haiku/lib/stdbool_.h	2008-09-29 13:38:31.000000000 +0000
++++ cvs-1.12.13-haiku/lib/stdbool_.h	2008-09-30 18:38:24.000000000 +0000
 @@ -55,7 +55,7 @@
  
  /* BeOS <sys/socket.h> already #defines false 0, true 1.  We use the same

 /* confdefs.h.  */
diff -urN cvs-1.12.13/configure.in cvs-1.12.13-haiku/configure.in
--- cvs-1.12.13/configure.in	2005-10-03 13:34:45.000000000 +0000
+++ cvs-1.12.13-haiku/configure.in	2008-09-29 13:32:01.000000000 +0000
@@ -515,7 +515,7 @@
 
 # Try to find connect and gethostbyname.

diff -urN cvs-1.12.13/configure cvs-1.12.13-haiku/configure
--- cvs-1.12.13/configure	2005-10-03 13:36:42.000000000 +0000
+++ cvs-1.12.13-haiku/configure	2008-09-30 18:38:24.000000000 +0000
@@ -37138,7 +37138,7 @@
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
