Re: Problem compiling postgres sql --with-tcl

Поиск
Список
Период
Сортировка
От Zeugswetter Andreas SB SD
Тема Re: Problem compiling postgres sql --with-tcl
Дата
Msg-id 46C15C39FEB2C44BA555E356FBCD6FA41EB45A@m0114.s-mxs.net
обсуждение исходный текст
Ответы Re: Problem compiling postgres sql --with-tcl  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
> I want to compile libpgtcl on a AIX 4.3.2 RS6000 but I have 
> problem at the linking phase.
> I ran the ./configure like that:
> $ sh ./configure --with-CC=gcc --with-includes=/usr/local/include
> --with-libraries=/usr/local/lib --with-tclconfig=/usr/local/lib
> --with-tkconfig=/usr/local/lib
> 
> After everything whent fine until time for libpgtcl.so I had those errors.
> Can you help me
> Thank you
> Jacques Talbot
> 
> 
> gcc -O2 -pipe -Wall -Wmissing-prototypes 
> -Wmissing-declarations  -Wl,-H512
> -Wl,-bM:SRE -Wl,-bI:../../../src/backend/postgres.imp 
> -Wl,-bE:libpgtcl.exp -o
> libpgtcl.so libpgtcl.a   -L../../../src/interfaces/libpq -lpq   -lc
.....
> ld: 0711-317 ERROR: Undefined symbol: .Tcl_DStringInit
> ld: 0711-317 ERROR: Undefined symbol: .Tcl_DStringStartSublist
> collect2: ld returned 8 exit status
> make[3]: *** [libpgtcl.so] Error 1

configure unfortunately does not include the tcl library 
for linking libpgtcl.so on AIX :-(

In the meantime Jacques, your tcl installation should have a shared 
tcl library (libtcl8.2.so) or better yet an *.exp, which you can include
in the above link command. 

In the shell manually execute the link, like:

cd src/pl/tcl
gcc -O2 -pipe -Wall -Wmissing-prototypes \-Wmissing-declarations  -Wl,-H512 \-Wl,-bM:SRE
-Wl,-bI:../../../src/backend/postgres.imp\-Wl,-bE:libpgtcl.exp -o \libpgtcl.so libpgtcl.a
-L../../../src/interfaces/libpq-lpq   -lc \  -L/usr/local/lib -Wl,-bI:/usr/local/lib/libtcl8.2.exp
 

The above addition could be generated with TCL_LIB_SPEC.
The -L/usr/local/lib is also essential to avoid runtime hassles,
why is this actually not automatic, since --with-libraries was used ?

Would a patch for src/pl/tcl/Makefile still be accepted for 7.2 ?

Andreas


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Doug McNaught
Дата:
Сообщение: Re: Platform testing (last call?)
Следующее
От: Luis Amigo
Дата:
Сообщение: can someone explain that?