[{"id":26137,"web_url":"https://patchwork.libcamera.org/comment/26137/","msgid":"<b2ff1da3-6e7d-8357-6bb2-76597c0845cd@ideasonboard.com>","date":"2022-12-23T11:27:10","subject":"Re: [libcamera-devel] [PATCH] meson: Only build pipeline handlers\n\tneeded in the host architecture","submitter":{"id":86,"url":"https://patchwork.libcamera.org/api/people/86/","name":"Umang Jain","email":"umang.jain@ideasonboard.com"},"content":"Hi Javier,\n\nthank you for the patch.\n\nOn 12/23/22 1:52 PM, Javier Martinez Canillas via libcamera-devel wrote:\n> By default all pipeline handlers are built, regardless on whether these\n> are needed in the host architecture or not. It makes more sense to build\n> only the pipeline handlers that will be used for the given architecture.\n>\n> Let's do that by default now, but still allow to build the other pipeline\n> handlers if needed, by using the `pipelines` meson option. For example:\n>\n>    $ meson build\n>    ...\n>      Configuration\n>      Enabled pipelines        : ipu3\n>                                 simple\n>                                 uvcvideo\n>      Enabled IPA modules      : ipu3\n>    ...\n>\n>    $ meson build -Dpipelines=\"ipu3,raspberrypi,rkisp1\" -Dtest=true\n>    ...\n>      Configuration\n>      Enabled pipelines        : ipu3\n>                                 raspberrypi\n>                                 rkisp1\n>                                 vimc\n>      Enabled IPA modules      : ipu3\n>                                 raspberrypi\n>                                 rkisp1\n>                                 vimc\n>    ...\n>\n> Suggested-by: Kieran Bingham <kieran.bingham@ideasonboard.com>\n> Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>\n\nReviewed-by: Umang Jain <umang.jain@ideasonboard.com>\n\n> ---\n>\n>   meson.build       | 14 ++++++++++++++\n>   meson_options.txt |  6 ++++--\n>   2 files changed, 18 insertions(+), 2 deletions(-)\n>\n> diff --git a/meson.build b/meson.build\n> index d02f9917965c..fc1023326ed3 100644\n> --- a/meson.build\n> +++ b/meson.build\n> @@ -164,6 +164,20 @@ liblttng = dependency('lttng-ust', required : get_option('tracing'))\n>   # are enabled.\n>   pipelines = get_option('pipelines')\n>   \n> +if pipelines.contains('auto')\n> +    host_cpu = host_machine.cpu_family()\n> +    if host_cpu == 'x86' or host_cpu == 'x86_64'\n> +        pipelines = ['ipu3']\n> +    elif host_cpu == 'aarch64'\n> +        pipelines = ['imx8-isi', 'ipu3', 'raspberrypi', 'rkisp1']\n> +    elif host_cpu == 'arm'\n> +        pipelines = ['raspberrypi']\n> +    endif\n> +\n> +    # Always include the simple and uvcvideo pipeline handlers.\n> +    pipelines += ['simple', 'uvcvideo']\n> +endif\n> +\n>   if get_option('test') and 'vimc' not in pipelines\n>       message('Enabling vimc pipeline handler to support tests')\n>       pipelines += ['vimc']\n> diff --git a/meson_options.txt b/meson_options.txt\n> index 1ba6778ce257..23505805de41 100644\n> --- a/meson_options.txt\n> +++ b/meson_options.txt\n> @@ -37,8 +37,10 @@ option('lc-compliance',\n>   \n>   option('pipelines',\n>           type : 'array',\n> -        choices : ['imx8-isi', 'ipu3', 'raspberrypi', 'rkisp1', 'simple', 'uvcvideo', 'vimc'],\n> -        description : 'Select which pipeline handlers to include')\n> +        value : ['auto'],\n> +        choices : ['auto', 'imx8-isi', 'ipu3', 'raspberrypi', 'rkisp1', 'simple', 'uvcvideo', 'vimc'],\n> +        description : '''Select which pipeline handlers to build. If this is set to auto, all\n> +                       the pipelines applicable to the target architecture will be built.''')\n>   \n>   option('qcam',\n>           type : 'feature',","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 18960C3200\n\tfor <parsemail@patchwork.libcamera.org>;\n\tFri, 23 Dec 2022 11:27:19 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 6DB9E633B4;\n\tFri, 23 Dec 2022 12:27:18 +0100 (CET)","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 ACB4C633A8\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 23 Dec 2022 12:27:17 +0100 (CET)","from [IPV6:2401:4900:1f3f:cd5d:4e48:3b91:9262:9565] (unknown\n\t[IPv6:2401:4900:1f3f:cd5d:4e48:3b91:9262:9565])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 21CD5492;\n\tFri, 23 Dec 2022 12:27:15 +0100 (CET)"],"DKIM-Signature":["v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1671794838;\n\tbh=5Cavb4mMWx+2+2htwzn2z8DNpGpIIrm6U1W6qJ2GJXU=;\n\th=Date:To:References:In-Reply-To:Subject:List-Id:List-Unsubscribe:\n\tList-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:\n\tFrom;\n\tb=GhcmitVryoHcn8Kvv/ZTLMi0AEa4Dh+1jDNRimOTdeTJenDRbWQAWdH1G+g9A6i6X\n\tvh67YiyzoSZI6u6UgdgG/laEKaPI1hAHH0G4aAtPusAQs5cF/dUclnqaF7MOlN1ivv\n\tEbJXLNhBLc/eioHfPvsycK7j3Poj2S8jYbSKye1K0kMaOnO3Hv7hghCgsBEwu37bVb\n\tSPTT3/gXs7AEfoed0pAwLpDGaCaKozRUr7Di8B7/6uentGnwJcbeYnZLVkTjyjizAS\n\tj0zLV8GPZZod+v6vBzqzC8BYaAnza2qtRL34VqJuErwVGquSHLY4vfaFk7PQv83tSM\n\tFGAc47L59L0MA==","v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1671794837;\n\tbh=5Cavb4mMWx+2+2htwzn2z8DNpGpIIrm6U1W6qJ2GJXU=;\n\th=Date:Subject:To:References:From:In-Reply-To:From;\n\tb=jX+ZB6chYqCDEJhibhS8hjnyICOi7pXde8hlw5V/6XKkaOnxhEx1MmpPAiKM4obGr\n\tB/95kgTUxhSEeiwcl2oXzUKWiDHl2FCgQ2rGFmAOuv5qrypycXoC+8jhnjCRSuUOH4\n\tlRMrWd9eOboweqsYwsH7NJ90Nvuuo8tm67pGy4fk="],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=ideasonboard.com\n\theader.i=@ideasonboard.com\n\theader.b=\"jX+ZB6ch\"; dkim-atps=neutral","Message-ID":"<b2ff1da3-6e7d-8357-6bb2-76597c0845cd@ideasonboard.com>","Date":"Fri, 23 Dec 2022 16:57:10 +0530","MIME-Version":"1.0","User-Agent":"Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101\n\tThunderbird/102.5.1","To":"Javier Martinez Canillas <javierm@redhat.com>,\n\tlibcamera-devel@lists.libcamera.org","References":"<20221223082229.2559907-1-javierm@redhat.com>","Content-Language":"en-US","In-Reply-To":"<20221223082229.2559907-1-javierm@redhat.com>","Content-Type":"text/plain; charset=UTF-8; format=flowed","Content-Transfer-Encoding":"7bit","Subject":"Re: [libcamera-devel] [PATCH] meson: Only build pipeline handlers\n\tneeded in the host architecture","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>","From":"Umang Jain via libcamera-devel <libcamera-devel@lists.libcamera.org>","Reply-To":"Umang Jain <umang.jain@ideasonboard.com>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":26145,"web_url":"https://patchwork.libcamera.org/comment/26145/","msgid":"<Y6Y3/7alVgT78gVu@pyrite.rasen.tech>","date":"2022-12-23T23:21:35","subject":"Re: [libcamera-devel] [PATCH] meson: Only build pipeline handlers\n\tneeded in the host architecture","submitter":{"id":17,"url":"https://patchwork.libcamera.org/api/people/17/","name":"Paul Elder","email":"paul.elder@ideasonboard.com"},"content":"On Fri, Dec 23, 2022 at 09:22:29AM +0100, Javier Martinez Canillas via libcamera-devel wrote:\n> By default all pipeline handlers are built, regardless on whether these\n> are needed in the host architecture or not. It makes more sense to build\n> only the pipeline handlers that will be used for the given architecture.\n> \n> Let's do that by default now, but still allow to build the other pipeline\n> handlers if needed, by using the `pipelines` meson option. For example:\n> \n>   $ meson build\n>   ...\n>     Configuration\n>     Enabled pipelines        : ipu3\n>                                simple\n>                                uvcvideo\n>     Enabled IPA modules      : ipu3\n>   ...\n> \n>   $ meson build -Dpipelines=\"ipu3,raspberrypi,rkisp1\" -Dtest=true\n>   ...\n>     Configuration\n>     Enabled pipelines        : ipu3\n>                                raspberrypi\n>                                rkisp1\n>                                vimc\n>     Enabled IPA modules      : ipu3\n>                                raspberrypi\n>                                rkisp1\n>                                vimc\n>   ...\n> \n> Suggested-by: Kieran Bingham <kieran.bingham@ideasonboard.com>\n> Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>\n\nReviewed-by: Paul Elder <paul.elder@ideasonboard.com>\n\n> ---\n> \n>  meson.build       | 14 ++++++++++++++\n>  meson_options.txt |  6 ++++--\n>  2 files changed, 18 insertions(+), 2 deletions(-)\n> \n> diff --git a/meson.build b/meson.build\n> index d02f9917965c..fc1023326ed3 100644\n> --- a/meson.build\n> +++ b/meson.build\n> @@ -164,6 +164,20 @@ liblttng = dependency('lttng-ust', required : get_option('tracing'))\n>  # are enabled.\n>  pipelines = get_option('pipelines')\n>  \n> +if pipelines.contains('auto')\n> +    host_cpu = host_machine.cpu_family()\n> +    if host_cpu == 'x86' or host_cpu == 'x86_64'\n> +        pipelines = ['ipu3']\n> +    elif host_cpu == 'aarch64'\n> +        pipelines = ['imx8-isi', 'ipu3', 'raspberrypi', 'rkisp1']\n> +    elif host_cpu == 'arm'\n> +        pipelines = ['raspberrypi']\n> +    endif\n> +\n> +    # Always include the simple and uvcvideo pipeline handlers.\n> +    pipelines += ['simple', 'uvcvideo']\n> +endif\n> +\n>  if get_option('test') and 'vimc' not in pipelines\n>      message('Enabling vimc pipeline handler to support tests')\n>      pipelines += ['vimc']\n> diff --git a/meson_options.txt b/meson_options.txt\n> index 1ba6778ce257..23505805de41 100644\n> --- a/meson_options.txt\n> +++ b/meson_options.txt\n> @@ -37,8 +37,10 @@ option('lc-compliance',\n>  \n>  option('pipelines',\n>          type : 'array',\n> -        choices : ['imx8-isi', 'ipu3', 'raspberrypi', 'rkisp1', 'simple', 'uvcvideo', 'vimc'],\n> -        description : 'Select which pipeline handlers to include')\n> +        value : ['auto'],\n> +        choices : ['auto', 'imx8-isi', 'ipu3', 'raspberrypi', 'rkisp1', 'simple', 'uvcvideo', 'vimc'],\n> +        description : '''Select which pipeline handlers to build. If this is set to auto, all\n> +                       the pipelines applicable to the target architecture will be built.''')\n>  \n>  option('qcam',\n>          type : 'feature',\n> -- \n> 2.38.1\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 DC507BD78E\n\tfor <parsemail@patchwork.libcamera.org>;\n\tFri, 23 Dec 2022 23:21:45 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 346CB623B8;\n\tSat, 24 Dec 2022 00:21:45 +0100 (CET)","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 F369261507\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tSat, 24 Dec 2022 00:21:42 +0100 (CET)","from pyrite.rasen.tech (unknown\n\t[IPv6:2604:2d80:ad8a:9000:1bf9:855b:22de:3645])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id E20BB4DD;\n\tSat, 24 Dec 2022 00:21:41 +0100 (CET)"],"DKIM-Signature":["v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1671837705;\n\tbh=A3hhIwHL3Z8K1poj1TdZXKXsxB2DSkrUQCME5Tmb8lU=;\n\th=Date:To:References:In-Reply-To:Subject:List-Id:List-Unsubscribe:\n\tList-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc:\n\tFrom;\n\tb=fAfo3h72D/ghrrE6B3Inktevp+oCXQEKGup7bhQxqVym2j5LtxEkbz5mPfkcnTDgj\n\trtBTkj3OCALtY2gj8UjAx1d04WEZBuXZDZNnI09toxK4X8hO9GFVnX/k0MOmyLIIAI\n\tmCYyCAW7TUjO/i/1YdRFzTgxVyqD5CQIO8aOpsheARL06RDx71z+XXxGQ43gRkfonD\n\tRnIbhv/CvCd06n0vIuUu9jnsPy/ZX6l4RBCJticM9hS8slbZgWi90Odqg/OrKN2qnV\n\trih1iET7l/E5qX9do32Eg9vMakl3oA746IBeAKZLk8kDVLSO1lXo1CWFa1VhZRjvHn\n\tKX7VJxn9yGnBg==","v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1671837702;\n\tbh=A3hhIwHL3Z8K1poj1TdZXKXsxB2DSkrUQCME5Tmb8lU=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=iNn5Z8oJRS9lhgpy7wtEuRa3l6ntVOYpkgQGipWdYRpq6f+ZTt3Rhywj91UI0+L32\n\tWSLdsxQTs07p4MHFpPHNkgdQGTcgLxno75RkRhfbF0KPG60SO3pb6r1jB+mY94dlit\n\tqsS6rUkyOi50Id6hp5ScEz9Wbwb2C67zEAoAM6Ew="],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=ideasonboard.com\n\theader.i=@ideasonboard.com\n\theader.b=\"iNn5Z8oJ\"; dkim-atps=neutral","Date":"Fri, 23 Dec 2022 17:21:35 -0600","To":"Javier Martinez Canillas <javierm@redhat.com>","Message-ID":"<Y6Y3/7alVgT78gVu@pyrite.rasen.tech>","References":"<20221223082229.2559907-1-javierm@redhat.com>","MIME-Version":"1.0","Content-Type":"text/plain; charset=us-ascii","Content-Disposition":"inline","In-Reply-To":"<20221223082229.2559907-1-javierm@redhat.com>","Subject":"Re: [libcamera-devel] [PATCH] meson: Only build pipeline handlers\n\tneeded in the host architecture","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>","From":"Paul Elder via libcamera-devel <libcamera-devel@lists.libcamera.org>","Reply-To":"Paul Elder <paul.elder@ideasonboard.com>","Cc":"libcamera-devel@lists.libcamera.org","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":26152,"web_url":"https://patchwork.libcamera.org/comment/26152/","msgid":"<Y6ZPdirGsA4SJXzI@pendragon.ideasonboard.com>","date":"2022-12-24T01:01:42","subject":"Re: [libcamera-devel] [PATCH] meson: Only build pipeline handlers\n\tneeded in the host architecture","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/people/2/","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"content":"Hi Javier,\n\nThank you for the patch.\n\nOn Fri, Dec 23, 2022 at 09:22:29AM +0100, Javier Martinez Canillas wrote:\n> By default all pipeline handlers are built, regardless on whether these\n> are needed in the host architecture or not. It makes more sense to build\n> only the pipeline handlers that will be used for the given architecture.\n> \n> Let's do that by default now, but still allow to build the other pipeline\n> handlers if needed, by using the `pipelines` meson option. For example:\n\nAs long as CI systems can build all pipeline handlers, that's fine with\nme. We may start getting somes patches that introduce compilation\nbreakages on pipeline handlers that are not compile-tested by\ndevelopers, but we can catch that in CI.\n\n>   $ meson build\n>   ...\n>     Configuration\n>     Enabled pipelines        : ipu3\n>                                simple\n>                                uvcvideo\n>     Enabled IPA modules      : ipu3\n>   ...\n> \n>   $ meson build -Dpipelines=\"ipu3,raspberrypi,rkisp1\" -Dtest=true\n>   ...\n>     Configuration\n>     Enabled pipelines        : ipu3\n>                                raspberrypi\n>                                rkisp1\n>                                vimc\n>     Enabled IPA modules      : ipu3\n>                                raspberrypi\n>                                rkisp1\n>                                vimc\n>   ...\n> \n> Suggested-by: Kieran Bingham <kieran.bingham@ideasonboard.com>\n> Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>\n> ---\n> \n>  meson.build       | 14 ++++++++++++++\n>  meson_options.txt |  6 ++++--\n>  2 files changed, 18 insertions(+), 2 deletions(-)\n> \n> diff --git a/meson.build b/meson.build\n> index d02f9917965c..fc1023326ed3 100644\n> --- a/meson.build\n> +++ b/meson.build\n> @@ -164,6 +164,20 @@ liblttng = dependency('lttng-ust', required : get_option('tracing'))\n>  # are enabled.\n>  pipelines = get_option('pipelines')\n>  \n> +if pipelines.contains('auto')\n> +    host_cpu = host_machine.cpu_family()\n> +    if host_cpu == 'x86' or host_cpu == 'x86_64'\n> +        pipelines = ['ipu3']\n> +    elif host_cpu == 'aarch64'\n> +        pipelines = ['imx8-isi', 'ipu3', 'raspberrypi', 'rkisp1']\n\nipu3 is only for x86.\n\n> +    elif host_cpu == 'arm'\n> +        pipelines = ['raspberrypi']\n> +    endif\n> +\n> +    # Always include the simple and uvcvideo pipeline handlers.\n> +    pipelines += ['simple', 'uvcvideo']\n\nThe simple pipeline handler is only useful on ARM platforms (both 32 and\n64 bits) at the moment.\n\n> +endif\n> +\n>  if get_option('test') and 'vimc' not in pipelines\n>      message('Enabling vimc pipeline handler to support tests')\n>      pipelines += ['vimc']\n> diff --git a/meson_options.txt b/meson_options.txt\n> index 1ba6778ce257..23505805de41 100644\n> --- a/meson_options.txt\n> +++ b/meson_options.txt\n> @@ -37,8 +37,10 @@ option('lc-compliance',\n>  \n>  option('pipelines',\n>          type : 'array',\n> -        choices : ['imx8-isi', 'ipu3', 'raspberrypi', 'rkisp1', 'simple', 'uvcvideo', 'vimc'],\n> -        description : 'Select which pipeline handlers to include')\n> +        value : ['auto'],\n> +        choices : ['auto', 'imx8-isi', 'ipu3', 'raspberrypi', 'rkisp1', 'simple', 'uvcvideo', 'vimc'],\n\nThis is getting long, let's wrap it:\n\n        choices : [\n            'auto',\n            'imx8-isi',\n            'ipu3',\n            'raspberrypi',\n            'rkisp1',\n            'simple',\n            'uvcvideo',\n            'vimc',\n        ],\n\n> +        description : '''Select which pipeline handlers to build. If this is set to auto, all\n> +                       the pipelines applicable to the target architecture will be built.''')\n\nThe spaces in the description cause weird-looking output depending on\nthe terminal width:\n\n  pipelines                     [imx8-isi, ipu3, raspberrypi,   [auto, imx8-isi, ipu3,          Select which pipeline handlers to build. If this is set to auto,\n                                rkisp1, simple, uvcvideo, vimc] raspberrypi, rkisp1, simple,    all                        the pipelines applicable to the\n                                                                uvcvideo,                       target architecture will be built.\n                                                                 vimc]\n\nYou can write\n\n        description : '''Select which pipeline handlers to build. If this is set\nto auto, all the pipelines applicable to the target architecture will be built.''')\n\nor\n\n        description : 'Select which pipeline handlers to build. If this is set to auto, all the pipelines applicable to the target architecture will be built.')\n\n>  \n>  option('qcam',\n>          type : 'feature',","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 81FBFC3200\n\tfor <parsemail@patchwork.libcamera.org>;\n\tSat, 24 Dec 2022 01:01:50 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id C5FE9623B8;\n\tSat, 24 Dec 2022 02:01:49 +0100 (CET)","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 92A8E61507\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tSat, 24 Dec 2022 02:01:48 +0100 (CET)","from pendragon.ideasonboard.com (213-243-189-158.bb.dnainternet.fi\n\t[213.243.189.158])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id DF3D34DD;\n\tSat, 24 Dec 2022 02:01:47 +0100 (CET)"],"DKIM-Signature":["v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1671843709;\n\tbh=zFj/xcsp0oZDgJPhst6B/LsGRY9lwDpgZVb2XRCNH+Q=;\n\th=Date:To:References:In-Reply-To:Subject:List-Id:List-Unsubscribe:\n\tList-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc:\n\tFrom;\n\tb=PCCEn1ZjWQYzXNqoPmmZB2EX1Dg9+bz8T3XDe2cRRxny8DkiB944JNU7rtv0VOwDt\n\tmwVaCnyZPEK4gcHZhWZrApDjNsYfd/eb+jqTt5ZwM+iK6bGekDtd6j6OcGRXfoUOhT\n\tJ78vjLtCcUSQQpqWnuQKw585QQm2ZXVA5JsNolK9NdaQwAVOiJGEbJp95uNF8Qgjgx\n\tEq1RViUF2nk5F6JVgK2DAPK+CiCrDIj/yypIWjb7i6p28MofcqqQOh511rAo2GVRy6\n\tt0SNQ1pMz8HAob5fPKr/WX+9xL0pAsUW1PT3OdwQaNV9+XHOXXH10jY0aSPFpWSoh7\n\tAH1p9/jRqcGFQ==","v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1671843708;\n\tbh=zFj/xcsp0oZDgJPhst6B/LsGRY9lwDpgZVb2XRCNH+Q=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=sPTNxGAylis7Ykn9E7RHAupg37mTer0ExgywMctyHJZVTb0G8JjOhkV/vHols9amL\n\tf6O16pXhYazLY8kG7lp1r6Z7DbmtPD7uADfYLFxV/It2OD1sSikhr774F4YS+ue/Ba\n\tJgUUnH9ZKD2rxmoNlwsCsZbj8cZKOjd9DHFQDqh4="],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=ideasonboard.com\n\theader.i=@ideasonboard.com\n\theader.b=\"sPTNxGAy\"; dkim-atps=neutral","Date":"Sat, 24 Dec 2022 03:01:42 +0200","To":"Javier Martinez Canillas <javierm@redhat.com>","Message-ID":"<Y6ZPdirGsA4SJXzI@pendragon.ideasonboard.com>","References":"<20221223082229.2559907-1-javierm@redhat.com>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","In-Reply-To":"<20221223082229.2559907-1-javierm@redhat.com>","Subject":"Re: [libcamera-devel] [PATCH] meson: Only build pipeline handlers\n\tneeded in the host architecture","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>","From":"Laurent Pinchart via libcamera-devel\n\t<libcamera-devel@lists.libcamera.org>","Reply-To":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","Cc":"libcamera-devel@lists.libcamera.org","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":26154,"web_url":"https://patchwork.libcamera.org/comment/26154/","msgid":"<cbd02420-e6d3-9067-f64d-f3114151fc3e@redhat.com>","date":"2022-12-24T01:32:07","subject":"Re: [libcamera-devel] [PATCH] meson: Only build pipeline handlers\n\tneeded in the host architecture","submitter":{"id":95,"url":"https://patchwork.libcamera.org/api/people/95/","name":"Javier Martinez Canillas","email":"javierm@redhat.com"},"content":"Hello Laurent,\n\nThanks a lot for your feedback.\n\nOn 12/24/22 02:01, Laurent Pinchart wrote:\n> Hi Javier,\n> \n> Thank you for the patch.\n> \n> On Fri, Dec 23, 2022 at 09:22:29AM +0100, Javier Martinez Canillas wrote:\n>> By default all pipeline handlers are built, regardless on whether these\n>> are needed in the host architecture or not. It makes more sense to build\n>> only the pipeline handlers that will be used for the given architecture.\n>>\n>> Let's do that by default now, but still allow to build the other pipeline\n>> handlers if needed, by using the `pipelines` meson option. For example:\n> \n> As long as CI systems can build all pipeline handlers, that's fine with\n> me. We may start getting somes patches that introduce compilation\n> breakages on pipeline handlers that are not compile-tested by\n> developers, but we can catch that in CI.\n>\n\nAgreed.\n \n>> +if pipelines.contains('auto')\n>> +    host_cpu = host_machine.cpu_family()\n>> +    if host_cpu == 'x86' or host_cpu == 'x86_64'\n>> +        pipelines = ['ipu3']\n>> +    elif host_cpu == 'aarch64'\n>> +        pipelines = ['imx8-isi', 'ipu3', 'raspberrypi', 'rkisp1']\n> \n> ipu3 is only for x86.\n>\n\nYes, that's a left over since I didn't meant to include it for aarch64.\n \n>> +    elif host_cpu == 'arm'\n>> +        pipelines = ['raspberrypi']\n>> +    endif\n>> +\n>> +    # Always include the simple and uvcvideo pipeline handlers.\n>> +    pipelines += ['simple', 'uvcvideo']\n> \n> The simple pipeline handler is only useful on ARM platforms (both 32 and\n> 64 bits) at the moment.\n> \n\nAh, good to know. I'll adjust that accordingly.\n\n>> +endif\n>> +\n>>  if get_option('test') and 'vimc' not in pipelines\n>>      message('Enabling vimc pipeline handler to support tests')\n>>      pipelines += ['vimc']\n>> diff --git a/meson_options.txt b/meson_options.txt\n>> index 1ba6778ce257..23505805de41 100644\n>> --- a/meson_options.txt\n>> +++ b/meson_options.txt\n>> @@ -37,8 +37,10 @@ option('lc-compliance',\n>>  \n>>  option('pipelines',\n>>          type : 'array',\n>> -        choices : ['imx8-isi', 'ipu3', 'raspberrypi', 'rkisp1', 'simple', 'uvcvideo', 'vimc'],\n>> -        description : 'Select which pipeline handlers to include')\n>> +        value : ['auto'],\n>> +        choices : ['auto', 'imx8-isi', 'ipu3', 'raspberrypi', 'rkisp1', 'simple', 'uvcvideo', 'vimc'],\n> \n> This is getting long, let's wrap it:\n>\n\nOK.\n\n[...]\n\n>> +        description : '''Select which pipeline handlers to build. If this is set to auto, all\n>> +                       the pipelines applicable to the target architecture will be built.''')\n> \n> The spaces in the description cause weird-looking output depending on\n> the terminal width:\n> \n>   pipelines                     [imx8-isi, ipu3, raspberrypi,   [auto, imx8-isi, ipu3,          Select which pipeline handlers to build. If this is set to auto,\n>                                 rkisp1, simple, uvcvideo, vimc] raspberrypi, rkisp1, simple,    all                        the pipelines applicable to the\n>                                                                 uvcvideo,                       target architecture will be built.\n>                                                                  vimc]\n> \n> You can write\n> \n>         description : '''Select which pipeline handlers to build. If this is set\n> to auto, all the pipelines applicable to the target architecture will be built.''')\n>\n\nRight. I'll do that. Thanks!\n -- \nBest regards,\n\nJavier Martinez Canillas\nCore Platforms\nRed Hat","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 C55EFC3200\n\tfor <parsemail@patchwork.libcamera.org>;\n\tSat, 24 Dec 2022 01:32:14 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 3D6BD623B8;\n\tSat, 24 Dec 2022 02:32:14 +0100 (CET)","from us-smtp-delivery-124.mimecast.com\n\t(us-smtp-delivery-124.mimecast.com [170.10.133.124])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id AB7E461507\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tSat, 24 Dec 2022 02:32:12 +0100 (CET)","from mail-wm1-f72.google.com (mail-wm1-f72.google.com\n\t[209.85.128.72]) by relay.mimecast.com with ESMTP with STARTTLS\n\t(version=TLSv1.3, cipher=TLS_AES_128_GCM_SHA256) id\n\tus-mta-150-DLLv_LgyNYycUSx63mbZ_A-1; Fri, 23 Dec 2022 20:32:10 -0500","by mail-wm1-f72.google.com with SMTP id\n\tq21-20020a7bce95000000b003d236c91639so1440632wmj.8\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 23 Dec 2022 17:32:10 -0800 (PST)","from [192.168.1.130] (205.pool92-176-231.dynamic.orange.es.\n\t[92.176.231.205]) by smtp.gmail.com with ESMTPSA id\n\ts6-20020a05600c384600b003d1e4120700sm6753558wmr.41.2022.12.23.17.32.08\n\t(version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128);\n\tFri, 23 Dec 2022 17:32:08 -0800 (PST)"],"DKIM-Signature":["v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1671845534;\n\tbh=oPHk3oLMDPCrmddFVE4k9lWgVgwSjBUbrVHWXylXHKI=;\n\th=Date:To:References:In-Reply-To:Subject:List-Id:List-Unsubscribe:\n\tList-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc:\n\tFrom;\n\tb=BuRJKAiMzF9xqwAW/VEgUqiWwpEtKLZkKPi8JOxIPN20CxMSuUXwnQs5rdbnZ8fpO\n\ti+0eOrORjYSklvXKtY0NiPASmpX9NJVjplHStnh3yIG+Xp4QhQMLsDY6ltWtsxY631\n\tlwyQUoRczNuDysKfnxuLPoNwy/dwPWpeEQ/nxCjgCsmFIELgrVf6brbsqr9zDUzESK\n\tFvMo7MKJ2Auo5cemViHPnzxD0F03xv8XX6dHaQURtobjUD+eG8qEq8++AMZAZa8aWA\n\tYnFlCYO5G/Vu+JFoOIdlzWCvXXN7YV2ghzH3inkrpz+v0XOLmMLnvTWQXp2MQ9Kqj0\n\tAIc4xj4QVJsYA==","v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com;\n\ts=mimecast20190719; t=1671845531;\n\th=from:from:reply-to:subject:subject:date:date:message-id:message-id:\n\tto:to:cc:cc:mime-version:mime-version:content-type:content-type:\n\tcontent-transfer-encoding:content-transfer-encoding:\n\tin-reply-to:in-reply-to:references:references;\n\tbh=d5pW1Xyj454nwSWWwPV1V0i/3jqZEci2ZgFMiY6y5+s=;\n\tb=LwcxTH9MLNvfjeVOv/+LSSbxFyB8SDYngIQZFTlESkmUWZBpEjG5rJQzhzTDh98yuYu8Vn\n\tyjOQUCfeeLBQ2O4GdhV9DC5aT7H8yiIHjSncvf98wgd06yOKGt8GQB4TdarPErbxCVInhw\n\tzbeU6WFmcZp8NUw0OqTXuKqK09Sde9k="],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=redhat.com\n\theader.i=@redhat.com header.b=\"LwcxTH9M\"; \n\tdkim-atps=neutral","X-MC-Unique":"DLLv_LgyNYycUSx63mbZ_A-1","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20210112;\n\th=content-transfer-encoding:in-reply-to:from:references:cc:to\n\t:content-language:subject:user-agent:mime-version:date:message-id\n\t:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to;\n\tbh=d5pW1Xyj454nwSWWwPV1V0i/3jqZEci2ZgFMiY6y5+s=;\n\tb=SSZ1N4I/Z+uhS30JvSxXcZvzEuIWMepUW5sOEtUwlq06vFu8ZVzHVgPaJomAJjdxA2\n\t/KST6xD/MMlroj3pT52zsTO2bp8uJO7vtbq0CO+pV0wKgsA9mTjjsg3iHLgvYQfex6fG\n\t3yPCYnRMSq3szy1YVWJBQshTDPbHDbIlqdDs1AJvJ7MMqucFd98mmz/1xsdBQQulBbCu\n\tVHBhjMCXXqJ/vaITL/u7FQqwsIvLy3OCITsIscJjHmcbYhjoHBu9F/NoBJkpI6eca92A\n\t3T2ddHckSuCj9vjEScZ+3vTRROab6oLaS1MMj07W3I9S3Z2ShtwTocwGGYsKNMDeh9L0\n\tx4OA==","X-Gm-Message-State":"AFqh2kog8a21gy2oky6F8LI95h4taI24VwG7Q/2kgJuwv4dS8E36RiOb\n\tkCi/zLZWavj8P9AMHxny2/7kY2wP+aDTgdYGMZoRhoSIiQ4iHM5p3gCn4sNxtIzlB2+O1PGbo2F\n\tdlFSsQ7//86+mdvJo1Dwub6cHyeatPNKZbg==","X-Received":["by 2002:a05:600c:1ca5:b0:3d1:d746:7bca with SMTP id\n\tk37-20020a05600c1ca500b003d1d7467bcamr8527871wms.4.1671845528961; \n\tFri, 23 Dec 2022 17:32:08 -0800 (PST)","by 2002:a05:600c:1ca5:b0:3d1:d746:7bca with SMTP id\n\tk37-20020a05600c1ca500b003d1d7467bcamr8527868wms.4.1671845528717; \n\tFri, 23 Dec 2022 17:32:08 -0800 (PST)"],"X-Google-Smtp-Source":"AMrXdXvZ1YVRHDojiz5hzaTraCq0jE5i8EpZ4hui834QdI/dGfZ8bQENF8XvSOfdm5Tu71fbQ8WHsQ==","Message-ID":"<cbd02420-e6d3-9067-f64d-f3114151fc3e@redhat.com>","Date":"Sat, 24 Dec 2022 02:32:07 +0100","MIME-Version":"1.0","User-Agent":"Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101\n\tThunderbird/102.5.0","To":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","References":"<20221223082229.2559907-1-javierm@redhat.com>\n\t<Y6ZPdirGsA4SJXzI@pendragon.ideasonboard.com>","In-Reply-To":"<Y6ZPdirGsA4SJXzI@pendragon.ideasonboard.com>","X-Mimecast-Spam-Score":"0","X-Mimecast-Originator":"redhat.com","Content-Language":"en-US","Content-Type":"text/plain; charset=UTF-8","Content-Transfer-Encoding":"7bit","Subject":"Re: [libcamera-devel] [PATCH] meson: Only build pipeline handlers\n\tneeded in the host architecture","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>","From":"Javier Martinez Canillas via libcamera-devel\n\t<libcamera-devel@lists.libcamera.org>","Reply-To":"Javier Martinez Canillas <javierm@redhat.com>","Cc":"libcamera-devel@lists.libcamera.org","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}}]