Mailinglist Archive: opensuse-commit (1828 mails)

< Previous Next >
commit yast2-packager
  • From: root@xxxxxxxxxxxxxxx (h_root)
  • Date: Mon, 08 Sep 2008 17:03:06 +0200
  • Message-id: <20080908150307.2EAA8678162@xxxxxxxxxxxxxxx>

Hello community,

here is the log from the commit of package yast2-packager
checked in at Mon Sep 8 17:03:06 CEST 2008.


--------
--- yast2-packager/yast2-packager.changes 2008-09-08 10:35:10.000000000
+0200
+++ /mounts/work_src_done/STABLE/yast2-packager/yast2-packager.changes
2008-09-08 16:54:00.301562000 +0200
@@ -1,0 +2,14 @@
+Mon Sep 8 16:36:40 CEST 2008 - lslezak@xxxxxxx
+
+- preliminary support for sevices - display a tree on the left side
+ (does not work yet), print to which service the selected
+ repository belongs
+- 2.17.11
+
+-------------------------------------------------------------------
+Mon Sep 8 13:29:25 CEST 2008 - locilka@xxxxxxx
+
+- Less confusing Add-On update/installation mode handling
+ independent on the base-product mode (FATE #301997).
+
+-------------------------------------------------------------------



Old:
----
yast2-packager-2.17.10.tar.bz2

New:
----
yast2-packager-2.17.11.tar.bz2

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

Other differences:
------------------
++++++ yast2-packager.spec ++++++
--- /var/tmp/diff_new_pack.AT7682/_old 2008-09-08 17:02:53.000000000 +0200
+++ /var/tmp/diff_new_pack.AT7682/_new 2008-09-08 17:02:53.000000000 +0200
@@ -1,5 +1,5 @@
#
-# spec file for package yast2-packager (Version 2.17.10)
+# spec file for package yast2-packager (Version 2.17.11)
#
# Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
@@ -19,12 +19,12 @@


Name: yast2-packager
-Version: 2.17.10
+Version: 2.17.11
Release: 1
License: GPL v2 or later
Group: System/YaST
BuildRoot: %{_tmppath}/%{name}-%{version}-build
-Source0: yast2-packager-2.17.10.tar.bz2
+Source0: yast2-packager-2.17.11.tar.bz2
Prefix: /usr
BuildRequires: gcc-c++ libxcrypt-devel perl-XML-Writer update-desktop-files
yast2-country-data yast2-devtools yast2-slp yast2-testsuite yast2-xml
# HTTP.ycp
@@ -80,7 +80,7 @@
Arvin Schnell <arvin@xxxxxxx>

%prep
-%setup -n yast2-packager-2.17.10
+%setup -n yast2-packager-2.17.11

%build
%{prefix}/bin/y2tool y2autoconf
@@ -116,6 +116,14 @@
%{prefix}/lib/YaST2/servers_non_y2/ag_*
%doc %{prefix}/share/doc/packages/yast2-packager
%changelog
+* Mon Sep 08 2008 lslezak@xxxxxxx
+- preliminary support for sevices - display a tree on the left side
+ (does not work yet), print to which service the selected
+ repository belongs
+- 2.17.11
+* Mon Sep 08 2008 locilka@xxxxxxx
+- Less confusing Add-On update/installation mode handling
+ independent on the base-product mode (FATE #301997).
* Mon Sep 08 2008 locilka@xxxxxxx
- Initializing the installation repository got from install.inf in
this order: ZyppRepoURL, YaSTRepoURL, RepoURL (bnc #406162).

++++++ yast2-packager-2.17.10.tar.bz2 -> yast2-packager-2.17.11.tar.bz2 ++++++
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn
--exclude=.svnignore old/yast2-packager-2.17.10/configure
new/yast2-packager-2.17.11/configure
--- old/yast2-packager-2.17.10/configure 2008-09-08 10:39:20.000000000
+0200
+++ new/yast2-packager-2.17.11/configure 2008-09-08 16:50:18.000000000
+0200
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.61 for yast2-packager 2.17.10.
+# Generated by GNU Autoconf 2.61 for yast2-packager 2.17.11.
#
# Report bugs to <http://bugs.opensuse.org/>.
#
@@ -574,8 +574,8 @@
# Identity of this package.
PACKAGE_NAME='yast2-packager'
PACKAGE_TARNAME='yast2-packager'
-PACKAGE_VERSION='2.17.10'
-PACKAGE_STRING='yast2-packager 2.17.10'
+PACKAGE_VERSION='2.17.11'
+PACKAGE_STRING='yast2-packager 2.17.11'
PACKAGE_BUGREPORT='http://bugs.opensuse.org/'

ac_unique_file="RPMNAME"
@@ -1197,7 +1197,7 @@
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures yast2-packager 2.17.10 to adapt to many kinds of
systems.
+\`configure' configures yast2-packager 2.17.11 to adapt to many kinds of
systems.

Usage: $0 [OPTION]... [VAR=VALUE]...

@@ -1268,7 +1268,7 @@

if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of yast2-packager 2.17.10:";;
+ short | recursive ) echo "Configuration of yast2-packager 2.17.11:";;
esac
cat <<\_ACEOF

@@ -1346,7 +1346,7 @@
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-yast2-packager configure 2.17.10
+yast2-packager configure 2.17.11
generated by GNU Autoconf 2.61

Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
@@ -1360,7 +1360,7 @@
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.

-It was created by yast2-packager $as_me 2.17.10, which was
+It was created by yast2-packager $as_me 2.17.11, which was
generated by GNU Autoconf 2.61. Invocation command line was

$ $0 $@
@@ -2181,7 +2181,7 @@

# Define the identity of the package.
PACKAGE='yast2-packager'
- VERSION='2.17.10'
+ VERSION='2.17.11'


cat >>confdefs.h <<_ACEOF
@@ -2409,7 +2409,7 @@



-VERSION="2.17.10"
+VERSION="2.17.11"
RPMNAME="yast2-packager"
MAINTAINER="Ladislav Slezak <lslezak@xxxxxxx>"

@@ -3304,7 +3304,7 @@
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by yast2-packager $as_me 2.17.10, which was
+This file was extended by yast2-packager $as_me 2.17.11, which was
generated by GNU Autoconf 2.61. Invocation command line was

CONFIG_FILES = $CONFIG_FILES
@@ -3347,7 +3347,7 @@
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF
ac_cs_version="\\
-yast2-packager config.status 2.17.10
+yast2-packager config.status 2.17.11
configured by $0, generated by GNU Autoconf 2.61,
with options \\"`echo "$ac_configure_args" | sed 's/^ //;
s/[\\""\`\$]/\\\\&/g'`\\"

diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn
--exclude=.svnignore old/yast2-packager-2.17.10/configure.in
new/yast2-packager-2.17.11/configure.in
--- old/yast2-packager-2.17.10/configure.in 2008-09-08 10:39:17.000000000
+0200
+++ new/yast2-packager-2.17.11/configure.in 2008-09-08 16:50:13.000000000
+0200
@@ -1,9 +1,9 @@
dnl configure.in for yast2-packager
dnl
-dnl -- This file is generated by y2autoconf 2.17.6 - DO NOT EDIT! --
+dnl -- This file is generated by y2autoconf 2.17.3 - DO NOT EDIT! --
dnl (edit configure.in.in instead)

-AC_INIT(yast2-packager, 2.17.10, http://bugs.opensuse.org/, yast2-packager)
+AC_INIT(yast2-packager, 2.17.11, http://bugs.opensuse.org/, yast2-packager)
dnl Check for presence of file 'RPMNAME'
AC_CONFIG_SRCDIR([RPMNAME])

@@ -18,7 +18,7 @@
AM_INIT_AUTOMAKE(tar-ustar -Wno-portability)

dnl Important YaST2 variables
-VERSION="2.17.10"
+VERSION="2.17.11"
RPMNAME="yast2-packager"
MAINTAINER="Ladislav Slezak <lslezak@xxxxxxx>"

diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn
--exclude=.svnignore old/yast2-packager-2.17.10/src/clients/repositories.ycp
new/yast2-packager-2.17.11/src/clients/repositories.ycp
--- old/yast2-packager-2.17.10/src/clients/repositories.ycp 2008-09-05
14:54:31.000000000 +0200
+++ new/yast2-packager-2.17.11/src/clients/repositories.ycp 2008-09-08
16:41:56.000000000 +0200
@@ -7,7 +7,7 @@
* Purpose:
* Adding, removing and prioritizing of repositories for packagemanager.
*
- * $Id: repositories.ycp 50737 2008-09-05 12:11:35Z lslezak $
+ * $Id: repositories.ycp 50812 2008-09-08 14:41:56Z lslezak $
*
*/

@@ -42,9 +42,17 @@

boolean full_mode = false;

+ // cache for textmode value
+ boolean text_mode = nil;
+
boolean textmode()
{
- return Mode::commandline() ? true :
UI::GetDisplayInfo()["TextMode"]:false;
+ if (text_mode == nil)
+ {
+ text_mode = Mode::commandline() ? true :
UI::GetDisplayInfo()["TextMode"]:false;
+ }
+
+ return text_mode;
}

integer numSources = 0;
@@ -59,6 +67,12 @@
// default (minimal) priority of a repository
const integer default_priority = 99;

+ // current view:
+ // selected service (or empty) if all services are selected
+ string displayed_service = "";
+ // service/repository view flag
+ boolean repository_view = true;
+
void RemoveDeletedAddNewRepos () {
list<map<string,any> > ret = [];

@@ -183,7 +197,7 @@
UI::ChangeWidget( `id( `table ), `Items, items );
}

- string repoInfoRichText(string name, string raw_url, string category)
+ string repoInfoRichText(string name, string raw_url, string category,
string service)
{
string schema = tolower(URL::Parse(raw_url)["scheme"]:"");
string icon_tag = "<IMG SRC=\"" + Directory::icondir + "/22x22/apps/"
@@ -197,16 +211,17 @@

string url = sformat (_("URL: %1"), raw_url);

- return sformat("<P>%1<B><BIG>%2</BIG></B></P><P>%3</P><P>%4</P>",
icon_tag, name, url, category);
+ return
sformat("<P>%1<B><BIG>%2</BIG></B></P><P>%3</P><P>%4</P><P>%5</P>", icon_tag,
name, url, category, service);
}

- term repoInfoTerm(string name, string url, string category)
+ term repoInfoTerm(string name, string url, string category, string service)
{
return textmode() ?
`VBox (
`Left(`Heading(`id(`name), `opt(`hstretch), name)),
`Left(`Label(`id(`url), `opt(`hstretch), url)),
- `Left(`Label(`id(`category), `opt(`hstretch), category ))
+ `Left(`Label(`id(`category), `opt(`hstretch), category )),
+ `Left(`Label(`id(`service), `opt(`hstretch), service))
)
:
`VSquash(`RichText(`id(`repo_info), ""));
@@ -224,15 +239,24 @@
// label, %1 is repo category (eg. YUM)
string category = sformat (_("Category: %1"),
info["type"]:_("Unknown"));

+ // label, %1 is repo category (eg. YUM)
+ string service = info["service"]:"";
+
+ if (service != "")
+ {
+ sformat (_("Service: %1"), service);
+ }
+
if (textmode())
{
UI::ChangeWidget(`id(`name), `Label, name);
UI::ChangeWidget(`id(`url), `Label, url);
UI::ChangeWidget(`id(`category), `Label, category);
+ UI::ChangeWidget(`id(`service), `Label, service);
}
else
{
- UI::ChangeWidget(`id(`repo_info), `Value, repoInfoRichText(name,
info["url"]:"", category));
+ UI::ChangeWidget(`id(`repo_info), `Value, repoInfoRichText(name,
info["url"]:"", category, service));
}

UI::ChangeWidget (`id (`enable), `Value, info["enabled"]:true);
@@ -342,8 +366,31 @@
return success;
}

+list<term> buildTree()
+{
+ list<term> ret = [];
+
+ list<term> services_t = [];

-symbol SummaryDialog () {
+ foreach(map<string,any> srv_state, serviceStatesOut,
+ {
+ term t = `item(`id(srv_state["name"]:""), srv_state["name"]:"");
+ services_t = add(services_t, t);
+ }
+ );
+
+ // alphabetically sort the repositories (by "name" key)
+ // TODO FIXME: use lsort
+// repositories_t = sort(term repo1, term repo2, repositories_t,
{y2internal("val: %1", repo1[1]:""); return repo1[1]:"" < repo2[1]:"";});
+
+ return [
+ // true = open the node
+ `item(`id(`services), _("Services"), true, services_t),
+ `item(`id(`repositories), _("Repositories"), true, [])
+ ];
+}
+
+any SummaryDialog () {
y2milestone ("Running Summary dialog");

// push button - change URL of the selected repository
@@ -365,6 +412,8 @@
}

term contents =
+ `HBox(
+ `Tree(`id(`tree), `opt(`notify), "", buildTree()),
`VBox(
`HBox(
`VSpacing(9),
@@ -390,7 +439,7 @@
`HBox (
`HSpacing (1),
`HWeight( 1, `VBox (
- repoInfoTerm("", "", ""),
+ repoInfoTerm("", "", "", ""),
// label
`Left (`Label (_("Properties"))),
// check box
@@ -438,6 +487,7 @@
])
),
`VSpacing( 0.5 )
+ )
);

// dialog caption
@@ -792,6 +842,11 @@
// do not refresh the item in the table
current = -1;
}
+ else if (input == `tree)
+ {
+ // TODO FIXME handle tree events here...
+ // rebuild the dialog here
+ }
else
{
y2warning("Unknown user input: %1", input);
@@ -903,7 +958,10 @@
PackageCallbacks::InitPackageCallbacks ();
}

+ // read repositories
boolean restore = (!full_mode) ? Pkg::SourceRestore() : true;
+ // read services
+ restore = restore && Pkg::ServicesLoad();
if( ! restore )
{
boolean cont = Popup::AnyQuestionRichText(
@@ -927,6 +985,18 @@
y2milestone( "Found repositories: %1", sourceStatesIn);
sourceStatesOut = sourceStatesIn;

+ list<string> srv_aliases = Pkg::ServiceAliases();
+ // get the current services
+ foreach(string srv_alias, srv_aliases,
+ {
+ serviceStatesIn = add(serviceStatesIn, Pkg::ServiceGet(srv_alias));
+ }
+ );
+
+ y2milestone("Loaded services: %1", serviceStatesIn);
+
+ serviceStatesOut = serviceStatesIn;
+
map<string,any> aliases = $[
"summary" : ``(SummaryDialog ()),
"type" : ``(StartTypeDialog()),
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn
--exclude=.svnignore
old/yast2-packager-2.17.10/src/include/repositories_include.ycp
new/yast2-packager-2.17.11/src/include/repositories_include.ycp
--- old/yast2-packager-2.17.10/src/include/repositories_include.ycp
2008-08-05 09:40:57.000000000 +0200
+++ new/yast2-packager-2.17.11/src/include/repositories_include.ycp
2008-09-05 10:29:07.000000000 +0200
@@ -28,6 +28,9 @@
list<map<string,any> > sourceStatesIn = [];
list<map<string,any> > sourceStatesOut = [];

+ list<map<string,any> > serviceStatesIn = [];
+ list<map<string,any> > serviceStatesOut = [];
+
// constant Plaindir
const string plaindir_type = "Plaindir";

diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn
--exclude=.svnignore old/yast2-packager-2.17.10/src/modules/AddOnProduct.ycp
new/yast2-packager-2.17.11/src/modules/AddOnProduct.ycp
--- old/yast2-packager-2.17.10/src/modules/AddOnProduct.ycp 2008-09-05
10:19:01.000000000 +0200
+++ new/yast2-packager-2.17.11/src/modules/AddOnProduct.ycp 2008-09-08
13:32:17.000000000 +0200
@@ -98,6 +98,58 @@
// if true, both are skipped at once without asking
global boolean skip_add_ons = false;

+// Which part installation.xml will be used
+string _inst_mode = "installation";
+
+/**
+ * Returns the current add-on installation mode.
+ *
+ * @return string current mode
+ * @see SetMode()
+ */
+string GetMode () {
+ return _inst_mode;
+}
+
+/**
+ * Sets internal add-on installation mode to either "installation" or "update".
+ * Mode is used later when deciding which part of the installation.xml to use.
+ *
+ * @param string new_mode ("installation" or "update")
+ * @see GetMode();
+ */
+void SetMode (string new_mode) {
+ if (new_mode == nil || ! contains (["installation", "update"], new_mode)) {
+ y2error ("Wrong Add-On mode: %1", new_mode);
+ }
+
+ _inst_mode = new_mode;
+}
+
+/**
+ * Returns whether add-on product got as parameter (source id)
+ * replaces some already installed add-on or whether it is a new
+ * installation.
+ *
+ * @param integer source_id
+ * @param string "installation" or "update" according the current state
+ */
+global string AddOnMode (integer source_id) {
+ list <map <string, any> > all_products = Pkg::ResolvableProperties ("",
`product, "");
+
+ all_products = filter (map <string, any> one_product, all_products, {
+ return (one_product["source"]:-1 == source_id);
+ });
+
+ // New add-on can replace some old one
+ if (all_products[0,"replaces"]:nil != nil && all_products[0,"replaces"]:""
!= "") {
+ y2milestone ("Add-on %1 replaces %2", source_id, all_products[0]:$[]);
+ return "update";
+ } else {
+ return "installation";
+ }
+}
+
// --> FATE #302123: Allow relative paths in "add_on_products" file
string base_product_url = nil;

@@ -379,7 +431,7 @@
}

string current_stage = "normal";
- string current_mode = Mode::mode();
+ string current_mode = GetMode();

list <map> steps = ProductControl::getModules (current_stage,
current_mode, `enabled);
if (steps == nil || size (steps) < 1) {
@@ -393,6 +445,7 @@
Wizard::SetContents(_("Initializing..."), `Empty (), "", false, false);

list <map> stage_mode = [$["stage": current_stage, "mode": current_mode,
]];
+ y2milestone ("Using Add-On control file parts: %1", stage_mode);
ProductControl::AddWizardSteps (stage_mode);

symbol ret = ProductControl::Run();
@@ -563,23 +616,9 @@
// FATE #302398: PATTERNS keyword in content file
HandleProductPATTERNS (src_id);

- list <map <string, any> > all_products = Pkg::ResolvableProperties ("",
`product, "");
- all_products = filter (map <string, any> one_product, all_products, {
- return (one_product["source"]:-1 == src_id);
- });
- y2milestone ("Added product: %1", all_products[0]:$[]);
-
- string old_mode = nil;
-
- // New add-on can replace some old one
- // Adjust mode accordingly
- if (all_products[0,"replaces"]:nil != nil && all_products[0,"replaces"]:""
!= "") {
- y2milestone ("New Add-On replaces %1, setting mode to update",
all_products[0,"replaces"]:nil);
- old_mode = Mode::mode();
- Mode::SetMode ("update");
- } else {
- Mode::SetMode ("installation");
- }
+ // FATE #301997: Support update of add-on products properly
+ string add_on_mode = AddOnMode (src_id);
+ SetMode (add_on_mode);

symbol ret = nil;

@@ -602,9 +641,6 @@
RegisterAddOnProduct (src_id);
}

- // Set mode to the previous state
- Mode::SetMode (old_mode);
-
y2milestone ("Returning: %1", ret);
return ret;
}
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn
--exclude=.svnignore old/yast2-packager-2.17.10/src/modules/InstURL.ycp
new/yast2-packager-2.17.11/src/modules/InstURL.ycp
--- old/yast2-packager-2.17.10/src/modules/InstURL.ycp 2008-09-08
10:35:22.000000000 +0200
+++ new/yast2-packager-2.17.11/src/modules/InstURL.ycp 2008-09-08
16:47:04.000000000 +0200
@@ -6,7 +6,7 @@
* Purpose: Convert /etc/install.inf data to URL
*
*
- * $Id: InstURL.ycp 50780 2008-09-08 08:35:22Z locilka $
+ * $Id: InstURL.ycp 50813 2008-09-08 14:43:57Z locilka $
*/

{
@@ -126,7 +126,7 @@

// bnc #406162
boolean repo_url_from_inf = false;
- foreach (string in_inf_key, ["ZyppRepoURL", "YaSTRepoURL", "RepoURL"], {
+ foreach (string in_inf_key, ["ZyppRepoURL"], {
repo_url = Linuxrc::InstallInf (in_inf_key);

if (repo_url != nil && repo_url != "") {
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn
--exclude=.svnignore old/yast2-packager-2.17.10/VERSION
new/yast2-packager-2.17.11/VERSION
--- old/yast2-packager-2.17.10/VERSION 2008-09-08 10:35:16.000000000 +0200
+++ new/yast2-packager-2.17.11/VERSION 2008-09-08 16:41:36.000000000 +0200
@@ -1 +1 @@
-2.17.10
+2.17.11


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



Remember to have fun...

---------------------------------------------------------------------
To unsubscribe, e-mail: opensuse-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse-commit+help@xxxxxxxxxxxx

< Previous Next >