[Gelistirici] YALI v.s parted

S.Çağlar Onur caglar at pardus.org.tr
23 Mayıs 2007 Çar 02:37:49 EEST


Selamlar;

...
 - Update to new version 1.8.3
     libparted:
     - Enable support for swsusp partitions and the ability to differentiate
       between old and new versions of linux-swap partitions.
...

sebebi ile ya YALI'da şu aşağıdaki değişiklik gerekiyor;

Index: gui/PartListImpl.py
===================================================================
--- gui/PartListImpl.py (revision 14011)
+++ gui/PartListImpl.py (working copy)
@@ -178,8 +178,8 @@
             p.setData(part)

             # use the first found "linux-swap" partition as swap (# 1049)
-            if part.getFSName() == "linux-swap" and not 
self.autoSwapSelected:
-                ctx.partrequests.append(
+            if part.getFSName() == "linux-swap(new)" and not 
self.autoSwapSelected:
+                ctx.partrequests.append(new)(
                     request.MountRequest(part, parttype.swap))

                 ctx.partrequests.append(
Index: fstab.py
===================================================================
--- fstab.py    (revision 14011)
+++ fstab.py    (working copy)
@@ -44,7 +44,7 @@
         self.write(fstab_header)

     def insert(self, e):
-        if e.filesystem == "linux-swap":
+        if e.filesystem == "linux-swap(new)":
             e.filesystem = "swap"

         l = "%-20s %-16s %-9s %-20s %s %s\n" % (
Index: filesystem.py
===================================================================
--- filesystem.py       (revision 14011)
+++ filesystem.py       (working copy)
@@ -40,7 +40,7 @@
     # later on.
     if name == "ext3":
         return Ext3FileSystem()
-    elif name == "swap" or name == "linux-swap":
+    elif name == "swap" or name == "linux-swap(new)":
         return SwapFileSystem()
     elif name == "ntfs":
         return NTFSFileSystem()
@@ -398,7 +398,7 @@
 # linux-swap
 class SwapFileSystem(FileSystem):

-    _name = "linux-swap"
+    _name = "linux-swap(new)"

     def __init__(self):
         FileSystem.__init__(self)

veya parted'a şu yama;

Index: parted-1.8.7/libparted/fs/linux_swap/linux_swap.c
===================================================================
--- parted-1.8.7.orig/libparted/fs/linux_swap/linux_swap.c
+++ parted-1.8.7/libparted/fs/linux_swap/linux_swap.c
@@ -719,6 +719,13 @@ static PedFileSystemType _swap_v2_type =
        block_sizes: LINUXSWAP_BLOCK_SIZES
 };
 
+static PedFileSystemType _swap_default_type = {
+       next:   NULL,
+       ops:    &_swap_v2_ops,
+       name:   "linux-swap",
+       block_sizes: LINUXSWAP_BLOCK_SIZES
+};
+
 static PedFileSystemType _swap_swsusp_type = {
         next:   NULL,
        ops:    &_swap_swsusp_ops,
@@ -729,6 +736,7 @@ static PedFileSystemType _swap_swsusp_ty
 void
 ped_file_system_linux_swap_init ()
 {
+       ped_file_system_type_register (&_swap_default_type);
        ped_file_system_type_register (&_swap_v1_type);
        ped_file_system_type_register (&_swap_v2_type);
        ped_file_system_type_register (&_swap_swsusp_type);

Hangisinin daha doğru bir çözüm olduğunu bilemedim (bu arada old (kernel'de 
old desteği kalkmış)/new/swsusp tipindeki swapleri birbirinden ayırmamız 
gerekiyor mu, ya da ilerisi için iyi olur mu da bilemedim) , Barış/Gökmen?

Saygılar
-- 
S.Çağlar Onur <caglar at pardus.org.tr>
http://cekirdek.pardus.org.tr/~caglar/

Linux is like living in a teepee. No Windows, no Gates and an Apache in house!
-------------- sonraki bölüm --------------
A non-text attachment was scrubbed...
Name: kullanılamıyor
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part.
URL: <http://liste.pardus.org.tr/gelistirici/attachments/20070523/705b70f1/attachment-0002.pgp>


Gelistirici mesaj listesiyle ilgili daha fazla bilgi