Opened 10 years ago

Closed 9 years ago

#27687 closed defect (fixed)

postgresql84 @8.4.5_0+python: PL/Python using Apple's Python

Reported by: dale+macports@… Owned by: mww@…
Priority: Normal Milestone:
Component: ports Version: 1.9.2
Keywords: Cc: jyrkiwahlstedt
Port: postgresql84



  • OS X 10.6.5
  • MacPorts 1.9.2, did selfupdate just today if memory serves
  • postgresql84 @8.4.5_0+python

Built with: port install postgresql84 +python

I expected PL/Python to use Python from MacPorts, especially since the python variant requires python26, but it seems to use Apple's Python no matter what, according to otool:

$ port installed postgresql84
The following ports are currently installed:
  postgresql84 @8.4.5_0+python (active)

$ python_select -s

$ otool -L /opt/local/lib/postgresql84/ 
	/System/Library/Frameworks/Python.framework/Versions/2.6/Python (compatibility version 2.6.0, current version 2.6.1)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 125.2.1)

The same thing happened with my source build, no matter what I set the PYTHON environment variable to. The only way I could fix when building from source was to:

  1. Use python_select before building (e.g. python_select python27).
  2. Include -F/opt/local/Library/Frameworks in CFLAGS.
  3. Set PYTHON=/opt/local/bin/python.

Since I had this problem building from source as well I don't know if this is an upstream bug or just a matter of configuration that MacPorts is supposed to address. Let me know if I need to refile this upstream.

Change History (2)

comment:1 Changed 10 years ago by ryandesign (Ryan Schmidt)

Cc: jwa@… added
Owner: changed from macports-tickets@… to mww@…

I'm guessing some of the other postgresql ports might be affected too.

comment:2 Changed 9 years ago by jmroot (Joshua Root)

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.