[oe-commits] Martin Jansa : rootfs.py: Allow to override postinst-intercepts location

git at git.openembedded.org git at git.openembedded.org
Sat Sep 19 08:53:12 UTC 2015


Module: openembedded-core.git
Branch: fido
Commit: 0f528bda0bac76e190b03764c603f199a6079fc6
URL:    http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=0f528bda0bac76e190b03764c603f199a6079fc6

Author: Martin Jansa <martin.jansa at gmail.com>
Date:   Fri Sep  4 14:22:26 2015 +0200

rootfs.py: Allow to override postinst-intercepts location

* useful when we need to overlay/extend intercept scripts from oe-core

(From OE-Core master rev: 7d08d2d5c0ae686e3bb8732ea82f30fd189b1cd8)

Signed-off-by: Martin Jansa <Martin.Jansa at gmail.com>
Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>

---

 meta/lib/oe/rootfs.py | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/meta/lib/oe/rootfs.py b/meta/lib/oe/rootfs.py
index e86480c..d2de2c6 100644
--- a/meta/lib/oe/rootfs.py
+++ b/meta/lib/oe/rootfs.py
@@ -114,6 +114,9 @@ class Rootfs(object):
         pre_process_cmds = self.d.getVar("ROOTFS_PREPROCESS_COMMAND", True)
         post_process_cmds = self.d.getVar("ROOTFS_POSTPROCESS_COMMAND", True)
 
+        postinst_intercepts_dir = self.d.getVar("POSTINST_INTERCEPTS_DIR", True)
+        if not postinst_intercepts_dir:
+            postinst_intercepts_dir = self.d.expand("${COREBASE}/scripts/postinst-intercepts")
         intercepts_dir = os.path.join(self.d.getVar('WORKDIR', True),
                                       "intercept_scripts")
 
@@ -123,8 +126,7 @@ class Rootfs(object):
 
         bb.utils.mkdirhier(self.deploy_dir_image)
 
-        shutil.copytree(self.d.expand("${COREBASE}/scripts/postinst-intercepts"),
-                        intercepts_dir)
+        shutil.copytree(postinst_intercepts_dir, intercepts_dir)
 
         shutil.copy(self.d.expand("${COREBASE}/meta/files/deploydir_readme.txt"),
                     self.deploy_dir_image +



More information about the Openembedded-commits mailing list