Re: narwhal and PGDLLIMPORT

Поиск
Список
Период
Сортировка
От Andres Freund
Тема Re: narwhal and PGDLLIMPORT
Дата
Msg-id 20140203143402.GE1225@awork2.anarazel.de
обсуждение исходный текст
Ответ на Re: narwhal and PGDLLIMPORT  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On 2014-02-03 09:25:57 -0500, Tom Lane wrote:
> Andres Freund <andres@2ndquadrant.com> writes:
> > What about the completely crazy thing of simply redefining export to
> > include the declspec on windows for backend build? That will possibly
> > blow up the size of the .def files et al a bit, but I have little mercy
> > with that.
> 
> You mean "#define extern extern PGDLLIMPORT" ?  What will that do to
> function declarations that have "extern"?

As far as I understand it's perfectly ok to have that on
functions. http://msdn.microsoft.com/en-us/library/aa271769%28v=vs.60%29.aspx
even claims it's faster in some scenarios.

> Are we sure C compilers
> are smart enough to not go into an infinite loop on such a macro?

I'd be really surprised if there were any that wouldn't completely choke
on pg otherwise. Especially not as we are only talking about windows
where only gcc and msvc is supported these days.

Greetings,

Andres Freund

-- Andres Freund                       http://www.2ndQuadrant.com/PostgreSQL Development, 24x7 Support, Training &
Services



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

Предыдущее
От: Alexander Korotkov
Дата:
Сообщение: Re: GIN improvements part2: fast scan
Следующее
От: amihay gonen
Дата:
Сообщение: Q: How to use indexer api smartly