summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Olbrich <m.olbrich@pengutronix.de>2012-07-09 11:21:11 +0200
committerMichael Olbrich <m.olbrich@pengutronix.de>2012-07-09 11:21:13 +0200
commitde4a81b59c3e6df447919553d7c689894798a482 (patch)
treea195e114a2034ae6361c840ae392ee7df98a8484
parenta602b694305e4d3cb9e2f34e2cd7a66732866429 (diff)
downloadptxdist-de4a81b59c3e6df447919553d7c689894798a482.tar.gz
ptxdist-de4a81b59c3e6df447919553d7c689894798a482.tar.xz
barebox: add option to install target 'bareboxenv'
Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
-rw-r--r--platforms/barebox.in8
-rw-r--r--rules/barebox.make13
2 files changed, 21 insertions, 0 deletions
diff --git a/platforms/barebox.in b/platforms/barebox.in
index 702828f81..a98fddf74 100644
--- a/platforms/barebox.in
+++ b/platforms/barebox.in
@@ -51,4 +51,12 @@ config BAREBOX_EXTRA_ENV_PATH
default "${PTXDIST_PLATFORMCONFIGDIR}/barebox-defaultenv"
depends on BAREBOX_EXTRA_ENV
+config BAREBOX_BAREBOXENV
+ prompt "install 'bareboxenv'"
+ bool
+ help
+ The tool 'bareboxenv' can be used to manipulate the barebox
+ environment. Enable this option access the barebox environment
+ from the target Linux system.
+
endif
diff --git a/rules/barebox.make b/rules/barebox.make
index a866e3c68..67fe32cab 100644
--- a/rules/barebox.make
+++ b/rules/barebox.make
@@ -116,6 +116,19 @@ endif
$(STATEDIR)/barebox.targetinstall:
@$(call targetinfo)
+
+ifdef PTXCONF_BAREBOX_BAREBOXENV
+ @$(call install_init, barebox)
+ @$(call install_fixup, barebox,PRIORITY,optional)
+ @$(call install_fixup, barebox,SECTION,base)
+ @$(call install_fixup, barebox,AUTHOR,"Robert Schwebel <r.schwebel@pengutronix.de>")
+ @$(call install_fixup, barebox,DESCRIPTION,missing)
+
+ @$(call install_copy, barebox, 0, 0, 0755, $(BAREBOX_DIR)/scripts/bareboxenv-target, \
+ /usr/bin/bareboxenv)
+
+ @$(call install_finish, barebox)
+endif
@install -D -m644 $(BAREBOX_DIR)/barebox.bin $(IMAGEDIR)/barebox-image
@install -D -m644 $(BAREBOX_DIR)/barebox_default_env $(IMAGEDIR)/barebox-default-environment
@$(call touch)