AIX 5.3 - Enabling Shared Library Support Vs Extensions

Anurag Chourasia anurag.chourasia at
Sat Nov 27 19:43:46 CET 2010

Hi Stefan,

I followed your suggestion and configured LDFLAGS but the make step fails
for another error now.

My configuration options are as follows

./configure --enable-shared --disable-ipv6 --with-gcc=gcc CPPFLAGS="-I
/opt/freeware/include -I /opt/freeware/include/readline -I
/opt/freeware/include/ncurses" LDFLAGS="-L. -L/usr/local/lib"

Below is the transcript from the make step.
running build
running build_ext
ldd: /lib/libreadline.a: File is an archive.
INFO: Can't locate Tcl/Tk libs and/or headers
building '_struct' extension
gcc -pthread -fno-strict-aliasing -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall
-Wstrict-prototypes -I. -I/u01/home/apli/wm/GDD/Python-2.6.6/./Include -I.
-IInclude -I./Include -I/opt/freeware/include
-I/opt/freeware/include/readline -I/opt/freeware/include/ncurses
-I/usr/local/include -I/u01/home/apli/wm/GDD/Python-2.6.6/Include
-I/u01/home/apli/wm/GDD/Python-2.6.6 -c
/u01/home/apli/wm/GDD/Python-2.6.6/Modules/_struct.c -o
./Modules/ld_so_aix gcc -pthread -bI:Modules/python.exp -L. -L/usr/local/lib
-L. -L/usr/local/lib -lpython2.6 -o build/lib.aix-5.3-2.6/
*Fatal Python error: Interpreter not initialized (version mismatch?)*
*make: 1254-059 The signal code from the last command is 6.*

The last command that i see above (ld_so_aix) seems to have completed as the
file exists after this command and hence I am not sure which step
is failing.

There is no other Python version on my machine.

Please guide.

On Thu, Nov 25, 2010 at 3:41 PM, Stefan Krah <stefan-usenet at>wrote:

> Anurag Chourasia <anurag.chourasia at> wrote:
> > When I configure python to enable shared libraries, none of the
> extensions are getting built during the make step due to this error.
> >
> > building 'cStringIO' extension
> > gcc -pthread -fno-strict-aliasing -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall
> > -Wstrict-prototypes -I. -I/u01/home/apli/wm/GDD/Python-2.6.6/./Include
> -I.
> > -IInclude -I./Include -I/opt/freeware/include
> > -I/opt/freeware/include/readline -I/opt/freeware/include/ncurses
> > -I/usr/local/include -I/u01/home/apli/wm/GDD/Python-2.6.6/Include
> > -I/u01/home/apli/wm/GDD/Python-2.6.6 -c
> > /u01/home/apli/wm/GDD/Python-2.6.6/Modules/cStringIO.c -o
> >
> build/temp.aix-5.3-2.6/u01/home/apli/wm/GDD/Python-2.6.6/Modules/cStringIO.o
> > ./Modules/ld_so_aix gcc -pthread -bI:Modules/python.exp
> >
> build/temp.aix-5.3-2.6/u01/home/apli/wm/GDD/Python-2.6.6/Modules/cStringIO.o
> > -L/usr/local/lib *-lpython2.6* -o build/lib.aix-5.3-2.6/
>   ^^^^^^^^^^^^^^^^
> Try these flags: -L. -L/usr/local/lib
> If this solves the problem and the issue is also present in Python-2.7,
> you should report a bug at .
> Stefan Krah
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the Python-list mailing list