newforrestgump001 / pythonxy

Automatically exported from code.google.com/p/pythonxy
0 stars 0 forks source link

Default installation location causes problems for weave #61

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I am running Python(x,y) 2.1.8 on Windows XP 64, installed to the default
location.  I have tried running weave.blitz but I get the following error,
which seems to be due to g++ having trouble handling path names with spaces
(which occur during the default installation directory)

at the IPython(x,y) prompt enter the following:

from scipy import weave
a = 5
b = 1
print weave.blitz("b = a+a")

Obviously the expected output should be 10, but instead I get a gcc error,
followed by a whole bunch of python exceptions which I have ommitted:

<weave: compiling>
Found executable C:\Program Files (x86)\pythonxy\mingw\bin\g++.exe
g++.exe: C:\Program: No such file or directory
g++.exe: Files: No such file or directory
g++.exe:
(x86)\pythonxy\python\lib\site-packages\scipy\weave\scxx\weave_imp.cpp: No
such file or directory
g++.exe: files: No such file or directory
g++.exe:
(x86)\pythonxy\python\lib\site-packages\scipy\weave\scxx\weave_imp.o: No
such file or directory
g++.exe: no input files

A simple workaround is to install python(x,y) to a path with no spaces in
the name (e.g. C:\pythonxy).

I am not sure whether this is a problem with weave, scipy, mingw or
Python(x,y) but it would be nice to have it fixed so that python(x,y) works
out of the box with all the defaults as most people would expect.  

There is another problem with weave.test() failing as well.  I am not sure
if these are related, so should I file this as a separate issue?

Original issue reported on code.google.com by DavidAnt...@gmail.com on 9 Jan 2009 at 12:41

GoogleCodeExporter commented 9 years ago
Thanks a lot for this very detailed bug report.

I think that I'll probably change the default path location of Python directory
(probably to the default value 'C:\Python25'). I chose to locate it into 
'C:\Program
Files\pythonxy' in order to respect the Windows standards. But defining path
locations depending on the locale is one of the very bad idea of Microsoft...

I'll mark this issue as fixed as soon as it's done.

Regarding weave.test(), does this test fail too if you choose path without 
spaces?
I'll take a look at it.

Original comment by pierre.raybaut on 9 Jan 2009 at 9:54

GoogleCodeExporter commented 9 years ago
weave.test() failures are related to some compatibility issues between SciPy 
0.6 and
NumPy 1.2.x. This will be solved with the new forthcoming release of SciPy.

Original comment by pierre.raybaut on 9 Jan 2009 at 5:23

GoogleCodeExporter commented 9 years ago
weave.test() fails, indeed. But scipy.test() fails as well, and that is 
'normal':
avoiding warnings due to NumPy 1.2.x causes these errors. But this will be 
solved
soon, with the forthcoming SciPy 0.7 release.

Original comment by pierre.raybaut on 9 Jan 2009 at 5:49

GoogleCodeExporter commented 9 years ago
Pierre - It would be nice if weave could be fixed so that it works with 
arbitrary
directory names but I am guessing that this is not something which you have 
control
over.  Do you build and configure these packages yourself or are you just 
taking the
pre-made .exe files?

Perhaps 'C:\pythonxy' would be a nicer choice of directory as a fix?

Original comment by DavidAnt...@gmail.com on 12 Jan 2009 at 5:10

GoogleCodeExporter commented 9 years ago
I try to not build packages, but sometimes I do when they are not available for
win32. But I didn't build scipy for example. I can't afford to spend a lot of 
time on
building modules to be able to maintain the whole distribution.

Regarding the directory, I prefer to locate Python under 'C:\Python25' and the 
rest
of Python(x,y) in the same directory as before because some other modules can 
be even
more dumb than weave! I recently built PyQt for example, and all the build 
settings
assume that Python is installed in C:\Python25... and it's so not convenient to
customize this location that it took me less time to uninstall and reinstall
Python(x,y) using this custom folder for Python.
So I prefer to change it right now, because if I don't, I suspect that in a few 
weeks
another bug will be reported because of it.

Original comment by pierre.raybaut on 17 Jan 2009 at 8:19

GoogleCodeExporter commented 9 years ago

Original comment by pierre.raybaut on 17 Jan 2009 at 10:23