[powertop] Updated version to show 2.2 (by version-fix patch)

Jaroslav Škarvada jskarvad at fedoraproject.org
Sun Dec 2 16:07:49 UTC 2012


commit 54c6bc6cf38c3ec12a0453f6a6d61fe9985f6728
Author: Jaroslav Škarvada <jskarvad at redhat.com>
Date:   Sun Dec 2 17:07:36 2012 +0100

    Updated version to show 2.2 (by version-fix patch)

 powertop-2.2-version-fix.patch |   34 ++++++++++++++++++++++++++++++++++
 powertop.spec                  |    8 +++++++-
 2 files changed, 41 insertions(+), 1 deletions(-)
---
diff --git a/powertop-2.2-version-fix.patch b/powertop-2.2-version-fix.patch
new file mode 100644
index 0000000..2f61e7c
--- /dev/null
+++ b/powertop-2.2-version-fix.patch
@@ -0,0 +1,34 @@
+From: Namhyung Kim <namhyung at gmail.com>
+To: powertop at lists.01.org
+Date: Sun, 18 Nov 2012 00:42:47 +0900
+Message-Id: <1353166967-24095-1-git-send-email-namhyung at gmail.com>
+Subject: [Powertop] [PATCH] Use PACKAGE_VERSION for POWERTOP_VERSION
+
+It was missed to update POWERTOP_VERSION macro so that the
+new v2.2 release still shows v2.1 string on the header of
+ncurses window.  Convert to use PACKAGE_VERSION macro which
+set by autotools to the AC_INIT version so that it cannot
+be missed anymore.
+
+Signed-off-by: Namhyung Kim <namhyung at gmail.com>
+---
+ src/lib.h |    4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/lib.h b/src/lib.h
+index 8cf4632..209421a 100644
+--- a/src/lib.h
++++ b/src/lib.h
+@@ -35,8 +35,8 @@
+ 
+ #define _(STRING)    gettext(STRING)
+ 
+-#define POWERTOP_VERSION "v2.1"
+-#define POWERTOP_SHORT_VERSION "2.1"
++#define POWERTOP_VERSION "v"PACKAGE_VERSION
++#define POWERTOP_SHORT_VERSION PACKAGE_VERSION
+ 
+ 
+ extern int get_max_cpu(void);
+-- 
+1.7.9.2
diff --git a/powertop.spec b/powertop.spec
index d65814f..5155d87 100644
--- a/powertop.spec
+++ b/powertop.spec
@@ -1,6 +1,6 @@
 Name:          powertop
 Version:       2.2
-Release:       2%{?dist}
+Release:       3%{?dist}
 Summary:       Power consumption monitor
 
 Group:         Applications/System
@@ -12,6 +12,8 @@ Source0:       http://01.org/powertop/sites/default/files/downloads/%{name}-%{ve
 Patch0:        powertop-2.0-always-create-params.patch
 # Sent upstream
 Patch1:        powertop-2.2-fix-crash-on-readonly-fs.patch
+# Cherrypicked from upstrean git
+Patch2:        powertop-2.2-version-fix.patch
 BuildRoot:     %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 BuildRequires: gettext, ncurses-devel, pciutils-devel, zlib-devel, libnl3-devel
 
@@ -23,6 +25,7 @@ computer use more power than necessary while it is idle.
 %setup -q
 %patch0 -p1 -b .always-create-params
 %patch1 -p1 -b .fix-crash-on-readonly-fs
+%patch2 -p1 -b .version-fix
 
 # remove left over object files
 find . -name "*.o" -exec rm {} \;
@@ -55,6 +58,9 @@ rm -rf %{buildroot}
 %{_mandir}/man8/powertop.8*
 
 %changelog
+* Sun Dec  2 2012 Jaroslav Škarvada <jskarvad at redhat.com> - 2.2-3
+- Updated version to show 2.2 (by version-fix patch)
+
 * Wed Nov 28 2012 Jaroslav Škarvada <jskarvad at redhat.com> - 2.2-2
 - Fixed crash when writing report on readonly filesystem
   (fix-crash-on-readonly-fs patch)


More information about the scm-commits mailing list