[libcamera-devel] [PATCH v3 1/4] android: Import libutils/libui headers from vndk v33
Mattijs Korpershoek
mkorpershoek at baylibre.com
Sat Sep 30 09:51:46 CEST 2023
Hi Laurent,
Thank you for your review.
On dim., sept. 24, 2023 at 18:51, Laurent Pinchart <laurent.pinchart at ideasonboard.com> wrote:
> Hi Mattijs,
>
> Thank you for the patch.
>
> On Sat, Sep 23, 2023 at 06:23:31PM +0200, Mattijs Korpershoek via libcamera-devel wrote:
>> In order to switch to the more modern GraphicBufferAllocator class, we need
>> additional compile-time dependencies.
>>
>> Import all the needed headers from the Android Vendor Native Development
>> Kit (vndk) and add them to the android_includes.
>>
>> These have been imported from:
>> URL: https://android.googlesource.com/platform/prebuilts/vndk/v33/
>
> This doesn't look like the upstream for those files, it's a prebuild
> repository for binaries, with header files that are regularly imported
> from upstream. for frameworks/native the upstream seems to be
> https://android.googlesource.com/platform/frameworks/native/, while for
> system/core it seems to be
> https://android.googlesource.com/platform/system/core/.
That's correct, and intentional. The vndk is known to provide stable
headers. However the VND and the NDK might be different versions.
>
> If we import files from those repositories, I think we should update the
> headers already included in libcamera to the same version. Mixing two
> versions seems dangerous.
Indeed
>
>> rev: 390028a9da88 ("Update VNDK snapshot v33 to build 9948968. am: 3042508aee am: 7092391a46")
>
> Would it make sense to go for a tagged release instead of the latest
> commit in the main branch ?
Yes it makes sense. I will either pick a tag from source or a release
version of the NDK.
I will add a first commit to update all existing headers to that known version.
Then I will add these headers here.
>
>> No changes have been made to the files, besides adding the SPDX comment.
>>
>> Signed-off-by: Mattijs Korpershoek <mkorpershoek at baylibre.com>
>> ---
>> .../native/libs/ui/include/ui/PixelFormat.h | 75 +++++++
>> include/android/meson.build | 2 +
>> .../system/core/libutils/include/utils/Compat.h | 94 +++++++++
>> .../system/core/libutils/include/utils/Errors.h | 78 ++++++++
>> .../system/core/libutils/include/utils/Mutex.h | 219 +++++++++++++++++++++
>> .../system/core/libutils/include/utils/Singleton.h | 102 ++++++++++
>> .../system/core/libutils/include/utils/Timers.h | 103 ++++++++++
>> 7 files changed, 673 insertions(+)
>
> [snip]
>
> --
> Regards,
>
> Laurent Pinchart
More information about the libcamera-devel
mailing list