Re: [HACKERS] AW: compilation problem on AIX

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [HACKERS] AW: compilation problem on AIX
Дата
Msg-id 3613.908289538@sss.pgh.pa.us
обсуждение исходный текст
Ответ на AW: compilation problem on AIX  (Andreas Zeugswetter <andreas.zeugswetter@telecom.at>)
Ответы RE: [HACKERS] AW: compilation problem on AIX
Список pgsql-hackers
Andreas Zeugswetter <andreas.zeugswetter@telecom.at> writes:
> I would simply do:

> #ifndef size_t
> typedef int size_t
> #endif

> #ifndef socklen_t
> typedef size_t socklen_t
> #endif

That has no hope of working, since typedefs generally are not macros.

Marc had the right idea: a configure test is the only real way to
discover how getsockname() is declared.  A small problem is that
configure can only detect outright compilation failures, not warnings.
That's probably good enough, but people with nonstandard definitions
of getsockname may have to live with looking at warnings.

> and use socklen_t which is now standard for socket functions

It is?  The machines I have access to think the parameter is plain,
unvarnished "int".

            regards, tom lane

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

Предыдущее
От: "Marc G. Fournier"
Дата:
Сообщение: Re: [HACKERS] Dumping of views -- done!
Следующее
От: "Matthew N. Dodd"
Дата:
Сообщение: Re: [HACKERS] dynamic libraries