This email list is read-only.  Emails sent to this list will be discarded
----------------------------------
 README                      |    2 +-
 debian/changelog            |   10 +-
 default_config/defaults.cfg |   95 +--
 gui/gui.py                  |   57 ++-
 gui/image-creator.glade     | 1385 ++++++++++++++++++++++++++++++++++++-------
 libs/InstallImage.py        |   28 +-
 libs/Platform.py            |   14 +-
 libs/Project.py             |   93 +---
 moblin-image-creator.spec   |    7 +
 9 files changed, 1293 insertions(+), 398 deletions(-)

New commits:
commit 33af6356abc745e74a0ecb44152d68940bad0b72
Author: Mitsutaka Amano <[EMAIL PROTECTED]>
Date:   Thu Oct 2 10:32:18 2008 +0900

    Updated debian/changelog and rpm spec file.

commit 905286fbbad6614ddb77cb27c5b4e7e48fa7f931
Merge: 0ae5927b6b090916cada9a42bffe7e4b2f9c4fd2 
04388d68dff9b9d86c107c6abd7fd082358c9fed
Author: Mitsutaka Amano <[EMAIL PROTECTED]>
Date:   Thu Oct 2 10:23:58 2008 +0900

    Merge commit 'moblin/master'
    
    Conflicts:
    
        debian/changelog
        gui/image-creator.glade

commit 04388d68dff9b9d86c107c6abd7fd082358c9fed
Author: Mitsutaka Amano <[EMAIL PROTECTED]>
Date:   Wed Oct 1 17:05:35 2008 +0900

    * Added the Target config function.

commit 23426213381809f72d3778231111ccde5b8c15f9
Merge: 1905e62002d86b8914edc95acf08356de938ab50 
def98e579a692667763eb7c81600dbb85bbf3b95
Author: Mitsutaka Amano <[EMAIL PROTECTED]>
Date:   Wed Oct 1 17:11:51 2008 +0900

    Merge branch 'master' of ssh://[EMAIL 
PROTECTED]/home/repos/tools/moblin-image-creator
    
    Conflicts:
    
        README
        debian/changelog

commit 1905e62002d86b8914edc95acf08356de938ab50
Author: Mitsutaka Amano <[EMAIL PROTECTED]>
Date:   Fri Sep 12 10:06:09 2008 +0900

    * Follow someone changelog. Updated the README.


Diff in this email is a maximum of 400 lines.
diff --git a/README b/README
index 7829cff..1fe19bf 100644
--- a/README
+++ b/README
@@ -31,7 +31,7 @@ Installation
 ------------
 
 It needs below packages that install Image-Creator.
-autoconf, automake, intltool, gettext-devel(only Fedora)
+autoconf, automake, intltool, gettext-devel(only fedora)
 
 $ ./autogen.sh
 $ ./configure
diff --git a/debian/changelog b/debian/changelog
index 9556af8..779f035 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -32,9 +32,13 @@ moblin-image-creator (0.46) UNRELEASED; urgency=low
   * Fixed rpm spec file for initial installation.
 
   [ Prajwal Mohan ]
-  * Adding feature to install package groups 
+  * Adding feature to install package groups
 
- -- Prajwal Mohan <[EMAIL PROTECTED]>  Wed, 01 Oct 2008 16:16:21 -0700
+  [ Mitsutaka Amano ]
+  * Added the Target config function.
+  * Updated debian/changelog and rpm spec file. 
+
+ -- Mitsutaka Amano <[EMAIL PROTECTED]>  Thu, 02 Oct 2008 10:28:00 +0900
 
 moblin-image-creator (0.45) gaston; urgency=low
 
@@ -220,7 +224,7 @@ moblin-image-creator (0.45) gaston; urgency=low
     xorg-x11-drv-i810
   * Adding post install scripts to netbook platform
 
- -- Mitsutaka Amano <[EMAIL PROTECTED]>  Wed, 17 Sep 2008 10:15:27 +0900
+ -- Mitsutaka Amano <[EMAIL PROTECTED]>  Wed, 01 Oct 2008 17:03:17 +0900
 
 moblin-image-creator (0.44) gaston; urgency=low
 
diff --git a/default_config/defaults.cfg b/default_config/defaults.cfg
index a6db587..0a860c2 100644
--- a/default_config/defaults.cfg
+++ b/default_config/defaults.cfg
@@ -45,21 +45,34 @@ buildroot_extras = squashfs-tools dosfstools syslinux 
module-init-tools mtools g
 # What packages need to be installed in the buildroot (outside the rootstrap 
archive)
 buildroot_packages = initramfs-tools debhelper devscripts liburi-perl 
kernel-package dpatch grub libncursesw5-dev libncurses5-dev man less vim 
apt-utils libgtk2.0-dev ssh automake autotools-dev build-essential 
gtk-doc-tools dh-make hildon-desktop libhildon-1-dev libhildonfm2-dev 
hildon-desktop-dev
 
-# Options for the kernel that will be booted from the hard drive on the device
-hd_kernel_cmdline = ro boot=disk resume=/dev/sda3
+# Target configurations
+target_configs = usb_kernel_cmdline usb_ext3fs_size hd_kernel_cmdline 
hd_swap_option hd_use_squashfs hd_swap_partition_size hd_boot_partition_size 
hd_fat32_partition_size cd_kernel_cmdline nand_kernel_cmdline nand_image_size
 
-# Options for the kernel that will be booted from the USB flash drive
+# Options for USB flash drive
 usb_kernel_cmdline = initrd=initrd.img boot=usb 
+usb_ext3fs_size = 100
+
+# Options for the hard drive on the device
+hd_kernel_cmdline = ro boot=disk resume=/dev/sda3
+hd_swap_option = 2 
+hd_use_squashfs = 1
+hd_swap_partition_size = 1024
+hd_boot_partition_size = 1024
+hd_fat32_partition_size = 0
 
-# Options for the kernel that will be booted from the CD drive
+# Options for the CD drive
 cd_kernel_cmdline = initrd=initrd.img boot=cd
 
-# Options for the kernel that will be booted from NAND
+# Options for the NAND
 nand_kernel_cmdline = ro no-hlt boot=nand single console=ttyMS0 
earlyprintk=serial apic=debug idle=poll loglevel=8
+nand_image_size = 512
+
+welcome_message = Welcome to Moblin:
 
 # Architecture to use for creating the rootstraps
 architecture=lpia
 
+
 # ********** Ubuntu Platforms **********
 
 # ********** Special stuff unique to McCaslin ********** 
@@ -95,19 +108,23 @@ buildroot_codename = hardy
 # ********** Special stuff unique to Menlow ********** 
 [platform.menlow-lpia]
 hd_kernel_cmdline = ro boot=disk resume=/dev/sda3 ht=on
+hd_fat32_partition_size = 4096
 
 [platform.menlow-lpia-ubuntu-gutsy-ppa]
 hd_kernel_cmdline = ro boot=disk resume=/dev/sda3 ht=on
+hd_fat32_partition_size = 4096
 
 [platform.menlow-lpia-ubuntu-hardy]
 # codename to use for platform rootstrap configuration
 hd_kernel_cmdline = ro boot=disk resume=/dev/sda3 ht=on
 buildroot_codename = hardy
+hd_fat32_partition_size = 4096
 
 [platform.menlow-lpia-ubuntu-hardy-ppa]
 # codename to use for platform rootstrap configuration
 hd_kernel_cmdline = ro boot=disk resume=/dev/sda3 ht=on
 buildroot_codename = hardy
+hd_fat32_partition_size = 4096
 
 [platform.menlow-lpia-ubuntu-hardy-ppa-snapshot]
 # codename to use for platform rootstrap configuration
@@ -115,15 +132,20 @@ hd_kernel_cmdline = ro boot=disk resume=/dev/sda3 ht=on
 buildroot_codename = hardy
 # Going to use the snapshot for the PPA platform
 buildroot_mirror = http://snapshot.ubuntu.com/lpia/snapshot/2008-02-27/ports/
+hd_fat32_partition_size = 4096
 
 [platform.menlow-lpia-ume]
 hd_kernel_cmdline = ro boot=disk resume=/dev/sda3 ht=on
 buildroot_codename = hardy
+hd_fat32_partition_size = 4096
 
 [platform.menlow-lpia-ubuntu-hardy-jax10-snapshot1]
 # codename to use for platform rootstrap configuration
 hd_kernel_cmdline = ro boot=disk resume=/dev/sda3 ht=on
 buildroot_codename = hardy
+use_squashfs = 1
+boot_partition_size = 768
+swap_partition_size = 512
 
 # ********** Fedora Platforms **********
 [platform.mccaslin-lpia-fedora]
@@ -141,10 +163,14 @@ buildroot_extras = squashfs-tools dosfstools syslinux 
module-init-tools mtools b
 # What packages need to be installed in the buildroot (outside the rootstrap 
archive)
 #buildroot_packages = grub man less vim automake autotools-dev openssh-clients
 buildroot_packages=
+boot_partition_size = 250
 
 [platform.menlow-lpia-moblin2]
 # What additional packages need to be installed in the buildroot roostrap
 buildroot_extras = squashfs-tools dosfstools syslinux module-init-tools mtools 
busybox setup
+use_squashfs = 1
+boot_partition_size = 768
+swap_partition_size = 512
 
 # What packages need to be installed in the buildroot (outside the rootstrap 
archive)
 #buildroot_packages = grub man less vim automake autotools-dev openssh-clients
@@ -154,65 +180,6 @@ buildroot_packages =
 [installimage]
 welcome_message = Welcome to Moblin:
 
-# How big, in megabytes, to make the nand flash image
-nand_image_size = 512
-
-# How big, in megabytes, to make the ext3 File System on the Live Read/Write
-# USB image
-ext3fs_size = 100
-
-# How big, in megabytes, to make the boot partition for HD installation image
-boot_partition_size = 1024
-
-# Options for swap partition: 0 = No swap, 1 = swap file created (but not
-# enabled because it is NOT put into /etc/fstab) this could be useful for
-# hibernation,  2 = swap on (swap file created and put into /etc/fstab)
-swap_option = 2
-
-# How big, in megabytes, to make the swap partition for HD installation image
-# Only meaningful when swap_option != 0, if swap_option == 0, then
-# swap_partition_size will be forced to 0.
-swap_partition_size = 1024
-
-# How big, in megabytes, to make the FAT32 partition for HD installation image
-fat32_partition_size = 0
-
-# Use squashfs, 1 = use squashfs, 0 = do NOT use squashfs on the target disk.
-use_squashfs = 0
-
-# ********** Special stuff unique to Menlow **********
-# Only Menlow has USBC and need fat32 partition for media sync usage
-[installimage.menlow-lpia]
-fat32_partition_size = 4096
-
-[installimage.menlow-lpia-ubuntu-gutsy-ppa]
-fat32_partition_size = 4096
-
-[installimage.menlow-lpia-ubuntu-hardy]
-fat32_partition_size = 4096
-
-[installimage.menlow-lpia-ubuntu-hardy-ppa]
-fat32_partition_size = 4096
-
-[installimage.menlow-lpia-ubuntu-hardy-ppa-snapshot]
-fat32_partition_size = 4096
-
-[installimage.menlow-lpia-ume]
-fat32_partition_size = 4096
-
-[installimage.menlow-lpia-ubuntu-hardy-jax10-snapshot1]
-use_squashfs = 1
-boot_partition_size = 768
-swap_partition_size = 512
-
-[installimage.menlow-lpia-moblin2]
-use_squashfs = 1
-boot_partition_size = 768
-swap_partition_size = 512
-
-[installimage.netbook-lpia-moblin2]
-boot_partition_size = 250
-
 # Distribution information
 # ubuntu = debian
 [distribution.debian]
diff --git a/gui/gui.py b/gui/gui.py
index aa8c68e..0d97218 100644
--- a/gui/gui.py
+++ b/gui/gui.py
@@ -28,6 +28,7 @@ import sys
 import time
 import traceback
 import signal
+import Platform
 from threading import Thread
 
 import pdk_utils
@@ -93,7 +94,7 @@ class App(object):
                 "on_about_activate": self.on_about_activate,
                 "on_term_launch_clicked": self.on_term_launch_clicked,
                 "on_target_term_launch_clicked": 
self.on_target_term_launch_clicked,
-                "on_target_kernel_cmdline_clicked": 
self.on_target_kernel_cmdline_clicked,
+                "on_target_config_clicked": self.on_target_config_clicked,
                 "on_Write_USB_clicked": self.writeUsbImage,
                 "on_launch_vm_btn_clicked": self.on_launch_vm_clicked, 
                 "on_WriteUsbImage_activate":self.on_WriteUsbImage_activate,
@@ -144,7 +145,6 @@ class App(object):
         #main_window.set_size_request(900, 600)
 
         self.newFeatureDialog()        
-
         obsolete_projects = self.sdk.return_obsolete_projects()
         if obsolete_projects:         
             error_message = ""
@@ -236,7 +236,7 @@ class App(object):
         self.buttons.create_liveusb.set_sensitive(fset_state)
         self.buttons.create_liverwusb.set_sensitive(fset_state)
         self.buttons.create_installusb.set_sensitive(fset_state)
-        self.buttons.target_kernel_cmdline.set_sensitive(fset_state)
+        self.buttons.target_config.set_sensitive(fset_state)
         self.buttons.create_liveCD.set_sensitive(fset_state)
         self.buttons.create_NAND.set_sensitive(fset_state)
         self.buttons.Write_USB.set_sensitive(fset_state)
@@ -842,26 +842,43 @@ class App(object):
             cmd = '/usr/bin/xterm -e /usr/sbin/chroot %s env -u SHELL 
HOME=/root sh &' % (project_path)
             os.system(cmd)
 
-    def on_target_kernel_cmdline_clicked(self, widget):
+    def on_target_config_clicked(self, widget):
         project_path = self.current_project().path
         target = self.current_target()
-        target_path= "%s/targets/%s/image" % (project_path, target.name)
-        widgets = gtk.glade.XML(self.gladefile, 'kernel_cmdline_dlg')
-        dialog = widgets.get_widget('kernel_cmdline_dlg')
-        usb_kernel_cmdline = widgets.get_widget('usb_kernel_cmdline')
-        hd_kernel_cmdline = widgets.get_widget('hd_kernel_cmdline')
-        cd_kernel_cmdline = widgets.get_widget('cd_kernel_cmdline')
-        nand_kernel_cmdline = widgets.get_widget('nand_kernel_cmdline')
-        
usb_kernel_cmdline.set_text(self.current_project().get_target_usb_kernel_cmdline(target.name))
-        
hd_kernel_cmdline.set_text(self.current_project().get_target_hd_kernel_cmdline(target.name))
-        
cd_kernel_cmdline.set_text(self.current_project().get_target_cd_kernel_cmdline(target.name))
-        
nand_kernel_cmdline.set_text(self.current_project().get_target_nand_kernel_cmdline(target.name))
+        widgets = gtk.glade.XML(self.gladefile, 'target_config_dlg')
+        dialog = widgets.get_widget('target_config_dlg')
+        current_target = {}
+        for config in self.current_project().platform.target_configs:
+            current_target[config] = widgets.get_widget(config)
+            config_value = 
self.current_project().get_target_config(target.name, config)
+            if not config_value:
+                print _("%s: Using default parametor.") % config
+                config_value = 
self.current_project().platform.target_configs[config]
+            if isinstance(current_target[config], gtk.Entry) or \
+                isinstance(current_target[config], gtk.SpinButton):
+                current_target[config].set_text(config_value)
+            elif isinstance(current_target[config], gtk.CheckButton) or \
+                isinstance(current_target[config], gtk.ComboBox):
+                current_target[config].set_active(int(config_value))
+            else:
+                try:
+                    current_target[config].set_text(config_value)
+                except:
+                    pass
         result = dialog.run()
         if result == gtk.RESPONSE_OK:
-            self.current_project().set_target_usb_kernel_cmdline(target.name, 
usb_kernel_cmdline.get_text())
-            self.current_project().set_target_hd_kernel_cmdline(target.name, 
hd_kernel_cmdline.get_text())
-            self.current_project().set_target_cd_kernel_cmdline(target.name, 
cd_kernel_cmdline.get_text())
-            self.current_project().set_target_nand_kernel_cmdline(target.name, 
nand_kernel_cmdline.get_text())
+            for config in self.current_project().platform.target_configs:
+                if isinstance(current_target[config], gtk.Entry) or \
+                    isinstance(current_target[config], gtk.SpinButton):
+                    self.current_project().set_target_config(target.name, 
config, current_target[config].get_text())
+                elif isinstance(current_target[config], gtk.CheckButton) or \
+                    isinstance(current_target[config], gtk.ComboBox):
+                    self.current_project().set_target_config(target.name, 
config, int(current_target[config].get_active()))
+                else:
+                    try:
+                        self.current_project().set_target_config(target.name, 
config, current_target[config].get_text())
+                    except:
+                        pass
         dialog.destroy()
 
     def on_liveUSB_clicked(self, widget):
@@ -1887,7 +1904,7 @@ class MainWindowButtons(object):
         # Terminal button
         self.term_launch = widgets.get_widget('term_launch')
         self.target_term_launch = widgets.get_widget('target_term_launch')
-        self.target_kernel_cmdline = 
widgets.get_widget('target_kernel_cmdline')
+        self.target_config = widgets.get_widget('target_config')
         self.Write_USB = widgets.get_widget('Write_USB')
         self.create_launchvm = widgets.get_widget('launch_vm_btn')
 
diff --git a/gui/image-creator.glade b/gui/image-creator.glade
index 23643e7..abe7122 100644
--- a/gui/image-creator.glade
+++ b/gui/image-creator.glade
@@ -730,44 +730,74 @@
                                         <property name="position">3</property>
                                       </packing>
                                     </child>
-                                    <child>
-                                      <widget class="GtkButton" 
id="target_kernel_cmdline">
-                                        <property 
name="visible">True</property>
-                                        <property 
name="sensitive">False</property>
-                                        <property 
name="can_focus">True</property>
-                                        <property name="tooltip" 
translatable="yes">Edit the kernel command lines for booting.</property>
-                                        <property 
name="response_id">0</property>
-                                        <signal name="clicked" 
handler="on_target_kernel_cmdline_clicked"/>
-                                        <child>
-                                          <widget class="GtkVBox" id="vbox23">
-                                            <property 
name="visible">True</property>
-                                            <child>
-                                              <widget class="GtkImage" 
id="image18">
-                                                <property 
name="visible">True</property>
-                                                <property 
name="stock">gtk-go-forward</property>
-                                              </widget>
-                                            </child>
-                                            <child>
-                                              <widget class="GtkLabel" 
id="label44">
-                                                <property 
name="visible">True</property>
-                                                <property name="label" 
translatable="yes">_Kernel cmdline</property>
-                                                <property 
name="use_underline">True</property>
-                                              </widget>
-                                              <packing>
-                                                <property 
name="expand">False</property>
-                                                <property 
name="fill">False</property>
-                                                <property 
name="position">1</property>
-                                              </packing>
-                                            </child>
-                                          </widget>
-                                        </child>
-                                      </widget>
-                                      <packing>
-                                        <property 
name="expand">False</property>
-                                        <property name="fill">False</property>
-                                        <property name="position">4</property>
-                                      </packing>
-                                    </child>
+
+                                 <child>
+                                   <widget class="GtkButton" 
id="target_config">
+                                     <property name="visible">True</property>
+                                     <property 
name="sensitive">False</property>
+                                     <property name="tooltip" 
translatable="yes">Edit the target configuration.</property>
+                                     <property name="can_focus">True</property>
+                                     <property 
name="relief">GTK_RELIEF_NORMAL</property>
+                                     <property 
name="focus_on_click">True</property>
+                                     <signal name="clicked" 
handler="on_target_config_clicked"/>
+
+                                     <child>
+                                       <widget class="GtkVBox" id="vbox23">
+                                         <property 
name="visible">True</property>
+                                         <property 
name="homogeneous">False</property>
+                                         <property name="spacing">0</property>
+
+                                         <child>
+                                           <widget class="GtkImage" 
id="image18">
+                                             <property 
name="visible">True</property>
+                                             <property 
name="stock">gtk-go-forward</property>
+                                             <property 
name="icon_size">4</property>
+                                             <property 
name="xalign">0.5</property>
+                                             <property 
name="yalign">0.5</property>
+                                             <property name="xpad">0</property>
+                                             <property name="ypad">0</property>
+                                           </widget>
+                                           <packing>
+                                             <property 
name="padding">0</property>
+                                             <property 
name="expand">True</property>
+                                             <property 
name="fill">True</property>
+                                           </packing>
+                                         </child>
+
+                                         <child>
_______________________________________________
Commits mailing list
[email protected]
https://lists.moblin.org/mailman/listinfo/commits

Reply via email to