On 30-dec-04, at 0:25, Jack Jansen wrote:


On 29-dec-04, at 11:40, Bob Ippolito wrote:
[Bob notes that my PantherPythonFix installer will break C++ compilation because distutils simply replaces the first component of LDSHARED with "c++"]
Any suggestions as to what to do to get c++ compilation fixed?

I can think of two ways:

1. Patch distutils to actually do os.environ['MACOSX_DEPLOYMENT_TARGET'] = '10.3' because CCompiler.spawn doesn't take an environment dict.
2. Patch distutils to skip over environment variables (basically change that "0" into something smarter). This is probably less desirable because who knows where this happens, and who knows what third party compiler subclasses used this original stupid code as a template.

Both of these mean that "the simple installer that just puts a new Makefile into lib/python2.3/config" has just gone out the window:-(

In the quick-and-dirty-hacks category: you could write two simple shell-scripts that start the compiler with the right environment variables:


run-cc:
    #!/bin/sh

    env MACOSX_DEPLOYMENT_TARGET=10.3 gcc "[EMAIL PROTECTED]"

run-c++:
        #!/bin/sh
        env MACOSX_DEPLOYMENT_TARGET=10.3 gcc "[EMAIL PROTECTED]"

The scripts can then be used in the CC and CXX variables in the patched makefile.

Ronald

_______________________________________________
Pythonmac-SIG maillist  -  Pythonmac-SIG@python.org
http://mail.python.org/mailman/listinfo/pythonmac-sig

Reply via email to