Hello community,
here is the log from the commit of package yast2-pkg-bindings
checked in at Thu Nov 8 22:54:46 CET 2007.
--------
--- yast2-pkg-bindings/yast2-pkg-bindings.changes 2007-10-11 16:17:48.000000000 +0200
+++ /mounts/work_src_done/STABLE/yast2-pkg-bindings/yast2-pkg-bindings.changes 2007-11-08 14:55:18.605471000 +0100
@@ -1,0 +2,8 @@
+Thu Nov 8 13:44:29 CET 2007 - lslezak@suse.cz
+
+- fixed PkgTaboo() and PkgNeutral() - set all available instaces
+ of the package (from all reposiories) (#297083)
+- fixed PkgDelete() - mark all installed instances for removal
+- 2.16.2
+
+-------------------------------------------------------------------
Old:
----
yast2-pkg-bindings-2.16.1.tar.bz2
New:
----
yast2-pkg-bindings-2.16.2.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ yast2-pkg-bindings-devel-doc.spec ++++++
--- /var/tmp/diff_new_pack.FR1213/_old 2007-11-08 22:54:31.000000000 +0100
+++ /var/tmp/diff_new_pack.FR1213/_new 2007-11-08 22:54:31.000000000 +0100
@@ -1,5 +1,5 @@
#
-# spec file for package yast2-pkg-bindings-devel-doc (Version 2.16.1)
+# spec file for package yast2-pkg-bindings-devel-doc (Version 2.16.2)
#
# Copyright (c) 2007 SUSE LINUX Products GmbH, Nuernberg, Germany.
# This file and all modifications and additions to the pristine
@@ -11,12 +11,12 @@
# norootforbuild
Name: yast2-pkg-bindings-devel-doc
-Version: 2.16.1
+Version: 2.16.2
Release: 1
License: GPL v2 or later
Group: Documentation/HTML
BuildRoot: %{_tmppath}/%{name}-%{version}-build
-Source0: yast2-pkg-bindings-2.16.1.tar.bz2
+Source0: yast2-pkg-bindings-2.16.2.tar.bz2
Prefix: /usr
# same as in the main package (because we use the same configure.in.in)
BuildRequires: blocxx-devel boost boost-devel dbus-1-devel docbook-xsl-stylesheets doxygen gcc-c++ hal-devel libgcrypt-devel libxcrypt-devel libxslt libzypp libzypp-devel perl-XML-Writer rpm-devel sgml-skel yast2-core-devel yast2-devtools
@@ -37,7 +37,7 @@
Ladislav Slez�k
%prep
-%setup -n yast2-pkg-bindings-2.16.1
+%setup -n yast2-pkg-bindings-2.16.2
# build only documentation, ignore all other directories
echo "doc" > SUBDIRS
++++++ yast2-pkg-bindings.spec ++++++
--- /var/tmp/diff_new_pack.FR1213/_old 2007-11-08 22:54:31.000000000 +0100
+++ /var/tmp/diff_new_pack.FR1213/_new 2007-11-08 22:54:31.000000000 +0100
@@ -1,5 +1,5 @@
#
-# spec file for package yast2-pkg-bindings (Version 2.16.1)
+# spec file for package yast2-pkg-bindings (Version 2.16.2)
#
# Copyright (c) 2007 SUSE LINUX Products GmbH, Nuernberg, Germany.
# This file and all modifications and additions to the pristine
@@ -11,12 +11,12 @@
# norootforbuild
Name: yast2-pkg-bindings
-Version: 2.16.1
+Version: 2.16.2
Release: 1
License: GPL v2 or later
Group: System/YaST
BuildRoot: %{_tmppath}/%{name}-%{version}-build
-Source0: yast2-pkg-bindings-2.16.1.tar.bz2
+Source0: yast2-pkg-bindings-2.16.2.tar.bz2
Prefix: /usr
BuildRequires: blocxx-devel boost boost-devel dbus-1-devel docbook-xsl-stylesheets doxygen gcc-c++ hal-devel libgcrypt-devel libxcrypt-devel libxslt perl-XML-Writer rpm-devel sgml-skel yast2-core-devel yast2-devtools
BuildRequires: libzypp-devel >= 3.25.0
@@ -40,7 +40,7 @@
Stanislav Visnovsky
%prep
-%setup -n yast2-pkg-bindings-2.16.1
+%setup -n yast2-pkg-bindings-2.16.2
# build only the library, ignore documentation (it is in devel-doc package)
echo "src" > SUBDIRS
@@ -72,6 +72,11 @@
%{_libdir}/YaST2/plugin/libpy2Pkg.so
%doc %{prefix}/share/doc/packages/yast2-pkg-bindings
%changelog
+* Thu Nov 08 2007 - lslezak@suse.cz
+- fixed PkgTaboo() and PkgNeutral() - set all available instaces
+ of the package (from all reposiories) (#297083)
+- fixed PkgDelete() - mark all installed instances for removal
+- 2.16.2
* Thu Oct 11 2007 - lslezak@suse.cz
- fixed Pkg::SourceLoad() - don't load resolvables from
repositories deleted by Pkg::SourceDelete()
++++++ yast2-pkg-bindings-2.16.1.tar.bz2 -> yast2-pkg-bindings-2.16.2.tar.bz2 ++++++
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-pkg-bindings-2.16.1/configure new/yast2-pkg-bindings-2.16.2/configure
--- old/yast2-pkg-bindings-2.16.1/configure 2007-10-11 16:14:44.000000000 +0200
+++ new/yast2-pkg-bindings-2.16.2/configure 2007-11-08 14:52:14.000000000 +0100
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.61 for yast2-pkg-bindings 2.16.1.
+# Generated by GNU Autoconf 2.61 for yast2-pkg-bindings 2.16.2.
#
# Report bugs to http://bugs.opensuse.org/.
#
@@ -728,8 +728,8 @@
# Identity of this package.
PACKAGE_NAME='yast2-pkg-bindings'
PACKAGE_TARNAME='yast2-pkg-bindings'
-PACKAGE_VERSION='2.16.1'
-PACKAGE_STRING='yast2-pkg-bindings 2.16.1'
+PACKAGE_VERSION='2.16.2'
+PACKAGE_STRING='yast2-pkg-bindings 2.16.2'
PACKAGE_BUGREPORT='http://bugs.opensuse.org/'
ac_unique_file="RPMNAME"
@@ -1447,7 +1447,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-pkg-bindings 2.16.1 to adapt to many kinds of systems.
+\`configure' configures yast2-pkg-bindings 2.16.2 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1518,7 +1518,7 @@
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of yast2-pkg-bindings 2.16.1:";;
+ short | recursive ) echo "Configuration of yast2-pkg-bindings 2.16.2:";;
esac
cat <<\_ACEOF
@@ -1627,7 +1627,7 @@
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-yast2-pkg-bindings configure 2.16.1
+yast2-pkg-bindings configure 2.16.2
generated by GNU Autoconf 2.61
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
@@ -1641,7 +1641,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-pkg-bindings $as_me 2.16.1, which was
+It was created by yast2-pkg-bindings $as_me 2.16.2, which was
generated by GNU Autoconf 2.61. Invocation command line was
$ $0 $@
@@ -2462,7 +2462,7 @@
# Define the identity of the package.
PACKAGE='yast2-pkg-bindings'
- VERSION='2.16.1'
+ VERSION='2.16.2'
cat >>confdefs.h <<_ACEOF
@@ -2689,7 +2689,7 @@
-VERSION="2.16.1"
+VERSION="2.16.2"
RPMNAME="yast2-pkg-bindings"
MAINTAINER="Ladislav Slezák "
@@ -21198,7 +21198,7 @@
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by yast2-pkg-bindings $as_me 2.16.1, which was
+This file was extended by yast2-pkg-bindings $as_me 2.16.2, which was
generated by GNU Autoconf 2.61. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -21251,7 +21251,7 @@
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF
ac_cs_version="\\
-yast2-pkg-bindings config.status 2.16.1
+yast2-pkg-bindings config.status 2.16.2
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-pkg-bindings-2.16.1/configure.in new/yast2-pkg-bindings-2.16.2/configure.in
--- old/yast2-pkg-bindings-2.16.1/configure.in 2007-10-11 16:14:29.000000000 +0200
+++ new/yast2-pkg-bindings-2.16.2/configure.in 2007-11-08 14:52:03.000000000 +0100
@@ -3,7 +3,7 @@
dnl -- This file is generated by y2autoconf 2.15.9 - DO NOT EDIT! --
dnl (edit configure.in.in instead)
-AC_INIT(yast2-pkg-bindings, 2.16.1, http://bugs.opensuse.org/, yast2-pkg-bindings)
+AC_INIT(yast2-pkg-bindings, 2.16.2, http://bugs.opensuse.org/, yast2-pkg-bindings)
dnl Check for presence of file 'RPMNAME'
AC_CONFIG_SRCDIR([RPMNAME])
@@ -17,7 +17,7 @@
AM_INIT_AUTOMAKE(tar-ustar) dnl searches for some needed programs
dnl Important YaST2 variables
-VERSION="2.16.1"
+VERSION="2.16.2"
RPMNAME="yast2-pkg-bindings"
MAINTAINER="Ladislav Slezák "
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-pkg-bindings-2.16.1/pkg-bindings.pot new/yast2-pkg-bindings-2.16.2/pkg-bindings.pot
--- old/yast2-pkg-bindings-2.16.1/pkg-bindings.pot 1970-01-01 01:00:00.000000000 +0100
+++ new/yast2-pkg-bindings-2.16.2/pkg-bindings.pot 2007-10-22 14:03:12.000000000 +0200
@@ -0,0 +1,53 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) YEAR SuSE Linux Products GmbH, Nuernberg
+# This file is distributed under the same license as the PACKAGE package.
+# FIRST AUTHOR , YEAR.
+#
+#, fuzzy
+msgid ""
+msgstr ""
+"Project-Id-Version: PACKAGE VERSION\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2007-10-22 14:03+0200\n"
+"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
+"Last-Translator: FULL NAME \n"
+"Language-Team: LANGUAGE \n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=CHARSET\n"
+"Content-Transfer-Encoding: 8bit\n"
+
+#: src/Source.cc:67
+msgid "Scanning products in "
+msgstr ""
+
+#: src/Source.cc:193
+msgid "Refreshing repository "
+msgstr ""
+
+#: src/Source.cc:214
+msgid "Probing repository "
+msgstr ""
+
+#. TODO: improve the error message
+#: src/Source.cc:284
+msgid "Cannot find source"
+msgstr ""
+
+#: src/Source.cc:1008 src/Source.cc:1136
+msgid "Downloading "
+msgstr ""
+
+#. error message (followed by detailed description)
+#: src/Source.cc:1793
+msgid "Error: Cannot copy the cache to the target directory\n"
+msgstr ""
+
+#. error message (followed by directory name)
+#: src/Source.cc:1827
+msgid "Cannot create directory "
+msgstr ""
+
+#. error message
+#: src/Source.cc:1857
+msgid "Copying failed"
+msgstr ""
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-pkg-bindings-2.16.1/src/Package.cc new/yast2-pkg-bindings-2.16.2/src/Package.cc
--- old/yast2-pkg-bindings-2.16.1/src/Package.cc 2007-10-02 15:33:51.000000000 +0200
+++ new/yast2-pkg-bindings-2.16.2/src/Package.cc 2007-11-08 14:16:14.000000000 +0100
@@ -1801,12 +1801,11 @@
/**
@builtin PkgDelete
- @short Select package for deletion
+ @short Select package for deletion (deletes all installed instances of the package)
@param string package
@return boolean
*/
-#warning This is bogus, as we have multiple matching (kernel) packages
YCPValue
PkgModuleFunctions::PkgDelete (const YCPString& p)
@@ -1815,40 +1814,44 @@
if (name.empty())
return YCPBoolean (false);
+ bool ret = true;
+
try
{
- // find the package
- zypp::ResPool::byName_iterator it = std::find_if (
- zypp_ptr()->pool().byNameBegin(name)
- , zypp_ptr()->pool().byNameEnd(name)
- , zypp::functor::chain (
- zypp::resfilter::ByInstalled (),
- zypp::resfilter::ByKind( zypp::ResTraitszypp::Package::kind )
- )
- );
+ bool found = false;
+ for (zypp::ResPool::byName_iterator it = zypp_ptr()->pool().byNameBegin(name);
+ it != zypp_ptr()->pool().byNameEnd(name); ++it)
+ {
+ // is it an installed package?
+ if (zypp::isKindzypp::Package(it->resolvable()) && it->status().isInstalled())
+ {
+ found = true;
+ ret = it->status().setToBeUninstalled(whoWantsIt) && ret;
+ }
+ }
- // set the status to uninstalled
- return YCPBoolean( (it != zypp_ptr()->pool().byNameEnd(name))
- && it->status().setToBeUninstalled(whoWantsIt) );
+ if (!found)
+ {
+ ret = false;
+ }
}
catch (...)
{
+ ret = false;
}
- return YCPBoolean (false);
+ return YCPBoolean(ret);
}
-
/**
@builtin PkgTaboo
- @short Set package to taboo
+ @short Set package to taboo (sets all instances of the package - all versions, from all repositories)
@param string package
@return boolean
*/
-#warning This is bogus, as we have multiple matching packages
YCPValue
PkgModuleFunctions::PkgTaboo (const YCPString& p)
@@ -1857,39 +1860,51 @@
if (name.empty())
return YCPBoolean (false);
+ bool ret = true;
+
try
{
- // find the package
- zypp::ResPool::byName_iterator it = std::find_if (
- zypp_ptr()->pool().byNameBegin(name)
- , zypp_ptr()->pool().byNameEnd(name)
- , zypp::resfilter::ByKind(zypp::ResTraitszypp::Package::kind)
- );
-
- // remove the transactions, lock the status
- return YCPBoolean( (it != zypp_ptr()->pool().byNameEnd(name))
- && it->status().resetTransact(whoWantsIt)
- // lock the package at the USER level (bug #186205)
- && it->status().resetTransact(zypp::ResStatus::USER)
- && it->status().setLock(true, zypp::ResStatus::USER)
- );
+ bool found = false;
+
+ for (zypp::ResPool::byName_iterator it = zypp_ptr()->pool().byNameBegin(name);
+ it != zypp_ptr()->pool().byNameEnd(name); ++it)
+ {
+ // is it a package?
+ // installed package cannot be set to taboo
+ if (zypp::isKindzypp::Package(it->resolvable()) && !it->status().isInstalled())
+ {
+ found = true;
+
+ bool res = it->status().resetTransact(whoWantsIt)
+ // lock the package at the USER level (bug #186205)
+ && it->status().resetTransact(zypp::ResStatus::USER)
+ && it->status().setLock(true, zypp::ResStatus::USER);
+
+ ret = ret && res;
+ }
+ }
+
+ if (!found)
+ {
+ ret = false;
+ }
}
catch (...)
{
+ ret = false;
}
- return YCPBoolean (false);
+ return YCPBoolean(ret);
}
/**
@builtin PkgNeutral
- @short Set package to neutral (drop install/delete flags)
+ @short Set package to neutral (drop install/delete flags) (sets all instances of the package - all versions, from all repositories)
@param string package
@return boolean
*/
-#warning This is bogus, as we have multiple matching packages
YCPValue
PkgModuleFunctions::PkgNeutral (const YCPString& p)
@@ -1898,24 +1913,34 @@
if (name.empty())
return YCPBoolean (false);
+ bool ret = true;
+
try
{
- // find the package
- zypp::ResPool::byName_iterator it = std::find_if (
- zypp_ptr()->pool().byNameBegin(name)
- , zypp_ptr()->pool().byNameEnd(name)
- , zypp::resfilter::ByKind(zypp::ResTraitszypp::Package::kind)
- );
-
- // reset all transactions
- return YCPBoolean( (it != zypp_ptr()->pool().byNameEnd(name))
- && it->status().resetTransact(whoWantsIt) );
+ bool found = false;
+
+ for (zypp::ResPool::byName_iterator it = zypp_ptr()->pool().byNameBegin(name);
+ it != zypp_ptr()->pool().byNameEnd(name); ++it)
+ {
+ // is it a package?
+ if (zypp::isKindzypp::Package(it->resolvable()))
+ {
+ found = true;
+ ret = it->status().resetTransact(whoWantsIt) && ret;
+ }
+ }
+
+ if (!found)
+ {
+ ret = false;
+ }
}
catch (...)
{
+ ret = false;
}
- return YCPBoolean (false);
+ return YCPBoolean(ret);
}
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-pkg-bindings-2.16.1/VERSION new/yast2-pkg-bindings-2.16.2/VERSION
--- old/yast2-pkg-bindings-2.16.1/VERSION 2007-10-11 15:21:34.000000000 +0200
+++ new/yast2-pkg-bindings-2.16.2/VERSION 2007-11-08 14:29:19.000000000 +0100
@@ -1 +1 @@
-2.16.1
+2.16.2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
---------------------------------------------------------------------
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org