Fix serverel gcc 4.3 related build failures.

git-svn-id: svn://svn.openwrt.org/openwrt/packages@14823 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
lars 2009-03-09 20:00:14 +00:00
parent bf610c5646
commit 4dea6a9e1e
9 changed files with 159 additions and 1 deletions

View File

@ -0,0 +1,25 @@
diff --git a/src/address.cpp b/src/address.cpp
index 453ad42..9f4cf46 100644
--- a/src/address.cpp
+++ b/src/address.cpp
@@ -28,6 +28,8 @@
#include <arpa/inet.h>
#include <cstdio>
+#include <cstring>
+#include <cstdlib>
base_stream &operator << (base_stream &os, const inet6_addr &addr) {
os.commit_change(addr.print_string(os.req_buffer(64), 64));
diff --git a/include/mrd/address.h b/include/mrd/address.h
index 80c8e45..1d2a495 100644
--- a/include/mrd/address.h
+++ b/include/mrd/address.h
@@ -31,6 +31,7 @@
#include <map>
#include <string>
#include <vector>
+#include <cstring>
class base_stream;

View File

@ -0,0 +1,12 @@
diff --git a/libport/semaphore.hxx b/libport/semaphore.hxx
index bb2546d..38b0d8e 100644
--- a/libport/semaphore.hxx
+++ b/libport/semaphore.hxx
@@ -5,6 +5,7 @@
# include "exception.hh"
# include <sstream>
# include <string>
+# include <cstring>
namespace libport
{

View File

@ -0,0 +1,25 @@
diff --git a/plugins/video/common/trace.cxx b/plugins/video/common/trace.cxx
index 7262478..de641af 100644
--- a/plugins/video/common/trace.cxx
+++ b/plugins/video/common/trace.cxx
@@ -30,6 +30,7 @@
/*****************************************************************************/
#include "trace.h"
+#include <cstring>
#ifdef __MACOSX__
#include <libgen.h>
diff --git a/plugins/video/H.263-ffmpeg/h263ffmpeg.cxx b/plugins/video/H.263-ffmpeg/h263ffmpeg.cxx
index 4a17b2c..a2f051c 100644
--- a/plugins/video/H.263-ffmpeg/h263ffmpeg.cxx
+++ b/plugins/video/H.263-ffmpeg/h263ffmpeg.cxx
@@ -54,6 +54,8 @@
#define _CRT_NONSTDC_NO_WARNINGS
#define _CRT_SECURE_NO_DEPRECATE
#include <codec/opalplugin.h>
+#include <cstdio>
+#include <climits>
#include <stdlib.h>
#ifdef _WIN32

View File

@ -0,0 +1,13 @@
diff --git a/src/ptclib/sockagg.cxx b/src/ptclib/sockagg.cxx
index a8f89d2..c1960f6 100644
--- a/src/ptclib/sockagg.cxx
+++ b/src/ptclib/sockagg.cxx
@@ -38,6 +38,7 @@
#include <ptlib.h>
#include <ptclib/sockagg.h>
-
+#include <algorithm>
+
#define new PNEW

View File

@ -0,0 +1,13 @@
diff --git a/src/ExternalConnector.h b/src/ExternalConnector.h
index 3d214f6..30d12a7 100644
--- a/src/ExternalConnector.h
+++ b/src/ExternalConnector.h
@@ -143,7 +143,7 @@ public:
bool Parse_Command(const wxString& buffer);
void GetCommand(const wxString &prompt, char* buffer, size_t buffer_size);
const CECPacket *SendRecvMsg_v2(const CECPacket *request) { return m_ECClient->SendRecvPacket(request); }
- void ConnectAndRun(const wxString &ProgName, const wxString& ProgName);
+ void ConnectAndRun(const wxString &ProgName, const wxString& ProgVersion);
void ShowGreet();
//

View File

@ -10,7 +10,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=mutella
PKG_VERSION:=0.4.5
PKG_RELEASE:=2
PKG_RELEASE:=3
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=@SF/$(PKG_NAME)

View File

@ -0,0 +1,34 @@
diff --git a/mutella/common.h b/mutella/common.h
--- a/mutella/common.h
+++ b/mutella/common.h
@@ -50,7 +50,7 @@ CString restore_string(CString s, bool bFormMode = true);
bool QueryMatch(CString Result, const CString& Query);
// fast functions which do not copy the string
void MakeWordList(LPSTR szQuery, vector<char*>& QWords);
-void MakeWordList(LPSTR szQuery, vector<char*>& QWords, vector<char*>& QWords);
+void MakeWordList(LPSTR szQuery, vector<char*>& QWordsInc, vector<char*>&QWordsExc);
bool MatchWordList(const CString& ResultLower, const vector<char*>& QWords, bool bMatchAll = true);
// slower but 'storage-independent' versions
diff --git a/mutella/mutella.h b/mutella/mutella.h
--- a/mutella/mutella.h
+++ b/mutella/mutella.h
@@ -79,6 +79,7 @@ using std::insert_iterator;
#include <arpa/inet.h>
#include <netdb.h>
#include <errno.h>
+#include <cstring>
// library-type includes
#include "defines.h"
diff --git a/mutella/tstring.h b/mutella/tstring.h
--- a/mutella/tstring.h
+++ b/mutella/tstring.h
@@ -22,6 +22,7 @@
#define __TSTRING_H__INCLUDED__
#include <stdarg.h>
+#include <climits>
#include <iostream>
#ifdef TSTRING_DEBUG

View File

@ -0,0 +1,24 @@
diff --git a/Main.cpp b/Main.cpp
index 0a5ae59..0c5274c 100755
--- a/Main.cpp
+++ b/Main.cpp
@@ -25,6 +25,7 @@
#include <signal.h>
#include <iostream>
#include <fstream>
+#include <cstring>
using namespace PG;
using namespace std;
diff --git a/PeerGuard.h b/PeerGuard.h
index 3d0d31c..7e1d0f7 100755
--- a/PeerGuard.h
+++ b/PeerGuard.h
@@ -24,6 +24,7 @@
#include "BlockList.h"
#include <ostream>
+#include <cstring>
namespace PG {

View File

@ -0,0 +1,12 @@
diff --git a/src/tctool.cpp b/src/tctool.cpp
index bbab13f..9ce8e5c 100644
--- a/src/tctool.cpp
+++ b/src/tctool.cpp
@@ -33,6 +33,7 @@
#include <string.h>
#include <unistd.h>
#include <signal.h>
+#include <cstdlib>
std::string options = "I:m:i:r:t:p:c:MUdsSCRh";
std::string ethDev = "eth0";