Hello community,
here is the log from the commit of package yast2-online-update
checked in at Fri Apr 25 15:09:10 CEST 2008.
--------
--- yast2-online-update/yast2-online-update.changes 2008-04-15 14:04:46.000000000 +0200
+++ /mounts/work_src_done/NOARCH/yast2-online-update/yast2-online-update.changes 2008-04-24 13:16:49.678096000 +0200
@@ -1,0 +2,7 @@
+Thu Apr 24 13:06:59 CEST 2008 - jsuchome@suse.cz
+
+- warn user if there are selected patches not for package management,
+ do not run solver silently (bnc#367057)
+- 2.16.12
+
+-------------------------------------------------------------------
Old:
----
yast2-online-update-2.16.11.tar.bz2
New:
----
yast2-online-update-2.16.12.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ yast2-online-update.spec ++++++
--- /var/tmp/diff_new_pack.N30228/_old 2008-04-25 15:09:05.000000000 +0200
+++ /var/tmp/diff_new_pack.N30228/_new 2008-04-25 15:09:05.000000000 +0200
@@ -1,5 +1,5 @@
#
-# spec file for package yast2-online-update (Version 2.16.11)
+# spec file for package yast2-online-update (Version 2.16.12)
#
# Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany.
# This file and all modifications and additions to the pristine
@@ -12,12 +12,12 @@
Name: yast2-online-update
-Version: 2.16.11
+Version: 2.16.12
Release: 1
License: GPL v2 or later
Group: System/YaST
BuildRoot: %{_tmppath}/%{name}-%{version}-build
-Source0: yast2-online-update-2.16.11.tar.bz2
+Source0: yast2-online-update-2.16.12.tar.bz2
Prefix: /usr
BuildRequires: gcc-c++ libxcrypt-devel perl-XML-Writer pkg-config update-desktop-files yast2-bootloader yast2-devtools yast2-packager
PreReq: grep sed
@@ -50,7 +50,7 @@
gs@suse.de
%prep
-%setup -n yast2-online-update-2.16.11
+%setup -n yast2-online-update-2.16.12
%build
%{prefix}/bin/y2tool y2autoconf
@@ -153,6 +153,10 @@
/var/lib/YaST2/cd_update.desktop
%ghost %{prefix}/share/applications/YaST2/cd_update.desktop
%changelog
+* Thu Apr 24 2008 jsuchome@suse.cz
+- warn user if there are selected patches not for package management,
+ do not run solver silently (bnc#367057)
+- 2.16.12
* Tue Apr 15 2008 jsuchome@suse.cz
- merged texts from proofread
- 2.16.11
++++++ yast2-online-update-2.16.11.tar.bz2 -> yast2-online-update-2.16.12.tar.bz2 ++++++
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-online-update-2.16.11/src/online_update_install.ycp new/yast2-online-update-2.16.12/src/online_update_install.ycp
--- old/yast2-online-update-2.16.11/src/online_update_install.ycp 2008-04-15 14:00:52.000000000 +0200
+++ new/yast2-online-update-2.16.12/src/online_update_install.ycp 2008-04-24 13:16:31.000000000 +0200
@@ -4,7 +4,7 @@
* Summary: YOU installation page
* Authors: Cornelius Schumacher
*
- * $Id: online_update_install.ycp 42280 2007-11-21 14:17:16Z jsuchome $
+ * $Id: online_update_install.ycp 47025 2008-04-24 11:16:31Z jsuchome $
*
* This is a client for installation.
* It displays the dialog with a progress of the actual installation and
@@ -56,12 +56,6 @@
if (!Stage::cont ())
Wizard::SetNextButton(`next, Label::FinishButton() );
- if (!Stage::cont ())
- {
- Wizard::SetNextButton(`next, Label::FinishButton() );
- Pkg::PkgSolve (true);
- }
-
integer total_progress = size (Pkg::GetPackages (`selected, true)) * 2;
if (total_progress == 0)
total_progress = 100;
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-online-update-2.16.11/src/online_update_select.ycp new/yast2-online-update-2.16.12/src/online_update_select.ycp
--- old/yast2-online-update-2.16.11/src/online_update_select.ycp 2008-02-21 12:40:40.000000000 +0100
+++ new/yast2-online-update-2.16.12/src/online_update_select.ycp 2008-04-23 09:59:17.000000000 +0200
@@ -47,28 +47,26 @@
Pkg::PkgEstablish();
+ boolean restart_yast = false;
+ boolean reboot_needed = false;
+ boolean normal_patches_selected = false;
integer selected = 0;
string saved_path = Directory::vardir + "/selected_patches.ycp";
- // check if there exists saved selection of patches to be installed
+ // check if YaST was restarted
if (FileUtils::Exists (saved_path))
{
- list<string> patches = (list<string>) SCR::Read(.target.ycp,saved_path);
- if (patches == nil)
- patches = [];
- foreach (string pname, patches, {
- if (Pkg::ResolvableInstall (pname, `patch))
- selected = selected + 1;
- });
+ string saved = (string) SCR::Read (.target.ycp, saved_path);
+ // before restart, patch requiring reboot was installed:
+ // show the reboot popup now
+ if (saved != nil && is (saved, string) && saved == "reboot")
+ reboot_needed = true;
SCR::Execute (.target.remove, saved_path);
- y2milestone ("Previously selected patches: %1", selected);
}
+
// if not, select the patches affecting pkg management
- else
- {
- selected = Pkg::ResolvablePreselectPatches (`affects_pkg_manager);
- y2milestone ("Preselected patches for pkg management: %1", selected);
- }
+ selected = Pkg::ResolvablePreselectPatches (`affects_pkg_manager);
+ y2milestone ("Preselected patches for pkg management: %1", selected);
// if no patch is selected, pre-select all security and recommended
if (selected < 1)
@@ -77,6 +75,8 @@
y2milestone ("All preselected patches: %1", selected);
}
+ Wizard::ClearContents();// do not show the remnant of initial progress
+
boolean simple_mode = OnlineUpdate::simple_mode && (UI::HasSpecialWidget(`SimplePatchSelector) == true);
if (simple_mode)
{
@@ -103,6 +103,34 @@
current = "simple";
ret = nil;
}
+ if (ret == `accept)
+ {
+ restart_yast = false;
+ normal_patches_selected = false;
+ foreach (map patch, Pkg::ResolvableProperties ("", `patch, ""), {
+ if (patch["status"]:`none == `selected)
+ {
+ if (patch["affects_pkg_manager"]:false)
+ restart_yast = true;
+ else
+ normal_patches_selected = true;
+ }
+ });
+ if (restart_yast && normal_patches_selected)
+ {
+ // continue/cancel popup
+ if (!Popup::ContinueCancel (_("There are patches for package management available requiring restart of YaST.
+They should be installed first and all other patches after the restart.
+
+You selected some other patches to be installed now.
+
+Continue with installing your selection?")))
+ {
+ ret = nil;
+ UI::OpenDialog (`opt(`defaultsize), `PackageSelector(`id(`selector), `opt(`youMode)));
+ }
+ }
+ }
} until ( ret == `cancel || ret == `accept );
Wizard::ClearContents();
@@ -110,41 +138,45 @@
y2milestone ("RunPkgSelection finally returned '%1'", ret);
if ( ret == `cancel ) return `abort;
- boolean restart_yast = false;
- list<string> normal_patches = [];
boolean more_patches_needed = false;
- boolean reboot_needed = false;
foreach (map patch, Pkg::ResolvableProperties("", `patch, ""), {
if (patch["status"]:`none == `selected)
{
if (patch["reboot_needed"]:false)
reboot_needed = true;
if (patch["affects_pkg_manager"]:false)
- restart_yast = true;
+ restart_yast = true;
else
- normal_patches = add (normal_patches, patch["name"]:"");
+ normal_patches_selected = true;
}
- else if (patch["is_needed"]:false) // patch not selected: bug #188541
+ // patch not selected: bug #188541 - touch saved_path to force the restart
+ else if (patch["is_needed"]:false)
{
- y2debug ("patch needed but not selected: %1", patch);
+ y2milestone ("patch needed but not selected: %1", patch);
more_patches_needed = true;
}
});
- // unselect non-affects_pkg_manager patches and save them to file
- // for later usage
- if (restart_yast && (size (normal_patches) > 0 || more_patches_needed))
- {
- foreach (string pname, normal_patches, {
- Pkg::ResolvableNeutral (pname, `patch, true);
- });
- SCR::Write (.target.ycp, saved_path, normal_patches);
- // show reboot popup only when yast is not going to restart itself automatically
+ // tell the caller (/sbin/yast2) to call online update again
+ if (restart_yast && more_patches_needed)
+ {
+ // what if kernel (=reboot) and zypp (=restart) are installed together?
+ // => restart YaST and show reboot message after the second run
+ string save_message = "restart";
+ if (reboot_needed)
+ save_message = "reboot";
+ SCR::Write (.target.ycp, saved_path, save_message);
+ // show reboot popup only when yast is not going to restart now
reboot_needed = false;
}
+ else
+ {
+ y2debug ("nothing left for the second run, no restart needed");
+ }
+
// no patch selected
- if (!restart_yast && normal_patches == [] && !Pkg::PkgAnyToInstall () &&
- !Pkg::PkgAnyToDelete ())
+ if (!restart_yast && !normal_patches_selected &&
+ !Pkg::PkgAnyToInstall () && !Pkg::PkgAnyToDelete ())
{
ret = `cancel;
}
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-online-update-2.16.11/src/online_update.ycp new/yast2-online-update-2.16.12/src/online_update.ycp
--- old/yast2-online-update-2.16.11/src/online_update.ycp 2008-04-15 14:00:52.000000000 +0200
+++ new/yast2-online-update-2.16.12/src/online_update.ycp 2008-04-21 15:28:34.000000000 +0200
@@ -91,7 +91,7 @@
});
// continue/cancel message
if (!is_available && Popup::YesNo (_("No active update repository available.
-Exit <b>Online Update</b> now?
+Exit Online Update now?
")))
{
Wizard::CloseDialog();
@@ -202,9 +202,10 @@
Popup::Message (OnlineUpdate::restart_message);
}
OnlineUpdate::restart_yast = false;
- retval = -42;// restart menu.ycp even if there are no other patches selected
+ // restart menu.ycp even if there are no other patches selected
+ retval = -42;
}
- else if (OnlineUpdate::reboot_needed)
+ if (OnlineUpdate::reboot_needed)
{
Popup::Message (OnlineUpdate::reboot_message);
}
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-online-update-2.16.11/VERSION new/yast2-online-update-2.16.12/VERSION
--- old/yast2-online-update-2.16.11/VERSION 2008-04-15 14:01:39.000000000 +0200
+++ new/yast2-online-update-2.16.12/VERSION 2008-04-24 13:07:59.000000000 +0200
@@ -1 +1 @@
-2.16.11
+2.16.12
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
---------------------------------------------------------------------
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org