otaimage.py: Arrage script for pyro
1. msger is replaced to logging module in yocto upstream (pyro branch).
2. move oe/misc.py one level up in yocto upstream (pyro branch).
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
#
+import logging
import os
+import sys
-from wic import msger
from wic.pluginbase import SourcePlugin
-from wic.utils.oe.misc import get_bitbake_var
+from wic.utils.misc import get_bitbake_var
class OTAImagePlugin(SourcePlugin):
"""
@@ -57,12 +58,12 @@ class OTAImagePlugin(SourcePlugin):
"""
bootimg_dir = get_bitbake_var("DEPLOY_DIR_IMAGE")
if not bootimg_dir:
- msger.error("Couldn't find DEPLOY_DIR_IMAGE, exiting\n")
+ logger.error("Couldn't find DEPLOY_DIR_IMAGE, exiting\n")
- msger.debug('Bootimg dir: %s' % bootimg_dir)
+ logger.debug('Bootimg dir: %s' % bootimg_dir)
src = bootimg_dir + "/" + get_bitbake_var("IMAGE_LINK_NAME") + ".otaimg"
- msger.debug('Preparing partition using image %s' % (src))
+ logger.debug('Preparing partition using image %s' % (src))
part.prepare_rootfs_from_fs_image(cr_workdir, src, "")
