2

your help on the below would be highly appreciated.

I am working on a python project for a RPi touch screen application. This comes with some issues on SDL 2.0.9, but are supposed to be solved in later versions. I have installed 2.0.14 through compilation, but Pygame persists in using SDL 2.0.9 (latest version in apt).

How can I force Pygame to use the compiled version?

Thanks! J

Issue raised in SDL 2.0.9 (occurs upon touch):

pygame 2.0.0 (SDL 2.0.9, python 3.7.3)
Hello from the pygame community. https://www.pygame.org/contribute.html    
INFO: The key you just pressed is not recognized by SDL. To help get this fixed, please report this to the SDL forums/mailing list <https://discourse.libsdl.org/> EVDEV KeyCode 330

SDL versions installed (from apt):

dpkg -l | grep sdl

ii  libsdl2-2.0-0:armhf                  2.0.9+dfsg1-1+rpt1                  armhf        Simple DirectMedia Layer
ii  libsdl2-2.0-0-dbgsym:armhf           2.0.9+dfsg1-1+rpt1                  armhf        debug symbols for libsdl2-2.0-0
ii  libsdl2-image-2.0-0:armhf            2.0.4+dfsg1-1+deb10u1               armhf        Image loading library for Simple DirectMedia Layer 2, libraries
ii  libsdl2-mixer-2.0-0:armhf            2.0.4+dfsg1-1                       armhf        Mixer library for Simple DirectMedia Layer 2, libraries
ii  libsdl2-ttf-2.0-0:armhf              2.0.15+dfsg1-1                      armhf        TrueType Font library for Simple DirectMedia Layer 2, libraries

compiled version:

/usr/local/bin/sdl2-config --version

2.0.14
3JL
  • 53
  • 6
  • It may need to "recompile" `PyGame` Did you check on https://www.pygame.org/ ? ie. [Compilation](https://www.pygame.org/wiki/Compilation) – furas Dec 24 '20 at 09:02
  • Tried that... "Installed /usr/local/lib/python3.7/dist-packages/pygame-2.0.2.dev1-py3.7-linux-armv7l.egg" -> no effect.... – 3JL Dec 25 '20 at 13:49
  • Ok, for the above also something weird is happening: python still uses an older version of Pygame... :s – 3JL Dec 25 '20 at 15:43

1 Answers1

0

I just installed pygame in python 3.7.3 (what you have), 3.7.6 (latest v3.7.x I think), and python 3.9.1 (latest stable). In all of these versions, I am getting SDL 2.0.14. So you may just need remove the existing SDL and pygame, and reinstalling pygame should get you the later version of SDL.

0xc0de
  • 8,028
  • 5
  • 49
  • 75
  • Really weird that it does not work with me.. Could be a permission / assignment error? How can I verify? – 3JL Dec 25 '20 at 13:49