-
-
Notifications
You must be signed in to change notification settings - Fork 7.8k
Switching Compilers (Intel Related) #4518
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
Comments
Taking a quick look at I think you can get it to behave by doing CC=icpc python setup.py install which gives me output like
which correctly fails as I don't have the intel compilers installed. Hope some of that is helpful! |
I think you can do On Fri, Jun 12, 2015 at 12:22 PM, Will French notifications@github.com
|
When I use building 'matplotlib._cntr' extension
icpc -fno-strict-aliasing -O3 -fPIC -fp-model strict -fomit-frame-pointer -DNDEBUG -g -O3 -Wall -fPIC -DPY_ARRAY_UNIQUE_SYMBOL=MPL_matplotlib__cntr_ARRAY_API -DNPY_NO_DEPRECATED_API=NPY_1_7_API_VERSION -I/usr/local/python2/2.7.8/x86_64/intel14/nonet/lib/python2.7/site-packages/numpy/core/include -I/usr/local/include -I/usr/include -I. -I/usr/local/python2/2.7.8/x86_64/intel14/nonet/include/python2.7 -c src/cntr.c -o build/temp.linux-x86_64-2.7/src/cntr.o
src/cntr.c(1846): error: a value of type "void *" cannot be assigned to an entity of type "char *"
if (mpa) mask = PyArray_DATA(mpa);
^
src/cntr.c(1904): error: a value of type "void *" cannot be assigned to an entity of type "char *"
data = PyArray_DATA(Cdata);
^
compilation aborted for src/cntr.c (code 2)
error: command 'icpc' failed with exit status 2 This looks like the opposite problem as before, i.e. the C++ compiler is having trouble with C code. I then tried I suspect there is a flag I can pass either icc to give it better C++ support, or icpc to give it better C support. I'll keep poking around. |
https://mail.python.org/pipermail/python-dev/2012-March/117219.html <- is Do you have similar issues compiling numpy/scipy/scikit-image ? On Fri, Jun 12, 2015 at 3:37 PM Will French notifications@github.com
|
Yes I battled with numpy for quite some time before getting it to build and pass all tests, but what I learned there does not help much in this case. I explored the use of different compiler flag options for both icc and icpc but I could not manage to get the matplotlib build to succeed. In the end, I decided to modify a few lines of code to remove Intel preprocessors and the template definition that triggered the original error. The build succeeded and no additional unit test errors or failures were introduced. See PR here: #4519 |
When pulling data from from PyArrray_DATA explicitly cast to (char *). Addresses issues raised in matplotlib#4518
Reading this again, it looks like the errors you are getting from the |
This has been fixed two different ways, closing. |
Hello all, I have an intel-compiled version of Python 2.7.8 that I'm trying to build and install Matplotlib into. When I run "python setup.py build" everything builds fine until:
The issue here is that icc does not support templates. When I manually run this command with icpc rather than icc it compiles fine. Can someone advise me on how I can go about switching to icpc to compile qhull_wrap.c? I'm also happy to submit a pull request if this is something that can be generalized in the build process. Version info listed below.
[frenchwr@vmps11 matplotlib]$ uname -a Linux vmps11 2.6.32-358.14.1.el6.x86_64 #1 SMP Tue Jul 16 23:51:20 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux
The text was updated successfully, but these errors were encountered: