[libcamera-devel,v3,0/2] Add libyuv to subprojects and download_subprojects option
mbox series

Message ID 20210203065128.1738003-1-hiroh@chromium.org
Headers show
Series
  • Add libyuv to subprojects and download_subprojects option
Related show

Message

Hirokazu Honda Feb. 3, 2021, 6:51 a.m. UTC
The first patch adds libyuv to subprojects. It downloads the
libyuv directory to the subprojects directory and the code is
built with. When I tried building libcamera with the patch in
ChromiumOS built development, I noticed the wrap-based
download is prohibited. It is reasonable to avoid a network
issue. For such an environment, the meson option,
download_subprojects, is introduced in the second patch. If
it is false, the local library is used for the build.
Fortunately, ChromiumOS has the ebuild for libyuv library.

Hirokazu Honda (2):
  subprojects: Add libyuv and built if -Dandroid=enabled
  meson: Add download_subprojects option

 README.rst              |  2 +-
 meson.build             |  2 +-
 meson_options.txt       |  5 +++++
 src/android/meson.build | 21 +++++++++++++++++++++
 subprojects/.gitignore  |  1 +
 subprojects/libyuv.wrap |  4 ++++
 6 files changed, 33 insertions(+), 2 deletions(-)
 create mode 100644 subprojects/.gitignore
 create mode 100644 subprojects/libyuv.wrap

--
2.30.0.365.g02bc693789-goog

Comments

Laurent Pinchart Feb. 3, 2021, 10:45 p.m. UTC | #1
Hi Hiro,

On Wed, Feb 03, 2021 at 06:51:26AM +0000, Hirokazu Honda wrote:
> The first patch adds libyuv to subprojects. It downloads the
> libyuv directory to the subprojects directory and the code is
> built with. When I tried building libcamera with the patch in
> ChromiumOS built development, I noticed the wrap-based
> download is prohibited. It is reasonable to avoid a network
> issue. For such an environment, the meson option,
> download_subprojects, is introduced in the second patch. If
> it is false, the local library is used for the build.
> Fortunately, ChromiumOS has the ebuild for libyuv library.

Very good point.

I've reviewed 2/2 and proposed an alternative implementation that
doesn't require a new project option. I would merge 1/2 already, but as
it would break the ebuild, I'd prefer merging the whole series in one
go.

If the solution I've proposed works fine for you, you can submit a v4 of
the whole series or only of 2/2, and I'll merge both patches.

> Hirokazu Honda (2):
>   subprojects: Add libyuv and built if -Dandroid=enabled
>   meson: Add download_subprojects option
> 
>  README.rst              |  2 +-
>  meson.build             |  2 +-
>  meson_options.txt       |  5 +++++
>  src/android/meson.build | 21 +++++++++++++++++++++
>  subprojects/.gitignore  |  1 +
>  subprojects/libyuv.wrap |  4 ++++
>  6 files changed, 33 insertions(+), 2 deletions(-)
>  create mode 100644 subprojects/.gitignore
>  create mode 100644 subprojects/libyuv.wrap