From: | Bruce Momjian <bruce(at)momjian(dot)us> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: [COMMITTERS] pgsql: Add include needed for new |
Date: | 2006-10-08 18:14:03 |
Message-ID: | 200610081814.k98IE3f21047@momjian.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers pgsql-hackers |
Tom Lane wrote:
> momjian(at)postgresql(dot)org (Bruce Momjian) writes:
> > Add include needed for new getrusage() call.
>
> If that's actually needed, how did the code build before? It's always
> included sys/resource.h, except possibly on machines without getrusage
> ... are there any? I was thinking rusagestub was dead code, myself.
Uh, all I know is that it started failing yesterday. The failure I got
was:
gcc -O2 -Wall -Wmissing-prototypes -Wpointer-arith -Winline
-fno-strict-aliasing -O1 -Wall -Wmissing-prototypes
-Wmissing-declarations -Wpointer-arith -Wcast-align
-I../../../src/include -I/usr/local/include/readline
-I/usr/contrib/include -DWIN32_STACK_RLIMIT=4194304 -c -o postgres.o
postgres.c
In file included from postgres.c:31:
/usr/include/sys/resource.h:63: field `ru_utime' has incomplete type
/usr/include/sys/resource.h:64: field `ru_stime' has incomplete type
gmake: *** [postgres.o] Error 1
and resource.h has:
struct rusage {
struct timeval ru_utime; /* user time used */
struct timeval ru_stime; /* system time used */
so it is timeval it wanted. But I have:
#define HAVE_GETRUSAGE 1
For me, 'struct timeval' is coming in via #include "libpq/libpq.h", but
of course that is _after_ the inclusion of resource.h. Not sure where
you see that sys/resource.h was always there. Looking at the CVS diffs
I see it added only in the past day.
--
Bruce Momjian bruce(at)momjian(dot)us
EnterpriseDB http://www.enterprisedb.com
+ If your life is a hard drive, Christ can be your backup. +
From | Date | Subject | |
---|---|---|---|
Next Message | Bruce Momjian | 2006-10-08 18:15:53 | pgsql: In release notes, mention that multi-line history saving does not |
Previous Message | Tom Lane | 2006-10-08 17:57:31 | Re: [COMMITTERS] pgsql: Add include needed for new getrusage() call. |
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2006-10-08 18:29:25 | Re: Use non-deprecated APIs for dynloader/darwin.c |
Previous Message | Bruce Momjian | 2006-10-08 18:03:55 | Re: The improvement for psql of 8.2beta1 not |