Re: [HACKERS] Patch: update Bonjour support to the newer non-deprecated API

2009-09-08 Thread Alvaro Herrera
Tom Lane wrote: > Alvaro Herrera writes: > > Should we inject some sort of compile-time rejection of the > > compatibility API? Like, say > > > #ifdef AVAHI_SERVICE_COOKIE > > #error The Avahi implementation is incompatible > > #endif > > > inside some #ifdef BONJOUR block? > > I looked into t

Re: [HACKERS] Patch: update Bonjour support to the newer non-deprecated API

2009-09-08 Thread Tom Lane
Alvaro Herrera writes: > Should we inject some sort of compile-time rejection of the > compatibility API? Like, say > #ifdef AVAHI_SERVICE_COOKIE > #error The Avahi implementation is incompatible > #endif > inside some #ifdef BONJOUR block? I looked into this and couldn't find any obvious cand

Re: [HACKERS] Patch: update Bonjour support to the newer non-deprecated API

2009-09-08 Thread Tom Lane
I wrote: > I've grown a bit tired of reading the "'DNSServiceRegistrationCreate' is > deprecated" warnings in OS X builds, and I'm also wondering whether any > of the recently reported problems with Snow Leopard might trace to our > use of an API that Apple has been deprecating since 2003. Hence,

Re: [HACKERS] Patch: update Bonjour support to the newer non-deprecated API

2009-09-07 Thread Alvaro Herrera
Tom Lane wrote: > Alvaro Herrera writes: > > The source is here: > > http://avahi.sourcearchive.com/documentation/0.6.25-1ubuntu1/avahi-compat-libdns__sd_2compat_8c-source.html > > After reading that code, I am content to remain forcibly non compatible > with it. If we relied on this it would in

Re: [HACKERS] Patch: update Bonjour support to the newer non-deprecated API

2009-09-07 Thread Tom Lane
Alvaro Herrera writes: > The source is here: > http://avahi.sourcearchive.com/documentation/0.6.25-1ubuntu1/avahi-compat-libdns__sd_2compat_8c-source.html After reading that code, I am content to remain forcibly non compatible with it. If we relied on this it would inject threading into the post

Re: [HACKERS] Patch: update Bonjour support to the newer non-deprecated API

2009-09-07 Thread Tom Lane
Alvaro Herrera writes: > Tom Lane wrote: >> Hmm, I read in their documentation that the dns_sd.h interface was >> deprecated, but not that it had been intentionally disabled. > I think it is supposed to work; the code suggests that it should. I > can't quite find out what the error number is sup

Re: [HACKERS] Patch: update Bonjour support to the newer non-deprecated API

2009-09-07 Thread Tom Lane
David Fetter writes: > On Mon, Sep 07, 2009 at 12:50:37PM -0400, Tom Lane wrote: >> The two possibilities for that seem to be to change the meaning of >> bonjour_name = '' (have it mean "no advertisement" instead of >> "default to service name = computer's name"), or to add a separate >> boolean G

Re: [HACKERS] Patch: update Bonjour support to the newer non-deprecated API

2009-09-07 Thread David Fetter
On Mon, Sep 07, 2009 at 12:50:37PM -0400, Tom Lane wrote: > > The two possibilities for that seem to be to change the meaning of > bonjour_name = '' (have it mean "no advertisement" instead of > "default to service name = computer's name"), or to add a separate > boolean GUC. If the latter, is th

Re: [HACKERS] Patch: update Bonjour support to the newer non-deprecated API

2009-09-07 Thread Alvaro Herrera
Tom Lane wrote: > Alvaro Herrera writes: > > *** WARNING *** The program 'postgres' uses the Apple Bonjour compatibility > > layer of Avahi. > > *** WARNING *** Please fix your application to use the native API of Avahi! > > *** WARNING *** For more information see > >

Re: [HACKERS] Patch: update Bonjour support to the newer non-deprecated API

2009-09-07 Thread Tom Lane
Alvaro Herrera writes: > *** WARNING *** The program 'postgres' uses the Apple Bonjour compatibility > layer of Avahi. > *** WARNING *** Please fix your application to use the native API of Avahi! > *** WARNING *** For more information see >

Re: [HACKERS] Patch: update Bonjour support to the newer non-deprecated API

2009-09-07 Thread Alvaro Herrera
Alvaro Herrera wrote: > Hmm, but it doesn't link unless I manually add -ldns_sd to the link > command. And then it throws a warning on start, and fails to work anyway: *** WARNING *** The program 'postgres' uses the Apple Bonjour compatibility layer of Avahi. *** WARNING *** Please fix your app

Re: [HACKERS] Patch: update Bonjour support to the newer non-deprecated API

2009-09-07 Thread Alvaro Herrera
Alvaro Herrera wrote: > Tom Lane wrote: > > > In principle this might enable use of Bonjour on non-Apple OSes, but > > I'm not personally interested enough to test that ... > > With this patch and Avahi's compatibility headers I can successfully > compile --enable-bonjour on my Debian system. I

Re: [HACKERS] Patch: update Bonjour support to the newer non-deprecated API

2009-09-07 Thread Alvaro Herrera
Tom Lane wrote: > In principle this might enable use of Bonjour on non-Apple OSes, but > I'm not personally interested enough to test that ... With this patch and Avahi's compatibility headers I can successfully compile --enable-bonjour on my Debian system. I haven't tested it. -- Alvaro Herre

Re: [HACKERS] Patch: update Bonjour support to the newer non-deprecated API

2009-09-06 Thread David E. Wheeler
On Sep 6, 2009, at 8:17 PM, Tom Lane wrote: In principle this might enable use of Bonjour on non-Apple OSes, but I'm not personally interested enough to test that ... Comments, objections? +1 Seems like a no-brainer. Best, David -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgre

[HACKERS] Patch: update Bonjour support to the newer non-deprecated API

2009-09-06 Thread Tom Lane
I've grown a bit tired of reading the "'DNSServiceRegistrationCreate' is deprecated" warnings in OS X builds, and I'm also wondering whether any of the recently reported problems with Snow Leopard might trace to our use of an API that Apple has been deprecating since 2003. Hence, attached is a pat