From patchwork Wed Aug 14 08:41:03 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Stefan Klug X-Patchwork-Id: 20909 Return-Path: X-Original-To: parsemail@patchwork.libcamera.org Delivered-To: parsemail@patchwork.libcamera.org Received: from lancelot.ideasonboard.com (lancelot.ideasonboard.com [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id 53345BDB13 for ; Wed, 14 Aug 2024 08:42:33 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id E6C5D633C0; Wed, 14 Aug 2024 10:42:32 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="bzQ243th"; dkim-atps=neutral Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 750E6633BF for ; Wed, 14 Aug 2024 10:42:28 +0200 (CEST) Received: from ideasonboard.com (unknown [IPv6:2a00:6020:448c:6c00:8a6:aa2:ebee:5ae5]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id BBE059FF; Wed, 14 Aug 2024 10:41:30 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1723624890; bh=buW6W8OInYbXhZvVAy41lNfViDRXc0wjfgd3HqbKD58=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=bzQ243tholqvJEgekLHPHGZZEM0VYj538zrOAa5i4QOvvpZm1fJRUvmAro9XKq2Pi pc9SOpduQ96jwkvV8zReX6hwpHFl4XC1hmQt81S7dBvO7EPt118QScg+iVov0eWUSp mZYPIzy1LsvP2lSeBDiO1GlqHJM6R2+sGEZZ0eUw= From: Stefan Klug To: libcamera-devel@lists.libcamera.org Cc: Stefan Klug Subject: [PATCH v1 2/2] Documentation: Add tuning guide from external source Date: Wed, 14 Aug 2024 10:41:03 +0200 Message-ID: <20240814084215.61857-3-stefan.klug@ideasonboard.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240814084215.61857-1-stefan.klug@ideasonboard.com> References: <20240814084215.61857-1-stefan.klug@ideasonboard.com> MIME-Version: 1.0 X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" Add the external tuning guide as meson subproject. Symlink it into the Documentation/guides directory, so that sphinx can pick it up. This setup feels a bit cumbersome, therefore I try to explain the reasoning (and maybe someone comes up with a better solution): The main reason is that we don't want to have large binary files (aka images) in the main libcamera repository. Especially if they change a lot the repository size increases tremendously. In a meson based project, meson subprojects are the way to go. This however has the following side effects: - The subprojects needs to contain a meson.build (That's why libcamera-tuning-guide is also meson based) - We can't reference ../subproject/libcamera-tuning-guide/tuning.rst from within the main meson build, as that violates the meson sandbox - Referencing ../subproject/libcamera-tuning-guide/tuning.rst via a sphinx include directive doesn't work either as sphinx then tries to resolve images relative to the outer document. - Symlinking ../subprojects/libcameta-tuning-guide into Documentation/guides works wuite well, but fails as soon as libcamera-tuning-guide contains an additional rst file (like index.rst) which is not referenced from the libcamera documentation. The solution is to move the actual content into ../subproject/libcamera-tuning-guide/content/ and to symlink that directory into Documentation/guides. Signed-off-by: Stefan Klug --- Documentation/conf.py | 4 ++-- Documentation/guides/tuning | 1 + Documentation/index.rst | 1 + Documentation/meson.build | 2 ++ subprojects/libcamera-tuning-guide.wrap | 7 +++++++ 5 files changed, 13 insertions(+), 2 deletions(-) create mode 120000 Documentation/guides/tuning create mode 100644 subprojects/libcamera-tuning-guide.wrap diff --git a/Documentation/conf.py b/Documentation/conf.py index 022e698efac4..7675efb6682a 100644 --- a/Documentation/conf.py +++ b/Documentation/conf.py @@ -21,8 +21,8 @@ # -- Project information ----------------------------------------------------- project = 'libcamera' -copyright = '2018-2019, The libcamera documentation authors' -author = u'Kieran Bingham, Jacopo Mondi, Laurent Pinchart, Niklas Söderlund' +copyright = '2018-2024, The libcamera documentation authors' +author = u'Kieran Bingham, Jacopo Mondi, Laurent Pinchart, Niklas Söderlund, Stefan Klug' # Version information is provided by the build environment, through the # sphinx command line. diff --git a/Documentation/guides/tuning b/Documentation/guides/tuning new file mode 120000 index 000000000000..3e62b7b660d0 --- /dev/null +++ b/Documentation/guides/tuning @@ -0,0 +1 @@ +../../subprojects/libcamera-tuning-guide/content/ \ No newline at end of file diff --git a/Documentation/index.rst b/Documentation/index.rst index 5442ae75dde7..991dcf2b66fb 100644 --- a/Documentation/index.rst +++ b/Documentation/index.rst @@ -16,6 +16,7 @@ Developer Guide Application Writer's Guide + Sensor Tuning Guide Pipeline Handler Writer's Guide IPA Writer's guide Tracing guide diff --git a/Documentation/meson.build b/Documentation/meson.build index 1ba40fdf67ac..58c656a54150 100644 --- a/Documentation/meson.build +++ b/Documentation/meson.build @@ -143,6 +143,8 @@ if sphinx.found() '../README.rst', ] + subproject('libcamera-tuning-guide', required : true) + release = 'release=v' + libcamera_git_version custom_target('documentation', diff --git a/subprojects/libcamera-tuning-guide.wrap b/subprojects/libcamera-tuning-guide.wrap new file mode 100644 index 000000000000..d8e172471fa6 --- /dev/null +++ b/subprojects/libcamera-tuning-guide.wrap @@ -0,0 +1,7 @@ +# SPDX-License-Identifier: CC0-1.0 + +[wrap-git] +directory = libcamera-tuning-guide +url = https://git.uk.ideasonboard.com/sklug/libcamera-tuning-guide.git +# tags/0.2.5 +revision = head