[{"id":16943,"web_url":"https://patchwork.libcamera.org/comment/16943/","msgid":"<e41d4dce-cd74-2f7a-8d99-744ef99b2f45@ideasonboard.com>","date":"2021-05-14T09:33:21","subject":"Re: [libcamera-devel] [PATCH v1 2/6] ipa: meson: Install mojom\n\tgenerated headers to include paths","submitter":{"id":4,"url":"https://patchwork.libcamera.org/api/people/4/","name":"Kieran Bingham","email":"kieran.bingham@ideasonboard.com"},"content":"Hi Umang,\n\nOn 14/05/2021 08:58, Umang Jain wrote:\n> Generated IPA headers from mojom files need to be installed sy\n\nsy? Perhaps in? or to?\n\n> $INCLUDE_PATH in order to be available system-wide. Without this,\n> out-of-tree IPAs won't be able to link and build themselves.\n> \n> Signed-off-by: Umang Jain <umang.jain@ideasonboard.com>\n\nSeems like the right things to do.\n\nReviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>\n\n> ---\n>  include/libcamera/ipa/meson.build | 8 +++++++-\n>  1 file changed, 7 insertions(+), 1 deletion(-)\n> \n> diff --git a/include/libcamera/ipa/meson.build b/include/libcamera/ipa/meson.build\n> index 69bc855e..da60aa68 100644\n> --- a/include/libcamera/ipa/meson.build\n> +++ b/include/libcamera/ipa/meson.build\n> @@ -1,5 +1,7 @@\n>  # SPDX-License-Identifier: CC0-1.0\n>  \n> +libcamera_ipa_include_dir = libcamera_include_dir / 'ipa'\n> +\n>  libcamera_ipa_headers = files([\n>      'ipa_controls.h',\n>      'ipa_interface.h',\n> @@ -11,7 +13,7 @@ libcamera_ipa_docs = files([\n>  ])\n>  \n>  install_headers(libcamera_ipa_headers,\n> -                subdir: libcamera_include_dir / 'ipa')\n> +                subdir: libcamera_ipa_include_dir)\n>  \n>  libcamera_generated_ipa_headers = []\n>  \n> @@ -35,6 +37,8 @@ libcamera_generated_ipa_headers += custom_target('core_ipa_interface_h',\n>                    input : ipa_mojom_core,\n>                    output : 'core_ipa_interface.h',\n>                    depends : mojom_templates,\n> +                  install : true,\n> +                  install_dir : get_option('includedir') / libcamera_ipa_include_dir,\n>                    command : [\n>                        mojom_generator, 'generate',\n>                        '-g', 'libcamera',\n> @@ -97,6 +101,8 @@ foreach file : ipa_mojom_files\n>                             input : mojom,\n>                             output : name + '_ipa_interface.h',\n>                             depends : mojom_templates,\n> +                           install : true,\n> +                           install_dir : get_option('includedir') / libcamera_ipa_include_dir,\n>                             command : [\n>                                 mojom_generator, 'generate',\n>                                 '-g', 'libcamera',\n>","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 255A6C31F8\n\tfor <parsemail@patchwork.libcamera.org>;\n\tFri, 14 May 2021 09:33:26 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id DAC7D68918;\n\tFri, 14 May 2021 11:33:25 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 435A268911\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 14 May 2021 11:33:24 +0200 (CEST)","from [192.168.0.20]\n\t(cpc89244-aztw30-2-0-cust3082.18-1.cable.virginm.net [86.31.172.11])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id ADA779F0;\n\tFri, 14 May 2021 11:33:23 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"Q9iahkAS\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1620984803;\n\tbh=EXmRNWJ8rLcV/kKwQwGviNzarM3kBIh2hoo0ymPDFAU=;\n\th=Reply-To:To:References:From:Subject:Date:In-Reply-To:From;\n\tb=Q9iahkAShOK/j9uJaUXuDBaP/JTKjBkQHCqgXahmdDhJgn17A0flV/HP3MQaJKNqW\n\t8/aT0wMS5uziMBxSOUBbBPtoWZcYIN3HLD4L8pIHLETRNOBcbrIv2b3v/OGMwmJ/01\n\tYiEAjXdeE42wdokIWLHIWwF7mL5c31XVBkMx2es8=","To":"Umang Jain <umang.jain@ideasonboard.com>,\n\tlibcamera-devel@lists.libcamera.org","References":"<20210514075808.282479-1-umang.jain@ideasonboard.com>\n\t<20210514075808.282479-3-umang.jain@ideasonboard.com>","From":"Kieran Bingham <kieran.bingham@ideasonboard.com>","Organization":"Ideas on Board","Message-ID":"<e41d4dce-cd74-2f7a-8d99-744ef99b2f45@ideasonboard.com>","Date":"Fri, 14 May 2021 10:33:21 +0100","User-Agent":"Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101\n\tThunderbird/78.7.1","MIME-Version":"1.0","In-Reply-To":"<20210514075808.282479-3-umang.jain@ideasonboard.com>","Content-Language":"en-GB","Subject":"Re: [libcamera-devel] [PATCH v1 2/6] ipa: meson: Install mojom\n\tgenerated headers to include paths","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Reply-To":"kieran.bingham@ideasonboard.com","Content-Type":"text/plain; charset=\"us-ascii\"","Content-Transfer-Encoding":"7bit","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":16947,"web_url":"https://patchwork.libcamera.org/comment/16947/","msgid":"<7897c340-310e-3ddd-e553-43a68e7a9007@ideasonboard.com>","date":"2021-05-14T10:09:18","subject":"Re: [libcamera-devel] [PATCH v1 4/6] meson: Add a configuration\n\toption to build IPAs","submitter":{"id":4,"url":"https://patchwork.libcamera.org/api/people/4/","name":"Kieran Bingham","email":"kieran.bingham@ideasonboard.com"},"content":"Hi Umang,\n\nOn 14/05/2021 08:58, Umang Jain wrote:\n> There can be multiple IPAs per pipeline-handler or platform.\n> For e.g., the IPU3 platform has a open source IPA in-tree whereas\n> it shall use a closed source one from a standalone separate remote\n> for ChromeOS. In a case like this, there should be configure-time\n> option whether to build the in-tree IPAs or not.\n\nWe don't need to state where external IPAs will be used. That's just\nthis current use case, and it may not be true.\n\nThey might use it. Or they might choose to use the open one. That's up\nto them, not us.\n\n\n> By default, all in-tree IPAs are built.\n\n\n\n> \n> Signed-off-by: Umang Jain <umang.jain@ideasonboard.com>\n> ---\n>  meson.build                     | 1 +\n>  meson_options.txt               | 5 +++++\n>  src/ipa/ipu3/meson.build        | 4 ++++\n>  src/ipa/meson.build             | 2 ++\n>  src/ipa/raspberrypi/meson.build | 4 ++++\n>  src/ipa/rkisp1/meson.build      | 4 ++++\n>  src/ipa/vimc/meson.build        | 4 ++++\n>  7 files changed, 24 insertions(+)\n> \n> diff --git a/meson.build b/meson.build\n> index fa2a62cf..b89797f3 100644\n> --- a/meson.build\n> +++ b/meson.build\n> @@ -167,6 +167,7 @@ py_mod.find_installation('python3', modules: py_modules)\n>  ## Summarise Configurations\n>  summary({\n>              'Enabled pipelines': pipelines,\n> +            'Enabled IPAs': ipas,\n>              'Android support': android_enabled,\n>              'GStreamer support': gst_enabled,\n>              'V4L2 emulation support': v4l2_enabled,\n> diff --git a/meson_options.txt b/meson_options.txt\n> index 69f11f85..1fcbecc1 100644\n> --- a/meson_options.txt\n> +++ b/meson_options.txt\n> @@ -25,6 +25,11 @@ option('gstreamer',\n>          value : 'auto',\n>          description : 'Compile libcamera GStreamer plugin')\n>  \n> +option('ipas',\n> +        type : 'array',\n> +        choices : ['ipu3', 'raspberrypi', 'rkisp1', 'vimc'],\n> +        description : 'Select which internal IPA to include')\n\nI know this description comes from the pipelines option, but 'include'\ndoesn't sound right to me.\n\nThis decides which ones get built. I'd prefer something like\n\t\"Select which IPA modules to build\"\n\n\n\n> +\n>  option('lc-compliance',\n>          type : 'feature',\n>          value : 'auto',\n> diff --git a/src/ipa/ipu3/meson.build b/src/ipa/ipu3/meson.build\n> index 0d843846..a9f5d0aa 100644\n> --- a/src/ipa/ipu3/meson.build\n> +++ b/src/ipa/ipu3/meson.build\n> @@ -2,6 +2,10 @@\n>  \n>  ipa_name = 'ipa_ipu3'\n>  \n> +if 'ipu3' not in ipas\n> +    subdir_done()\n> +endif\n\nYou shouldn't need this.\n\nIf ipu3 isn't specified in get_option('ipas') then it won't go into the\nsubdir.\n\n\n> +\n>  ipu3_ipa_sources = files([\n>      'ipu3.cpp',\n>      'ipu3_agc.cpp',\n> diff --git a/src/ipa/meson.build b/src/ipa/meson.build\n> index 5b5684a1..fb687497 100644\n> --- a/src/ipa/meson.build\n> +++ b/src/ipa/meson.build\n> @@ -22,6 +22,8 @@ ipa_sign = files('ipa-sign.sh')\n>  ipas = ['ipu3', 'raspberrypi', 'rkisp1', 'vimc']\n>  ipa_names = []\n>  \n> +ipas = get_option('ipas')\n\nI think you forgot to remove the ipas list 3 lines above it.\nThis should replace that line.\n\n\n> +\n>  # The ipa-sign-install.sh script which uses the ipa_names variable will itself\n>  # prepend MESON_INSTALL_DESTDIR_PREFIX to each ipa module name, therefore we\n>  # must not include the prefix string here.\n> diff --git a/src/ipa/raspberrypi/meson.build b/src/ipa/raspberrypi/meson.build\n> index d1397a32..02c143b1 100644\n> --- a/src/ipa/raspberrypi/meson.build\n> +++ b/src/ipa/raspberrypi/meson.build\n> @@ -2,6 +2,10 @@\n>  \n>  ipa_name = 'ipa_rpi'\n>  \n> +if 'rasberrypi' not in ipas\n> +    subdir_done()\n> +endif\n\nThis isn't needed.\n\n\n> +\n>  rpi_ipa_deps = [\n>      libcamera_dep,\n>      dependency('boost'),\n> diff --git a/src/ipa/rkisp1/meson.build b/src/ipa/rkisp1/meson.build\n> index 1a1c7159..eecc5877 100644\n> --- a/src/ipa/rkisp1/meson.build\n> +++ b/src/ipa/rkisp1/meson.build\n> @@ -2,6 +2,10 @@\n>  \n>  ipa_name = 'ipa_rkisp1'\n>  \n> +if 'rkisp1' not in ipas\n> +    subdir_done()\n> +endif\n\nsame.\n\n> +\n>  mod = shared_module(ipa_name,\n>                      ['rkisp1.cpp', libcamera_generated_ipa_headers],\n>                      name_prefix : '',\n> diff --git a/src/ipa/vimc/meson.build b/src/ipa/vimc/meson.build\n> index a35825ae..a41a0407 100644\n> --- a/src/ipa/vimc/meson.build\n> +++ b/src/ipa/vimc/meson.build\n> @@ -2,6 +2,10 @@\n>  \n>  ipa_name = 'ipa_vimc'\n>  \n> +if 'ipu3' not in ipas\n> +    subdir_done()\n> +endif\n\n\nsame.\n\n\n> +\n>  mod = shared_module(ipa_name,\n>                      ['vimc.cpp', libcamera_generated_ipa_headers],\n>                      name_prefix : '',\n>","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 0EEDEC31F8\n\tfor <parsemail@patchwork.libcamera.org>;\n\tFri, 14 May 2021 10:09:24 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 660D868919;\n\tFri, 14 May 2021 12:09:23 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 2B75C602B5\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 14 May 2021 12:09:22 +0200 (CEST)","from [192.168.0.20]\n\t(cpc89244-aztw30-2-0-cust3082.18-1.cable.virginm.net [86.31.172.11])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 9C0029F0;\n\tFri, 14 May 2021 12:09:21 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"bNi8FHi8\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1620986961;\n\tbh=3TzsTGNA7bWjOsq2EnUgq5hf3Nv25FJtcMBEMhR3Hz4=;\n\th=Reply-To:To:References:From:Subject:Date:In-Reply-To:From;\n\tb=bNi8FHi8KBKYIJVq8Mf+BVoyIbeuSHa3oLyPzPwJkDdd1KBI7r/UfFcITnVjGhfqk\n\tSPtlc2+48oquhZk2STW1BgoCOF1cMu82fU4vzjhfnCKSLeMySfaDYWswkgza3X8w2r\n\tqwio7DuIBVVmeJEYUN/r4J6lNR6qWqCv2o3X0Ta8=","To":"Umang Jain <umang.jain@ideasonboard.com>,\n\tlibcamera-devel@lists.libcamera.org","References":"<20210514075808.282479-1-umang.jain@ideasonboard.com>\n\t<20210514075808.282479-5-umang.jain@ideasonboard.com>","From":"Kieran Bingham <kieran.bingham@ideasonboard.com>","Organization":"Ideas on Board","Message-ID":"<7897c340-310e-3ddd-e553-43a68e7a9007@ideasonboard.com>","Date":"Fri, 14 May 2021 11:09:18 +0100","User-Agent":"Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101\n\tThunderbird/78.7.1","MIME-Version":"1.0","In-Reply-To":"<20210514075808.282479-5-umang.jain@ideasonboard.com>","Content-Language":"en-GB","Subject":"Re: [libcamera-devel] [PATCH v1 4/6] meson: Add a configuration\n\toption to build IPAs","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Reply-To":"kieran.bingham@ideasonboard.com","Content-Type":"text/plain; charset=\"us-ascii\"","Content-Transfer-Encoding":"7bit","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":16948,"web_url":"https://patchwork.libcamera.org/comment/16948/","msgid":"<57bfd8d5-c038-4799-2891-16fb550ef8f8@ideasonboard.com>","date":"2021-05-14T10:34:51","subject":"Re: [libcamera-devel] [PATCH v1 5/6] meson: Generate a helper .so\n\tcontaining libcamera's internal headers","submitter":{"id":4,"url":"https://patchwork.libcamera.org/api/people/4/","name":"Kieran Bingham","email":"kieran.bingham@ideasonboard.com"},"content":"Hi Umang,\n\nOn 14/05/2021 08:58, Umang Jain wrote:\n> The IPU3 closed source IPA shall live externally(out-of-tree) however,\n> it needs access to some of the internal libcamera headers. These headers\n> are not typically intended for public usage hence, shouldn't be placed\n> as  headers in $includedir. In order to solve this issue, generate a\n> helper shared library, which can be used to link with, by the external\n> IPU3 closed source IPA.\n\nThis is a much bigger task than just sharing the headers.\nHeaders should be accompanied with implementation.\n\n\n\n> Signed-off-by: Umang Jain <umang.jain@ideasonboard.com>\n> ---\n>  include/libcamera/internal/meson.build | 6 ++++++\n>  meson.build                            | 7 +++++++\n>  src/libcamera/meson.build              | 6 ++++++\n>  3 files changed, 19 insertions(+)\n> \n> diff --git a/include/libcamera/internal/meson.build b/include/libcamera/internal/meson.build\n> index 6cff1b90..fcbf4212 100644\n> --- a/include/libcamera/internal/meson.build\n> +++ b/include/libcamera/internal/meson.build\n> @@ -49,3 +49,9 @@ libcamera_internal_headers = files([\n>      'v4l2_subdevice.h',\n>      'v4l2_videodevice.h',\n>  ])\n> +\n> +libcamera_helpers = files ([\n> +    'buffer.h',\n> +    'file.h',\n> +    'log.h',\n> +])\n> diff --git a/meson.build b/meson.build\n> index b89797f3..c48c5a66 100644\n> --- a/meson.build\n> +++ b/meson.build\n> @@ -160,6 +160,13 @@ pkg_mod.generate(libraries : libcamera,\n>                   description : 'Complex Camera Support Library',\n>                   subdirs : 'libcamera')\n>  \n> +# \\todo Bikeshedding on camera_helper naming\n> +pkg_mod.generate(libraries : libcamera_helper_lib,\n> +                 version : '0.0',\n> +                 name : 'libcamera_helper_lib',\n> +                 filebase : 'camera_helper',\n> +                 description : 'libcamera internal helper library')\n> +\n>  # Check for python installation and modules.\n>  py_mod = import('python')\n>  py_mod.find_installation('python3', modules: py_modules)\n> diff --git a/src/libcamera/meson.build b/src/libcamera/meson.build\n> index 7bc59b84..788b767d 100644\n> --- a/src/libcamera/meson.build\n> +++ b/src/libcamera/meson.build\n> @@ -162,4 +162,10 @@ libcamera_dep = declare_dependency(sources : [\n>                                     include_directories : libcamera_includes,\n>                                     link_with : libcamera)\n>  \n> +# libcamera helper shared library\n> +libcamera_helper_lib = shared_library('camera_helper', [libcamera_helpers],\n> +                                      install: true,\n> +                                      install_dir: libcamera_libdir,\n> +                                      dependencies: libcamera_dep)\n\nAs a separate library, it should be separated from src/libcamera\n\nSo dependant upon the name selected this should have it's own structure\n\n include/\n\tlibcamera-support/\n\t\tfile.h\n\t\tlog.h\n\t\tbuffer.h\n\n src/\n\tlibcamera-support/\n\t\tfile.cpp\n\t\tlog.cpp\n\t\tbuffer.cpp\n\nAnd then libcamera should link against it. But things are not that\nsimple, and the dependencies between all these are quite convoluted.\n\n\nOf course the library name is hard to choose.\nIt could be\n\tlibcamera-helper,\n\tlibcamera-utils,\n\tlibcamera-support,\n\tlibcamera-internal ...\n\n\nAnd then the scope of what goes in there could be interesting too.\n\nlog and file are system helpers, accessing files and generic logging.\nBuffers are (our) common buffer abstraction\n\n\n\nBut there's others to consider (in the future, not necessarily immediately)\n\n\n## definitely libcamera internal?\n\nbyte_stream_buffer.h\ncamera_controls.h\ncamera_sensor.h\ncamera_sensor.h.orig\ncamera_sensor_properties.h\ncontrol_serializer.h\ncontrol_validator.h\ndelayed_controls.h\nevent_dispatcher.h\nevent_dispatcher_poll.h\nevent_notifier.h\nipa_data_serializer.h\nipa_manager.h\nipa_module.h\nipa_proxy.h\npipeline_handler.h\ntracepoints\nutils.h\n\n\n# Linux V4L2/MediaController/Pixel Formats / buffers\ndevice_enumerator.h\ndevice_enumerator_sysfs.h\ndevice_enumerator_udev.h\nmedia_device.h\nmedia_object.h\nv4l2_controls.h\nv4l2_device.h\nv4l2_pixelformat.h\nv4l2_subdevice.h\nv4l2_videodevice.h\n\n\n# Pixel Formats and buffers\nbayer_format.h\nbuffer.h\nformats.h\n\n\n# Operating system specific abstractions ?\nfile.h\nipc_pipe.h\nipc_pipe_unixsocket.h\nipc_unixsocket.h\nlog.h\nmessage.h\nprocess.h\npub_key.h\nsemaphore.h\nsysfs.h\nthread.h\ntimer.h\n\n\n\n\n\n\n\n> +\n>  subdir('proxy/worker')\n>","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 46B7DC31F6\n\tfor <parsemail@patchwork.libcamera.org>;\n\tFri, 14 May 2021 10:34:57 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id A93B26153C;\n\tFri, 14 May 2021 12:34:56 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 33905602B5\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 14 May 2021 12:34:55 +0200 (CEST)","from [192.168.0.20]\n\t(cpc89244-aztw30-2-0-cust3082.18-1.cable.virginm.net [86.31.172.11])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 73B7A3E5;\n\tFri, 14 May 2021 12:34:54 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"bWWDSPcv\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1620988494;\n\tbh=oroJu96G3EGIodMZItX/FzTklrT21B1EN0bpMRFyrd0=;\n\th=Reply-To:To:References:From:Subject:Date:In-Reply-To:From;\n\tb=bWWDSPcv4X+VJmZAyRAEl2VDt+OqaQubrrvpaBTkd2hDalrKNdnItHQV3LNnTu/Ko\n\tVlN2rq9aH1G5PfHHL/AwPYgdgkSYRh3ZWAUFnvaOxpCaU+1/IhO2Ca7fVax6YB1OCH\n\tf68rYVsdG4Xo32+YnxfkGLy8GrdtgSP9q/DJNQHY=","To":"Umang Jain <umang.jain@ideasonboard.com>,\n\tlibcamera-devel@lists.libcamera.org","References":"<20210514075808.282479-1-umang.jain@ideasonboard.com>\n\t<20210514075808.282479-6-umang.jain@ideasonboard.com>","From":"Kieran Bingham <kieran.bingham@ideasonboard.com>","Organization":"Ideas on Board","Message-ID":"<57bfd8d5-c038-4799-2891-16fb550ef8f8@ideasonboard.com>","Date":"Fri, 14 May 2021 11:34:51 +0100","User-Agent":"Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101\n\tThunderbird/78.7.1","MIME-Version":"1.0","In-Reply-To":"<20210514075808.282479-6-umang.jain@ideasonboard.com>","Content-Language":"en-GB","Subject":"Re: [libcamera-devel] [PATCH v1 5/6] meson: Generate a helper .so\n\tcontaining libcamera's internal headers","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Reply-To":"kieran.bingham@ideasonboard.com","Content-Type":"text/plain; charset=\"us-ascii\"","Content-Transfer-Encoding":"7bit","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":16955,"web_url":"https://patchwork.libcamera.org/comment/16955/","msgid":"<YJ/2i0L72yRQU1L3@pendragon.ideasonboard.com>","date":"2021-05-15T16:27:55","subject":"Re: [libcamera-devel] [PATCH v1 2/6] ipa: meson: Install mojom\n\tgenerated headers to include paths","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/people/2/","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"content":"On Fri, May 14, 2021 at 10:33:21AM +0100, Kieran Bingham wrote:\n> On 14/05/2021 08:58, Umang Jain wrote:\n> > Generated IPA headers from mojom files need to be installed sy\n> \n> sy? Perhaps in? or to?\n> \n> > $INCLUDE_PATH in order to be available system-wide. Without this,\n> > out-of-tree IPAs won't be able to link and build themselves.\n> > \n> > Signed-off-by: Umang Jain <umang.jain@ideasonboard.com>\n> \n> Seems like the right things to do.\n> \n> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>\n\nAgreed,\n\nReviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n\n> > ---\n> >  include/libcamera/ipa/meson.build | 8 +++++++-\n> >  1 file changed, 7 insertions(+), 1 deletion(-)\n> > \n> > diff --git a/include/libcamera/ipa/meson.build b/include/libcamera/ipa/meson.build\n> > index 69bc855e..da60aa68 100644\n> > --- a/include/libcamera/ipa/meson.build\n> > +++ b/include/libcamera/ipa/meson.build\n> > @@ -1,5 +1,7 @@\n> >  # SPDX-License-Identifier: CC0-1.0\n> >  \n> > +libcamera_ipa_include_dir = libcamera_include_dir / 'ipa'\n> > +\n> >  libcamera_ipa_headers = files([\n> >      'ipa_controls.h',\n> >      'ipa_interface.h',\n> > @@ -11,7 +13,7 @@ libcamera_ipa_docs = files([\n> >  ])\n> >  \n> >  install_headers(libcamera_ipa_headers,\n> > -                subdir: libcamera_include_dir / 'ipa')\n> > +                subdir: libcamera_ipa_include_dir)\n> >  \n> >  libcamera_generated_ipa_headers = []\n> >  \n> > @@ -35,6 +37,8 @@ libcamera_generated_ipa_headers += custom_target('core_ipa_interface_h',\n> >                    input : ipa_mojom_core,\n> >                    output : 'core_ipa_interface.h',\n> >                    depends : mojom_templates,\n> > +                  install : true,\n> > +                  install_dir : get_option('includedir') / libcamera_ipa_include_dir,\n> >                    command : [\n> >                        mojom_generator, 'generate',\n> >                        '-g', 'libcamera',\n> > @@ -97,6 +101,8 @@ foreach file : ipa_mojom_files\n> >                             input : mojom,\n> >                             output : name + '_ipa_interface.h',\n> >                             depends : mojom_templates,\n> > +                           install : true,\n> > +                           install_dir : get_option('includedir') / libcamera_ipa_include_dir,\n> >                             command : [\n> >                                 mojom_generator, 'generate',\n> >                                 '-g', 'libcamera',","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 39789C31FB\n\tfor <parsemail@patchwork.libcamera.org>;\n\tSat, 15 May 2021 16:28:08 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 670486891D;\n\tSat, 15 May 2021 18:28:07 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id A85BE6891A\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tSat, 15 May 2021 18:28:05 +0200 (CEST)","from pendragon.ideasonboard.com (62-78-145-57.bb.dnainternet.fi\n\t[62.78.145.57])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 12504436;\n\tSat, 15 May 2021 18:28:04 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"ft9h47d1\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1621096085;\n\tbh=JFcuoTbVv9tveDuv9tKlMq5+N0OL2Oo4IVGWXM1pQ3k=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=ft9h47d1FpPpSt5DKxM7DQboy+ZRuWuHdC+JFPMitlKesgyXqzZu2iiMGZdAepLXR\n\t47d3foy0Zp3T2SoqStLwOiDP+qY/yPb7nbvNUmooyzs4FFtLVWUu9SfKn8eH3YPA+b\n\tQGjeQ+kwP+kKYyw/YRnBCOuycdWMtt9vkFmO2rKM=","Date":"Sat, 15 May 2021 19:27:55 +0300","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"Kieran Bingham <kieran.bingham@ideasonboard.com>","Message-ID":"<YJ/2i0L72yRQU1L3@pendragon.ideasonboard.com>","References":"<20210514075808.282479-1-umang.jain@ideasonboard.com>\n\t<20210514075808.282479-3-umang.jain@ideasonboard.com>\n\t<e41d4dce-cd74-2f7a-8d99-744ef99b2f45@ideasonboard.com>","MIME-Version":"1.0","Content-Disposition":"inline","In-Reply-To":"<e41d4dce-cd74-2f7a-8d99-744ef99b2f45@ideasonboard.com>","Subject":"Re: [libcamera-devel] [PATCH v1 2/6] ipa: meson: Install mojom\n\tgenerated headers to include paths","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Cc":"libcamera-devel@lists.libcamera.org","Content-Type":"text/plain; charset=\"us-ascii\"","Content-Transfer-Encoding":"7bit","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":16957,"web_url":"https://patchwork.libcamera.org/comment/16957/","msgid":"<YJ/4OgvYORTnpDlX@pendragon.ideasonboard.com>","date":"2021-05-15T16:35:06","subject":"Re: [libcamera-devel] [PATCH v1 4/6] meson: Add a configuration\n\toption to build IPAs","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/people/2/","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"content":"Hi Umang,\n\nThank you for the patch.\n\nOn Fri, May 14, 2021 at 11:09:18AM +0100, Kieran Bingham wrote:\n> On 14/05/2021 08:58, Umang Jain wrote:\n> > There can be multiple IPAs per pipeline-handler or platform.\n> > For e.g., the IPU3 platform has a open source IPA in-tree whereas\n\ns/a open/an open/\n\n> > it shall use a closed source one from a standalone separate remote\n> > for ChromeOS. In a case like this, there should be configure-time\n> > option whether to build the in-tree IPAs or not.\n> \n> We don't need to state where external IPAs will be used. That's just\n> this current use case, and it may not be true.\n> \n> They might use it. Or they might choose to use the open one. That's up\n> to them, not us.\n> \n> > By default, all in-tree IPAs are built.\n> > \n> > Signed-off-by: Umang Jain <umang.jain@ideasonboard.com>\n> > ---\n> >  meson.build                     | 1 +\n> >  meson_options.txt               | 5 +++++\n> >  src/ipa/ipu3/meson.build        | 4 ++++\n> >  src/ipa/meson.build             | 2 ++\n> >  src/ipa/raspberrypi/meson.build | 4 ++++\n> >  src/ipa/rkisp1/meson.build      | 4 ++++\n> >  src/ipa/vimc/meson.build        | 4 ++++\n> >  7 files changed, 24 insertions(+)\n> > \n> > diff --git a/meson.build b/meson.build\n> > index fa2a62cf..b89797f3 100644\n> > --- a/meson.build\n> > +++ b/meson.build\n> > @@ -167,6 +167,7 @@ py_mod.find_installation('python3', modules: py_modules)\n> >  ## Summarise Configurations\n> >  summary({\n> >              'Enabled pipelines': pipelines,\n> > +            'Enabled IPAs': ipas,\n\nI'd write 'Enabled IPA modules', and perhaps rename the ipas variable to\nipa_modules.\n\n> >              'Android support': android_enabled,\n> >              'GStreamer support': gst_enabled,\n> >              'V4L2 emulation support': v4l2_enabled,\n> > diff --git a/meson_options.txt b/meson_options.txt\n> > index 69f11f85..1fcbecc1 100644\n> > --- a/meson_options.txt\n> > +++ b/meson_options.txt\n> > @@ -25,6 +25,11 @@ option('gstreamer',\n> >          value : 'auto',\n> >          description : 'Compile libcamera GStreamer plugin')\n> >  \n> > +option('ipas',\n\nWe could also rename the option to ipa_modules.\n\n> > +        type : 'array',\n> > +        choices : ['ipu3', 'raspberrypi', 'rkisp1', 'vimc'],\n> > +        description : 'Select which internal IPA to include')\n\n'IPA modules' here too.\n\n> I know this description comes from the pipelines option, but 'include'\n> doesn't sound right to me.\n> \n> This decides which ones get built. I'd prefer something like\n> \t\"Select which IPA modules to build\"\n> \n> > +\n> >  option('lc-compliance',\n> >          type : 'feature',\n> >          value : 'auto',\n> > diff --git a/src/ipa/ipu3/meson.build b/src/ipa/ipu3/meson.build\n> > index 0d843846..a9f5d0aa 100644\n> > --- a/src/ipa/ipu3/meson.build\n> > +++ b/src/ipa/ipu3/meson.build\n> > @@ -2,6 +2,10 @@\n> >  \n> >  ipa_name = 'ipa_ipu3'\n> >  \n> > +if 'ipu3' not in ipas\n> > +    subdir_done()\n> > +endif\n> \n> You shouldn't need this.\n> \n> If ipu3 isn't specified in get_option('ipas') then it won't go into the\n> subdir.\n> \n> > +\n> >  ipu3_ipa_sources = files([\n> >      'ipu3.cpp',\n> >      'ipu3_agc.cpp',\n> > diff --git a/src/ipa/meson.build b/src/ipa/meson.build\n> > index 5b5684a1..fb687497 100644\n> > --- a/src/ipa/meson.build\n> > +++ b/src/ipa/meson.build\n> > @@ -22,6 +22,8 @@ ipa_sign = files('ipa-sign.sh')\n> >  ipas = ['ipu3', 'raspberrypi', 'rkisp1', 'vimc']\n> >  ipa_names = []\n> >  \n> > +ipas = get_option('ipas')\n> \n> I think you forgot to remove the ipas list 3 lines above it.\n> This should replace that line.\n> \n> > +\n> >  # The ipa-sign-install.sh script which uses the ipa_names variable will itself\n> >  # prepend MESON_INSTALL_DESTDIR_PREFIX to each ipa module name, therefore we\n> >  # must not include the prefix string here.\n> > diff --git a/src/ipa/raspberrypi/meson.build b/src/ipa/raspberrypi/meson.build\n> > index d1397a32..02c143b1 100644\n> > --- a/src/ipa/raspberrypi/meson.build\n> > +++ b/src/ipa/raspberrypi/meson.build\n> > @@ -2,6 +2,10 @@\n> >  \n> >  ipa_name = 'ipa_rpi'\n> >  \n> > +if 'rasberrypi' not in ipas\n> > +    subdir_done()\n> > +endif\n> \n> This isn't needed.\n> \n> > +\n> >  rpi_ipa_deps = [\n> >      libcamera_dep,\n> >      dependency('boost'),\n> > diff --git a/src/ipa/rkisp1/meson.build b/src/ipa/rkisp1/meson.build\n> > index 1a1c7159..eecc5877 100644\n> > --- a/src/ipa/rkisp1/meson.build\n> > +++ b/src/ipa/rkisp1/meson.build\n> > @@ -2,6 +2,10 @@\n> >  \n> >  ipa_name = 'ipa_rkisp1'\n> >  \n> > +if 'rkisp1' not in ipas\n> > +    subdir_done()\n> > +endif\n> \n> same.\n> \n> > +\n> >  mod = shared_module(ipa_name,\n> >                      ['rkisp1.cpp', libcamera_generated_ipa_headers],\n> >                      name_prefix : '',\n> > diff --git a/src/ipa/vimc/meson.build b/src/ipa/vimc/meson.build\n> > index a35825ae..a41a0407 100644\n> > --- a/src/ipa/vimc/meson.build\n> > +++ b/src/ipa/vimc/meson.build\n> > @@ -2,6 +2,10 @@\n> >  \n> >  ipa_name = 'ipa_vimc'\n> >  \n> > +if 'ipu3' not in ipas\n> > +    subdir_done()\n> > +endif\n> \n> same.\n> \n> > +\n> >  mod = shared_module(ipa_name,\n> >                      ['vimc.cpp', libcamera_generated_ipa_headers],\n> >                      name_prefix : '',","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id DD672C31FB\n\tfor <parsemail@patchwork.libcamera.org>;\n\tSat, 15 May 2021 16:35:18 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 20BAD6891D;\n\tSat, 15 May 2021 18:35:18 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id F40E76891A\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tSat, 15 May 2021 18:35:16 +0200 (CEST)","from pendragon.ideasonboard.com (62-78-145-57.bb.dnainternet.fi\n\t[62.78.145.57])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id D74C1436;\n\tSat, 15 May 2021 18:35:15 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"iAweCVYf\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1621096516;\n\tbh=DkktruAcMItpIhUJLw0/QyJqL02MKbWY7ulZ6Bu5PFg=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=iAweCVYf1sgIp8LnqjeCW36/+/KLkm1Exs+0U4LI27Rnc8dnl2qSFhCyWMpKwk29a\n\tWZlHpc93DFvOEW267g6QPUhYEfWs8lAVsk17OUrusf4+9rVL/WJOQIWrGmvFuf5ANa\n\t1tluzzsk7dJOu4/NUY4L/pH0BDhHGLiXIKO656OQ=","Date":"Sat, 15 May 2021 19:35:06 +0300","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"Umang Jain <umang.jain@ideasonboard.com>","Message-ID":"<YJ/4OgvYORTnpDlX@pendragon.ideasonboard.com>","References":"<20210514075808.282479-1-umang.jain@ideasonboard.com>\n\t<20210514075808.282479-5-umang.jain@ideasonboard.com>\n\t<7897c340-310e-3ddd-e553-43a68e7a9007@ideasonboard.com>","MIME-Version":"1.0","Content-Disposition":"inline","In-Reply-To":"<7897c340-310e-3ddd-e553-43a68e7a9007@ideasonboard.com>","Subject":"Re: [libcamera-devel] [PATCH v1 4/6] meson: Add a configuration\n\toption to build IPAs","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Cc":"libcamera-devel@lists.libcamera.org","Content-Type":"text/plain; charset=\"us-ascii\"","Content-Transfer-Encoding":"7bit","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":16958,"web_url":"https://patchwork.libcamera.org/comment/16958/","msgid":"<YJ/62b5oK2tc+jfj@pendragon.ideasonboard.com>","date":"2021-05-15T16:46:17","subject":"Re: [libcamera-devel] [PATCH v1 5/6] meson: Generate a helper .so\n\tcontaining libcamera's internal headers","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/people/2/","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"content":"Hello,\n\nOn Fri, May 14, 2021 at 11:34:51AM +0100, Kieran Bingham wrote:\n> On 14/05/2021 08:58, Umang Jain wrote:\n> > The IPU3 closed source IPA shall live externally(out-of-tree) however,\n> > it needs access to some of the internal libcamera headers. These headers\n> > are not typically intended for public usage hence, shouldn't be placed\n> > as  headers in $includedir. In order to solve this issue, generate a\n> > helper shared library, which can be used to link with, by the external\n> > IPU3 closed source IPA.\n> \n> This is a much bigger task than just sharing the headers.\n> Headers should be accompanied with implementation.\n> \n> > Signed-off-by: Umang Jain <umang.jain@ideasonboard.com>\n> > ---\n> >  include/libcamera/internal/meson.build | 6 ++++++\n> >  meson.build                            | 7 +++++++\n> >  src/libcamera/meson.build              | 6 ++++++\n> >  3 files changed, 19 insertions(+)\n> > \n> > diff --git a/include/libcamera/internal/meson.build b/include/libcamera/internal/meson.build\n> > index 6cff1b90..fcbf4212 100644\n> > --- a/include/libcamera/internal/meson.build\n> > +++ b/include/libcamera/internal/meson.build\n> > @@ -49,3 +49,9 @@ libcamera_internal_headers = files([\n> >      'v4l2_subdevice.h',\n> >      'v4l2_videodevice.h',\n> >  ])\n> > +\n> > +libcamera_helpers = files ([\n> > +    'buffer.h',\n> > +    'file.h',\n> > +    'log.h',\n> > +])\n> > diff --git a/meson.build b/meson.build\n> > index b89797f3..c48c5a66 100644\n> > --- a/meson.build\n> > +++ b/meson.build\n> > @@ -160,6 +160,13 @@ pkg_mod.generate(libraries : libcamera,\n> >                   description : 'Complex Camera Support Library',\n> >                   subdirs : 'libcamera')\n> >  \n> > +# \\todo Bikeshedding on camera_helper naming\n> > +pkg_mod.generate(libraries : libcamera_helper_lib,\n> > +                 version : '0.0',\n> > +                 name : 'libcamera_helper_lib',\n> > +                 filebase : 'camera_helper',\n> > +                 description : 'libcamera internal helper library')\n> > +\n> >  # Check for python installation and modules.\n> >  py_mod = import('python')\n> >  py_mod.find_installation('python3', modules: py_modules)\n> > diff --git a/src/libcamera/meson.build b/src/libcamera/meson.build\n> > index 7bc59b84..788b767d 100644\n> > --- a/src/libcamera/meson.build\n> > +++ b/src/libcamera/meson.build\n> > @@ -162,4 +162,10 @@ libcamera_dep = declare_dependency(sources : [\n> >                                     include_directories : libcamera_includes,\n> >                                     link_with : libcamera)\n> >  \n> > +# libcamera helper shared library\n> > +libcamera_helper_lib = shared_library('camera_helper', [libcamera_helpers],\n> > +                                      install: true,\n> > +                                      install_dir: libcamera_libdir,\n> > +                                      dependencies: libcamera_dep)\n> \n> As a separate library, it should be separated from src/libcamera\n> \n> So dependant upon the name selected this should have it's own structure\n> \n>  include/\n> \tlibcamera-support/\n> \t\tfile.h\n> \t\tlog.h\n> \t\tbuffer.h\n\nI had envisioned include/libcamera/support/ (bikeshedding on the\n'support' name aside).\n\n>  src/\n> \tlibcamera-support/\n> \t\tfile.cpp\n> \t\tlog.cpp\n> \t\tbuffer.cpp\n\nAnd possibly similarly here, although I wouldn't object keeping the\nfiles in src/libcamera/\n\n> And then libcamera should link against it. But things are not that\n> simple, and the dependencies between all these are quite convoluted.\n> \n> \n> Of course the library name is hard to choose.\n> It could be\n> \tlibcamera-helper,\n> \tlibcamera-utils,\n> \tlibcamera-support,\n> \tlibcamera-internal ...\n\nMy initial preference is libcamera-utils.\n\n> And then the scope of what goes in there could be interesting too.\n> \n> log and file are system helpers, accessing files and generic logging.\n> Buffers are (our) common buffer abstraction\n> \n> \n> \n> But there's others to consider (in the future, not necessarily immediately)\n> \n> \n> ## definitely libcamera internal?\n> \n> byte_stream_buffer.h\n> camera_controls.h\n> camera_sensor.h\n> camera_sensor.h.orig\n\nI think we can skip this one ;-)\n\n> camera_sensor_properties.h\n> control_serializer.h\n> control_validator.h\n> delayed_controls.h\n> event_dispatcher.h\n> event_dispatcher_poll.h\n> event_notifier.h\n> ipa_data_serializer.h\n> ipa_manager.h\n> ipa_module.h\n> ipa_proxy.h\n> pipeline_handler.h\n> tracepoints\n> utils.h\n\nutils.h sounds fairly useful for IPA modules.\n\n> # Linux V4L2/MediaController/Pixel Formats / buffers\n> device_enumerator.h\n> device_enumerator_sysfs.h\n> device_enumerator_udev.h\n> media_device.h\n> media_object.h\n> v4l2_controls.h\n> v4l2_device.h\n> v4l2_pixelformat.h\n> v4l2_subdevice.h\n> v4l2_videodevice.h\n\nAll this is definitely libcamera internal, IPA modules must never access\ndevices.\n\n> # Pixel Formats and buffers\n> bayer_format.h\n> buffer.h\n> formats.h\n> \n> \n> # Operating system specific abstractions ?\n> file.h\n> ipc_pipe.h\n> ipc_pipe_unixsocket.h\n> ipc_unixsocket.h\n\nIPC should be handled transparently by the generated code for the IPA\nmodule, so I'd skip it for now. We'll have to revisit this as part of\nthe IPC mechanism rework discussions (related to whether to keep\nspawning a process directly, or use an external daemon), for now I'd\nprefer only moving code that we know is of interest to IPA modules,\nexcluding the proxy.\n\n> log.h\n> message.h\n> process.h\n> pub_key.h\n\nI'd also skip process.h and pub_key.h, I don't see a need for IPA\nmodules to use those.\n\n> semaphore.h\n> sysfs.h\n\nSame for sysfs.h.\n\n> thread.h\n> timer.h\n\nTimers and threads require an event dispatcher, so you would need to\nalso move event_dispatcher.h and event_dispatcher_poll.h, and, as a\nconsequence, event_notifier.h.\n\n> > +\n> >  subdir('proxy/worker')\n> >","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 5E1C9C31FC\n\tfor <parsemail@patchwork.libcamera.org>;\n\tSat, 15 May 2021 16:46:28 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id CBAE16891F;\n\tSat, 15 May 2021 18:46:27 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id DDDE16891A\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tSat, 15 May 2021 18:46:26 +0200 (CEST)","from pendragon.ideasonboard.com (62-78-145-57.bb.dnainternet.fi\n\t[62.78.145.57])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 4871E436;\n\tSat, 15 May 2021 18:46:26 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"TVF8MKaM\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1621097186;\n\tbh=5uzPbFT7vThhqHiOOQdiepIKbY/WkN5EYmlC+e5eDBA=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=TVF8MKaMEaqxWgCCvYg8NZO8unwcKTYtzyOKrTpcNUrRMA1h0snJf3rJdPLwExwRK\n\tJTe0Bw2C5U9ipMbv/ESBYFd7YVnX3XMD3wY6GitTXHiKjbEpPREhxw9Q8fy1snI/tz\n\tQFWyHz+vHb2vUGAR2If8TPUJ+coC/4guziJzvncY=","Date":"Sat, 15 May 2021 19:46:17 +0300","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"Kieran Bingham <kieran.bingham@ideasonboard.com>","Message-ID":"<YJ/62b5oK2tc+jfj@pendragon.ideasonboard.com>","References":"<20210514075808.282479-1-umang.jain@ideasonboard.com>\n\t<20210514075808.282479-6-umang.jain@ideasonboard.com>\n\t<57bfd8d5-c038-4799-2891-16fb550ef8f8@ideasonboard.com>","MIME-Version":"1.0","Content-Disposition":"inline","In-Reply-To":"<57bfd8d5-c038-4799-2891-16fb550ef8f8@ideasonboard.com>","Subject":"Re: [libcamera-devel] [PATCH v1 5/6] meson: Generate a helper .so\n\tcontaining libcamera's internal headers","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Cc":"libcamera-devel@lists.libcamera.org","Content-Type":"text/plain; charset=\"us-ascii\"","Content-Transfer-Encoding":"7bit","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}}]