On ons, 2011-08-17 at 18:28 +0530, Ashesh Vashi wrote:
> I am trying to build PostgreSQL 9.1beta3 using the ActiveState Python 3.2.
> It did not compile successfully.

Note that building against Python 3.2 works at least on Debian, so this
is not a universal problem.  It appears to have to do with the stable
ABI thing they introduced in Python 3.2, so it will be mainly relevant
to platforms targeted by that.

> When I tried to figure out the exact reason for the failure, I found that:
> 1. 'python_configdir' variable is hardcoded, instead it should use the
> configuration 'LIBPL'.

That looks reasonable.  My Debian installation works around this by a
symlink, but that's perhaps a hack they put in for this reason.

> 2. 'plpython' is trying get linked using '-lpython${*python_version*}', but
> it should be '-lpython${*python_ldversion*}'.

That, on the other hand, will be a problem.
get_config_vars('LDVERSION') isn't defined before Python 3.2, so this
will break all previous versions.

I find it a bit curious that this is necessary, because the previous
coding works for me:

$ python3.2 -c "import distutils.sysconfig,string; print(' 
'.join(filter(None,distutils.sysconfig.get_config_vars('LDLIBRARY'))))"
libpython3.2mu.so

$ python3.2 -c "import distutils.sysconfig,string; print(' 
'.join(filter(None,distutils.sysconfig.get_config_vars('LDVERSION'))))"
3.2mu

So it is not in fact true that we are linking against '-lpython
${*python_version*}'.



-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to