Merged revisions 84680 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r84680 | antoine.pitrou | 2010-09-10 21:44:44 +0200 (ven., 10 sept. 2010) | 4 lines

  Issue #941346: Improve the build process under AIX and allow Python to
  be built as a shared library.  Patch by Sébastien Sablé.
........
diff --git a/configure.in b/configure.in
index 3ccb66a..73ab4a4 100644
--- a/configure.in
+++ b/configure.in
@@ -748,6 +748,10 @@
 	BLDLIBRARY='-L. -lpython$(VERSION)'
 	RUNSHARED='DYLD_LIBRARY_PATH=`pwd`:${DYLD_LIBRARY_PATH}'
 	;;
+    AIX*)
+	LDLIBRARY='libpython$(VERSION).so'
+	RUNSHARED=LIBPATH=`pwd`:${LIBPATH}
+	;;
 
   esac
 else # shared is disabled
@@ -1723,7 +1727,7 @@
 then
 	case $ac_sys_system/$ac_sys_release in
 	AIX*)
-		BLDSHARED="\$(srcdir)/Modules/ld_so_aix \$(CC) -bI:Modules/python.exp"
+		BLDSHARED="\$(srcdir)/Modules/ld_so_aix \$(CC) -bI:Modules/python.exp -L\$(srcdir)"
 		LDSHARED="\$(BINLIBDEST)/config/ld_so_aix \$(CC) -bI:\$(BINLIBDEST)/config/python.exp"
 		;;
 	IRIX/5*) LDSHARED="ld -shared";;
@@ -4106,6 +4110,7 @@
 
 # generate output files
 AC_CONFIG_FILES(Makefile.pre Modules/Setup.config Misc/python.pc)
+AC_CONFIG_FILES([Modules/ld_so_aix], [chmod +x Modules/ld_so_aix])
 AC_OUTPUT
 
 echo "creating Modules/Setup"