port select python and config error

Joshua Root jmr at macports.org
Mon Oct 29 00:19:21 UTC 2018


On 2018-10-29 10:49 , Mark Brethen wrote:
> There is no python setup file. The makefile uses python-config to get
> the path to the python header files. When port select sets python to
> none, it builds with apple python 2.7 without error. When port select
> sets python to python27 it fails because it cannot find a python setup.
> 
> In the terminal, with it set to python27 I get:
> 
> brethen-air:~ marbre$ python-config --includes
> -I/opt/local/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7
> -I/opt/local/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7
> 
> with it set to none:
> 
> brethen-air:~ marbre$ python-config --includes
> -bash: /opt/local/bin/python-config: No such file or directory
> 
> but /usr/bin//usr/bin/python-config works,
> 
> brethen-air:~ marbre$ /usr/bin/python-config --includes
> -I/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7
> -I/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7

Then you need to tell the makefile to use ${prefix}/bin/python2.7-config
if you want it to use the python27 port.

- Josh


More information about the macports-dev mailing list