Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Numpy-stl not installable under Windows 7 and Python 3 #54

Closed
DietBru opened this issue May 30, 2017 · 6 comments
Closed

Numpy-stl not installable under Windows 7 and Python 3 #54

DietBru opened this issue May 30, 2017 · 6 comments
Assignees

Comments

@DietBru
Copy link

DietBru commented May 30, 2017

The numpy-stl package cannot be installed with Python 3 under Windows, since Cython does not
fully support Python 3. (At least v2.2.3 has this problem.) In the
"stl/_speedups.pyx" file the statement in line 4
IF UNAME_SYSNAME == u"Windows":
is not evaluated correctly.
Cheers, dietrich

PS: Tested on Window7, Python 3.6, Cython 0.25.2 (Anaconda 4.3)

@wolph
Copy link
Owner

wolph commented May 30, 2017

Can you give the current develop branch a try? It should work even when the speedups module cannot be build correctly.

@DietBru
Copy link
Author

DietBru commented May 31, 2017

That did the trick (Interestingly, I did not see any warning while installing).

@wolph
Copy link
Owner

wolph commented May 31, 2017

Glad it worked.

The pure python version is more than fast enough in most cases and if you need more speed than I would recommend the binary stl files anyhow.

@wolph wolph self-assigned this Jun 11, 2017
@gigaj0ule
Copy link

gigaj0ule commented Jun 15, 2017

I found personally that creating a one line file:

#include <io.h>

Named unistd.h in ./stl/ solved the install issue for me.

Error I was experiencing was something along the lines of:

_speedups.c
stl/_speedups.c(449): fatal error C1083: Cannot open include file: 'unistd.h': No such file or directory
error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\VC\\BIN\\x86_amd64\\cl.exe' failed with exit status 2

@David-Herman
Copy link

I also wanted to report that I had a similar error under windows and Python 2.7.10 and the solution from @adammunich worked from me. Thanks. The numpy-stl package was v2.2.3 as well.

@wolph wolph closed this as completed in ad6cbbc Jul 27, 2017
@wolph wolph removed the in progress label Jul 27, 2017
@wolph
Copy link
Owner

wolph commented Jul 27, 2017

I finally had access to a windows machine with visual studio to test for myself and it seems that cython doesn't support python 3 on windows yet, or at least... not fully. The UNAME_SYSNAME constant isn't defined on windows it seems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants