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

Build fails due to missing header files #81

Open
SvenMichaelKlose opened this issue Sep 28, 2024 · 4 comments
Open

Build fails due to missing header files #81

SvenMichaelKlose opened this issue Sep 28, 2024 · 4 comments

Comments

@SvenMichaelKlose
Copy link

Latest Raspi OS Lite 32-bit on RPI-3A:

gcc -Wall -Wextra -pedantic -I. -I./raylib -I/opt/vc/include/ -march=armv8-a -mfloat-abi=hard -mfpu=neon-fp-armv8 -O3 -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -lstdc++ -c -o platforms/amiga/rtg/rtg-output-raylib.o platforms/amiga/rtg/rtg-output-raylib.c
platforms/amiga/rtg/rtg-output-raylib.c:17:10: fatal error: interface/vmcs_host/vc_tvservice.h: No such file or directory
17 | #include "interface/vmcs_host/vc_tvservice.h"
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make: *** [: platforms/amiga/rtg/rtg-output-raylib.o] Error 1

@Skelbagz
Copy link

Skelbagz commented Oct 5, 2024

There is a comment in the README.md file which addresses this issue. I would also make sure (if you are using the RPi imager) to select Raspberry Pi OS (Legacy, 32 bit) Lite as the ISO to use.

Important note: If you are using Raspberry Pi OS "Bullseye", the main graphics backend for the OS has changed from dispmanx to DRM, and you need to follow these steps instead of just running make:

  • First run sudo apt-get install libdrm-dev libegl1-mesa-dev libgles2-mesa-dev libgbm-dev to install the DRM OpenGL/ES libraries, which are for some reason not included with the distro by default. These are necessary to link the graphics output library (raylib).
  • Then finally, run make PLATFORM=PI3_BULLSEYE for the emulator to compile successfully.

@SvenMichaelKlose
Copy link
Author

Thanks! I used that image. It's a friend's dream to have that thing installed, so I'll have to check it out later.

@StrayDogge
Copy link

StrayDogge commented Jan 2, 2025

The latest Raspberry PI OS image - as of writing this - is 12 (bookworm). It won't have the /usr/include/interface/vmcs_host/vc_tvservice.h header and none of the packages mentioned in the README will add it. Hence any user will run into this same issue. I had to reinstall the OS image using the legacy bullseye version to successfully compile the emulator.

@JoshS80
Copy link

JoshS80 commented Jan 14, 2025

For anyone using Raspberry Pi OS 12 (bookworm), the failure finding header file vc_tvservice.h can be resolved by adding libraspberrypi-dev to the apt-get command line used for Raspberry Pi OS 11 (bullseye). So the apt-get command line would become sudo apt-get install libdrm-dev libegl1-mesa-dev libgles2-mesa-dev libgbm-dev libraspberrypi-dev. Then run the make command as already indicated for "bullseye".

Doing this I was able to get the build working with "bookworm" and running the emulator binary seems to work properly. If needed I could submit a PR to update the readme.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants