Repository navigation
replace libcamera::Span with std::span - #213
Conversation
Signed-off-by: Patrick Gehrsitz <github@mryel.de>
Signed-off-by: Patrick Gehrsitz <github@mryel.de>
|
Just updating it like this will break compilation on Bookworm and non updated libcamera version. I think this action run was done with your changes: Right now it's just deprecated and as they didn't change the libcamera version yet, it's kinda messy to distinguish between an updated Therefore my recommendation is to add a dedicated The above changes should fix the compilation error and keep backwards compatibility with Bookworm and non updated libcamera for now. P.S.: I forgot to open a PR as I got sick the day I fixed it for our pipeline 🙈 edit: Here the successful run: https://github.com/mryel00/camera-streamer/actions/runs/38812205620 |
RPi made a release on top of the master branch which is in effect an unreleased libcamera-0.8. If it helps, I'm planning to tag 0.8 early next week. |
Yeah, not the first time they did this... 🙈
For this specific case a version bump of libcamera won't help, as they already released their breaking update with 0.7.2. |
|
Alright, thanks for the feedback! Yes, these API-breaking updates are a bit annoying. They're the main reason I have to keep updating camera-streamer 😅 |
Feel free to use my branch, as I have an automated build pipeline for libcamera updates. Therefore I often find build issues within like 6-12h and try my best to fix them asap. Especially as my software is depending on it working, as the rpi software can be quite a bi*** downgrading libcamera ^^
I'm fine with both. You can even just copy my commits and add me as co-author, if you want. Just tell me your decision and I will act accordingly.
It's not my decision tbh ^^ As there are no new features recently, it most likely would be fine drop it. Further supporting it wouldn't be hard either. It would need some version check, as they were already added e.g. here: camera-streamer/device/libcamera/options.cc Lines 236 to 238 in e17a86e I can to this later this week in preparation for libcamera 0.8.0, if you want. (Have to do this anyway if Bookworm support won't get dropped) If the support would get dropped, such checks should get removed too, as most of them wouldn't be needed anymore. Anyway this would be a job for another PR ^^ |
9fabc23 to
61bf2da
Compare
|
I just replaced my commit by yours :) |
|
@kenohassler Will look tomorrow morning :) |
|
Thanks. This looks great. Lets ship it! |
|
@ayufan did you read the rest of this thread too? Especially this from kenohassler:
And my opinion on this:
edit: Additional information from kbingham for libcamera:
|
Lets wait for 0.8.x, as once the 0.8.x lands we will have a proper cutover for the changes. Now, we seem that we can compile on all platforms for time being. |
…n` now (ayufan#213) Bump the required `stdc++` to `c++20` as required by `std::span`. Signed-off-by: Patrick Gehrsitz <github@mryel.de> Co-authored-by: Patrick Gehrsitz <github@mryel.de> (cherry picked from commit aec3311)
The current version will not compile with a recent raspberry pi OS. This is due to raspberrypi/libcamera@b7694f7 dropping
libcamera::Span.This small fix bumps the C++ standard to c++20, which unlocks
std::span, and replaces two occurrences oflibcamera::Spanon our side withstd::span.