From patchwork Fri Oct 28 10:19:35 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Opdenacker X-Patchwork-Id: 14522 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id C9A99FA3741 for ; Fri, 28 Oct 2022 10:19:55 +0000 (UTC) Received: from relay2-d.mail.gandi.net (relay2-d.mail.gandi.net [217.70.183.194]) by mx.groups.io with SMTP id smtpd.web09.4667.1666952389111243451 for ; Fri, 28 Oct 2022 03:19:49 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=cyGMy16v; spf=pass (domain: bootlin.com, ip: 217.70.183.194, mailfrom: michael.opdenacker@bootlin.com) Received: (Authenticated sender: michael.opdenacker@bootlin.com) by mail.gandi.net (Postfix) with ESMTPSA id 68B5F40006; Fri, 28 Oct 2022 10:19:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1666952386; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=FBwUGVlgHKH66tlh4Bz9LKRl0yvIeYkPvK4QM4DLd4U=; b=cyGMy16vOhdB+XfH0IJjb+nk+XyF4miwJ1J0WbUfX7X4k5k6zk/K5HV3062y9VFcDdodNq i4Z01SW/AQHFHxaNHKRK4XBNDIL8Wv2WQD8VPAXCT40EZIVW5scyoOgYT5NE2+DdT6A2wr LwQromdvvW0EQNl3H7Dmxh9pYHdYmEeUdFln1MA13beHArq7VTa9OMgpjC6wsT9w13c8eT kJTelHJ9N8qel1mnliZ5WoDx7FY+QkJOTfobTtocr2bLVTLIjjByZw6Hpd81j8VEuCNjYy tYZbrIY10l57wZ4RgCLA/dXjJPVvREZTzIC6q4kwANpcd7vgKCOLZoW2TfSVqg== From: michael.opdenacker@bootlin.com To: docs@lists.yoctoproject.org Cc: Michael Opdenacker Subject: [PATCH 1/5] ref-manual: terms.rst: add SBOM and SPDX terms Date: Fri, 28 Oct 2022 12:19:35 +0200 Message-Id: <20221028101939.93195-2-michael.opdenacker@bootlin.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221028101939.93195-1-michael.opdenacker@bootlin.com> References: <20221028101939.93195-1-michael.opdenacker@bootlin.com> MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Fri, 28 Oct 2022 10:19:55 -0000 X-Groupsio-URL: https://lists.yoctoproject.org/g/docs/message/3432 From: Michael Opdenacker Signed-off-by: Michael Opdenacker --- documentation/ref-manual/terms.rst | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/documentation/ref-manual/terms.rst b/documentation/ref-manual/terms.rst index 1e3f718a8f..5aedd08aae 100644 --- a/documentation/ref-manual/terms.rst +++ b/documentation/ref-manual/terms.rst @@ -323,6 +323,23 @@ universal, the list includes them just in case: :term:`build host` and other components, that can work on specific hardware. + :term:`SBOM` + This term means *Software Bill of Materials*. When you distribute + software, it offers a description of all the components you used, + their corresponding licenses, their dependencies, the changes that were + applied and the known vulnerabilities that were fixed. + + This can be used by the recipients of the software to assess + their exposure to license compliance and security vulnerability issues. + + See the `Software Supply Chain `__ + article on Wikipedia for more details. + + The OpenEmbedded Build System can generate such documentation for your + project, in :term:`SPDX` format, based on all the metadata it used to + build the software images. See the ":ref:`dev-manual/common-tasks:creating + a software bill of materials`" section of the Development Tasks manual. + :term:`Source Directory` This term refers to the directory structure created as a result of creating a local copy of the ``poky`` Git @@ -383,6 +400,15 @@ universal, the list includes them just in case: ":ref:`overview-manual/development-environment:repositories, tags, and branches`" section in the Yocto Project Overview and Concepts Manual. + :term:`SPDX` + This term means *Software Package Data Exchange*, and is used as a open + standard for providing a *Software Bill of Materials* (:term:`SBOM`). + This standard is developed through a `Linux Foundation project + `__ and is used by the OpenEmbedded Build System to + provide an :term:`SBOM` associated to each a software image. + + For details, see Wikipedia's `SPDX page `__. + :term:`Sysroot` When cross-compiling, the target file system may be differently laid out and contain different things compared to the host system. The concept From patchwork Fri Oct 28 10:19:36 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Opdenacker X-Patchwork-Id: 14523 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id D55E6FA3746 for ; Fri, 28 Oct 2022 10:19:55 +0000 (UTC) Received: from relay7-d.mail.gandi.net (relay7-d.mail.gandi.net [217.70.183.200]) by mx.groups.io with SMTP id smtpd.web11.4619.1666952389542883847 for ; Fri, 28 Oct 2022 03:19:50 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=AyM7Di1g; spf=pass (domain: bootlin.com, ip: 217.70.183.200, mailfrom: michael.opdenacker@bootlin.com) Received: (Authenticated sender: michael.opdenacker@bootlin.com) by mail.gandi.net (Postfix) with ESMTPSA id B5A242000C; Fri, 28 Oct 2022 10:19:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1666952387; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=TU7qDzZW5Cvkq2K/xqGc9TgZih3HK9r3IGfv/lTQOvs=; b=AyM7Di1gWCPHakWinkcW7fGCgnRM4kzUerbPH4iArf9Gfw2jGSdXj8xXNYgtkFJdoro8rz doAD9cbtoeL7Ey/plD8vdnIZUJVNpIFVJ2Az6ikF64BddeLcWG2HAa/mr6JKadh/rJCZ3i LcOtX6olPLOLUUIr152ujyBPe878C9ZwXHv83rSLPfKAL2ZyGaCLa/FV27k4SQCUYlgLfu +PD+hdss80+lSx6qwiOaAlvAwnA/50/SpyNC5MYwGkm5coi9yQ5KO/HJsanrSoJNVFN9g/ s58yviUoAnE8N+f0jwvEdrgz8588/jfpocTEY9HRu5XioMumR0/A43+6BtLmRQ== From: michael.opdenacker@bootlin.com To: docs@lists.yoctoproject.org Cc: Michael Opdenacker Subject: [PATCH 2/5] ref-manual: variables.rst: document spdx-create class variables Date: Fri, 28 Oct 2022 12:19:36 +0200 Message-Id: <20221028101939.93195-3-michael.opdenacker@bootlin.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221028101939.93195-1-michael.opdenacker@bootlin.com> References: <20221028101939.93195-1-michael.opdenacker@bootlin.com> MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Fri, 28 Oct 2022 10:19:55 -0000 X-Groupsio-URL: https://lists.yoctoproject.org/g/docs/message/3433 From: Michael Opdenacker Signed-off-by: Michael Opdenacker --- documentation/ref-manual/variables.rst | 79 ++++++++++++++++++++++++++ 1 file changed, 79 insertions(+) diff --git a/documentation/ref-manual/variables.rst b/documentation/ref-manual/variables.rst index 0f9df3ac20..14a20711f5 100644 --- a/documentation/ref-manual/variables.rst +++ b/documentation/ref-manual/variables.rst @@ -7290,6 +7290,85 @@ system and gives an overview of their function and contents. You can specify only a single URL in :term:`SOURCE_MIRROR_URL`. + :term:`SPDX_ARCHIVE_PACKAGED` + This option allows to add to :term:`SPDX` output compressed archives + of the files in the generated target packages. + + Such archives are available in + ``tmp/deploy/spdx/MACHINE/packages/packagename.tar.zst`` + under the :term:`Build Directory`. + + Enable this option as follows:: + + SPDX_ARCHIVE_PACKAGED = "1" + + According to our tests on release 4.1 "langdale", building + ``core-image-minimal`` for the ``qemux86-64`` machine, enabling this + option multiplied the size of the ``tmp/deploy/spdx`` directory by a + factor of 13 (+1.6 GiB for this image), compared to just using the + :ref:`create-spdx ` class with no option. + + Note that this option doesn't increase the size of :term:`SPDX` + files in ``tmp/deploy/images/MACHINE``. + + :term:`SPDX_ARCHIVE_SOURCES` + This option allows to add to :term:`SPDX` output compressed archives + of the sources for packages installed on the target. It currently + only works when :term:`SPDX_INCLUDE_SOURCES` is set. + + Such archives are available in + ``tmp/deploy/spdx/MACHINE/recipes/recipe-packagename.tar.zst`` + under the :term:`Build Directory`. + + Enable this option as follows:: + + SPDX_INCLUDE_SOURCES = "1" + SPDX_ARCHIVE_SOURCES = "1" + + According to our tests on release 4.1 "langdale", building + ``core-image-minimal`` for the ``qemux86-64`` machine, enabling + these options multiplied the size of the ``tmp/deploy/spdx`` + directory by a factor of 11 (+1.4 GiB for this image), + compared to just using the :ref:`create-spdx ` + class with no option. + + Note that using this option only marginally increases the size + of the :term:`SPDX` output in ``tmp/deploy/images/MACHINE/`` + (+ 0.07\% with the tested image), compared to just enabling + :term:`SPDX_INCLUDE_SOURCES`. + + :term:`SPDX_INCLUDE_SOURCES` + This option allows to add a description of the source files used to build + the host tools and the target packages, to the ``spdx.json`` files in + ``tmp/deploy/spdx/MACHINE/recipes/`` under the :term:`Build Directory`. + As a consequence, the ``spdx.json`` files under the ``by-namespace`` and + ``packages`` subdirectories in ``tmp/deploy/spdx/MACHINE`` are also + modified to include references to such source file descriptions. + + Enable this option as follows:: + + SPDX_INCLUDE_SOURCES = "1" + + According to our tests on release 4.1 "langdale", building + ``core-image-minimal`` for the ``qemux86-64`` machine, enabling + this option multiplied the total size of the ``tmp/deploy/spdx`` + directory by a factor of 3 (+291 MiB for this image), + and the size of the ``IMAGE-MACHINE.spdx.tar.zst`` in + ``tmp/deploy/images/MACHINE`` by a factor of 130 (+15 MiB for this + image), compared to just using the + :ref:`create-spdx ` class with no option. + + :term:`SPDX_PRETTY` + This option makes the SPDX output more human-readable, using + identation and newlines, instead of the default output in a + single line:: + + SPDX_PRETTY = "1" + + The generated SPDX files are approximately 20% bigger, but + this option is recommended if you want to inspect the SPDX + output files with a text editor. + :term:`SPDXLICENSEMAP` Maps commonly used license names to their SPDX counterparts found in ``meta/files/common-licenses/``. For the default :term:`SPDXLICENSEMAP` From patchwork Fri Oct 28 10:19:37 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Opdenacker X-Patchwork-Id: 14524 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id D1140FA3745 for ; Fri, 28 Oct 2022 10:19:55 +0000 (UTC) Received: from relay2-d.mail.gandi.net (relay2-d.mail.gandi.net [217.70.183.194]) by mx.groups.io with SMTP id smtpd.web10.4597.1666952390112469888 for ; Fri, 28 Oct 2022 03:19:50 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=a9jTAy9h; spf=pass (domain: bootlin.com, ip: 217.70.183.194, mailfrom: michael.opdenacker@bootlin.com) Received: (Authenticated sender: michael.opdenacker@bootlin.com) by mail.gandi.net (Postfix) with ESMTPSA id A400640009; Fri, 28 Oct 2022 10:19:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1666952388; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=eMK6ESoEG5IXlcK1syeP1dYCG/hfFNDy/U42B5dl6so=; b=a9jTAy9huniABLFQf7tWM3L68oqJ1vYsw8z7Ufigxf9D9bbKjN43vTfyKzL8h5E9DOiKUy 3agRyeiWoDz0tDMAuswT7KSkpmis9oAfmM7pj2p+fcbrO8Yoj1QiWy4yDYdC3ddlDjKDk5 YwQ0J7MCxQc87Y4I92O9OcTUZiBYS2L13IbaceSSxHwACWX+wZhrZntLXj1HDZrupJQrEc il5PCKbmd5pdJDb4Z8tGZMktWEkdbQm97b+Kduo7HOMFwioyGgw97GWVFAJltfWVRE3fI1 ZR5hW3NirfAXbUi9TWC36jJl7W8cQPAvsd+uHP+Eoggt9Ri/7vxw/6B4TxdfqQ== From: michael.opdenacker@bootlin.com To: docs@lists.yoctoproject.org Cc: Michael Opdenacker Subject: [PATCH 3/5] dev-manual: common-tasks.rst: add section about SPDX / SBOM generation Date: Fri, 28 Oct 2022 12:19:37 +0200 Message-Id: <20221028101939.93195-4-michael.opdenacker@bootlin.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221028101939.93195-1-michael.opdenacker@bootlin.com> References: <20221028101939.93195-1-michael.opdenacker@bootlin.com> MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Fri, 28 Oct 2022 10:19:55 -0000 X-Groupsio-URL: https://lists.yoctoproject.org/g/docs/message/3434 From: Michael Opdenacker Also stop refering to the meta-spdxscanner class, no longer relevant. Signed-off-by: Michael Opdenacker --- documentation/dev-manual/common-tasks.rst | 96 ++++++++++++++--------- 1 file changed, 61 insertions(+), 35 deletions(-) diff --git a/documentation/dev-manual/common-tasks.rst b/documentation/dev-manual/common-tasks.rst index 25d7edbc29..263a1d302b 100644 --- a/documentation/dev-manual/common-tasks.rst +++ b/documentation/dev-manual/common-tasks.rst @@ -11236,8 +11236,6 @@ to be covered by assuming that there are three main areas of concern: - Compilation scripts and modifications to the source code must be provided. -- spdx files can be provided. - There are other requirements beyond the scope of these three and the methods described in this section (e.g. the mechanism through which source code is distributed). @@ -11429,39 +11427,6 @@ layers (recipes, configuration files, and so forth) enables you to meet your requirements to include the scripts to control compilation as well as any modifications to the original source. -Providing spdx files -~~~~~~~~~~~~~~~~~~~~~~~~~ - -The spdx module has been integrated to a layer named meta-spdxscanner. -meta-spdxscanner provides several kinds of scanner. If you want to enable -this function, you have to follow the following steps: - -1. Add meta-spdxscanner layer into ``bblayers.conf``. - -2. Refer to the README in meta-spdxscanner to setup the environment (e.g, - setup a fossology server) needed for the scanner. - -3. Meta-spdxscanner provides several methods within the bbclass to create spdx files. - Please choose one that you want to use and enable the spdx task. You have to - add some config options in ``local.conf`` file in your :term:`Build - Directory`. Here is an example showing how to generate spdx files - during BitBake using the fossology-python.bbclass:: - - # Select fossology-python.bbclass. - INHERIT += "fossology-python" - # For fossology-python.bbclass, TOKEN is necessary, so, after setup a - # Fossology server, you have to create a token. - TOKEN = "eyJ0eXAiO..." - # The fossology server is necessary for fossology-python.bbclass. - FOSSOLOGY_SERVER = "http://xx.xx.xx.xx:8081/repo" - # If you want to upload the source code to a special folder: - FOLDER_NAME = "xxxx" //Optional - # If you don't want to put spdx files in tmp/deploy/spdx, you can enable: - SPDX_DEPLOY_DIR = "${DEPLOY_DIR}" //Optional - -For more usage information refer to :yocto_git:`the meta-spdxscanner repository -`. - Compliance Limitations with Executables Built from Static Libraries ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -11711,6 +11676,67 @@ When analyzing CVEs, it is recommended to: - follow public `open source security mailing lists `__ for discussions and advance notifications of CVE bugs and software releases with fixes. +Creating a Software Bill of Materials +===================================== + +Once you are able to build an image for your project, once the licenses for +each software component are all identified (see +":ref:`dev-manual/common-tasks:working with licenses`") and once vulnerability +fixes are applied (see ":ref:`dev-manual/common-tasks:checking +for vulnerabilities`"), the OpenEmbedded build system can generate +a description of all the components you used, their licenses, their dependencies, +the changes that were applied and the known vulnerabilities that were fixed. + +This description is generated in the form of a *Software Bill of Materials* +(:term:`SBOM`), using the :term:`SPDX` standard. + +When you release software, this is the most standard way to provide information +about the Software Supply Chain of your software image and SDK, and allow your +users and customers to perform vulnerability and license compliance assessments, +using the tools of their choice. + +The OpenEmbedded build system doesn't generate such information by default. +To make this happen, you must inherit the +:ref:`create-spdx ` class from a configuration file:: + + INHERIT += "create-spdx" + +You then get :term:`SPDX` output in JSON format as an +``IMAGE-MACHINE.spdx.json`` file in ``tmp/deploy/images/MACHINE/`` inside the +:term:`Build Directory`. + +This is a toplevel file accompanied by an ``IMAGE-MACHINE.spdx.index.json`` +containing an index of JSON :term:`SPDX` files for individual recipes, together +with an ``IMAGE-MACHINE.spdx.tar.zst`` compressed archive containing all such +files. + +The :ref:`create-spdx ` class offers options to include +more information in the output :term:`SPDX` data, such as making the generated +files more human readable (:term:`SPDX_PRETTY`), adding compressed archives of +the files in the generated target packages (:term:`SPDX_ARCHIVE_PACKAGED`), +adding a description of the source files handled by the target recipes +(:term:`SPDX_INCLUDE_SOURCES`) and adding archives of these source files +themselves (:term:`SPDX_ARCHIVE_SOURCES`). + +Though the toplevel :term:`SPDX` output is available in +``tmp/deploy/images/MACHINE/`` inside the :term:`Build Directory`, ancillary +generated files are available in ``tmp/deploy/spdx/MACHINE`` too, such as: + +- The individual :term:`SPDX` JSON files in the ``IMAGE-MACHINE.spdx.tar.zst`` + archive. + +- Compressed archives of the files in the generated target packages, + in ``packages/packagename.tar.zst`` (when :term:`SPDX_ARCHIVE_PACKAGED` + is set). + +- Compressed archives of the source files used to build the host tools + and the target packages in ``recipes/recipe-packagename.tar.zst`` + (when :term:`SPDX_ARCHIVE_SOURCES` is set). + +See the `tools page `__ on the :term:`SPDX` +project website for a list of tools to consume and transform the :term:`SPDX` +data generated by the OpenEmbedded build system. + Using the Error Reporting Tool ============================== From patchwork Fri Oct 28 10:19:38 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Opdenacker X-Patchwork-Id: 14525 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id C7F65FA3744 for ; Fri, 28 Oct 2022 10:19:55 +0000 (UTC) Received: from relay5-d.mail.gandi.net (relay5-d.mail.gandi.net [217.70.183.197]) by mx.groups.io with SMTP id smtpd.web11.4620.1666952391835357278 for ; Fri, 28 Oct 2022 03:19:52 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=Zhzfh34c; spf=pass (domain: bootlin.com, ip: 217.70.183.197, mailfrom: michael.opdenacker@bootlin.com) Received: (Authenticated sender: michael.opdenacker@bootlin.com) by mail.gandi.net (Postfix) with ESMTPSA id DDEF61C0003; Fri, 28 Oct 2022 10:19:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1666952390; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=SuHY8mkAPixWDtYgtRufyW+Hon2L4HPLKiCw0ZUwxiQ=; b=Zhzfh34cUjbzN4kK7QyyL0A21zL4c23bcUvx+AcX3lyeW3d29T7wdYZm90A4nfu7ylWQEi thGtiK9y3nzsVvMxsPDwJoX7obPlBdGFk8X6ZEdFlRecD1lM7va+FCMgeUlY/izFzlvsen A+0JLpDd8SbRYMh24BVMI9iarYR5nCqVe5TLC5rZKU1fpk8uwVEGCtiZz5Bq8RJAwOkE7M VuGz+FYHoZk95GIE9LFvbDuCQZpqKXX/xlb+RRgt/SsETTtjOm8foHYr6OCvLW/NbA/5xm FTSfrHlK8Zh3AoCI2opCJCTs5Uw9ez37eVSoB4wkq3+inzw6lGC31sN2OKiEUw== From: michael.opdenacker@bootlin.com To: docs@lists.yoctoproject.org Cc: Michael Opdenacker Subject: [PATCH 4/5] ref-manual: classes.rst: expand documentation of create-spdx class Date: Fri, 28 Oct 2022 12:19:38 +0200 Message-Id: <20221028101939.93195-5-michael.opdenacker@bootlin.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221028101939.93195-1-michael.opdenacker@bootlin.com> References: <20221028101939.93195-1-michael.opdenacker@bootlin.com> MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Fri, 28 Oct 2022 10:19:55 -0000 X-Groupsio-URL: https://lists.yoctoproject.org/g/docs/message/3435 From: Michael Opdenacker Signed-off-by: Michael Opdenacker --- documentation/ref-manual/classes.rst | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/documentation/ref-manual/classes.rst b/documentation/ref-manual/classes.rst index cce0269b9a..621cf9c8b6 100644 --- a/documentation/ref-manual/classes.rst +++ b/documentation/ref-manual/classes.rst @@ -373,8 +373,24 @@ support. ``create-spdx.bbclass`` ======================= -The :ref:`create-spdx ` class provides support for automatically creating -SPDX SBoM documents based upon image and SDK contents. +The :ref:`create-spdx ` class provides support for +automatically creating :term:`SPDX` :term:`SBOM` documents based upon image +and SDK contents. + +This class is meant to be inherited globally from a configuration file:: + + INHERIT += "create-spdx" + +The output files are generated in ``tmp/deploy/spdx`` under the +:term:`Build Directory`. + +The exact behaviour of this class, and the amount of output can be controlled +by the :term:`SPDX_PRETTY`, :term:`SPDX_ARCHIVE_PACKAGED`, +:term:`SPDX_ARCHIVE_SOURCES` and :term:`SPDX_INCLUDE_SOURCES` variables. + +See the description of these variables and the +":ref:`dev-manual/common-tasks:creating a software bill of materials`" +section in the Yocto Project Development Manual for more details. .. _ref-classes-cross: From patchwork Fri Oct 28 10:19:39 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Opdenacker X-Patchwork-Id: 14521 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id C6B50ECAAA1 for ; Fri, 28 Oct 2022 10:19:55 +0000 (UTC) Received: from relay1-d.mail.gandi.net (relay1-d.mail.gandi.net [217.70.183.193]) by mx.groups.io with SMTP id smtpd.web11.4621.1666952393495278250 for ; Fri, 28 Oct 2022 03:19:53 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=JTXQ1PO8; spf=pass (domain: bootlin.com, ip: 217.70.183.193, mailfrom: michael.opdenacker@bootlin.com) Received: (Authenticated sender: michael.opdenacker@bootlin.com) by mail.gandi.net (Postfix) with ESMTPSA id 7CE0B240004; Fri, 28 Oct 2022 10:19:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1666952391; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=wizpYppE0f/9sVS2bK1K3AqfZzkmEX4Dlw8dVhSK0qc=; b=JTXQ1PO8srWUvlOzNw8O4Out8Uzqfczn/E/yaxtG26VjaD4UoUUF0iDO/4iC/EadYDa7+E J9FVXomVYKSocye1ttXTJLuLDi+xIpLlkaACJXNdsqqUrpsv+F8X98pFjSmiCuQx5j7c9b oTHUoMzjkcd1au31O3nw1WEKygmyfIxAsuQUDsr5oNxoVSJw7YP5TYjt1ZFC5kR1jJ9Q9x Fqk5JqRvHoX7FC6Ock3K2M34zNs6bawsYv1FRR0aOtpVZG0Ol4tO7UFQHmFH7C/inrr0eR YgMEusc29oGVXO9iQ4J+xkh+A5PziRu3jNyHU3rnapi0VLnKfTnUN8xatkP7Xw== From: michael.opdenacker@bootlin.com To: docs@lists.yoctoproject.org Cc: Michael Opdenacker Subject: [PATCH 5/5] ref-manual: terms.rst: add reference to new SBOM/SPDX section in dev manual Date: Fri, 28 Oct 2022 12:19:39 +0200 Message-Id: <20221028101939.93195-6-michael.opdenacker@bootlin.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221028101939.93195-1-michael.opdenacker@bootlin.com> References: <20221028101939.93195-1-michael.opdenacker@bootlin.com> MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Fri, 28 Oct 2022 10:19:55 -0000 X-Groupsio-URL: https://lists.yoctoproject.org/g/docs/message/3436 From: Michael Opdenacker Signed-off-by: Michael Opdenacker --- documentation/ref-manual/terms.rst | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/documentation/ref-manual/terms.rst b/documentation/ref-manual/terms.rst index 5aedd08aae..454f46b0b8 100644 --- a/documentation/ref-manual/terms.rst +++ b/documentation/ref-manual/terms.rst @@ -407,7 +407,9 @@ universal, the list includes them just in case: `__ and is used by the OpenEmbedded Build System to provide an :term:`SBOM` associated to each a software image. - For details, see Wikipedia's `SPDX page `__. + For details, see Wikipedia's `SPDX page `__ + and the ":ref:`dev-manual/common-tasks:creating a software bill of materials`" + section of the Development Tasks manual. :term:`Sysroot` When cross-compiling, the target file system may be differently laid