packages: poldek/poldek.spec, poldek/poldek-show_only_relative_used_space.p...
cactus
cactus at pld-linux.org
Thu Feb 4 22:38:42 CET 2010
Author: cactus Date: Thu Feb 4 21:38:42 2010 GMT
Module: packages Tag: HEAD
---- Log message:
- patch32 - LP#506568
- patch33 - LP#499504
- patch34 - do not info. about amount of transaction space req. but relative to already installed
- rel 36
---- Files affected:
packages/poldek:
poldek.spec (1.391 -> 1.392) , poldek-show_only_relative_used_space.patch (NONE -> 1.1) (NEW)
---- Diffs:
================================================================
Index: packages/poldek/poldek.spec
diff -u packages/poldek/poldek.spec:1.391 packages/poldek/poldek.spec:1.392
--- packages/poldek/poldek.spec:1.391 Wed Feb 3 03:24:30 2010
+++ packages/poldek/poldek.spec Thu Feb 4 22:38:36 2010
@@ -16,7 +16,7 @@
%define ver_rpm 4.5-5
#
%define snap 20080820.23
-%define rel 35
+%define rel 36
Summary: RPM packages management helper tool
Summary(pl.UTF-8): Pomocnicze narzędzie do zarządzania pakietami RPM
Name: poldek
@@ -69,6 +69,9 @@
Patch29: %{name}-dont-be-greedy.patch
Patch30: %{name}-dont-lose-deps.patch
Patch31: %{name}-ls-queryfmt.patch
+Patch32: %{name}-prepare_url_fix.patch
+Patch33: %{name}-noloop_on_terminal_loos.patch
+Patch34: %{name}-show_only_relative_used_space.patch
URL: http://poldek.pld-linux.org/
BuildRequires: autoconf
BuildRequires: automake
@@ -216,7 +219,7 @@
%patch22 -p0
%patch23 -p1
%patch24 -p1
-# LP#392984
+# LP#392984: add source rpm to ls
%patch25 -p1
# LP#408036
%patch26 -p1
@@ -227,8 +230,15 @@
# dont be greedy if upgraded pkg has needed capabilities
%patch29 -p1
# http://lists.pld-linux.org/mailman/pipermail/pld-devel-pl/2009-November/150519.html
-%patch30 -p1
+%patch30 -p1
+# LP#392984: add query format to ls
%patch31 -p1
+# LP#506568
+%patch32 -p0
+# LP#499504
+%patch33 -p1
+# do not info. about amount of transaction space req. but relative to already installed
+%patch34 -p1
# cleanup backups after patching
find . '(' -name '*~' -o -name '*.orig' ')' -print0 | xargs -0 -r -l512 rm -f
@@ -508,6 +518,12 @@
All persons listed below can be reached at <cvs_login>@pld-linux.org
$Log$
+Revision 1.392 2010/02/04 21:38:36 cactus
+- patch32 - LP#506568
+- patch33 - LP#499504
+- patch34 - do not info. about amount of transaction space req. but relative to already installed
+- rel 36
+
Revision 1.391 2010/02/03 02:24:30 sparky
- BR: gettext-devel
- dropped unused BR: check, gettext-autopoint, perl-tools-pod, xmlto
================================================================
Index: packages/poldek/poldek-show_only_relative_used_space.patch
diff -u /dev/null packages/poldek/poldek-show_only_relative_used_space.patch:1.1
--- /dev/null Thu Feb 4 22:38:42 2010
+++ packages/poldek/poldek-show_only_relative_used_space.patch Thu Feb 4 22:38:36 2010
@@ -0,0 +1,89 @@
+diff --git a/pkgfetch.c b/pkgfetch.c
+index 049eb0e..b2cffbd 100644
+--- a/pkgfetch.c
++++ b/pkgfetch.c
+@@ -105,11 +105,6 @@ void packages_fetch_summary(struct pm_ctx *pmctx, const tn_array *pkgs,
+ msgn(1, _("_ (%s to download)."), buf);
+ }
+
+- if (bytesused) {
+- char buf[64];
+- snprintf_size(buf, sizeof(buf), bytesused, 1, 1);
+- msg(1, _("After unpacking %s will be used."), buf);
+- }
+ }
+
+ msg(1, "_\n");
+diff --git a/poldek_ts.c b/poldek_ts.c
+index a0dd436..306b492 100644
+--- a/poldek_ts.c
++++ b/poldek_ts.c
+@@ -834,9 +834,10 @@ void poldek__ts_update_summary(struct poldek_ts *ts,
+ void poldek__ts_display_summary(struct poldek_ts *ts)
+ {
+ int ninst = 0, ndep = 0, nrm = 0, npkgs = 0, parseable = 0;
++ long sinsts = 0, sdeps = 0, srems = 0, sdiff = 0;
+ tn_array *ipkgs, *idepkgs, *rmpkgs, *pkgs;
+- char ms[1024], *to, *prefix;
+- int n;
++ char ms[1024], *to, *prefix, *take;
++ int i, n;
+
+ ipkgs = n_hash_get(ts->ts_summary, "I");
+ idepkgs = n_hash_get(ts->ts_summary, "D");
+@@ -846,16 +847,36 @@ void poldek__ts_display_summary(struct poldek_ts *ts)
+ ndep = idepkgs ? n_array_size(idepkgs) : 0;
+ nrm = rmpkgs ? n_array_size(rmpkgs) : 0;
+
+- to = _("to install");
+- prefix = "I";
+- pkgs = ipkgs;
+- npkgs = ninst + ndep;
+-
+- if (ts->type == POLDEK_TS_UNINSTALL) {
++ if (ipkgs)
++ for (i=0; i < n_array_size(ipkgs); i++) {
++ struct pkg *pkg = n_array_nth(ipkgs, i);
++ sinsts += pkg->size;
++ }
++ if (idepkgs)
++ for (i=0; i < n_array_size(idepkgs); i++) {
++ struct pkg *pkg = n_array_nth(idepkgs, i);
++ sdeps += pkg->size;
++ }
++ if (rmpkgs)
++ for (i=0; i < n_array_size(rmpkgs); i++) {
++ struct pkg *pkg = n_array_nth(rmpkgs, i);
++ srems += pkg->size;
++ }
++
++ if (ts->type != POLDEK_TS_UNINSTALL) {
++ to = _("to install");
++ prefix = "I";
++ pkgs = ipkgs;
++ npkgs = ninst + ndep;
++ take = _("take");
++ sdiff = sinsts + sdeps - srems;
++ } else {
+ to = _("to remove");
+ prefix = "R";
+ pkgs = rmpkgs;
+ npkgs = nrm + ndep;
++ take = _("free");
++ sdiff = sdeps + srems;
+ nrm = 0;
+ }
+ n_assert(pkgs);
+@@ -896,6 +917,12 @@ void poldek__ts_display_summary(struct poldek_ts *ts)
+ if (rmpkgs)
+ packages_display_summary(1, "R", rmpkgs, parseable);
+ }
++
++ if (sdiff) {
++ char size[64];
++ snprintf_size(size, sizeof(size), abs(sdiff), 1, 1);
++ msgn(1, _("This operation will %s %s of disk space."), take, size);
++ }
+ }
+
+ tn_array *poldek_ts_get_summary(const struct poldek_ts *ts, const char *mark)
================================================================
---- CVS-web:
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/poldek/poldek.spec?r1=1.391&r2=1.392&f=u
More information about the pld-cvs-commit
mailing list