Hello community,

here is the log from the commit of package mksusecd for openSUSE:Factory 
checked in at 2017-03-21 22:51:12
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/mksusecd (Old)
 and      /work/SRC/openSUSE:Factory/.mksusecd.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "mksusecd"

Tue Mar 21 22:51:12 2017 rev:33 rq:481457 version:1.45

Changes:
--------
--- /work/SRC/openSUSE:Factory/mksusecd/mksusecd.changes        2017-03-17 
15:07:28.481987335 +0100
+++ /work/SRC/openSUSE:Factory/.mksusecd.new/mksusecd.changes   2017-03-21 
22:51:13.656545141 +0100
@@ -1,0 +2,7 @@
+Mon Mar 20 16:20:20 UTC 2017 - snw...@suse.com
+
+- fix typo
+- add --rebuild-initrd option for smaller initrds
+- 1.45
+
+-------------------------------------------------------------------

Old:
----
  mksusecd-1.44.tar.xz

New:
----
  mksusecd-1.45.tar.xz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ mksusecd.spec ++++++
--- /var/tmp/diff_new_pack.ExVO5O/_old  2017-03-21 22:51:14.224464853 +0100
+++ /var/tmp/diff_new_pack.ExVO5O/_new  2017-03-21 22:51:14.228464287 +0100
@@ -18,7 +18,7 @@
 
 
 Name:           mksusecd
-Version:        1.44
+Version:        1.45
 Release:        0
 Summary:        Create SUSE Linux installation ISOs
 License:        GPL-3.0+

++++++ mksusecd-1.44.tar.xz -> mksusecd-1.45.tar.xz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/mksusecd-1.44/VERSION new/mksusecd-1.45/VERSION
--- old/mksusecd-1.44/VERSION   2017-03-16 13:21:55.000000000 +0100
+++ new/mksusecd-1.45/VERSION   2017-03-20 17:19:36.000000000 +0100
@@ -1 +1 @@
-1.44
+1.45
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/mksusecd-1.44/changelog new/mksusecd-1.45/changelog
--- old/mksusecd-1.44/changelog 2017-03-16 13:21:55.000000000 +0100
+++ new/mksusecd-1.45/changelog 2017-03-20 17:19:36.000000000 +0100
@@ -1,3 +1,7 @@
+2017-03-17:    1.45
+       - fix typo
+       - add --rebuild-initrd option for smaller initrds
+
 2017-03-16:    1.44
        - support old mksquashfs version
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/mksusecd-1.44/mksusecd new/mksusecd-1.45/mksusecd
--- old/mksusecd-1.44/mksusecd  2017-03-16 13:21:55.000000000 +0100
+++ new/mksusecd-1.45/mksusecd  2017-03-20 17:19:36.000000000 +0100
@@ -235,6 +235,8 @@
 my $opt_addon_name;
 my $opt_addon_alias;
 my $opt_addon_prio = 60;
+my $opt_rebuild_initrd;
+
 
 GetOptions(
   'create|c=s'       => sub { $opt_create = 1; $opt_dst = $_[1] },
@@ -263,6 +265,7 @@
   'mbr-chs'          => sub { $opt_no_mbr_chs = 0 },
   'no-mbr-chs'       => \$opt_no_mbr_chs,
   'initrd=s'         => \@opt_initrds,
+  'rebuild-initrd'   => \$opt_rebuild_initrd,
   'boot=s'           => \$opt_boot_options,
   'grub2'            => sub { $opt_loader = "grub" },
   'isolinux'         => sub { $opt_loader = "isolinux" },
@@ -295,6 +298,10 @@
 usage 1 if $opt_hybrid_fs !~ '^(|iso|fat)$';
 usage 1 if defined($opt_digest) && $opt_digest !~ 
'^(md5|sha1|sha224|sha256|sha384|sha512)$';
 
+if($opt_rebuild_initrd && $>) {
+  die "mksusecd must be run with root permissions when --rebuild-initrd is 
used\n"
+}
+
 if(open my $f, "$ENV{HOME}/.mksusecdrc") {
   while(<$f>) {
     next if /^\s*#/;
@@ -538,6 +545,9 @@
       --no-zipl                 Don't make zIPL bootable (default except on 
s390x).
       --initrd DIR|RPM|DUD      Add directory DIR or package RPM or driver 
update DUD
                                 to initrd.
+      --rebuild-initrd          Rebuild the entire initrd instead of appending 
changes.
+                                This makes the initrd smaller but requires to 
run mksusecd
+                                with root permissions.
       --no-docs                 Don't include package documentation when 
updating the
                                 initrd (default).
       --keep-docs               Include package documentation when updating 
initrd.
@@ -1715,7 +1725,7 @@
   return undef if !@opt_initrds;
 
   my $tmp_initrd = $tmp->file();
-  my $tmp_dir = $tmp->dir();
+  my $tmp_dir = $opt_rebuild_initrd ? $orig_initrd : $tmp->dir();
 
   for my $i (@opt_initrds) {
     my $type = get_archive_type $i;
@@ -1817,7 +1827,12 @@
     }
 
     if(my $n = fname $x->{initrd}) {
-      system "cat '$add_initrd' >> '$n'";
+      if($opt_rebuild_initrd) {
+        system "cp '$add_initrd' '$n'";
+      }
+      else {
+        system "cat '$add_initrd' >> '$n'";
+      }
     }
   }
   else {
@@ -3137,6 +3152,9 @@
     mkdir "$tmp_dir/parts", 0755;
 
     my $p = sprintf "%02u_lib", $initrd_has_parts++;
+    # XX_lib contains kernel modules - replace the original one if we are
+    # going to rebuild the initrd anyway
+    $p = "00_lib" if $opt_rebuild_initrd;
 
     mkdir "$tmp_dir/lib", 0755;
     mkdir "$tmp_dir/lib/modules", 0755;


Reply via email to