mirror of
https://github.com/postgres/postgres.git
synced 2025-07-28 23:42:10 +03:00
Remove configure probe for sys/resource.h and refactor.
<sys/resource.h> is in SUSv2 and is on all targeted Unix systems. We have a replacement for getrusage() on Windows, so let's just move its declarations into src/include/port/win32/sys/resource.h so that we can use a standard-looking #include. Also remove an obsolete reference to CLK_TCK. Also rename src/port/getrusage.c to win32getrusage.c, following the convention for Windows-only fallback code. Reviewed-by: Tom Lane <tgl@sss.pgh.pa.us> Discussion: https://postgr.es/m/CA%2BhUKG%2BL_3brvh%3D8e0BW_VfX9h7MtwgN%3DnFHP5o7X2oZucY9dg%40mail.gmail.com
This commit is contained in:
@ -1459,7 +1459,6 @@ AC_CHECK_HEADERS(m4_normalize([
|
||||
sys/personality.h
|
||||
sys/prctl.h
|
||||
sys/procctl.h
|
||||
sys/resource.h
|
||||
sys/signalfd.h
|
||||
sys/sockio.h
|
||||
sys/ucred.h
|
||||
@ -1897,7 +1896,6 @@ fi
|
||||
if test "$PORTNAME" = "win32"; then
|
||||
AC_CHECK_FUNCS(_configthreadlocale)
|
||||
AC_LIBOBJ(dirmod)
|
||||
AC_LIBOBJ(getrusage)
|
||||
AC_LIBOBJ(kill)
|
||||
AC_LIBOBJ(open)
|
||||
AC_LIBOBJ(system)
|
||||
@ -1905,6 +1903,7 @@ if test "$PORTNAME" = "win32"; then
|
||||
AC_LIBOBJ(win32env)
|
||||
AC_LIBOBJ(win32error)
|
||||
AC_LIBOBJ(win32fdatasync)
|
||||
AC_LIBOBJ(win32getrusage)
|
||||
AC_LIBOBJ(win32link)
|
||||
AC_LIBOBJ(win32ntdll)
|
||||
AC_LIBOBJ(win32pread)
|
||||
|
Reference in New Issue
Block a user