port select python and config error

Mark Brethen mark.brethen at gmail.com
Sun Oct 28 23:49:33 UTC 2018


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


Mark Brethen
mark.brethen at gmail.com



> On Oct 28, 2018, at 6:23 PM, Mark Brethen <mark.brethen at gmail.com> wrote:
> 
> 
> Mark Brethen
> mark.brethen at gmail.com <mailto:mark.brethen at gmail.com>
> 
> 
> 
>> On Oct 28, 2018, at 5:46 PM, Ryan Schmidt <ryandesign at macports.org <mailto:ryandesign at macports.org>> wrote:
>> 
>> setup.py is where a python project defines how it is to be set up. It's like a configure file. It's specific to each project. There isn't a default. Maybe for this software the configure script creates the setup.py file; I'm not sure.
> 
> RedPy.so is written in c code. The makefile has this:
> 
> RedPy.o: $(srcdir)/RedPy.c
> 	$(CC) -c $(CFLAGS) $(shell python-config --includes) -o RedPy.o $(srcdir)/RedPy.c
> 
> <RedPy.c>
> 
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macports.org/pipermail/macports-dev/attachments/20181028/a6c944ce/attachment.html>


More information about the macports-dev mailing list