BUG #18086: compilation failed due to epoll_create1 not present

Поиск
Список
Период
Сортировка
От PG Bug reporting form
Тема BUG #18086: compilation failed due to epoll_create1 not present
Дата
Msg-id 18086-345129dec3223b38@postgresql.org
обсуждение исходный текст
Ответы Re: BUG #18086: compilation failed due to epoll_create1 not present  (Daniel Gustafsson <daniel@yesql.se>)
Список pgsql-bugs
The following bug has been logged on the website:

Bug reference:      18086
Logged by:          Duke Astar
Email address:      dukeastar@gmail.com
PostgreSQL version: 14.9
Operating system:   Linux x86
Description:

Operating system: CentOS release 5.8 (Final) - Linux dev-linuxx86
2.6.18-308.el5 #1 SMP Tue Feb 21 20:05:41 EST 2012 i686 i686
Build options: from source code using default options for 'configure'

during make, compilation failed due to missing epoll_create1,  compilation
works in postgres 13.12

Below the error.
latch.c
latch.c: In function ‘CreateWaitEventSet’:
latch.c:763: warning: implicit declaration of function ‘epoll_create1’
latch.c:763: error: ‘EPOLL_CLOEXEC’ undeclared (first use in this
function)
latch.c:763: error: (Each undeclared identifier is reported only once
latch.c:763: error: for each function it appears in.)
make[4]: *** [latch.o] Error 1
make[4]: Leaving directory
`/home2/ctaillef/pgdbg/libs/postgresql-14.9/src/backend/storage/ipc'
make[3]: *** [ipc-recursive] Error 2
make[3]: Leaving directory
`/home2/ctaillef/pgdbg/libs/postgresql-14.9/src/backend/storage'
make[2]: *** [storage-recursive] Error 2
make[2]: Leaving directory
`/home2/ctaillef/pgdbg/libs/postgresql-14.9/src/backend'
make[1]: *** [all-backend-recurse] Error 2
make[1]: Leaving directory
`/home2/ctaillef/pgdbg/libs/postgresql-14.9/src'
make: *** [all-src-recurse] Error 2

configure set macro HAVE_SYS_EPOLL_H when sys/epoll.h is present
and in src/backend/storageipc/latch.c 
HAVE_SYS_EPOLL_H define WAIT_USE_EPOLL 
and WAIT_USE_EPOLL use have 'epoll_create1' which is not present on the
operating system, only first version is present 'epoll_create'

I compared source code between 13.2 and 14.9 and I saw the ifdef
EPOLL_CLOEXEC section was removed, which was a previous constraint which use
epoll_create if not defined instead of epoll_create1 .

Workaround 
As a workaround I found that i can set -DWAIT_USE_POLL during configure to
use poll instead epoll but I think that's lead to performance issue.

Thanks by advance,
Regards


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

Предыдущее
От: John Naylor
Дата:
Сообщение: Re: BUG #18082: coredump during initdb
Следующее
От: Duke Astar
Дата:
Сообщение: Re: BUG #18082: coredump during initdb