Openembedded Core Discussions
 help / color / mirror / Atom feed
* [PATCH 0/2] devshell should make finding source and build artifacts easy
@ 2013-10-31  8:02 blloyd
  2013-10-31  8:02 ` [PATCH 1/2] Allow passthrough of important placement variables when using devshell blloyd
  2013-10-31  8:02 ` [PATCH 2/2] Removed trailing whitespace added with last commit blloyd
  0 siblings, 2 replies; 5+ messages in thread
From: blloyd @ 2013-10-31  8:02 UTC (permalink / raw)
  To: openembedded-core

Make finding sources and build artificts easy from a developer shell, while not affecting normal shells.
Also cleans up EOL issue from first attempt at patch.

The following changes since commit 523f2a9ea970713fb775bc48f84b67420b1106a0:

  cross-canadian: Improve comment (2013-10-30 18:01:34 +0000)

are available in the git repository at:

  git://git.yoctoproject.org/poky-contrib blloyd/devshell
  http://git.yoctoproject.org/cgit.cgi/poky-contrib/log/?h=blloyd/devshell

blloyd (2):
  Allow passthrough of important placement variables when using devshell
  Removed trailing whitespace added with last commit

 meta/classes/devshell.bbclass | 10 ++++++++++
 1 file changed, 10 insertions(+)

-- 
1.8.1.4



^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH 1/2] Allow passthrough of important placement variables when using devshell
  2013-10-31  8:02 [PATCH 0/2] devshell should make finding source and build artifacts easy blloyd
@ 2013-10-31  8:02 ` blloyd
  2013-11-01 11:04   ` Richard Purdie
  2013-11-01 11:04   ` Richard Purdie
  2013-10-31  8:02 ` [PATCH 2/2] Removed trailing whitespace added with last commit blloyd
  1 sibling, 2 replies; 5+ messages in thread
From: blloyd @ 2013-10-31  8:02 UTC (permalink / raw)
  To: openembedded-core

The environment is very well sanitized when using the shell.  However, when using devshell developers are typically interested in sources and build artifacts.  The variables B S and D control this but are cleaned from the environment when a shell is started.  Add a new variable to allow additional variables to be kept for a developer shell and set it to "B S D" by default.  The implementation allows variables for developer convenience and verification while not changing shells used for compile tasks.

Signed-off-by: blloyd <blloyd@familyhonor.net>
---
 meta/classes/devshell.bbclass | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/meta/classes/devshell.bbclass b/meta/classes/devshell.bbclass
index 92edb9e..cc1bb64 100644
--- a/meta/classes/devshell.bbclass
+++ b/meta/classes/devshell.bbclass
@@ -2,7 +2,17 @@ inherit terminal
 
 DEVSHELL = "${SHELL}"
 
+OE_DEVSHELL_TERMINAL_ADDL_EXPORTS ?= "B S D"
+OE_DEVSHELL_TERMINAL_ADDL_EXPORTS[type] = 'list'
+
 python do_devshell () {
+    import oe.data
+    import oe.terminal
+    export_dev=d.getVar('OE_DEVSHELL_TERMINAL_ADDL_EXPORTS') 
+    export_term=d.getVar('OE_TERMINAL_EXPORTS')
+    export_term = export_term + ' ' + export_dev
+    d.setVar('OE_TERMINAL_EXPORTS', export_term)
+
     if d.getVarFlag("do_devshell", "manualfakeroot"):
        d.prependVar("DEVSHELL", "pseudo ")
        fakeenv = d.getVar("FAKEROOTENV", True).split()
-- 
1.8.1.4



^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [PATCH 2/2] Removed trailing whitespace added with last commit
  2013-10-31  8:02 [PATCH 0/2] devshell should make finding source and build artifacts easy blloyd
  2013-10-31  8:02 ` [PATCH 1/2] Allow passthrough of important placement variables when using devshell blloyd
@ 2013-10-31  8:02 ` blloyd
  1 sibling, 0 replies; 5+ messages in thread
From: blloyd @ 2013-10-31  8:02 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: blloyd <blloyd@familyhonor.net>
---
 meta/classes/devshell.bbclass | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/classes/devshell.bbclass b/meta/classes/devshell.bbclass
index cc1bb64..552fa90 100644
--- a/meta/classes/devshell.bbclass
+++ b/meta/classes/devshell.bbclass
@@ -8,7 +8,7 @@ OE_DEVSHELL_TERMINAL_ADDL_EXPORTS[type] = 'list'
 python do_devshell () {
     import oe.data
     import oe.terminal
-    export_dev=d.getVar('OE_DEVSHELL_TERMINAL_ADDL_EXPORTS') 
+    export_dev=d.getVar('OE_DEVSHELL_TERMINAL_ADDL_EXPORTS')
     export_term=d.getVar('OE_TERMINAL_EXPORTS')
     export_term = export_term + ' ' + export_dev
     d.setVar('OE_TERMINAL_EXPORTS', export_term)
-- 
1.8.1.4



^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH 1/2] Allow passthrough of important placement variables when using devshell
  2013-10-31  8:02 ` [PATCH 1/2] Allow passthrough of important placement variables when using devshell blloyd
@ 2013-11-01 11:04   ` Richard Purdie
  2013-11-01 11:04   ` Richard Purdie
  1 sibling, 0 replies; 5+ messages in thread
From: Richard Purdie @ 2013-11-01 11:04 UTC (permalink / raw)
  To: blloyd; +Cc: openembedded-core

On Thu, 2013-10-31 at 03:02 -0500, blloyd wrote:
> The environment is very well sanitized when using the shell.  However, when using devshell developers are typically interested in sources and build artifacts.  The variables B S and D control this but are cleaned from the environment when a shell is started.  Add a new variable to allow additional variables to be kept for a developer shell and set it to "B S D" by default.  The implementation allows variables for developer convenience and verification while not changing shells used for compile tasks.
> 
> Signed-off-by: blloyd <blloyd@familyhonor.net>
> ---
>  meta/classes/devshell.bbclass | 10 ++++++++++
>  1 file changed, 10 insertions(+)
> 
> diff --git a/meta/classes/devshell.bbclass b/meta/classes/devshell.bbclass
> index 92edb9e..cc1bb64 100644
> --- a/meta/classes/devshell.bbclass
> +++ b/meta/classes/devshell.bbclass
> @@ -2,7 +2,17 @@ inherit terminal
>  
>  DEVSHELL = "${SHELL}"
>  
> +OE_DEVSHELL_TERMINAL_ADDL_EXPORTS ?= "B S D"
> +OE_DEVSHELL_TERMINAL_ADDL_EXPORTS[type] = 'list'

Can we call this something like DEVSHELL_EXTRA_ENVVARS which is a little
simpler?

>  python do_devshell () {
> +    import oe.data
> +    import oe.terminal

Why do we need to import these?

> +    export_dev=d.getVar('OE_DEVSHELL_TERMINAL_ADDL_EXPORTS') 

We should probably use ", True" here and expand since that is the common
behaviour. I'd also prefer " = " for consistent spacing.

> +    export_term=d.getVar('OE_TERMINAL_EXPORTS')

ditto spacing and ", True".

> +    export_term = export_term + ' ' + export_dev
> +    d.setVar('OE_TERMINAL_EXPORTS', export_term)
> +
>      if d.getVarFlag("do_devshell", "manualfakeroot"):
>         d.prependVar("DEVSHELL", "pseudo ")
>         fakeenv = d.getVar("FAKEROOTENV", True).split()

Cheers,

Richard



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH 1/2] Allow passthrough of important placement variables when using devshell
  2013-10-31  8:02 ` [PATCH 1/2] Allow passthrough of important placement variables when using devshell blloyd
  2013-11-01 11:04   ` Richard Purdie
@ 2013-11-01 11:04   ` Richard Purdie
  1 sibling, 0 replies; 5+ messages in thread
From: Richard Purdie @ 2013-11-01 11:04 UTC (permalink / raw)
  To: blloyd; +Cc: openembedded-core

On Thu, 2013-10-31 at 03:02 -0500, blloyd wrote:
> The environment is very well sanitized when using the shell.  However, when using devshell developers are typically interested in sources and build artifacts.  The variables B S and D control this but are cleaned from the environment when a shell is started.  Add a new variable to allow additional variables to be kept for a developer shell and set it to "B S D" by default.  The implementation allows variables for developer convenience and verification while not changing shells used for compile tasks.
> 
> Signed-off-by: blloyd <blloyd@familyhonor.net>
> ---
>  meta/classes/devshell.bbclass | 10 ++++++++++
>  1 file changed, 10 insertions(+)

Also, the summary of the commit message should start "devshell: " and
you should fold in the whitespace fix patch.

Cheers,

Richard



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2013-11-01 11:05 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-10-31  8:02 [PATCH 0/2] devshell should make finding source and build artifacts easy blloyd
2013-10-31  8:02 ` [PATCH 1/2] Allow passthrough of important placement variables when using devshell blloyd
2013-11-01 11:04   ` Richard Purdie
2013-11-01 11:04   ` Richard Purdie
2013-10-31  8:02 ` [PATCH 2/2] Removed trailing whitespace added with last commit blloyd

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox