[{"id":35824,"web_url":"https://patchwork.libcamera.org/comment/35824/","msgid":"<175794164845.653594.5594249739617266142@localhost>","date":"2025-09-15T13:07:28","subject":"Re: [libcamera-ci] [PATCH v2] Add sphinx-book-theme package to\n\tcontainer images","submitter":{"id":184,"url":"https://patchwork.libcamera.org/api/people/184/","name":"Stefan Klug","email":"stefan.klug@ideasonboard.com"},"content":"Hi Laurent,\n\nThank you for the patch.\n\nQuoting Laurent Pinchart (2025-09-12 18:54:58)\n> libcamera will soon switch to sphinx-book-theme for documentation. Add\n> the corresponding package to container images.\n> \n> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n\nLooks good to me.\n\nReviewed-by: Stefan Klug <stefan.klug@ideasonboard.com>\n\nRegards,\nStefan\n\n> ---\n> Changes since v1:\n> \n> - Fix pip package name\n> - Fix handling of missing debian packages\n> ---\n>  .gitlab-ci/setup-container.sh | 20 +++++++++++++++++---\n>  gitlab-ci.yml                 |  6 +++---\n>  2 files changed, 20 insertions(+), 6 deletions(-)\n> \n> diff --git a/.gitlab-ci/setup-container.sh b/.gitlab-ci/setup-container.sh\n> index 7029919c509c..9d8319c9779b 100755\n> --- a/.gitlab-ci/setup-container.sh\n> +++ b/.gitlab-ci/setup-container.sh\n> @@ -111,6 +111,7 @@ PKGS_VIRTME_RUNTIME=(\n>  PKGS_PIP_MIN_VERSIONS=(\n>         'meson meson 1.2.0 remove'\n>         'python3-pygments pygments 2.10.0 keep'\n> +       'python3-sphinx-book-theme sphinx-book-theme 0.1.7 remove'\n>         'python3-sphinxcontrib.doxylink sphinxcontrib-doxylink 1.6.1 remove'\n>  )\n>  \n> @@ -125,6 +126,8 @@ case $FDO_DISTRIBUTION_VERSION in\n>         PKGS_LIBCAMERA_RUNTIME+=( g++-9 )\n>         ;;\n>  'bookworm')\n> +       # Sphinx theme for the documentation.\n> +       PKGS_LIBCAMERA_RUNTIME+=( python3-sphinx-book-theme )\n>         # libclang-rt-dev for the clang ASan runtime.\n>         PKGS_LIBCAMERA_RUNTIME_MULTIARCH+=( libclang-rt-dev )\n>         # For cam and lc-compliance\n> @@ -134,6 +137,8 @@ case $FDO_DISTRIBUTION_VERSION in\n>  'trixie')\n>         # gcc 13 to expand compilation testing coverage.\n>         PKGS_LIBCAMERA_RUNTIME+=( g++-13 )\n> +       # Sphinx theme for the documentation.\n> +       PKGS_LIBCAMERA_RUNTIME+=( python3-sphinx-book-theme )\n>         # libclang-rt-dev for the clang ASan runtime.\n>         PKGS_LIBCAMERA_RUNTIME_MULTIARCH+=( libclang-rt-dev )\n>         ;;\n> @@ -196,7 +201,7 @@ cbuild_install_pkgs() {\n>  dpkg_version() {\n>         local pkg=$1\n>  \n> -       local version=$(dpkg -s $pkg | grep '^Version: ')\n> +       local version=$(dpkg -s $pkg 2>/dev/null | grep '^Version: ')\n>         version=${version#* }\n>         version=${version%%+*}\n>         version=${version%%-*}\n> @@ -230,8 +235,17 @@ cbuild_fixups() {\n>  \n>                 local version=$(dpkg_version $pkg_name)\n>  \n> -               if dpkg_check_version $version $min_version ; then\n> -                       echo \"$pkg_name $version too old, installing $min_version from pip\"\n> +               if dpkg_check_version \"$version\" \"$min_version\" ; then\n> +                       local reason\n> +\n> +                       if [[ -n \"$version\" ]] ; then\n> +                               reason=\"$version too old\"\n> +                       else\n> +                               reason=\"missing\"\n> +                               action=\n> +                       fi\n> +\n> +                       echo \"$pkg_name $reason, installing $min_version from pip\"\n>  \n>                         if [[ $action == 'remove' ]] ; then\n>                                 apt remove -y ${pkg_name}\n> diff --git a/gitlab-ci.yml b/gitlab-ci.yml\n> index 57607dbfe7e4..e5bcc6883c95 100644\n> --- a/gitlab-ci.yml\n> +++ b/gitlab-ci.yml\n> @@ -59,17 +59,17 @@ include:\n>  .libcamera-ci.debian:11:\n>    variables:\n>      FDO_DISTRIBUTION_VERSION: 'bullseye'\n> -    FDO_DISTRIBUTION_TAG: '2025-07-27.1'\n> +    FDO_DISTRIBUTION_TAG: '2025-09-12.2'\n>  \n>  .libcamera-ci.debian:12:\n>    variables:\n>      FDO_DISTRIBUTION_VERSION: 'bookworm'\n> -    FDO_DISTRIBUTION_TAG: '2025-07-27.1'\n> +    FDO_DISTRIBUTION_TAG: '2025-09-12.2'\n>  \n>  .libcamera-ci.debian:13:\n>    variables:\n>      FDO_DISTRIBUTION_VERSION: 'trixie'\n> -    FDO_DISTRIBUTION_TAG: '2025-07-27.1'\n> +    FDO_DISTRIBUTION_TAG: '2025-09-12.2'\n>  \n>  .container-debian:\n>    extends:\n> \n> base-commit: d58b30ed21a5663c5c6fd19da158de01b186831e\n> -- \n> Regards,\n> \n> Laurent Pinchart\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 404B9BE173\n\tfor <parsemail@patchwork.libcamera.org>;\n\tMon, 15 Sep 2025 13:07:34 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 132726936F;\n\tMon, 15 Sep 2025 15:07:33 +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 B1286613A0\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon, 15 Sep 2025 15:07:31 +0200 (CEST)","from ideasonboard.com (unknown\n\t[IPv6:2a00:6020:448c:6c00:2a47:b7e5:c39c:d1b3])\n\tby perceval.ideasonboard.com (Postfix) with UTF8SMTPSA id 2A5C31744; \n\tMon, 15 Sep 2025 15:06:14 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"wGFVUUU1\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1757941574;\n\tbh=BGUlDQFgxy9IcxPe2rMULFdjtGQ2Rf3GoWVn1Zk4nqI=;\n\th=In-Reply-To:References:Subject:From:To:Date:From;\n\tb=wGFVUUU1CFSgSsy2nm9zj+qdzGwtqY8yUOXqpO+pJC5w3+R+N5GoQc3VT2Sf1N+MS\n\tnUAbghD0F+07rvkL5Pauyko7VaNjyePsIvXHybHMJUfg+L3nSPN9+m8t7uiz7OveJZ\n\tRgAkwTBzFhkvM9RlReA3NtJpqTjyWdsSsf4cLOfo=","Content-Type":"text/plain; charset=\"utf-8\"","MIME-Version":"1.0","Content-Transfer-Encoding":"quoted-printable","In-Reply-To":"<20250912165458.32168-1-laurent.pinchart@ideasonboard.com>","References":"<20250912165458.32168-1-laurent.pinchart@ideasonboard.com>","Subject":"Re: [libcamera-ci] [PATCH v2] Add sphinx-book-theme package to\n\tcontainer images","From":"Stefan Klug <stefan.klug@ideasonboard.com>","To":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>,\n\tlibcamera-devel@lists.libcamera.org","Date":"Mon, 15 Sep 2025 15:07:28 +0200","Message-ID":"<175794164845.653594.5594249739617266142@localhost>","User-Agent":"alot/0.12.dev8+g2c003385c862.d20250602","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>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":35828,"web_url":"https://patchwork.libcamera.org/comment/35828/","msgid":"<70323e4d-4dc9-48e5-bb97-3be48f1f489a@ideasonboard.com>","date":"2025-09-15T14:43:31","subject":"Re: [libcamera-ci] [PATCH v2] Add sphinx-book-theme package to\n\tcontainer images","submitter":{"id":216,"url":"https://patchwork.libcamera.org/api/people/216/","name":"Barnabás Pőcze","email":"barnabas.pocze@ideasonboard.com"},"content":"2025. 09. 12. 18:54 keltezéssel, Laurent Pinchart írta:\n> libcamera will soon switch to sphinx-book-theme for documentation. Add\n> the corresponding package to container images.\n> \n> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n> ---\n\nNot tested, but looks good.\n\nReviewed-by: Barnabás Pőcze <barnabas.pocze@ideasonboard.com>\n\n\n> Changes since v1:\n> \n> - Fix pip package name\n> - Fix handling of missing debian packages\n> ---\n>   .gitlab-ci/setup-container.sh | 20 +++++++++++++++++---\n>   gitlab-ci.yml                 |  6 +++---\n>   2 files changed, 20 insertions(+), 6 deletions(-)\n> \n> diff --git a/.gitlab-ci/setup-container.sh b/.gitlab-ci/setup-container.sh\n> index 7029919c509c..9d8319c9779b 100755\n> --- a/.gitlab-ci/setup-container.sh\n> +++ b/.gitlab-ci/setup-container.sh\n> @@ -111,6 +111,7 @@ PKGS_VIRTME_RUNTIME=(\n>   PKGS_PIP_MIN_VERSIONS=(\n>   \t'meson meson 1.2.0 remove'\n>   \t'python3-pygments pygments 2.10.0 keep'\n> +\t'python3-sphinx-book-theme sphinx-book-theme 0.1.7 remove'\n>   \t'python3-sphinxcontrib.doxylink sphinxcontrib-doxylink 1.6.1 remove'\n>   )\n>   \n> @@ -125,6 +126,8 @@ case $FDO_DISTRIBUTION_VERSION in\n>   \tPKGS_LIBCAMERA_RUNTIME+=( g++-9 )\n>   \t;;\n>   'bookworm')\n> +\t# Sphinx theme for the documentation.\n> +\tPKGS_LIBCAMERA_RUNTIME+=( python3-sphinx-book-theme )\n>   \t# libclang-rt-dev for the clang ASan runtime.\n>   \tPKGS_LIBCAMERA_RUNTIME_MULTIARCH+=( libclang-rt-dev )\n>   \t# For cam and lc-compliance\n> @@ -134,6 +137,8 @@ case $FDO_DISTRIBUTION_VERSION in\n>   'trixie')\n>   \t# gcc 13 to expand compilation testing coverage.\n>   \tPKGS_LIBCAMERA_RUNTIME+=( g++-13 )\n> +\t# Sphinx theme for the documentation.\n> +\tPKGS_LIBCAMERA_RUNTIME+=( python3-sphinx-book-theme )\n>   \t# libclang-rt-dev for the clang ASan runtime.\n>   \tPKGS_LIBCAMERA_RUNTIME_MULTIARCH+=( libclang-rt-dev )\n>   \t;;\n> @@ -196,7 +201,7 @@ cbuild_install_pkgs() {\n>   dpkg_version() {\n>   \tlocal pkg=$1\n>   \n> -\tlocal version=$(dpkg -s $pkg | grep '^Version: ')\n> +\tlocal version=$(dpkg -s $pkg 2>/dev/null | grep '^Version: ')\n>   \tversion=${version#* }\n>   \tversion=${version%%+*}\n>   \tversion=${version%%-*}\n> @@ -230,8 +235,17 @@ cbuild_fixups() {\n>   \n>   \t\tlocal version=$(dpkg_version $pkg_name)\n>   \n> -\t\tif dpkg_check_version $version $min_version ; then\n> -\t\t\techo \"$pkg_name $version too old, installing $min_version from pip\"\n> +\t\tif dpkg_check_version \"$version\" \"$min_version\" ; then\n> +\t\t\tlocal reason\n> +\n> +\t\t\tif [[ -n \"$version\" ]] ; then\n> +\t\t\t\treason=\"$version too old\"\n> +\t\t\telse\n> +\t\t\t\treason=\"missing\"\n> +\t\t\t\taction=\n> +\t\t\tfi\n> +\n> +\t\t\techo \"$pkg_name $reason, installing $min_version from pip\"\n>   \n>   \t\t\tif [[ $action == 'remove' ]] ; then\n>   \t\t\t\tapt remove -y ${pkg_name}\n> diff --git a/gitlab-ci.yml b/gitlab-ci.yml\n> index 57607dbfe7e4..e5bcc6883c95 100644\n> --- a/gitlab-ci.yml\n> +++ b/gitlab-ci.yml\n> @@ -59,17 +59,17 @@ include:\n>   .libcamera-ci.debian:11:\n>     variables:\n>       FDO_DISTRIBUTION_VERSION: 'bullseye'\n> -    FDO_DISTRIBUTION_TAG: '2025-07-27.1'\n> +    FDO_DISTRIBUTION_TAG: '2025-09-12.2'\n>   \n>   .libcamera-ci.debian:12:\n>     variables:\n>       FDO_DISTRIBUTION_VERSION: 'bookworm'\n> -    FDO_DISTRIBUTION_TAG: '2025-07-27.1'\n> +    FDO_DISTRIBUTION_TAG: '2025-09-12.2'\n>   \n>   .libcamera-ci.debian:13:\n>     variables:\n>       FDO_DISTRIBUTION_VERSION: 'trixie'\n> -    FDO_DISTRIBUTION_TAG: '2025-07-27.1'\n> +    FDO_DISTRIBUTION_TAG: '2025-09-12.2'\n>   \n>   .container-debian:\n>     extends:\n> \n> base-commit: d58b30ed21a5663c5c6fd19da158de01b186831e","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 44AE2C328C\n\tfor <parsemail@patchwork.libcamera.org>;\n\tMon, 15 Sep 2025 14:43:36 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id EA4396936A;\n\tMon, 15 Sep 2025 16:43:35 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 5BF0669369\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon, 15 Sep 2025 16:43:34 +0200 (CEST)","from [192.168.33.2] (185.221.142.115.nat.pool.zt.hu\n\t[185.221.142.115])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id DE4846DF;\n\tMon, 15 Sep 2025 16:42:16 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"SqVkQ1IY\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1757947337;\n\tbh=fsN0qb355XdKZVg9oHKhnqL/O/IXWZ5RUnFw41CNS30=;\n\th=Date:Subject:To:References:From:In-Reply-To:From;\n\tb=SqVkQ1IYcwd4ENcflJKeyb27AH9F40QTd3R5uX1VcdIeQ7nid5hVgPdUZZkrZrBqV\n\tzZtSXyGusQA3E6RceR5kkQjW8D+rQZyZ1TAxjtliX9GLCX14IYuRCbT7DD0RyAxCq5\n\thGmxl5BObFdQrjiJS71tzOhB+N0WZSF2DgzEPJNE=","Message-ID":"<70323e4d-4dc9-48e5-bb97-3be48f1f489a@ideasonboard.com>","Date":"Mon, 15 Sep 2025 16:43:31 +0200","MIME-Version":"1.0","User-Agent":"Mozilla Thunderbird","Subject":"Re: [libcamera-ci] [PATCH v2] Add sphinx-book-theme package to\n\tcontainer images","To":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>,\n\tlibcamera-devel@lists.libcamera.org","References":"<20250912165458.32168-1-laurent.pinchart@ideasonboard.com>","From":"=?utf-8?q?Barnab=C3=A1s_P=C5=91cze?= <barnabas.pocze@ideasonboard.com>","Content-Language":"en-US, hu-HU","In-Reply-To":"<20250912165458.32168-1-laurent.pinchart@ideasonboard.com>","Content-Type":"text/plain; charset=UTF-8; format=flowed","Content-Transfer-Encoding":"8bit","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>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}}]