SDL2 on Raspberry Pi without X?
问题 I'm hoping to develop some code that uses SDL2 to display graphics on the 7" RPi touchscreen, but I'd rather not install a full desktop OS. I've got Raspbian Buster Lite installed. Some simple test code gets an error when I try to run it: user@rpi4:~/01_hello_SDL $ ./hw Window could not be created! SDL_Error: Could not initialize EGL user@rpi4:~/01_hello_SDL $ sudo ./hw error: XDG_RUNTIME_DIR not set in the environment. Window could not be created! SDL_Error: Could not initialize EGL I'm