Bug 10002 - Suggested glossary entries for PATH and EXTRANATIVEPATH
Summary: Suggested glossary entries for PATH and EXTRANATIVEPATH
Status: RESOLVED FIXED
Alias: None
Product: Reference
Classification: Documentation
Component: handbook (show other bugs)
Version: 2.2
Hardware: x86 Multiple
: Medium normal
Target Milestone: 2.2 M3
Assignee: Paul Eggleton
QA Contact:
URL:
Whiteboard: 01 August 2016: RESOLVED
Depends on:
Blocks:
 
Reported: 2016-07-22 12:56 UTC by ulfalizer
Modified: 2016-08-01 18:58 UTC (History)
5 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: Done (doc changes complete)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description ulfalizer 2016-07-22 12:56:48 UTC
This would make it a bit more transparent how the path handling works. Here's the proposed definitions:

  PATH: This variable is exported to the environment of all tasks, where it
  serves the usual purpose of the PATH environment variable. See bitbake.conf for
  a list of paths that are guaranteed to appear in PATH.
  

  EXTRANATIVEPATH: A list of subdirectories of ${STAGING_BINDIR_NATIVE} that are
  added to the beginning of [PATH]. As an example, the following prepends
  "${STAGING_BINDIR_NATIVE}/foo:${STAGING_BINDIR_NATIVE}/bar:" to PATH:
  
    EXTRANATIVEPATH = "foo bar"

Cheers,
Ulf
Comment 1 Scott Rifenbark 2016-07-22 15:25:34 UTC
Adding Paul Eggleton to the CC list.  In the past, we had made the decision to not include environment variables as part of the variables glossary.  However, the issue of making these types of variables more transparent on how YP uses them is a point.  

Is the variable EXTRANATIVEPATH an environment variable or is that unique to YP?

Scott
Comment 2 ulfalizer 2016-07-22 16:20:25 UTC
(In reply to comment #1)
> Adding Paul Eggleton to the CC list.  In the past, we had made the decision
> to not include environment variables as part of the variables glossary. 
> However, the issue of making these types of variables more transparent on
> how YP uses them is a point.  

Yeah, wouldn't hurt to have some more coverage for how Yocto deals with the environment, IMO. I think many people wanting to know how Yocto handles the path would look up PATH in the glossary thinking there might be a Yocto variable for it. When reading the definition, they would indirectly learn that variables can be exported to the environment.
 
> Is the variable EXTRANATIVEPATH an environment variable or is that unique to
> YP?

It's unique to YP. base.bbclass prepends PATH with the extra directories from EXTRANATIVEPATH.
Comment 3 Scott Rifenbark 2016-07-29 22:15:46 UTC
Paul, 

Can I get a raw description of the EXTRANATIVEPATH variable from you?

Based on Ulf's statement I have this:

  "EXTRANATIVEPATH:
     Provides extra directories, which are pre-pended to the environment 
     variable PATH.  The OpenEmbedded build system uses EXTRANATIVEPATH to be 
     sure to include these paths when searching for metadata."

That is pretty basic.

Thanks,
Scott
Comment 4 ulfalizer 2016-07-30 19:35:16 UTC
Note (In reply to comment #3)
> Paul, 
> 
> Can I get a raw description of the EXTRANATIVEPATH variable from you?
> 
> Based on Ulf's statement I have this:
> 
>   "EXTRANATIVEPATH:
>      Provides extra directories, which are pre-pended to the environment 
>      variable PATH.  The OpenEmbedded build system uses EXTRANATIVEPATH to
> be 
>      sure to include these paths when searching for metadata."
> 
> That is pretty basic.
> 
> Thanks,
> Scott

Note that EXTRANATIVEPATH does not contain full paths though. The entries in it are relative to ${STAGING_BINDIR_NATIVE}. I don't think it's used to search for metadata either, but just for setting the right PATH while tasks run.

I included a description for EXTRANATIVEPATH above btw, in case you only saw the PATH one.

Cheers,
Ulf
Comment 5 Scott Rifenbark 2016-08-01 18:40:43 UTC
Ulf, 

I didn't see that definition... sorry.  See http://www.yoctoproject.org/docs/2.2/ref-manual/ref-manual.html#var-EXTRANATIVEPATH for the new entry.  

Thanks,
Scott
Comment 6 ulfalizer 2016-08-01 18:56:49 UTC
Looks good to me.

Thanks,
Ulf
Comment 7 Scott Rifenbark 2016-08-01 18:58:52 UTC
Resetting to RESOLVED and "done."


Thanks