[packages/razor-qt] - patch from Debian to fix building with libstatgrab >= 0.90 - updated BRs - rel 6

baggins baggins at pld-linux.org
Sun Dec 13 13:22:46 CET 2015


commit d6c935ea4877387f716235f6b7bf2ace1dc803ed
Author: Jan Rękorajski <baggins at pld-linux.org>
Date:   Sun Dec 13 13:22:08 2015 +0100

    - patch from Debian to fix building with libstatgrab >= 0.90
    - updated BRs
    - rel 6

 libstatgrab-0.90.patch | 57 ++++++++++++++++++++++++++++++++++++++++++++++++++
 razor-qt.spec          |  9 +++++---
 2 files changed, 63 insertions(+), 3 deletions(-)
---
diff --git a/razor-qt.spec b/razor-qt.spec
index 323e78c..b87b589 100644
--- a/razor-qt.spec
+++ b/razor-qt.spec
@@ -6,12 +6,13 @@ Summary:	Razor a lightweight desktop toolbox
 Summary(pl.UTF-8):	Razor jest lekkim zestawem narzędzi na biurko
 Name:		razor-qt
 Version:	0.5.2
-Release:	5
+Release:	6
 License:	GPL v2+
 Group:		X11/Applications
 Source0:	http://razor-qt.org/downloads/razorqt-%{version}.tar.bz2
 # Source0-md5:	8b2da8ab69065926bfc998cf1960bffb
 Patch0:		lightdm-1.7.patch
+Patch1:		libstatgrab-0.90.patch
 URL:		http://www.razor-qt.org/
 BuildRequires:	QtCore-devel >= %{qtver}
 BuildRequires:	QtDBus-devel >= %{qtver}
@@ -22,12 +23,13 @@ BuildRequires:	automoc4
 BuildRequires:	cmake
 BuildRequires:	desktop-file-utils
 BuildRequires:	libmagic-devel
-BuildRequires:	libstatgrab-devel
+BuildRequires:	libstatgrab-devel >= 0.90
 BuildRequires:	libstdc++-devel
-BuildRequires:	lightdm-libs-qt-devel
+BuildRequires:	lightdm-libs-qt4-devel
 BuildRequires:	pkgconfig
 BuildRequires:	polkit-qt-1-agent-devel
 BuildRequires:	polkit-qt-1-devel
+BuildRequires:	polkit-qt-1-gui-devel
 BuildRequires:	qt4-build >= %{qtver}
 BuildRequires:	qt4-linguist
 BuildRequires:	qt4-qmake >= %{qtver}
@@ -65,6 +67,7 @@ Pakiet programistyczny RazorQt.
 %prep
 %setup -q -n razorqt-%{version}
 %patch0 -p1
+%patch1 -p1
 
 %build
 install -d build
diff --git a/libstatgrab-0.90.patch b/libstatgrab-0.90.patch
new file mode 100644
index 0000000..d168e56
--- /dev/null
+++ b/libstatgrab-0.90.patch
@@ -0,0 +1,57 @@
+--- a/razorqt-panel/plugin-networkmonitor/razornetworkmonitor.cpp
++++ b/razorqt-panel/plugin-networkmonitor/razornetworkmonitor.cpp
+@@ -45,7 +45,7 @@
+     addWidget(&m_stuff);
+ 
+     /* Initialise statgrab */
+-    sg_init();
++    sg_init(1);
+ 
+     m_iconList << "modem" << "monitor"
+                << "network" << "wireless";
+@@ -72,11 +72,11 @@
+ {
+     bool matched = false;
+ 
+-    int num_network_stats;
++    size_t num_network_stats;
+ 
+     sg_network_io_stats *network_stats = sg_get_network_io_stats_diff(&num_network_stats);
+ 
+-    for (int x = 0; x < num_network_stats; x++)
++    for (size_t x = 0; x < num_network_stats; x++)
+     {
+         if (m_interface == QString::fromLocal8Bit(network_stats->interface_name))
+         {
+@@ -129,9 +129,9 @@
+ {
+     if (event->type() == QEvent::ToolTip)
+     {
+-        int num_network_stats;
++        size_t num_network_stats;
+         sg_network_io_stats *network_stats = sg_get_network_io_stats(&num_network_stats);
+-        for (int x = 0; x < num_network_stats; x++)
++        for (size_t x = 0; x < num_network_stats; x++)
+         {
+             if (m_interface == QString::fromLocal8Bit(network_stats->interface_name))
+             {
+--- a/razorqt-panel/plugin-cpuload/razorcpuload.cpp
++++ b/razorqt-panel/plugin-cpuload/razorcpuload.cpp
+@@ -52,7 +52,7 @@
+ 	addWidget(&m_stuff);
+ 
+ 	/* Initialise statgrab */
+-	sg_init();
++	sg_init(1);
+ 
+ 	/* Drop setuid/setgid privileges. */
+ 	if (sg_drop_privileges() != 0) {
+@@ -89,7 +89,7 @@
+ 
+ double RazorCpuLoad::getLoadCpu() const
+ {
+-	sg_cpu_percents* cur = sg_get_cpu_percents();
++	sg_cpu_percents* cur = sg_get_cpu_percents(NULL);
+ 	return (cur->user + cur->kernel + cur->nice);
+ }
+ 
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/razor-qt.git/commitdiff/d6c935ea4877387f716235f6b7bf2ace1dc803ed



More information about the pld-cvs-commit mailing list