Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Kivy installation does not find GL/gl.h?

Tags:

python

kivy

i just wanted to install kivy to test it and make some apps
i installed cython and the other things
then i typed into the terminal (ubuntu 12.04):

sudo easy_install kivy

as answer i got this:

Searching for kivy
Reading http://pypi.python.org/simple/kivy/
Best match: Kivy 1.2.0
Downloading http://pypi.python.org/packages/source/K/Kivy/Kivy-1.2.0.tar.gz#md5=468da8a353c2ea4936eb92d71403c960
Processing Kivy-1.2.0.tar.gz
Running Kivy-1.2.0/setup.py -q bdist_egg --dist-dir /tmp/easy_install-rcrkeK/Kivy-1.2.0/egg-dist-tmp-xdOqxi
[INFO   ] Kivy v1.2.0
WARNING: GLES 2.0 headers are not found
Fallback to Desktop opengl headers.
Build configuration is:
 * use_opengl_es2  =  False
 * use_glew  =  False
 * use_opengl_debug  =  False
 * use_mesagl  =  False
Generate config.h
Generate config.pxi
In file included from /tmp/easy_install-rcrkeK/Kivy-1.2.0/kivy/graphics/texture.c:273:0:
/tmp/easy_install-rcrkeK/Kivy-1.2.0/kivy/graphics/gl_redirect.h:38:22: fatal error: GL/gl.h: El fitxer o directori no existeix
compilation terminated.
 error: Setup script exited with error: command 'gcc' failed with exit status 1

did i something wrong? or do i need to install something?

P.S. sorry for the catalan El fitxer o directori no existeix means File not found.

like image 229
mid_kid Avatar asked Apr 23 '12 15:04

mid_kid


People also ask

Does Python 3.9 support Kivy?

Yes! Kivy 2.1. 0 officially supports Python versions 3.7 - 3.10. As of version 2.0.

How do I install pip on Kivy?

Open the command terminal with (kvenv), type python -m pip install kivy[full] , and press enter. Note: If you look at Kivy's website, you will see that it says to type “python -m pip install kivy[full] kivy_examples” instead of “python -m pip install kivy[full].” However, both ways will work.


2 Answers

Install libgl1-mesa-dev package through apt. Also maybe you would wish to look on building instructions at launchpad: http://bazaar.launchpad.net/~kivy-team/kivy/packaging/view/head:/debian/control

like image 182
simplylizz Avatar answered Oct 25 '22 20:10

simplylizz


You probably have to install mesa-common-dev, also see: Debian packages search.
If you have a Nvidia card, you may need to install nvidia-glx-dev.
You may experiment the same issue with the file glut.h, which is included in freeglut3-dev. Again, see the Debian packages which contain that file.

like image 32
rubik Avatar answered Oct 25 '22 21:10

rubik