[matahari] fix compile with recent gcc

Tom Callaway spot at fedoraproject.org
Sun Sep 19 23:31:24 UTC 2010


commit 1885c54b43b404d0a254382e68ae313a78e9d136
Author: Tom "spot" Callaway <tcallawa at redhat.com>
Date:   Mon Sep 20 01:31:15 2010 +0200

    fix compile with recent gcc

 matahari-0.0.5-gcc-fix.patch |   50 ++++++++++++++++++++++++++++++++++++++++++
 matahari.spec                |    6 ++++-
 2 files changed, 55 insertions(+), 1 deletions(-)
---
diff --git a/matahari-0.0.5-gcc-fix.patch b/matahari-0.0.5-gcc-fix.patch
new file mode 100644
index 0000000..f342140
--- /dev/null
+++ b/matahari-0.0.5-gcc-fix.patch
@@ -0,0 +1,50 @@
+diff -up matahari-0.0.5/src/host.cpp.gcc matahari-0.0.5/src/host.cpp
+--- matahari-0.0.5/src/host.cpp.gcc	2010-09-20 01:08:26.476255002 +0200
++++ matahari-0.0.5/src/host.cpp	2010-09-20 01:08:33.928255002 +0200
+@@ -24,6 +24,7 @@
+ #include <stdexcept>
+ 
+ #include <cstdlib>
++#include <limits.h>
+ #include <unistd.h>
+ 
+ #include <libvirt/libvirt.h>
+diff -up matahari-0.0.5/src/main.cpp.gcc matahari-0.0.5/src/main.cpp
+--- matahari-0.0.5/src/main.cpp.gcc	2010-09-20 01:08:56.444254998 +0200
++++ matahari-0.0.5/src/main.cpp	2010-09-20 01:12:23.486255002 +0200
+@@ -22,12 +22,13 @@
+ 
+ #include <iostream>
+ #include <fstream>
+-#include <string>
++#include <cstring>
+ #include <vector>
+ #include <exception>
+ 
+ #include <signal.h>
+ #include <cstdlib>
++#include <cerrno>
+ 
+ #include <getopt.h>
+ 
+@@ -81,7 +82,7 @@ int do_main(int argc, char **argv)
+     char *service = NULL;
+     int port = 5672;
+ 
+-    ConnectionSettings settings;
++    qpid::management::ConnectionSettings settings;
+     ManagementAgent *agent;
+     HostWrapper *hostWrapper;
+ 
+diff -up matahari-0.0.5/src/nic.cpp.gcc matahari-0.0.5/src/nic.cpp
+--- matahari-0.0.5/src/nic.cpp.gcc	2010-09-20 01:12:38.887255001 +0200
++++ matahari-0.0.5/src/nic.cpp	2010-09-20 01:12:44.412255003 +0200
+@@ -18,7 +18,7 @@
+  */
+ 
+ #include <iostream>
+-#include <string>
++#include <cstring>
+ #include <sstream>
+ #include <vector>
+ #include <stdexcept>
diff --git a/matahari.spec b/matahari.spec
index 1bba95f..94e0eb5 100644
--- a/matahari.spec
+++ b/matahari.spec
@@ -1,12 +1,13 @@
 Summary: Qpid QMF Agent for Ovirt Nodes
 Name: matahari
 Version: 0.0.5
-Release: 2%{?dist}
+Release: 3%{?dist}
 Source: http://mcpierce.fedorapeople.org/sources/matahari-%{version}.tar.gz
 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
 License: GPLv2
 Group: Applications/System
 URL: http://matahari.fedorahosted.org/
+Patch0: matahari-0.0.5-gcc-fix.patch
 
 Requires: dbus >= 1.2.12
 Requires: hal >= 0.5.12
@@ -37,6 +38,7 @@ as a set of objects with properties and methods.
 
 %prep
 %setup -q
+%patch0 -p1 -b .gcc
 
 %build
 %configure
@@ -76,6 +78,8 @@ test "x%{buildroot}" != "x" && rm -rf %{buildroot}
 %doc AUTHORS COPYING
 
 %changelog
+* Mon Sep 20 2010 Tom "spot" Callaway <tcallawa at redhat.com> - 0.0.5-3
+- fix header and compiler issues in code which were preventing build
 
 * Mon Aug 16 2010 Darryl L. Pierce <dpierce at redhat.com> - 0.0.5-2
 - Rebuild for updated Qpid/WMF.


More information about the scm-commits mailing list