diff options
| author | Charles E. Rolke <chug@apache.org> | 2011-08-04 20:17:09 +0000 |
|---|---|---|
| committer | Charles E. Rolke <chug@apache.org> | 2011-08-04 20:17:09 +0000 |
| commit | e95be9c27959221fce9d501eab220be81d786983 (patch) | |
| tree | 6e6f74a5f607730b7b4738a11ab218ef2d510848 /qpid/cpp/src/tests/SessionState.cpp | |
| parent | 427d1f82fd7ee9d6f4ad573330c85bd2fd30547d (diff) | |
| download | qpid-python-e95be9c27959221fce9d501eab220be81d786983.tar.gz | |
QPID-2643 Building QPID with Visual Studio 2010
This patch changes:
List.h - add a typedef from the original post
IntegerTypes.h - adds 'signed' to int_8 to avoid MSVC complaint
SessionState.cpp, qpid-perftest.cpp - adds explicit boost:: to disambiguate methods recently defined by 'using std'.
CMakeLists.txt -
Adds a CMake option that allows user to include '#define _WIN32_WINNT=0x0502' or not.
Linux users see no change.
This replaces CMake code that includes a similar definition when the build system _has VS2005 installed_.
Even if the Generator is VS2010 the def was added because VS2005 is installed. This in not right.
Without this definition several components define _WIN32_WINNT=0x0501 to target network and system api components.
Those components will still work correctly with 0x0502.
Defining _WIN32_WINNT=0x0501 across the board causes a build error in cpp\qpid\store that 0x0502 avoids.
This patch will move the minimum required version of Windows from WinXP to WinXP-SP3.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1153993 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/cpp/src/tests/SessionState.cpp')
| -rw-r--r-- | qpid/cpp/src/tests/SessionState.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/qpid/cpp/src/tests/SessionState.cpp b/qpid/cpp/src/tests/SessionState.cpp index 157cabfb63..3be9bb0cbc 100644 --- a/qpid/cpp/src/tests/SessionState.cpp +++ b/qpid/cpp/src/tests/SessionState.cpp @@ -43,7 +43,7 @@ using namespace qpid::framing; // Apply f to [begin, end) and accumulate the result template <class Iter, class T, class F> T applyAccumulate(Iter begin, Iter end, T seed, const F& f) { - return std::accumulate(begin, end, seed, bind(std::plus<T>(), _1, bind(f, _2))); + return std::accumulate(begin, end, seed, boost::bind(std::plus<T>(), _1, boost::bind(f, _2))); } // Create a frame with a one-char string. @@ -105,8 +105,8 @@ size_t transferN(qpid::SessionState& s, string content) { char last = content[content.size()-1]; content.resize(content.size()-1); size += applyAccumulate(content.begin(), content.end(), 0, - bind(&send, ref(s), - bind(contentFrameChar, _1, false))); + boost::bind(&send, boost::ref(s), + boost::bind(contentFrameChar, _1, false))); size += send(s, contentFrameChar(last, true)); } return size; @@ -115,7 +115,7 @@ size_t transferN(qpid::SessionState& s, string content) { // Send multiple transfers with single-byte content. size_t transfers(qpid::SessionState& s, string content) { return applyAccumulate(content.begin(), content.end(), 0, - bind(transfer1Char, ref(s), _1)); + boost::bind(transfer1Char, boost::ref(s), _1)); } size_t contentFrameSize(size_t n=1) { return AMQFrame(( AMQContentBody())).encodedSize() + n; } |
