[XML-SIG] Installation trouble on OS X

Gary Robinson grobinson@transpose.com
Tue, 13 May 2003 21:21:26 -0400


Hello,

I'm trying to install PyXML-0.8.2 on OS X. I think I've located a bug in the
installer.

I'm running 

    python setup.py install

I get the error:

% python setup.py install
Traceback (most recent call last):
  File "setup.py", line 58, in ?
    if sys.platform[:6] == "darwin" and \
NameError: name 'distutils' is not defined


When I examine setup.py, at the top I see:

    from distutils.sysconfig import get_config_vars

but lines 58 and 59, where it is choking, say:

    if sys.platform[:6] == "darwin" and \
    distutils.sysconfig.get_config_var("LDSHARED").find("-flat_namespace") \
        == -1:

The problem seems to be that distutils hasn't been imported; just
get_config_vars has been. So the above should say:

    if sys.platform[:6] == "darwin" and \
       get_config_vars("LDSHARED").find("-flat_namespace") == -1:

Is that right?

Also -- I'm a newbie to the process of doing this kind of install. Does it
matter where in my directory structure I place the PyXML-0.8.2 directory
which contains setup.py when I run it? Or can it be anywhere (in which case
it must be smart enough to know where everything should go).
        
Many thanks in advance for any help you can give.

--Gary

-- 
<http://ThisURLEnablesEmailToGetThroughOverzealousSpamFilters.org>

Gary Robinson
CEO
Transpose, LLC
grobinson@transpose.com
207-942-3463
http://www.transpose.com
http://radio.weblogs.com/0101454