summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEd Bartosh <ed.bartosh@linux.intel.com>2015-03-16 12:57:55 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-03-20 11:03:45 +0000
commit35fbb0f470fb9a6eac5cad7c82cb77cc372ba4b4 (patch)
treea42de9b0b128289f2d553d09aef6969f1d31217c
parent40d3d7a23aab2af3bbf82e8a865cc480169f31e7 (diff)
downloadpoky-35fbb0f470fb9a6eac5cad7c82cb77cc372ba4b4.tar.gz
wic: Consider PSEUDO_* environment variables
Used default values of PSEUDO_* environment variables only if variables are not set. This allows to set custom PSEUDO_PREFIX and other pseudo variables in order to use pseudo database from non-standard locations. Change-Id: I0bc1af5e521121d1f96d590cb6edb23cf0cb0b83 (From OE-Core rev: cd121c06e9de8951d507998be443f95f0edc246a) Signed-off-by: Ed Bartosh <eduard.bartosh@intel.com> Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--scripts/lib/wic/kickstart/custom_commands/partition.py13
1 files changed, 9 insertions, 4 deletions
diff --git a/scripts/lib/wic/kickstart/custom_commands/partition.py b/scripts/lib/wic/kickstart/custom_commands/partition.py
index 4f5a1e5ce4..f3d553b885 100644
--- a/scripts/lib/wic/kickstart/custom_commands/partition.py
+++ b/scripts/lib/wic/kickstart/custom_commands/partition.py
@@ -193,10 +193,15 @@ class Wic_PartData(Mic_PartData):
193 193
194 Currently handles ext2/3/4, btrfs and vfat. 194 Currently handles ext2/3/4, btrfs and vfat.
195 """ 195 """
196 pseudo = "export PSEUDO_PREFIX=%s/usr;" % native_sysroot 196 p_prefix = os.environ.get("PSEUDO_PREFIX", "%s/usr" % native_sysroot)
197 pseudo += "export PSEUDO_LOCALSTATEDIR=%s/../pseudo;" % rootfs_dir 197 p_localstatedir = os.environ.get("PSEUDO_LOCALSTATEDIR",
198 pseudo += "export PSEUDO_PASSWD=%s;" % rootfs_dir 198 "%s/../pseudo" % rootfs_dir)
199 pseudo += "export PSEUDO_NOSYMLINKEXP=1;" 199 p_passwd = os.environ.get("PSEUDO_PASSWD", rootfs_dir)
200 p_nosymlinkexp = os.environ.get("PSEUDO_NOSYMLINKEXP", "1")
201 pseudo = "export PSEUDO_PREFIX=%s;" % p_prefix
202 pseudo += "export PSEUDO_LOCALSTATEDIR=%s;" % p_localstatedir
203 pseudo += "export PSEUDO_PASSWD=%s;" % p_passwd
204 pseudo += "export PSEUDO_NOSYMLINKEXP=%s;" % p_nosymlinkexp
200 pseudo += "%s/usr/bin/pseudo " % native_sysroot 205 pseudo += "%s/usr/bin/pseudo " % native_sysroot
201 206
202 if self.fstype.startswith("ext"): 207 if self.fstype.startswith("ext"):