Re: solaris 10 with gcc 3.3.2

From: "Belbin, Peter" <PBelbin(at)McLeodUSA(dot)com>
To: 'Tom Lane' <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "Belbin, Peter" <PBelbin(at)McLeodUSA(dot)com>
Cc: pgsql-bugs(at)postgreSQL(dot)org
Subject: Re: solaris 10 with gcc 3.3.2
Date: 2004-12-16 23:15:12
Message-ID: DAC7935736BD9F4AAC601EE021D1B23403D4C188@txhouexch01.mcld.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

It seems that rather than using the /usr/include/sys/types.h, gcc 3.3.2 is
instead, using a version of the same file, located at
/usr/local/lib/gcc-lib/sparc-sun-solaris2.10/3.3.2/include/sys, which does
not have a definition for ctid_t

Presumedly there's either something bogus about the gcc for solaris 10, or
perhaps there's a way to get gcc to ignore the gcc version, and use the
'normal' version......?

-----Original Message-----
From: Tom Lane [mailto:tgl(at)sss(dot)pgh(dot)pa(dot)us]
Sent: Sunday, December 12, 2004 12:04 AM
To: Belbin, Peter
Cc: pgsql-bugs(at)postgreSQL(dot)org
Subject: Re: [BUGS] solaris 10 with gcc 3.3.2

"Belbin, Peter" <PBelbin(at)McLeodUSA(dot)com> writes:
> Should I be able to compile with gcc 3.3.2 (from sunfreeware) on solaris
10?

Yes ...

> gcc -DPOSIX -Wall -Wmissing-prototypes -Wpointer-arith -Wendif-labels
> -fno-strict-aliasing -I../../src/port -DFRONTEND -I../../src/include -c
-o
> exec.o exec.c
> In file included from /usr/include/sys/wait.h:24,
> from exec.c:26:
> /usr/include/sys/siginfo.h:259: error: parse error before "ctid_t"
> /usr/include/sys/siginfo.h:292: error: parse error before '}' token

This looks like your platform's <sys/wait.h> is not designed to be included
free-standing, but requires certain other system headers to be included
first. (This is poor practice, but seen all too often :-() A fairly likely
guess is that the missing header is <sys/types.h>.
You might be able to find out for sure by checking the man page for
waitpid() and related system calls ... or just try hacking exec.c till it
compiles.

It's likely that exec.c is not the only place missing the extra include(s).
Please send a patch after you get it all to build.

regards, tom lane

NOTICE: This electronic mail transmission may contain confidential
information and is intended only for the person(s) named. Any use, copying
or disclosure by any other person is strictly prohibited. If you have
received this transmission in error, please notify the sender via e-mail.

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2004-12-17 00:12:46 Re: Checkpoints occur too frequently
Previous Message Bruno Wolff III 2004-12-16 21:42:03 Re: BUG #1349: Gap in documentation - pg_dump