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

Clean cython build error #1792

Closed
brussee opened this issue Dec 14, 2015 · 7 comments
Closed

Clean cython build error #1792

brussee opened this issue Dec 14, 2015 · 7 comments

Comments

@brussee
Copy link
Member

brussee commented Dec 14, 2015

From: https://gist.github.com/brussee/bc376f8491a9e2ac42a4

Check build dependencies for Ubuntu
Packages missing: cython 
It might break the compilation, except if you installed thoses packages manually.
Check environment
**snip**
kivy/graphics/vbo.c:1:2: error: #error Do not use this file, it is the result of a failed Cython compilation.
 #error Do not use this file, it is the result of a failed Cython compilation.
  ^
 error: command 'arm-linux-androideabi-gcc' failed with exit status 1

As per instructions I did install manually: https://buildozer.readthedocs.org/en/latest/installation.html?highlight=cython

$ sudo pip install --upgrade cython

The directory '/home/paul/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
The directory '/home/paul/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Requirement already up-to-date: cython in /usr/local/lib/python2.7/dist-packages
@whirm
Copy link

whirm commented Dec 14, 2015

For higienic reasons, don't install pip stuff as root. Use --user instead so it gets installed into your $HOME.

@brussee
Copy link
Member Author

brussee commented Dec 14, 2015

I cleaned up as much of the pip packages I could and reinstalled them as --user.

Did this for Ubuntu: http://kivy.org/docs/installation/installation-linux.html
Choose Kivy nightly build 1.9.1 with OS cython 0.23.3 and python cython 0.23.4

Also manually removed /python-4-android/build and buildozer distclean and android clean.

@brussee
Copy link
Member Author

brussee commented Dec 14, 2015

Now I get this: https://gist.github.com/brussee/f90753397393bd61310d

running build_ext
failed to import Cython: /home/paul/.local/lib/python2.7/site-packages/Cython/Compiler/Scanning.so:
undefined symbol: PyUnicodeUCS4_DecodeUTF8
error: Cython does not appear to be installed

Following advice from: http://stackoverflow.com/questions/16871799/trying-to-import-a-module-undefined-symbol-pyunicodeucs4-decodeutf8

@whirm
Copy link

whirm commented Dec 14, 2015

I may be finding the wrong libraries (maybe some of the manually instaled stuff?).
Do an ldd /home/paul/.local/lib/python2.7/site-packages/Cython/Compiler/Scanning.so to see if it's finding the wrong stuff.

@brussee
Copy link
Member Author

brussee commented Dec 14, 2015

$ ldd /home/paul/.local/lib/python2.7/site-packages/Cython/Compiler/Scanning.so
linux-vdso.so.1 => (0x00007ffc86fb0000)
libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007fbd309a6000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007fbd305dc000)
/lib64/ld-linux-x86-64.so.2 (0x00005595e2cde000)

According to the code from: https://docs.python.org/2.7/faq/extending.html#when-importing-module-x-why-do-i-get-undefined-symbol-pyunicodeucs2
I do have the appropriate python build.... (>>> sys.maxunicode 1114111)

@whirm
Copy link

whirm commented Dec 15, 2015

I'll come by in a bit and we can have a look at it.

@brussee
Copy link
Member Author

brussee commented Jan 29, 2016

Aborted this approach last year. Switched to the new p4a toolchain.

@brussee brussee closed this as completed Jan 29, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants