-
Notifications
You must be signed in to change notification settings - Fork 31
Description
I think a sizeable use-case for this library is to develop libcamera
applications for raspberry pi devices - at least that is my use case. The problem is that these devices can be very underpowered with regards to software development and compiling programs.
I have therefore been spending the last couple of days on and off trying to get cross compilation working - I think I'm getting pretty close now.
I am using this repo to provide the cross compilation toolchain binaries, as well as a basic sysroot
directory. It is missing a couple of things:
-
GLIBC is v2.27, but we need at least v2.30. I think this is just a case of updating the configs and re-running the github action on the above-linked repo.
-
It doesn't have an up to date
libcamera
compiled within it. I have currently circumvented this problem by compilinglibcamera
on my raspberry pi 0 and copy the appropriate files to thesysroot
of the above toolchain.
There is one more oddity that I have come across, regarding stream.h
. The static assertion on line 24 static_assert(sizeof(struct libcamera_stream_configuration) == sizeof(libcamera_stream_configuration_t));
fails (112 == 88)... and I'm not sure why (something to do with host being 64-bit and target being 32-bit?) . Naively commenting the line out at least lets me compile camera_c_api
, before getting the errors numbered above. I don't know why that static assertion is required in the first place, or why those two sizes would be different.