{"id":18791,"url":"https://patchwork.libcamera.org/api/1.1/patches/18791/?format=json","web_url":"https://patchwork.libcamera.org/patch/18791/","project":{"id":1,"url":"https://patchwork.libcamera.org/api/1.1/projects/1/?format=json","name":"libcamera","link_name":"libcamera","list_id":"libcamera_core","list_email":"libcamera-devel@lists.libcamera.org","web_url":"","scm_url":"","webscm_url":""},"msgid":"<20230705083111.32462-1-laurent.pinchart@ideasonboard.com>","date":"2023-07-05T08:31:11","name":"[libcamera-devel,v2.1,1/2] Documentation: Add predefined macros from config.h to Doxyfile","commit_ref":null,"pull_url":null,"state":"accepted","archived":false,"hash":"b4170894c0ebdb117a64c8cf8a67d5d89f4a979a","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/1.1/people/2/?format=json","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"delegate":null,"mbox":"https://patchwork.libcamera.org/patch/18791/mbox/","series":[{"id":3955,"url":"https://patchwork.libcamera.org/api/1.1/series/3955/?format=json","web_url":"https://patchwork.libcamera.org/project/libcamera/list/?series=3955","date":"2023-07-05T08:31:11","name":"[libcamera-devel,v2.1,1/2] Documentation: Add predefined macros from config.h to Doxyfile","version":1,"mbox":"https://patchwork.libcamera.org/series/3955/mbox/"}],"comments":"https://patchwork.libcamera.org/api/patches/18791/comments/","check":"pending","checks":"https://patchwork.libcamera.org/api/patches/18791/checks/","tags":{},"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 2A32CBDC71\n\tfor <parsemail@patchwork.libcamera.org>;\n\tWed,  5 Jul 2023 08:31:15 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 5ADBD628C0;\n\tWed,  5 Jul 2023 10:31:14 +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 51B2A61E34\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed,  5 Jul 2023 10:31:12 +0200 (CEST)","from pendragon.ideasonboard.com (85-160-42-71.reb.o2.cz\n\t[85.160.42.71])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 3B5EB6D5\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed,  5 Jul 2023 10:30:27 +0200 (CEST)"],"DKIM-Signature":["v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1688545874;\n\tbh=sUB2/YIKoVd/tm6O8jzPauHXYZ0YnztOVn59R1nX5CY=;\n\th=To:Date:In-Reply-To:References:Subject:List-Id:List-Unsubscribe:\n\tList-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:\n\tFrom;\n\tb=WuEdDoA8IU4/lw/FHnk2uCBvt6Ye4Exjt5iw48rMCrydrK/mfg8Vpp05lknoIekSb\n\tFfhM1NgLZyHK35t1hfU7Gt742oOPIBsdfam0Rt39AU/56sB4zz3L7hBYSxAQ5AenYW\n\twTxzxfzGRZaB0BxuwOxBSXn86lrl7pFmGKLMU9rFTw3Iv/ii0YKIEQ5gWEeE4x6Ow1\n\t8uoZdrTwrdUdufCdAJxUy4NvtkZSlPl7Nny1KvuXIyE8hkJm1+7rgWaB+cqTq+KyzL\n\tuP8JQkn2/rVfoMFLSG32Rlzzc/YLXArDVdoUiqPs4D2ZxqQMPe7riftxQjKJA+KVqd\n\tnAglFmsWHtHHQ==","v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1688545827;\n\tbh=sUB2/YIKoVd/tm6O8jzPauHXYZ0YnztOVn59R1nX5CY=;\n\th=From:To:Subject:Date:In-Reply-To:References:From;\n\tb=UarkMQqoFNmAu46L0+4K1wDyp0IO+2ZFpvPwEkFZQOUsrMAfaMhEftl7z4TNJ9FNy\n\tYkZpAx/8FQ1/tnfhhrF/ug/NKcndFVsESG4nsDejbJBb5TCS84WJqyqOX27gjbD2+A\n\tjZlO1QwxR+7R2cLwQU9E2LcE170JZonFojcs1pYw="],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=ideasonboard.com\n\theader.i=@ideasonboard.com\n\theader.b=\"UarkMQqo\"; dkim-atps=neutral","To":"libcamera-devel@lists.libcamera.org","Date":"Wed,  5 Jul 2023 11:31:11 +0300","Message-Id":"<20230705083111.32462-1-laurent.pinchart@ideasonboard.com>","X-Mailer":"git-send-email 2.39.3","In-Reply-To":"<20230704234422.11863-2-laurent.pinchart@ideasonboard.com>","References":"<20230704234422.11863-2-laurent.pinchart@ideasonboard.com>","MIME-Version":"1.0","Content-Transfer-Encoding":"8bit","Subject":"[libcamera-devel] [PATCH v2.1 1/2] Documentation: Add predefined\n\tmacros from config.h to Doxyfile","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>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"},"content":"libcamera creates a config.h file with predefined macros, and instructs\nthe compiler to include it implicitly with the -include argument.\nDoxygen has no support for implicit inclusion of headers, but has a\nPREDEFINED configuration option for its preprocessor that lists\npredefined macros. Populate it with the values from the config_h\nconfiguration data object that is used for generate the config.h file,\nto ensure that documentation matches the configuration options libcamera\nhas been built with.\n\nBump the minimum meson version to 0.57 to use cfg_data.keys().\n\nSigned-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\nReviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>\n---\nChanges since v2:\n\n- Bump the minimum meson version to 0.57.\n\nChanges since v1:\n\n- Correct indentation and line wrap in the generate Doxyfile\n---\n Documentation/Doxyfile.in | 3 ++-\n Documentation/meson.build | 7 +++++++\n meson.build               | 2 +-\n 3 files changed, 10 insertions(+), 2 deletions(-)","diff":"diff --git a/Documentation/Doxyfile.in b/Documentation/Doxyfile.in\nindex 1447abdb7d8c..697a14d1dfe2 100644\n--- a/Documentation/Doxyfile.in\n+++ b/Documentation/Doxyfile.in\n@@ -80,6 +80,7 @@ INCLUDE_FILE_PATTERNS  = *.h\n \n PREDEFINED             = __DOXYGEN__ \\\n                          __cplusplus \\\n-                         __attribute__(x)=\n+                         __attribute__(x)= \\\n+\t\t\t @PREDEFINED@\n \n HAVE_DOT               = YES\ndiff --git a/Documentation/meson.build b/Documentation/meson.build\nindex 186461561f8d..d675f368cf79 100644\n--- a/Documentation/meson.build\n+++ b/Documentation/meson.build\n@@ -16,6 +16,13 @@ if doxygen.found() and dot.found()\n     cdata.set('TOP_BUILDDIR', meson.project_build_root())\n     cdata.set('OUTPUT_DIR', meson.current_build_dir())\n \n+    doxygen_predefined = []\n+    foreach key : config_h.keys()\n+        doxygen_predefined += '@0@=@1@'.format(key, config_h.get(key))\n+    endforeach\n+\n+    cdata.set('PREDEFINED', ' \\\\\\n\\t\\t\\t '.join(doxygen_predefined))\n+\n     doxyfile = configure_file(input : 'Doxyfile.in',\n                               output : 'Doxyfile',\n                               configuration : cdata)\ndiff --git a/meson.build b/meson.build\nindex 9c1e708131eb..62db8ed8105d 100644\n--- a/meson.build\n+++ b/meson.build\n@@ -1,7 +1,7 @@\n # SPDX-License-Identifier: CC0-1.0\n \n project('libcamera', 'c', 'cpp',\n-    meson_version : '>= 0.56',\n+    meson_version : '>= 0.57',\n     version : '0.0.5',\n     default_options : [\n         'werror=true',\n","prefixes":["libcamera-devel","v2.1","1/2"]}