summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/xmlrpc-c-1-fixes.patch109
-rw-r--r--src/xmlrpc-c.mk37
2 files changed, 146 insertions, 0 deletions
diff --git a/src/xmlrpc-c-1-fixes.patch b/src/xmlrpc-c-1-fixes.patch
new file mode 100644
index 0000000..f0f9efe
--- /dev/null
+++ b/src/xmlrpc-c-1-fixes.patch
@@ -0,0 +1,109 @@
+This file is part of MXE.
+See index.html for further information.
+
+Index: stable/lib/curl_transport/curltransaction.c
+===================================================================
+--- stable/lib/curl_transport/curltransaction.c (revision 2571)
++++ stable/lib/curl_transport/curltransaction.c (working copy)
+@@ -2,8 +2,6 @@
+ curlTransaction
+ =============================================================================*/
+
+-#define _XOPEN_SOURCE 600 /* Make sure strdup() is in <string.h> */
+-
+ #include <assert.h>
+ #include <string.h>
+ #include <stdlib.h>
+Index: stable/lib/expat/xmlparse/xmlparse.c
+===================================================================
+--- stable/lib/expat/xmlparse/xmlparse.c (revision 2571)
++++ stable/lib/expat/xmlparse/xmlparse.c (working copy)
+@@ -4547,14 +4547,6 @@
+
+
+ int
+-XML_SetHashSalt(XML_Parser parser,
+- unsigned long hash_salt)
+-{
+- hash_secret_salt = hash_salt;
+- return 1;
+-}
+-
+-int
+ xmlrpc_XML_Parse(XML_Parser const xmlParserP,
+ const char * const s,
+ size_t const len,
+Index: stable/lib/expat/xmlparse/xmlparse.h
+===================================================================
+--- stable/lib/expat/xmlparse/xmlparse.h (revision 2571)
++++ stable/lib/expat/xmlparse/xmlparse.h (working copy)
+@@ -491,8 +491,6 @@
+ function behavior. This must be called before parsing is started.
+ Returns 1 if successful, 0 when called after parsing has started.
+ */
+-int
+-XML_SetHashSalt(XML_Parser parser, unsigned long hash_salt);
+
+ enum XML_Error {
+ XML_ERROR_NONE,
+Index: stable/src/cpp/packetsocket.cpp
+===================================================================
+--- stable/src/cpp/packetsocket.cpp (revision 2571)
++++ stable/src/cpp/packetsocket.cpp (working copy)
+@@ -45,7 +45,7 @@
+ example, an unplugged TCP/IP network cable. It's probably better
+ to use the TCP keepalive facility for that.
+ ============================================================================*/
+-#include "xmlrpc_config.h"
++#define MSVCRT 1
+
+ #include <cassert>
+ #include <string>
+Index: stable/src/cpp/server_abyss.cpp
+===================================================================
+--- stable/src/cpp/server_abyss.cpp (revision 2571)
++++ stable/src/cpp/server_abyss.cpp (working copy)
+@@ -1,4 +1,4 @@
+-#include "xmlrpc_config.h"
++#define MSVCRT 1
+ #define WIN32_LEAN_AND_MEAN /* required by xmlrpc-c/abyss.h */
+ #include <cstdlib>
+ #include <string>
+Index: stable/src/cpp/server_cgi.cpp
+===================================================================
+--- stable/src/cpp/server_cgi.cpp (revision 2571)
++++ stable/src/cpp/server_cgi.cpp (working copy)
+@@ -12,7 +12,7 @@
+ Contributed to the public domain by its author.
+ =============================================================================*/
+
+-#include "xmlrpc_config.h"
++#define MSVCRT 1
+ #if MSVCRT
+ #ifndef _CRT_SECURE_NO_WARNINGS
+ #define _CRT_SECURE_NO_WARNINGS
+Index: stable/src/cpp/server_pstream.cpp
+===================================================================
+--- stable/src/cpp/server_pstream.cpp (revision 2571)
++++ stable/src/cpp/server_pstream.cpp (working copy)
+@@ -14,7 +14,7 @@
+ Contributed to the public domain by its author.
+ =============================================================================*/
+
+-#include "xmlrpc_config.h"
++#define MSVCRT 1
+ #if MSVCRT
+ #ifndef _CRT_SECURE_NO_WARNINGS
+ #define _CRT_SECURE_NO_WARNINGS
+Index: stable/src/xmlrpc_datetime.c
+===================================================================
+--- stable/src/xmlrpc_datetime.c (revision 2571)
++++ stable/src/xmlrpc_datetime.c (working copy)
+@@ -1,7 +1,5 @@
+ #include "xmlrpc_config.h"
+
+-#define _XOPEN_SOURCE 600 /* Make sure strdup() is in <string.h> */
+-
+ #include <time.h>
+ #include <stdlib.h>
+ #include <string.h>
diff --git a/src/xmlrpc-c.mk b/src/xmlrpc-c.mk
new file mode 100644
index 0000000..7b1002c
--- /dev/null
+++ b/src/xmlrpc-c.mk
@@ -0,0 +1,37 @@
+# This file is part of MXE.
+# See index.html for further information.
+
+PKG := xmlrpc-c
+$(PKG)_IGNORE :=
+$(PKG)_VERSION := 1.33.7
+$(PKG)_CHECKSUM := 2f1b1ac796247d412ebdbfa5d0a91dc286da6820
+$(PKG)_SUBDIR := xmlrpc-c-$($(PKG)_VERSION)
+$(PKG)_FILE := xmlrpc-c-$($(PKG)_VERSION).tgz
+# there is no .tgz for the "stable" branch on sourceforge.net so I have created one myself and put it on my server.
+# is there a way to pull from the sourceforge.net svn instead ?
+$(PKG)_URL := http://doido.aline.nu/~lars/src/$($(PKG)_FILE)
+$(PKG)_DEPS := curl pthreads
+
+define $(PKG)_UPDATE
+ $(WGET) -q -O- 'http://sourceforge.net/p/xmlrpc-c/svn/HEAD/tree/release_number/' | \
+ grep '<a href="' | \
+ $(SED) -n 's,.*<a href="release-\([0-9][^"]*\)".*,\1,p' | \
+ tail -1
+endef
+
+TMP_BIN_DIR := $(realpath .)/tmp-$(PKG)/curl-bin
+
+define $(PKG)_BUILD
+ cd '$(1)' && ./configure \
+ --host='$(TARGET)' \
+ --prefix='$(PREFIX)/$(TARGET)' \
+ --enable-curl-client \
+ --enable-abyss-server \
+ --enable-cgi-server \
+ --enable-cplusplus \
+ --enable-abyss-threads
+
+ mkdir $(TMP_BIN_DIR); cd $(TMP_BIN_DIR); ln -s $(PREFIX)/$(TARGET)/bin/curl-config
+ PATH=$(TMP_BIN_DIR):$(PATH) $(MAKE) -C '$(1)' -j '$(JOBS)' BUILDTOOL_CC=gcc BUILDTOOL_CCLD=gcc
+ $(MAKE) -C '$(1)' -j '$(JOBS)' install
+endef