Message ID | 20231019214827.405886-1-bhstalel@gmail.com |
---|---|
State | New |
Headers | show |
Series | [1/3] ref-manual: variabls: Add RECIPE_SYSROOT and RECIPE_SYSROOT_NATIVE variables | expand |
Hi Talel, Thanks for this update! I still have a few comments. See below... On 19.10.23 at 23:48, BELHADJ SALEM Talel wrote: > Signed-off-by: Talel BELHAJSALEM <bhstalel@gmail.com> > --- > documentation/ref-manual/variables.rst | 36 +++++++++++++++++++++++++- > 1 file changed, 35 insertions(+), 1 deletion(-) > > diff --git a/documentation/ref-manual/variables.rst b/documentation/ref-manual/variables.rst > index 26a5aed82..22787f3b4 100644 > --- a/documentation/ref-manual/variables.rst > +++ b/documentation/ref-manual/variables.rst > @@ -6971,6 +6971,36 @@ system and gives an overview of their function and contents. > in the ":ref:`ref-manual/devtool-reference:checking on the upgrade status of a recipe`" > section. > > + :term:`RECIPE_SYSROOT` > + This variable points to the directory that holds all files populated from > + recipes specified in :term:`DEPENDS`. As the name indicates, > + think of this variable as a custom root ``/`` for the recipe that will be > + used by the compiler in order to find headers and other needs to complete > + its job. Oops, you forgot my previous comment: s/other needs/other files needed/ > + > + This variable is related to :term:`STAGING_DIR_HOST` or :term:`STAGING_DIR_TARGET` > + according to the type of the recipe and the build target. > + > + To understand more this variable, consider the following examples: s/more this variable/this variable bette/ > + > + - For ``#include <header.h>``, ``header.h`` should be in ``"${RECIPE_SYSROOT}/usr/include"`` > + > + - For ``-lexample``, ``libexample.so`` should be in ``"${RECIPE_SYSROOT}/lib"`` > + or other library sysroot directories. > + > + The default value is ``"${WORKDIR}/recipe-sysroot"``. > + Do not modify it. > + > + :term:`RECIPE_SYSROOT_NATIVE` > + This is similar to :term:`RECIPE_SYSROOT` but the populated files are from > + ``-native`` recipes. This allows a recipe built for the target machine to > + use ``native`` tools. > + > + This variable is related to :term:`STAGING_DIR_NATIVE`. > + > + The default value is ``"${WORKDIR}/recipe-sysroot-native"``. > + Do not modify it. > + > :term:`REPODIR` > See :term:`bitbake:REPODIR` in the BitBake manual. > > @@ -8242,7 +8272,8 @@ system and gives an overview of their function and contents. > the component is built to run (the system that hosts the component). > For most recipes, this sysroot is the one in which that recipe's > :ref:`ref-tasks-populate_sysroot` task copies > - files. Exceptions include ``-native`` recipes, where the > + files, check :term:`RECIPE_SYSROOT`. Aren't you missing a few words a few "where the files"? If you meant to say "the files check :term:`RECIPE_SYSROOT`", I don't understand. The rest looks good. Almost there :) Thanks Michael.
On 20.10.23 at 11:10, Michael Opdenacker via lists.yoctoproject.org wrote: > Hi Talel, > > Thanks for this update! > I still have a few comments. See below... Ah, also fix the typo in the commit title (s/variabls/variables/) and make it shorter: ref-manual: variables: add RECIPE_SYSROOT and RECIPE_SYSROOT_NATIVE Thanks Michael.
diff --git a/documentation/ref-manual/variables.rst b/documentation/ref-manual/variables.rst index 26a5aed82..22787f3b4 100644 --- a/documentation/ref-manual/variables.rst +++ b/documentation/ref-manual/variables.rst @@ -6971,6 +6971,36 @@ system and gives an overview of their function and contents. in the ":ref:`ref-manual/devtool-reference:checking on the upgrade status of a recipe`" section. + :term:`RECIPE_SYSROOT` + This variable points to the directory that holds all files populated from + recipes specified in :term:`DEPENDS`. As the name indicates, + think of this variable as a custom root ``/`` for the recipe that will be + used by the compiler in order to find headers and other needs to complete + its job. + + This variable is related to :term:`STAGING_DIR_HOST` or :term:`STAGING_DIR_TARGET` + according to the type of the recipe and the build target. + + To understand more this variable, consider the following examples: + + - For ``#include <header.h>``, ``header.h`` should be in ``"${RECIPE_SYSROOT}/usr/include"`` + + - For ``-lexample``, ``libexample.so`` should be in ``"${RECIPE_SYSROOT}/lib"`` + or other library sysroot directories. + + The default value is ``"${WORKDIR}/recipe-sysroot"``. + Do not modify it. + + :term:`RECIPE_SYSROOT_NATIVE` + This is similar to :term:`RECIPE_SYSROOT` but the populated files are from + ``-native`` recipes. This allows a recipe built for the target machine to + use ``native`` tools. + + This variable is related to :term:`STAGING_DIR_NATIVE`. + + The default value is ``"${WORKDIR}/recipe-sysroot-native"``. + Do not modify it. + :term:`REPODIR` See :term:`bitbake:REPODIR` in the BitBake manual. @@ -8242,7 +8272,8 @@ system and gives an overview of their function and contents. the component is built to run (the system that hosts the component). For most recipes, this sysroot is the one in which that recipe's :ref:`ref-tasks-populate_sysroot` task copies - files. Exceptions include ``-native`` recipes, where the + files, check :term:`RECIPE_SYSROOT`. + Exceptions include ``-native`` recipes, where the :ref:`ref-tasks-populate_sysroot` task instead uses :term:`STAGING_DIR_NATIVE`. Depending on the type of recipe and the build target, :term:`STAGING_DIR_HOST` can @@ -8279,6 +8310,9 @@ system and gives an overview of their function and contents. Specifies the path to the sysroot directory used when building components that run on the build host itself. + The default value is ``"${RECIPE_SYSROOT_NATIVE}"``, + check :term:`RECIPE_SYSROOT_NATIVE`. + :term:`STAGING_DIR_TARGET` Specifies the path to the sysroot used for the system for which the component generates code. For components that do not generate code,
Signed-off-by: Talel BELHAJSALEM <bhstalel@gmail.com> --- documentation/ref-manual/variables.rst | 36 +++++++++++++++++++++++++- 1 file changed, 35 insertions(+), 1 deletion(-)