From f7ad4a203ad184d97002111f4ffb8bfe6a8f7c01 Mon Sep 17 00:00:00 2001 From: Martin Sustrik Date: Mon, 14 Sep 2009 17:04:57 +0200 Subject: forwarder device compilable on windows --- foreign/xmlParser/xmlParser.cpp | 12 ++- msvc/forwarder/forwarder.vcproj | 174 ++++++++++++++++++++++++++++++++++++++++ msvc/msvc.sln | 9 +++ python/pyzmq.cpp | 3 - ruby/rbzmq.cpp | 3 +- 5 files changed, 196 insertions(+), 5 deletions(-) create mode 100644 msvc/forwarder/forwarder.vcproj diff --git a/foreign/xmlParser/xmlParser.cpp b/foreign/xmlParser/xmlParser.cpp index 2414c01..b9ebe54 100644 --- a/foreign/xmlParser/xmlParser.cpp +++ b/foreign/xmlParser/xmlParser.cpp @@ -78,10 +78,16 @@ * **************************************************************************** */ + +#if defined _MSC_VER +#pragma warning (push) +#pragma warning (disable:4996) +#endif + #ifndef _CRT_SECURE_NO_DEPRECATE #define _CRT_SECURE_NO_DEPRECATE #endif -#include +#include "xmlParser.hpp" #ifdef _XMLWINDOWS //#ifdef _DEBUG //#define _CRTDBG_MAP_ALLOC @@ -2886,3 +2892,7 @@ unsigned char *XMLParserBase64Tool::decode(XMLCSTR data, int *outlen, XMLError * return (unsigned char*)buf; } +#if defined _MSC_VER +#pragma warning (pop) +#endif + diff --git a/msvc/forwarder/forwarder.vcproj b/msvc/forwarder/forwarder.vcproj new file mode 100644 index 0000000..4e704b9 --- /dev/null +++ b/msvc/forwarder/forwarder.vcproj @@ -0,0 +1,174 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/msvc/msvc.sln b/msvc/msvc.sln index 842ee9b..139a8df 100644 --- a/msvc/msvc.sln +++ b/msvc/msvc.sln @@ -73,6 +73,11 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "python", "python\python.vcp {641C5F36-32EE-4323-B740-992B651CF9D6} = {641C5F36-32EE-4323-B740-992B651CF9D6} EndProjectSection EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "forwarder", "forwarder\forwarder.vcproj", "{7529DFB2-685C-4534-B40E-0B148509178A}" + ProjectSection(ProjectDependencies) = postProject + {641C5F36-32EE-4323-B740-992B651CF9D6} = {641C5F36-32EE-4323-B740-992B651CF9D6} + EndProjectSection +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Win32 = Debug|Win32 @@ -138,6 +143,10 @@ Global {CB9B47E2-3F9C-45B2-9C30-C27038CDB856}.Debug|Win32.ActiveCfg = Debug|Win32 {CB9B47E2-3F9C-45B2-9C30-C27038CDB856}.Release|Win32.ActiveCfg = Release|Win32 {CB9B47E2-3F9C-45B2-9C30-C27038CDB856}.Release|Win32.Build.0 = Release|Win32 + {7529DFB2-685C-4534-B40E-0B148509178A}.Debug|Win32.ActiveCfg = Debug|Win32 + {7529DFB2-685C-4534-B40E-0B148509178A}.Debug|Win32.Build.0 = Debug|Win32 + {7529DFB2-685C-4534-B40E-0B148509178A}.Release|Win32.ActiveCfg = Release|Win32 + {7529DFB2-685C-4534-B40E-0B148509178A}.Release|Win32.Build.0 = Release|Win32 EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/python/pyzmq.cpp b/python/pyzmq.cpp index a373988..93b8b8f 100644 --- a/python/pyzmq.cpp +++ b/python/pyzmq.cpp @@ -484,9 +484,6 @@ PyMODINIT_FUNC initlibpyzmq () t = PyInt_FromLong (ZMQ_SWAP); PyDict_SetItemString (dict, "SWAP", t); Py_DECREF (t); - t = PyInt_FromLong (ZMQ_MASK); - PyDict_SetItemString (dict, "MASK", t); - Py_DECREF (t); t = PyInt_FromLong (ZMQ_AFFINITY); PyDict_SetItemString (dict, "AFFINITY", t); Py_DECREF (t); diff --git a/ruby/rbzmq.cpp b/ruby/rbzmq.cpp index 8837aa1..5d679b9 100644 --- a/ruby/rbzmq.cpp +++ b/ruby/rbzmq.cpp @@ -280,11 +280,12 @@ extern "C" void Init_librbzmq () rb_define_global_const ("HWM", INT2NUM (ZMQ_HWM)); rb_define_global_const ("LWM", INT2NUM (ZMQ_LWM)); rb_define_global_const ("SWAP", INT2NUM (ZMQ_SWAP)); - rb_define_global_const ("MASK", INT2NUM (ZMQ_MASK)); rb_define_global_const ("AFFINITY", INT2NUM (ZMQ_AFFINITY)); rb_define_global_const ("IDENTITY", INT2NUM (ZMQ_IDENTITY)); + rb_define_global_const ("NOBLOCK", INT2NUM (ZMQ_NOBLOCK)); rb_define_global_const ("NOFLUSH", INT2NUM (ZMQ_NOFLUSH)); + rb_define_global_const ("P2P", INT2NUM (ZMQ_P2P)); rb_define_global_const ("SUB", INT2NUM (ZMQ_SUB)); rb_define_global_const ("PUB", INT2NUM (ZMQ_PUB)); -- cgit v1.2.3