Re: Rendezvous/Bonjour broken in 8.1 beta

Поиск
Список
Период
Сортировка
От Andrew Dunstan
Тема Re: Rendezvous/Bonjour broken in 8.1 beta
Дата
Msg-id 4320CD40.2060805@dunslane.net
обсуждение исходный текст
Ответ на Re: Rendezvous/Bonjour broken in 8.1 beta  (<pmagnoli@systemevolution.it>)
Ответы Re: Rendezvous/Bonjour broken in 8.1 beta  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: Rendezvous/Bonjour broken in 8.1 beta  (Sandy McArthur <sandymac@gmail.com>)
Список pgsql-hackers

Andrew Dunstan wrote:

> Tom Lane wrote:
>
>>
>> Grumble.  Are you going to send in a patch?  I can test that the OS X
>> side still works, but I can't test Windows.
>>
>
> I can make a patch and see that it configures and compiles. But I 
> can't test it.
>
> I guess that will be an advance, though.
>
>

It gets a lot worse. The Windows SDK does not export the same API. None 
of the DNSfoo things we refer to in postmaster.c are defined in the 
supplied header file (not to mention other idiocies I was able to 
negotiate past). Apparently Apple have never heard of code portability.

I have no idea what I'm looking for in here, so I don't intend to take 
anything further - someone who actually cares about this might like to 
try ;-)

Below are shown diffs to configure.in and postmaster.c that I made to 
get as far as I did.

cheers

andrew

Index: configure.in
===================================================================
RCS file: /cvsroot/pgsql/configure.in,v
retrieving revision 1.425
diff -c -r1.425 configure.in
*** configure.in        25 Aug 2005 02:28:03 -0000      1.425
--- configure.in        8 Sep 2005 23:43:14 -0000
***************
*** 755,761 **** fi if test "$with_bonjour" = yes ; then
!   AC_CHECK_HEADER(DNSServiceDiscovery/DNSServiceDiscovery.h, [], 
[AC_MSG_ERROR([header file <DNSServiceDiscovery/DNSServiceDiscovery.h> 
is required for Bonjour])]) fi
--- 755,765 ---- fi if test "$with_bonjour" = yes ; then
!    if test "$PORTNAME" = "win32"; then
!               AC_CHECK_HEADER(dns_sd.h, [], [AC_MSG_ERROR([header file 
<dns_sd.h> is required for Bonjour])])
!    else
!               
AC_CHECK_HEADER(DNSServiceDiscovery/DNSServiceDiscovery.h, [], 
[AC_MSG_ERROR([header file <DNSServiceDiscovery/DNSServiceDiscovery.h> 
is required for Bonjour])])
!   fi fi
Index: src/backend/postmaster/postmaster.c
===================================================================
RCS file: /projects/cvsroot/pgsql/src/backend/postmaster/postmaster.c,v
retrieving revision 1.467
diff -c -r1.467 postmaster.c
*** src/backend/postmaster/postmaster.c 20 Aug 2005 23:26:17 -0000      
1.467
--- src/backend/postmaster/postmaster.c 8 Sep 2005 23:39:50 -0000
***************
*** 89,96 ****
--- 89,104 ---- #endif #ifdef USE_BONJOUR
+ #ifdef WIN32
+ #include <stdint.h>
+ #define _MSL_STDINT_H
+ #include <dns_sd.h>
+ #undef _MSL_STDINT_H
+ typedef int DNSServiceRegistrationReplyErrorType;
+ #else #include <DNSServiceDiscovery/DNSServiceDiscovery.h> #endif
+ #endif #include "access/xlog.h" #include "bootstrap/bootstrap.h"







В списке pgsql-hackers по дате отправления:

Предыдущее
От: Peter Eisentraut
Дата:
Сообщение: Re: initdb profiles
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Rendezvous/Bonjour broken in 8.1 beta