cannot install

Benjamin Kaplan benjamin.kaplan at case.edu
Mon Feb 9 10:56:14 EST 2009


On Mon, Feb 9, 2009 at 9:05 AM, Vladimír Župka <vzupka at volny.cz> wrote:

> I have Mac OS X Leopard 10.5.6 and I downloaded and unpacked Python 3.0
> into a folder (/Library/Frameworks/Python.framework) and ran commands:
>
> cd /Library/Frameworks/Python.framework/Python-3.0
> python setup.py install
>
> and got the message reporting a syntax error:
>
> Macintosh:~ vzupka$ /bin/csh
> [Macintosh:~] vzupka% cd /Library/Frameworks/Python.framework/Python-3.0
> [Macintosh:Frameworks/Python.framework/Python-3.0] vzupka% python setup.py
> install
>   File "setup.py", line 232
>     except (CCompilerError, DistutilsError) as why:
>                                              ^
> SyntaxError: invalid syntax
> [Macintosh:Frameworks/Python.framework/Python-3.0] vzupka%
>
> What is the reason and how do I install?
>


You can't use setup.py because the python 2.5 on your system (or 2.6 if you
installed it) is incompatible with Python 3 modules. You need to compile
Python 3 yourself. It will then automatically call setup.py to create all
the extension modules.

Just unpack the tarball anywhere and use the following commands  Python 3 is
automatically installed as python3.0, so you don't need to worry about
overwriting the default python on the system.

./configure --enable-framework
make
sudo make install

more complete instructions are in the Mac/README file, except substitute
"Python 3.0" everywhere it says "MacPython 2.6". You will probably need to
install a whole bunch of packages to compile it. configure will tell you
about them. MacPorts (www.macports.org) and fink (www.finkproject.org)
provide an easy way to get them.


> Regards,
> Vladimír Župka
> vzupka at volny.cz
>
>
>
>
>
>
> --
> http://mail.python.org/mailman/listinfo/python-list
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20090209/d4e829ec/attachment-0001.html>


More information about the Python-list mailing list