Обсуждение: aix build question re: duplicate symbol warning

Поиск
Список
Период
Сортировка

aix build question re: duplicate symbol warning

От
Kevin Murphy
Дата:
Hi all,

I'm trying to build PG 8.1 beta on an AIX server.

The 'make' finishes without errors, but I'm getting lots of duplicate
symbol warnings like the following one.  What am I to make of these?

gcc -O2 -Wall -Wmissing-prototypes -Wpointer-arith -Winline
-fno-strict-aliasing   -Wl,-bnoentry -Wl,-H512 -Wl,-bM:SRE -o libpq.\
so libpq.a -L../../../src/port    -L../../../src/port -lnsl
-Wl,-bI:../../../src/backend/postgres.imp -Wl,-bE:libpq.exp
ld: 0711-224 WARNING: Duplicate symbol:
.pqStrerror

ld: 0711-224 WARNING: Duplicate symbol:
.pqGetpwuid

...

I used a vanilla configure except for --without-readline.

Tools that seem to be in use:

AIX 5.1
GNU Make 3.80
gcc 3.2.2
ld - AIX version

This is an 8-CPU machine that recently became disused in our research
department and looks like a nice potential PG host.

Thanks,
Kevin Murphy


Re: aix build question re: duplicate symbol warning

От
Tom Lane
Дата:
Kevin Murphy <murphy@genome.chop.edu> writes:
> I'm trying to build PG 8.1 beta on an AIX server.

> The 'make' finishes without errors, but I'm getting lots of duplicate
> symbol warnings like the following one.  What am I to make of these?

> gcc -O2 -Wall -Wmissing-prototypes -Wpointer-arith -Winline
> -fno-strict-aliasing   -Wl,-bnoentry -Wl,-H512 -Wl,-bM:SRE -o libpq.\
> so libpq.a -L../../../src/port    -L../../../src/port -lnsl
> -Wl,-bI:../../../src/backend/postgres.imp -Wl,-bE:libpq.exp
> ld: 0711-224 WARNING: Duplicate symbol:
> .pqStrerror

Hmm.  pqStrerror is defined in libpgport (which is linked into the
backend) as well as libpq.  ISTM that libpq should not be linked with
-Wl,-bI:../../../src/backend/postgres.imp, since it's not intended to
be loaded into the backend.  Without having looked at the code, I'm
wondering if the AIX makefiles stick that option into LDFLAGS_SL rather
than someplace more restricted.

            regards, tom lane