Build error with Python 3 and clang
I get the following build error with Python 3 and clang in acor/_acor.c:
https://gist.github.com/cdeil/7983971
$ clang --version
Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn)
Target: x86_64-apple-darwin13.0.0
Unfortunately this extension doesn't support Python 3 yet but it should actually be very easy to update that. I'll try to fix it this afternoon! Sorry about the delay!
I think that everything should work under 3.x now if you use the git version or 1.1.0 from PyPI. Let me know if you run into any other problems!
Hi folks. Even with version 1.1.0, I'm still having a problem installing acor using pip. I have python 3.3 and am using clang. It claims to have installed, but there an no functions inside the module when I import it and try to use acor.acor
Here's the gobbly-guck output from the terminal
[lemay:~] arh5361% pip install acor Downloading/unpacking acor Downloading acor-1.1.0.tar.gz Running setup.py (path:/private/tmp/pip_build_arh5361/acor/setup.py) egg_info for package acor
Requirement already satisfied (use --upgrade to upgrade): numpy in ./code/anaconda/lib/python3.3/site-packages (from acor)
Installing collected packages: acor
Running setup.py install for acor
building 'acor._acor' extension
clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -g -O2 -I/astro/grads/arh5361/code/include -I/opt/local/include -g -O2 -I/astro/grads/arh5361/code/include -I/opt/local/include -Iacor -I/astro/grads/arh5361/code/anaconda/lib/python3.3/site-packages/numpy/core/include -I/astro/grads/arh5361/code/anaconda/include/python3.3m -c acor/_acor.c -o build/temp.macosx-10.5-x86_64-3.3/acor/_acor.o
In file included from acor/_acor.c:6:
In file included from /astro/grads/arh5361/code/anaconda/lib/python3.3/site-packages/numpy/core/include/numpy/arrayobject.h:4:
In file included from /astro/grads/arh5361/code/anaconda/lib/python3.3/site-packages/numpy/core/include/numpy/ndarrayobject.h:17:
In file included from /astro/grads/arh5361/code/anaconda/lib/python3.3/site-packages/numpy/core/include/numpy/ndarraytypes.h:1761:
/astro/grads/arh5361/code/anaconda/lib/python3.3/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:15:2: warning: "Using deprecated NumPy API, disable it by " "#defining NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-W#warnings]
#warning "Using deprecated NumPy API, disable it by "
^
1 warning generated.
clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -g -O2 -I/astro/grads/arh5361/code/include -I/opt/local/include -g -O2 -I/astro/grads/arh5361/code/include -I/opt/local/include -Iacor -I/astro/grads/arh5361/code/anaconda/lib/python3.3/site-packages/numpy/core/include -I/astro/grads/arh5361/code/anaconda/include/python3.3m -c acor/acor.c -o build/temp.macosx-10.5-x86_64-3.3/acor/acor.o
clang -bundle -undefined dynamic_lookup -L/astro/grads/arh5361/code/anaconda/lib -L/astro/grads/arh5361/code/lib -L/opt/local/lib -L/astro/grads/arh5361/code/lib -L/opt/local/lib -g -O2 -I/astro/grads/arh5361/code/include -I/opt/local/include -g -O2 -I/astro/grads/arh5361/code/include -I/opt/local/include -arch x86_64 build/temp.macosx-10.5-x86_64-3.3/acor/_acor.o build/temp.macosx-10.5-x86_64-3.3/acor/acor.o -L/astro/grads/arh5361/code/anaconda/lib -o build/lib.macosx-10.5-x86_64-3.3/acor/_acor.so
File "/astro/grads/arh5361/code/anaconda/lib/python3.3/site-packages/acor/acor.py", line 66
print function(x, 20000).shape
^
SyntaxError: invalid syntax
Successfully installed acor Cleaning up...
This was fixed in the GitHub version (see #3) but I've updated the PyPI version now so is should work now.
great, thanks. that seems to fix the install error, but i'm still having issues. Its not related to this issue (i think, so i'll open another issue).
Let's close this then.