Thread: Re: [HACKERS] Call for platforms AIX 4.3.3 Failed

Re: [HACKERS] Call for platforms AIX 4.3.3 Failed

From
Gilles DAROLD
Date:
Gilles DAROLD wrote:

> Hi,
>
> I am currently testing beta6 on AIX 4.3.3 on a RS6000 H80 with 4 cpu and 4
> Go RAM
> I use :
>
> ./configure
>         --with-CC=/usr/local/bin/gcc
>         --with-includes=/usr/local/include
>         --with-libraries=/usr/local/lib
>
> All seem to be ok, There just the geometry failure in regression test
>
> But when I configure with --with-perl I have the following error :

Ok symbolic link between cc and gcc seem to be the better fix.

I have now tested the --with-CXX option to compile libpq++ and it
really don't work, here are the output :

ld: 0711-319 WARNING: Exported symbol not defined:
PgConnection::CloseConnection
ld: 0711-319 WARNING: Exported symbol not defined: PgConnection::Connect
ld: 0711-319 WARNING: Exported symbol not defined: PgConnection::ConnectionBad

ld: 0711-319 WARNING: Exported symbol not defined: PgConnection::DBName
ld: 0711-319 WARNING: Exported symbol not defined: PgConnection::ErrorMessage
ld: 0711-319 WARNING: Exported symbol not defined: PgConnection::Exec
ld: 0711-319 WARNING: Exported symbol not defined: PgConnection::ExecCommandOk

ld: 0711-319 WARNING: Exported symbol not defined: PgConnection::ExecTuplesOk
ld: 0711-319 WARNING: Exported symbol not defined: PgConnection::IntToString

....

ld: 0711-317 ERROR: Undefined symbol: basic_string<char,
string_char_traits<char>, __default_alloc_template<false, 0> >::nilRep
ld: 0711-317 ERROR: Undefined symbol:
__malloc_alloc_template<0>::__malloc_alloc_oom_handler
ld: 0711-317 ERROR: Undefined symbol: endl(ostream &)
ld: 0711-317 ERROR: Undefined symbol: cerr
ld: 0711-317 ERROR: Undefined symbol: .ostream::operator<<(char const *)
ld: 0711-317 ERROR: Undefined symbol: __default_alloc_template<false,
0>::_S_end_free
ld: 0711-317 ERROR: Undefined symbol: __default_alloc_template<false,
0>::_S_start_free
ld: 0711-317 ERROR: Undefined symbol: __default_alloc_template<false,
0>::_S_heap_size
ld: 0711-317 ERROR: Undefined symbol: __default_alloc_template<false,
0>::_S_free_list
ld: 0711-317 ERROR: Undefined symbol: .__out_of_range(char const *)
ld: 0711-317 ERROR: Undefined symbol: .__length_error(char const *)
collect2: ld returned 8 exit status
make[3]: *** [libpq++.so] Error 1
make[3]: Leaving directory
`/home/darold/postgresql-7.1beta6/src/interfaces/libpq++'
make[2]: *** [all] Error 2

I have change the Makefile.global and replace c++ by g++ but it the same
output.

Could you tell me what going wrong ? Is my GNU install not fully functionnal ?

I use :
gcc version 2.95.2.1 19991024 (release) libs for powerpc-ibm-aix4.3.2.0

Regards

Gilles DAROLD


Re: Re: [HACKERS] Call for platforms AIX 4.3.3 Failed

From
Peter Eisentraut
Date:
Gilles DAROLD writes:

> I have now tested the --with-CXX option to compile libpq++ and it
> really don't work, here are the output :

> ld: 0711-317 ERROR: Undefined symbol: __default_alloc_template<false,
> 0>::_S_start_free
> ld: 0711-317 ERROR: Undefined symbol: __default_alloc_template<false,
> 0>::_S_heap_size
> ld: 0711-317 ERROR: Undefined symbol: __default_alloc_template<false,
> 0>::_S_free_list
> ld: 0711-317 ERROR: Undefined symbol: .__out_of_range(char const *)
> ld: 0711-317 ERROR: Undefined symbol: .__length_error(char const *)
> collect2: ld returned 8 exit status
> make[3]: *** [libpq++.so] Error 1
> make[3]: Leaving directory
> `/home/darold/postgresql-7.1beta6/src/interfaces/libpq++'
> make[2]: *** [all] Error 2

This could be a name mangling problem.  Maybe the linker needs to be
invoked specially when building C++ libraries.  Maybe the C++ compiler
driver needs to be invoked directly.  This could especially be a problem
if you're using the GNU compiler with system libraries, since those are
usually compiled by the system compiler.

> I have change the Makefile.global and replace c++ by g++ but it the same
> output.

I think the good C++ compiler on AIX is called xlC.  In any case, make
sure that you don't mix different C++ compilers.  You need to do 'gmake
clean' at least in the libpq++ directory if you're switching.

--
Peter Eisentraut      peter_e@gmx.net       http://yi.org/peter-e/


Re:Call for platforms AIX 4.3.3 Failed

From
Gilles DAROLD
Date:
Peter Eisentraut wrote:

> This could be a name mangling problem.  Maybe the linker needs to be
> invoked specially when building C++ libraries.  Maybe the C++ compiler
> driver needs to be invoked directly.  This could especially be a problem
> if you're using the GNU compiler with system libraries, since those are
> usually compiled by the system compiler.
>
> > I have change the Makefile.global and replace c++ by g++ but it the same
> > output.
>
> I think the good C++ compiler on AIX is called xlC.  In any case, make
> sure that you don't mix different C++ compilers.  You need to do 'gmake
> clean' at least in the libpq++ directory if you're switching.

AIX faq said that xlC compiler don't work with libpq++ but with g++ it
may works :

> libpq++ does not work because xlC does not have the string and bool
classes.
> compiling the few files, that fail, with g++ does work.

Humm, I have no xlC compiler installed.Here are the compilation lines :

make[3]: Entering directory
`/home/darold/postgresql-7.1beta6/src/interfaces/libpq++'
g++ -O2 -Wall  -I../../../src/interfaces/libpq -I../../../src/include
-I/usr/local/include  -c -o pgconnection.o p
gconnection.cc
g++ -O2 -Wall  -I../../../src/interfaces/libpq -I../../../src/include
-I/usr/local/include  -c -o pgdatabase.o pgd
atabase.cc
g++ -O2 -Wall  -I../../../src/interfaces/libpq -I../../../src/include
-I/usr/local/include  -c -o pgtransdb.o pgtr
ansdb.cc
g++ -O2 -Wall  -I../../../src/interfaces/libpq -I../../../src/include
-I/usr/local/include  -c -o pgcursordb.o pgc
ursordb.cc
g++ -O2 -Wall  -I../../../src/interfaces/libpq -I../../../src/include
-I/usr/local/include  -c -o pglobject.o pglo
bject.cc
ar crs libpq++.a pgconnection.o pgdatabase.o pgtransdb.o pgcursordb.o
pglobject.o
touch libpq++.a
../../../src/backend/port/aix/mkldexport.sh libpq++.a > libpq++.exp
/usr/local/bin/gcc -Wl,-H512 -Wl,-bM:SRE
-Wl,-bI:../../../src/backend/postgres.imp -Wl,-bE:libpq++.exp -o libpq++.
so libpq++.a -L/usr/local/lib  -L../../../src/interfaces/libpq -lpq -lc
ld: 0711-224 WARNING: Duplicate symbol: __start

All work until it want to link with libraries, it seems to want the libc
(-lc) and I don't
have it installed. Is it normal or this realease is not portable with AIX
4.3.3 ?