[sblim-wbemcli] Fix gcc47 compile failure

vcrhonek vcrhonek at fedoraproject.org
Thu Jan 5 13:01:32 UTC 2012


commit c8f42866a8b41cac8b3a0b8fa9395ea34741c77c
Author: Vitezslav Crhonek <vcrhonek at redhat.com>
Date:   Thu Jan 5 14:01:23 2012 +0100

    Fix gcc47 compile failure

 sblim-wbemcli-1.6.2-gcc47.patch |   26 ++++++++++++++++++++++++++
 sblim-wbemcli.spec              |    7 ++++++-
 2 files changed, 32 insertions(+), 1 deletions(-)
---
diff --git a/sblim-wbemcli-1.6.2-gcc47.patch b/sblim-wbemcli-1.6.2-gcc47.patch
new file mode 100644
index 0000000..8e6b5b6
--- /dev/null
+++ b/sblim-wbemcli-1.6.2-gcc47.patch
@@ -0,0 +1,26 @@
+diff -up sblim-wbemcli-1.6.2/CimCurl.h.orig sblim-wbemcli-1.6.2/CimCurl.h
+--- sblim-wbemcli-1.6.2/CimCurl.h.orig	2012-01-05 13:55:30.901154659 +0100
++++ sblim-wbemcli-1.6.2/CimCurl.h	2012-01-05 13:55:44.723271863 +0100
+@@ -24,6 +24,7 @@
+ #include "CimXml.h"
+ #include <curl/curl.h>
+ #include <sstream>
++#include <unistd.h>
+ 
+ 
+ class CimomCurl : public Cimom {
+diff -up sblim-wbemcli-1.6.2/CimXml.h.orig sblim-wbemcli-1.6.2/CimXml.h
+--- sblim-wbemcli-1.6.2/CimXml.h.orig	2012-01-05 13:54:52.445828446 +0100
++++ sblim-wbemcli-1.6.2/CimXml.h	2012-01-05 13:54:52.449828480 +0100
+@@ -129,9 +129,9 @@ template<class T> class ArrayXml : publi
+   public:
+    ArrayXml() {}
+    ArrayXml<T> * clone() const { return new ArrayXml<T>(*this);}
+-   void add(const T& t) { push_back(t); }
++   void add(const T& t) { this->push_back(t); }
+ #if !defined(GCC_VERSION) || GCC_VERSION >= 3000
+-   T& operator[] (size_type n) {return at(n);}
++   T& operator[] (size_type n) {return this->at(n);}
+    const T& operator[] (size_type n) const {return at(n);}
+ #endif
+    T *get(int n)    { return &(*this)[n]; }
diff --git a/sblim-wbemcli.spec b/sblim-wbemcli.spec
index ebe74f2..d7aac73 100644
--- a/sblim-wbemcli.spec
+++ b/sblim-wbemcli.spec
@@ -1,6 +1,6 @@
 Name:           sblim-wbemcli
 Version:        1.6.2
-Release:        1%{?dist}
+Release:        2%{?dist}
 Summary:        SBLIM WBEM Command Line Interface
 
 Group:          Applications/System
@@ -8,6 +8,7 @@ License:        EPL
 URL:            http://sblim.wiki.sourceforge.net/
 Source0:        http://downloads.sourceforge.net/sblim/%{name}-%{version}.tar.bz2
 Patch0:         sblim-wbemcli-1.5.1-gcc43.patch
+Patch1:         sblim-wbemcli-1.6.2-gcc47.patch
 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
 BuildRequires:  curl-devel >= 7.9.3
@@ -22,6 +23,7 @@ scripts.
 %prep
 %setup -q
 %patch0 -p1 -b .gcc43
+%patch1 -p1 -b .gcc47
 
 %build
 %configure CACERT=/etc/Pegasus/client.pem
@@ -43,6 +45,9 @@ rm -rf $RPM_BUILD_ROOT
 %{_datadir}/%{name}
 
 %changelog
+* Thu Jan 05 2012 Vitezslav Crhonek <vcrhonek at redhat.com> - 1.6.2-2
+- Fix gcc47 compile failure
+
 * Tue Jul 19 2011 Vitezslav Crhonek <vcrhonek at redhat.com> - 1.6.2-1
 - Update to sblim-wbemcli-1.6.2
 


More information about the scm-commits mailing list