Merge release-0.27.4 from 'tools/mic' accepted/tizen_3.0_common accepted/tizen_3.0_ivi accepted/tizen_3.0_mobile accepted/tizen_3.0_tv accepted/tizen_3.0_wearable accepted/tizen_4.0_unified accepted/tizen_5.0_unified accepted/tizen_5.5_unified_mobile_hotfix sandbox/soong9/0.27.4_upgrade tizen_3.0 tizen_4.0 tizen_4.0_tv tizen_5.0 tizen_5.5_mobile_hotfix accepted/tizen/3.0/common/20170630.141935 accepted/tizen/3.0/ivi/20170630.081242 accepted/tizen/3.0/mobile/20170630.081407 accepted/tizen/3.0/tv/20170630.081427 accepted/tizen/3.0/wearable/20170630.081227 accepted/tizen/4.0/unified/20170816.013304 accepted/tizen/4.0/unified/20170828.222729 accepted/tizen/5.0/unified/20181102.030014 accepted/tizen/5.5/unified/20191031.011055 accepted/tizen/5.5/unified/mobile/hotfix/20201027.073755 accepted/tizen/unified/20170629.085549 submit/tizen/20170602.051709 submit/tizen/20170619.064646 submit/tizen_3.0/20170602.051619 submit/tizen_3.0/20170619.080749 submit/tizen_4.0/20170811.094300 submit/tizen_4.0/20170828.100006 submit/tizen_5.0/20181101.000007 submit/tizen_5.5/20191031.000007 submit/tizen_5.5_mobile_hotfix/20201026.185107 tizen_4.0.IoT.p1_release tizen_4.0.IoT.p2_release tizen_4.0.m2_release tizen_5.5.m2_release upstream/0.27.4
authorSoonKyu Park <sk7.park@samsung.com>
Thu, 1 Jun 2017 10:39:16 +0000 (19:39 +0900)
committerSoonKyu Park <sk7.park@samsung.com>
Thu, 1 Jun 2017 10:39:16 +0000 (19:39 +0900)
Change-Id: I7f4d55c6c384bc520b2fbe2004affb9d27ed919f

ChangeLog
debian/changelog
doc/RELEASE_NOTES
mic/__init__.py
mic/imager/baseimager.py [changed mode: 0644->0755]
mic/kickstart/__init__.py [changed mode: 0644->0755]
mic/utils/misc.py
packaging/mic.changes
packaging/mic.spec

index 316d69b..7a3cfb8 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+Release 0.27.4 - Wed Apr 5 2017 - SoonKyu Park <sk7.park@samsung.com>
+=====================================================================
+  * Fixup changelog that causes errors
+  * Merge add mipsel register on binfmt_misc && Add support of qemu-mipsel patch
+  * Replace 'copy' to 'symbolic link' in timeznoe setting inside mic
+  * Copy ks setting lang to file /etc/config/mic_language for other use
+  * Show logs inside 'Running scripts' in mic
+
 Release 0.27.3 - Mon Dec 19 2016 - Jiankang Fan <jiankang.fan@samsung.com>
 =====================================================================
   * Support vdfs and squashfs image creation
index 2e290fc..6a35c66 100644 (file)
@@ -1,8 +1,17 @@
+mic (0.27.4) unstable; urgency=low
+  * Fixup changelog that causes errors
+  * Merge add mipsel register on binfmt_misc && Add support of qemu-mipsel patch
+  * Replace 'copy' to 'symbolic link' in timeznoe setting inside mic
+  * Copy ks setting lang to file /etc/config/mic_language for other use
+  * Show logs inside 'Running scripts' in mic
+
+ -- SoonKyu Park <sk7.park@samsung.com>  Wed, 5 Apr 2017 17:00:00 +0900
+
 mic (0.27.3) unstable; urgency=low
   * support vdfs and squashfs image creation
   * Show pkgid when install pkg error
 
- -- Jiankang Fan <jiankang.fan@samsung.com> Mon, 19 Dec 2016 15:00:00 +0800
+ -- Jiankang Fan <jiankang.fan@samsung.com>  Mon, 19 Dec 2016 15:00:00 +0800
 
 mic (0.27.2) unstable; urgency=low
   * Add exclude-from-image option to exclude specific images 
index c5a3c2b..4f0dd82 100644 (file)
@@ -1,3 +1,21 @@
+MIC Image Creator 0.27.4 Release Notes
+======================================
+Released Apr 5 2017
+
+This release note documents the changes included in the new release. And
+the release contains new features, enhancements and bug fixes.
+
+New Features & Enhancements
+--------------------------
+  * Fixup changelog that causes errors
+  * Merge add mipsel register on binfmt_misc && Add support of qemu-mipsel patch
+  * Replace 'copy' to 'symbolic link' in timeznoe setting inside mic
+  * Copy ks setting lang to file /etc/config/mic_language for other use
+  * Show logs inside 'Running scripts' in mic
+
+Bug Fixes
+---------
+
 MIC Image Creator 0.27.3 Release Notes
 ======================================
 Released Dec 19 2016
index 9951594..e91b81d 100644 (file)
@@ -16,7 +16,7 @@
 
 import os, sys
 
-__version__ = "0.27.3"
+__version__ = "0.27.4"
 
 cur_path = os.path.dirname(__file__) or '.'
 sys.path.insert(0, cur_path + '/3rdparty')
old mode 100644 (file)
new mode 100755 (executable)
index c905724..0812023
@@ -155,25 +155,45 @@ class BaseImageCreator(object):
             if len(self.ks.handler.partition.partitions) > 1:
                 self.multiple_partitions = True
 
-        if self.target_arch and self.target_arch.startswith("arm"):
-            for dep in self._dep_checks:
-                if dep == "extlinux":
-                    self._dep_checks.remove(dep)
-
-            if not os.path.exists("/usr/bin/qemu-arm") or \
-               not misc.is_statically_linked("/usr/bin/qemu-arm"):
-                self._dep_checks.append("qemu-arm-static")
-
-            if os.path.exists("/proc/sys/vm/vdso_enabled"):
-                vdso_fh = open("/proc/sys/vm/vdso_enabled","r")
-                vdso_value = vdso_fh.read().strip()
-                vdso_fh.close()
-                if (int)(vdso_value) == 1:
-                    msger.warning("vdso is enabled on your host, which might "
-                        "cause problems with arm emulations.\n"
-                        "\tYou can disable vdso with following command before "
-                        "starting image build:\n"
-                        "\techo 0 | sudo tee /proc/sys/vm/vdso_enabled")
+        if self.target_arch:
+            if self.target_arch.startswith("arm"):
+                for dep in self._dep_checks:
+                    if dep == "extlinux":
+                        self._dep_checks.remove(dep)
+
+                if not os.path.exists("/usr/bin/qemu-arm") or \
+                   not misc.is_statically_linked("/usr/bin/qemu-arm"):
+                    self._dep_checks.append("qemu-arm-static")
+
+                if os.path.exists("/proc/sys/vm/vdso_enabled"):
+                    vdso_fh = open("/proc/sys/vm/vdso_enabled","r")
+                    vdso_value = vdso_fh.read().strip()
+                    vdso_fh.close()
+                    if (int)(vdso_value) == 1:
+                        msger.warning("vdso is enabled on your host, which might "
+                            "cause problems with arm emulations.\n"
+                            "\tYou can disable vdso with following command before "
+                            "starting image build:\n"
+                            "\techo 0 | sudo tee /proc/sys/vm/vdso_enabled")
+            elif self.target_arch == "mipsel":
+                for dep in self._dep_checks:
+                    if dep == "extlinux":
+                        self._dep_checks.remove(dep)
+
+                if not os.path.exists("/usr/bin/qemu-mipsel") or \
+                   not misc.is_statically_linked("/usr/bin/qemu-mipsel"):
+                    self._dep_checks.append("qemu-mipsel-static")
+
+                if os.path.exists("/proc/sys/vm/vdso_enabled"):
+                    vdso_fh = open("/proc/sys/vm/vdso_enabled","r")
+                    vdso_value = vdso_fh.read().strip()
+                    vdso_fh.close()
+                    if (int)(vdso_value) == 1:
+                        msger.warning("vdso is enabled on your host, which might "
+                            "cause problems with mipsel emulations.\n"
+                            "\tYou can disable vdso with following command before "
+                            "starting image build:\n"
+                            "\techo 0 | sudo tee /proc/sys/vm/vdso_enabled")
 
         # make sure the specified tmpdir and cachedir exist
         if not os.path.exists(self.tmpdir):
@@ -1144,8 +1164,8 @@ class BaseImageCreator(object):
                                        env = env,
                                        stdout = subprocess.PIPE,
                                        stderr = subprocess.STDOUT)
-                    for entry in p.communicate()[0].splitlines():
-                        msger.info(entry)
+                    while p.poll() == None:
+                       msger.info(p.stdout.readline().strip())
                 except OSError, (err, msg):
                     raise CreatorError("Failed to execute %%post script "
                                        "with '%s' : %s" % (s.interp, msg))
old mode 100644 (file)
new mode 100755 (executable)
index a4b4f80..fb0e4d8
@@ -167,6 +167,12 @@ class LanguageConfig(KickstartConfig):
             f.write("LANG=\"" + kslang.lang + "\"\n")
             f.close()
 
+            #cp ks lang setting to other file, then can access the file in %post section
+            fs.makedirs(self.path("/etc/config"))
+            f = open(self.path("/etc/config/mic_language"), "w+")
+            f.write("LANG=\"" + kslang.lang + "\"\n")
+            f.close()
+
 class KeyboardConfig(KickstartConfig):
     """A class to apply a kickstart keyboard configuration to a system."""
     @apply_wrapper
@@ -197,12 +203,12 @@ class TimezoneConfig(KickstartConfig):
         tz_source = "/usr/share/zoneinfo/%s" % (tz)
         tz_dest = "/etc/localtime"
         try:
-            cpcmd = fs.find_binary_inchroot('cp', self.instroot)
+            cpcmd = fs.find_binary_inchroot('ln', self.instroot)
             if cpcmd:
-                self.call([cpcmd, "-f", tz_source, tz_dest])
+                self.call([cpcmd, "-s", tz_source, tz_dest])
             else:
-                cpcmd = fs.find_binary_path('cp')
-                subprocess.call([cpcmd, "-f",
+                cpcmd = fs.find_binary_path('ln')
+                subprocess.call([cpcmd, "-s",
                                  self.path(tz_source),
                                  self.path(tz_dest)])
         except (IOError, OSError), (errno, msg):
index 1e337d9..f7693b2 100755 (executable)
@@ -908,6 +908,13 @@ def setup_qemu_emulator(rootdir, arch):
             arm_binary = "qemu-aarch64-static"
         else:
             raise CreatorError("Please install a statically-linked %s" % arm_binary)
+    elif arch == "mipsel":
+        node = "/proc/sys/fs/binfmt_misc/mipsel"
+        arm_binary = "qemu-mipsel"
+        if not os.path.exists("/usr/bin/%s" % arm_binary) or not is_statically_linked("/usr/bin/%s"):
+            arm_binary = "qemu-mipsel-static"
+        if not os.path.exists("/usr/bin/%s" % arm_binary):
+            raise CreatorError("Please install a statically-linked %s" % arm_binary)
     else:
         node = "/proc/sys/fs/binfmt_misc/arm"
         arm_binary = "qemu-arm"
@@ -937,6 +944,8 @@ def setup_qemu_emulator(rootdir, arch):
     if not os.path.exists(node):
         if arch == "aarch64":
             qemu_arm_string = ":aarch64:M::\\x7fELF\\x02\\x01\\x01\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x02\\x00\\xb7:\\xff\\xff\\xff\\xff\\xff\\xff\\xff\\x00\\xff\\xff\\xff\\xff\\xff\\xff\\xff\\xff\\xfe\\xff\\xff:%s:\n" % qemu_emulator
+        elif arch == "mipsel":
+            qemu_arm_string = ":mipsel:M::\\x7fELF\\x01\\x01\\x01\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x02\\x00\\x08\\x00:\\xff\\xff\\xff\\xff\\xff\\xff\\xff\\x00\\xfe\\xff\\xff\\xff\\xff\\xff\\xff\\xff\\xfe\\xff\\xff\\xff:%s:\n" % qemu_emulator
         else:
             qemu_arm_string = ":arm:M::\\x7fELF\\x01\\x01\\x01\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x02\\x00\\x28\\x00:\\xff\\xff\\xff\\xff\\xff\\xff\\xff\\x00\\xff\\xff\\xff\\xff\\xff\\xff\\xff\\xff\\xfa\\xff\\xff\\xff:%s:\n" % qemu_emulator
         with open("/proc/sys/fs/binfmt_misc/register", "w") as fd:
index ef79851..935ed3a 100644 (file)
@@ -1,3 +1,10 @@
+* Wed Apr 5 2017 SoonKyu Park <sk7.park@samsung.com> - 0.27.4
+  * Fixup changelog that causes errors
+  * Merge add mipsel register on binfmt_misc && Add support of qemu-mipsel patch
+  * Replace 'copy' to 'symbolic link' in timeznoe setting inside mic
+  * Copy ks setting lang to file /etc/config/mic_language for other use
+  * Show logs inside 'Running scripts' in mic
+
 * Mon Dec 19 2016 Jiankang Fan <jiankang.fan@samsung.com> - 0.27.3
   * Show pkgid when install pkg error
   * support vdfs and squashfs image creation
index eb52974..d78e67b 100644 (file)
@@ -9,7 +9,7 @@
 
 Name:       mic
 Summary:    Image Creator for Linux Distributions
-Version:    0.27.3
+Version:    0.27.4
 Release:    0
 Group:      Development/Tools
 License:    GPLv2