etch-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vei...@apache.org
Subject svn commit: r1460566 [3/3] - in /etch/trunk: binding-cpp/compiler/src/main/resources/org/apache/etch/bindings/cpp/compiler/ binding-cpp/runtime/ binding-cpp/runtime/include/common/ binding-cpp/runtime/include/serialization/ binding-cpp/runtime/include/...
Date Mon, 25 Mar 2013 09:43:46 GMT
Modified: etch/trunk/binding-cpp/runtime/src/test/support/EtchRemoteBaseTest.cpp
URL: http://svn.apache.org/viewvc/etch/trunk/binding-cpp/runtime/src/test/support/EtchRemoteBaseTest.cpp?rev=1460566&r1=1460565&r2=1460566&view=diff
==============================================================================
--- etch/trunk/binding-cpp/runtime/src/test/support/EtchRemoteBaseTest.cpp (original)
+++ etch/trunk/binding-cpp/runtime/src/test/support/EtchRemoteBaseTest.cpp Mon Mar 25 09:43:41
2013
@@ -326,9 +326,8 @@ TEST_F(EtchRemoteBaseTest, endCallTest) 
   EXPECT_TRUE(ETCH_OK == replyMessage->getInReplyToMessageId(id));
   capu::SmartPointer<EtchMessage> replymess = replyMessage;
   capu::SmartPointer<EtchObject> data = new EtchLong(123);
-  capu::SmartPointer<EtchObject> old;
   EtchField field = replyType->getResponseField();
-  replyMessage->put(field, data, &old);
+  replyMessage->put(field, data);
   //call the sessionMessage of mailbox manager as if it is called from messagizer to deliver
data from
   EXPECT_TRUE(ETCH_OK == manager->sessionMessage(NULL, replymess));
   capu::SmartPointer<EtchObject> result;

Modified: etch/trunk/binding-cpp/runtime/src/test/transport/EtchDefaultDeliveryServiceTest.cpp
URL: http://svn.apache.org/viewvc/etch/trunk/binding-cpp/runtime/src/test/transport/EtchDefaultDeliveryServiceTest.cpp?rev=1460566&r1=1460565&r2=1460566&view=diff
==============================================================================
--- etch/trunk/binding-cpp/runtime/src/test/transport/EtchDefaultDeliveryServiceTest.cpp (original)
+++ etch/trunk/binding-cpp/runtime/src/test/transport/EtchDefaultDeliveryServiceTest.cpp Mon
Mar 25 09:43:41 2013
@@ -248,7 +248,7 @@ TEST_F(EtchDefaultDeliveryServiceTest, e
   capu::SmartPointer<EtchObject> data = new EtchLong(123);
   capu::SmartPointer<EtchObject> old;
   EtchField field = replyType->getResponseField();
-  replymessage->put(field, data, &old);
+  replymessage->put(field, data);
 
   //call the sessionMessage of mailbox manager as if it is called from messagizer to deliver
data from
   status = mailboxManager->sessionMessage(NULL, replymessage);

Modified: etch/trunk/binding-cpp/runtime/src/test/transport/EtchMessageTest.cpp
URL: http://svn.apache.org/viewvc/etch/trunk/binding-cpp/runtime/src/test/transport/EtchMessageTest.cpp?rev=1460566&r1=1460565&r2=1460566&view=diff
==============================================================================
--- etch/trunk/binding-cpp/runtime/src/test/transport/EtchMessageTest.cpp (original)
+++ etch/trunk/binding-cpp/runtime/src/test/transport/EtchMessageTest.cpp Mon Mar 25 09:43:41
2013
@@ -192,7 +192,6 @@ TEST_F(EtchMessageTest, putTest) {
   capu::SmartPointer<EtchObject> object = new EtchBool(true);
   capu::SmartPointer<EtchObject> object2 = new EtchBool(false);
   capu::SmartPointer<EtchObject> object3 = NULL;
-  capu::SmartPointer<EtchObject> object4 = NULL;
 
   //check the empty struct value
   EXPECT_TRUE(sv->count() == 0);
@@ -203,7 +202,7 @@ TEST_F(EtchMessageTest, putTest) {
   EXPECT_TRUE(sv->put(field2, object2) == ETCH_OK);
   EXPECT_TRUE(sv->count() == 2);
   //add a null element and expect a remove operation
-  EXPECT_TRUE(sv->put(field1, object3, &object4) == ETCH_OK);
+  EXPECT_TRUE(sv->put(field1, object3) == ETCH_OK);
   EXPECT_TRUE(sv->count() == 1);
 
   delete sv;
@@ -239,7 +238,7 @@ TEST_F(EtchMessageTest, getTest) {
 
   //add another element
   capu::SmartPointer<EtchObject> object2 = new EtchBool(false);
-  EXPECT_TRUE(sv->put(field1, object2, &object) == ETCH_OK);
+  EXPECT_TRUE(sv->put(field1, object2) == ETCH_OK);
   EXPECT_TRUE(sv->count() == 1);
   //get element
   EXPECT_TRUE(sv->get(field1, &object) == ETCH_OK);

Modified: etch/trunk/binding-cpp/runtime/src/test/transport/EtchTcpConnectionTest.cpp
URL: http://svn.apache.org/viewvc/etch/trunk/binding-cpp/runtime/src/test/transport/EtchTcpConnectionTest.cpp?rev=1460566&r1=1460565&r2=1460566&view=diff
==============================================================================
--- etch/trunk/binding-cpp/runtime/src/test/transport/EtchTcpConnectionTest.cpp (original)
+++ etch/trunk/binding-cpp/runtime/src/test/transport/EtchTcpConnectionTest.cpp Mon Mar 25
09:43:41 2013
@@ -64,7 +64,7 @@ public:
     EtchString _socket("socket");
     EtchObject *tmp;
     resources.put(_socket, connection, tmp);
-    connection->send((unsigned char *) "mock", 4);
+    connection->send("mock", 4);
     socket = connection;
     return ETCH_OK;
   }

Modified: etch/trunk/binding-cpp/runtime/src/test/transport/EtchTcpListenerTest.cpp
URL: http://svn.apache.org/viewvc/etch/trunk/binding-cpp/runtime/src/test/transport/EtchTcpListenerTest.cpp?rev=1460566&r1=1460565&r2=1460566&view=diff
==============================================================================
--- etch/trunk/binding-cpp/runtime/src/test/transport/EtchTcpListenerTest.cpp (original)
+++ etch/trunk/binding-cpp/runtime/src/test/transport/EtchTcpListenerTest.cpp Mon Mar 25 09:43:41
2013
@@ -54,7 +54,7 @@ public:
     EtchString _socket("socket");
     EtchObject *tmp;
     resources.put(_socket, connection, tmp);
-    connection->send((unsigned char *) "mock", 4);
+    connection->send("mock", 4);
     delete connection;
     return ETCH_OK;
   }

Modified: etch/trunk/binding-cpp/runtime/src/test/util/EtchCircularQueueTest.cpp
URL: http://svn.apache.org/viewvc/etch/trunk/binding-cpp/runtime/src/test/util/EtchCircularQueueTest.cpp?rev=1460566&r1=1460565&r2=1460566&view=diff
==============================================================================
--- etch/trunk/binding-cpp/runtime/src/test/util/EtchCircularQueueTest.cpp (original)
+++ etch/trunk/binding-cpp/runtime/src/test/util/EtchCircularQueueTest.cpp Mon Mar 25 09:43:41
2013
@@ -156,9 +156,9 @@ TEST(EtchCirclerQueueTest, closeTest) {
 
 namespace {
 
-class R1 : public capu::Runnable {
+class Runnable1 : public capu::Runnable {
 public:
-  R1(EtchCircularQueue* queue) {
+  Runnable1(EtchCircularQueue* queue) {
     mQueue = queue;
   }
 
@@ -174,9 +174,9 @@ private:
   EtchCircularQueue* mQueue;
 };
 
-class R2 : public capu::Runnable {
+class Runnable2 : public capu::Runnable {
 public:
-  R2(EtchCircularQueue* queue) {
+  Runnable2(EtchCircularQueue* queue) {
     mQueue = queue;
   }
 
@@ -198,13 +198,13 @@ private:
 TEST(EtchCirclerQueueTest, concurrency) {
   EtchCircularQueue* queue = new EtchCircularQueue(5);
 
-  R1* r1 = new R1(queue);
-  capu::Thread* t1 = new capu::Thread(r1);
-  t1->start();
-
-  R2* r2 = new R2(queue);
-  capu::Thread* t2 = new capu::Thread(r2);
-  t2->start();
+  Runnable1* r1 = new Runnable1(queue);
+  capu::Thread* t1 = new capu::Thread();
+  t1->start(*r1);
+
+  Runnable2* r2 = new Runnable2(queue);
+  capu::Thread* t2 = new capu::Thread();
+  t2->start(*r2);
 
   t1->join();
   t2->join();

Modified: etch/trunk/binding-cpp/runtime/src/test/util/EtchUtilTest.cpp
URL: http://svn.apache.org/viewvc/etch/trunk/binding-cpp/runtime/src/test/util/EtchUtilTest.cpp?rev=1460566&r1=1460565&r2=1460566&view=diff
==============================================================================
--- etch/trunk/binding-cpp/runtime/src/test/util/EtchUtilTest.cpp (original)
+++ etch/trunk/binding-cpp/runtime/src/test/util/EtchUtilTest.cpp Mon Mar 25 09:43:41 2013
@@ -47,7 +47,7 @@ TEST(EtchUtilTest, etch_strcpy_s) {
 
 TEST(EtchUtilTest, etch_utf8_strlen) {
   const char utf8 [] = {(char)0xF0, (char)0xA4, (char)0xAD, (char)0xA2, (char)0xE2, (char)0x82,
(char)0xAC, (char)0xC2, (char)0xA2, (char)0x24, (char)0x0};
-  capu::int32_t dstSize = 0;
+  capu::uint32_t dstSize = 0;
 
   status_t retval = etch_strlen_utf8(NULL, dstSize);
   EXPECT_TRUE(retval == ETCH_EINVAL);

Modified: etch/trunk/binding-cpp/runtime/toolchains/Linux_ARMv7l.toolchain
URL: http://svn.apache.org/viewvc/etch/trunk/binding-cpp/runtime/toolchains/Linux_ARMv7l.toolchain?rev=1460566&r1=1460565&r2=1460566&view=diff
==============================================================================
--- etch/trunk/binding-cpp/runtime/toolchains/Linux_ARMv7l.toolchain (original)
+++ etch/trunk/binding-cpp/runtime/toolchains/Linux_ARMv7l.toolchain Mon Mar 25 09:43:41 2013
@@ -37,5 +37,7 @@ SET(CMAKE_FIND_ROOT_PATH /opt/pb-a8/stag
 SET(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
 SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
 
+add_definitions("-DTARGET_OS=Linux")
+add_definitions("-DTARGET_ARCH=ARMV7L")
 add_definitions("-DOS_LINUX")
 add_definitions("-DARCH_ARMV7L")

Modified: etch/trunk/binding-cpp/runtime/toolchains/Linux_X86_32.toolchain
URL: http://svn.apache.org/viewvc/etch/trunk/binding-cpp/runtime/toolchains/Linux_X86_32.toolchain?rev=1460566&r1=1460565&r2=1460566&view=diff
==============================================================================
--- etch/trunk/binding-cpp/runtime/toolchains/Linux_X86_32.toolchain (original)
+++ etch/trunk/binding-cpp/runtime/toolchains/Linux_X86_32.toolchain Mon Mar 25 09:43:41 2013
@@ -28,5 +28,7 @@ SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_C_FLA
 SET(CMAKE_C_FLAGS_RELEASE "-m32 -Wall -O3 -DNDEBUG")
 SET(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE}")
 
+add_definitions("-DTARGET_OS=Linux")
+add_definitions("-DTARGET_ARCH=X86_32")
 add_definitions("-DOS_LINUX")
 add_definitions("-DARCH_X86_32")

Modified: etch/trunk/binding-cpp/runtime/toolchains/Linux_X86_64.toolchain
URL: http://svn.apache.org/viewvc/etch/trunk/binding-cpp/runtime/toolchains/Linux_X86_64.toolchain?rev=1460566&r1=1460565&r2=1460566&view=diff
==============================================================================
--- etch/trunk/binding-cpp/runtime/toolchains/Linux_X86_64.toolchain (original)
+++ etch/trunk/binding-cpp/runtime/toolchains/Linux_X86_64.toolchain Mon Mar 25 09:43:41 2013
@@ -28,5 +28,7 @@ SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_C_FLA
 SET(CMAKE_C_FLAGS_RELEASE "-m64 -Wall -O3 -DNDEBUG")
 SET(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE}")
 
+add_definitions("-DTARGET_OS=Linux")
+add_definitions("-DTARGET_ARCH=X86_64")
 add_definitions("-DOS_LINUX")
 add_definitions("-DARCH_X86_64")

Copied: etch/trunk/binding-cpp/runtime/toolchains/MacOSX_X86_64.toolchain (from r1460564,
etch/trunk/binding-cpp/runtime/lib/capu/cmake/acme/toolchain/Linux_X86_64.toolchain)
URL: http://svn.apache.org/viewvc/etch/trunk/binding-cpp/runtime/toolchains/MacOSX_X86_64.toolchain?p2=etch/trunk/binding-cpp/runtime/toolchains/MacOSX_X86_64.toolchain&p1=etch/trunk/binding-cpp/runtime/lib/capu/cmake/acme/toolchain/Linux_X86_64.toolchain&r1=1460564&r2=1460566&rev=1460566&view=diff
==============================================================================
--- etch/trunk/binding-cpp/runtime/lib/capu/cmake/acme/toolchain/Linux_X86_64.toolchain (original)
+++ etch/trunk/binding-cpp/runtime/toolchains/MacOSX_X86_64.toolchain Mon Mar 25 09:43:41
2013
@@ -13,14 +13,14 @@
 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 # See the License for the specific language governing permissions and 
 # limitations under the License. 
-#
 
-SET(CMAKE_SYSTEM_NAME Linux)
+
+SET(CMAKE_SYSTEM_NAME MacOSX)
 SET(CMAKE_SYSTEM_VERSION 1)
 
-SET(TARGET_OS Linux)
-SET(TARGET_ARCH X86_64)
-SET(TARGET_COMPILER GCC)
+SET(TARGET_OS MacOSX)
+SET(TARGET_ARCH x86_64)
+# SET(TARGET_COMPILER GCC)
 
 SET(CMAKE_C_FLAGS_DEBUG "-m64 -ggdb -Wall -D_DEBUG")
 SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG}")
@@ -28,5 +28,7 @@ SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_C_FLA
 SET(CMAKE_C_FLAGS_RELEASE "-m64 -Wall -O3 -DNDEBUG")
 SET(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE}")
 
-add_definitions("-DOS_LINUX")
+add_definitions("-DTARGET_OS=MacOSX")
+add_definitions("-DTARGET_ARCH=X86_64")
+add_definitions("-DOS_MACOSX")
 add_definitions("-DARCH_X86_64")

Modified: etch/trunk/binding-cpp/runtime/toolchains/QNX_X86_32.toolchain
URL: http://svn.apache.org/viewvc/etch/trunk/binding-cpp/runtime/toolchains/QNX_X86_32.toolchain?rev=1460566&r1=1460565&r2=1460566&view=diff
==============================================================================
--- etch/trunk/binding-cpp/runtime/toolchains/QNX_X86_32.toolchain (original)
+++ etch/trunk/binding-cpp/runtime/toolchains/QNX_X86_32.toolchain Mon Mar 25 09:43:41 2013
@@ -23,7 +23,7 @@
 #   Windows: set PATH=%QNX_HOST%\usr\bin;%PATH%
 #   Linux: export PATH=$QNX_HOST/usr/bin:$PATH
 #4. execute cmake in build-folder:
-#   cmake -G "Unix Makefiles" -DCMAKE_TOOLCHAIN_FILE=<path to capu>/cmake/acme/toolchain/QNX_X86.toolchain
-DCMAKE_BUILD_TYPE=Debug|Release ..
+#   cmake -G "Unix Makefiles" -DCMAKE_TOOLCHAIN_FILE=<path to toolchain>/QNX_X86.toolchain
-DCMAKE_BUILD_TYPE=Debug|Release ..
 #5. make
 #
 #------------------------------------------------------------------#
@@ -96,5 +96,10 @@ SET(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NE
 SET(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
 SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
 
+ADD_DEFINITIONS("-DTARGET_OS=QNX")
+ADD_DEFINITIONS("-DTARGET_ARCH=X86_32")
 ADD_DEFINITIONS("-DOS_QNX")
 ADD_DEFINITIONS("-DARCH_X86_32")
+
+# necessary for gmock
+ADD_DEFINITIONS("-DGTEST_HAS_PTHREAD=1")

Modified: etch/trunk/binding-cpp/runtime/toolchains/Windows_X86_32.toolchain
URL: http://svn.apache.org/viewvc/etch/trunk/binding-cpp/runtime/toolchains/Windows_X86_32.toolchain?rev=1460566&r1=1460565&r2=1460566&view=diff
==============================================================================
--- etch/trunk/binding-cpp/runtime/toolchains/Windows_X86_32.toolchain (original)
+++ etch/trunk/binding-cpp/runtime/toolchains/Windows_X86_32.toolchain Mon Mar 25 09:43:41
2013
@@ -28,10 +28,15 @@ SET(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_C_F
 SET(CMAKE_C_FLAGS_DEBUG "/MDd /Zi /Od /RTC1 /D_DEBUG /MP8" )
 SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} /W3")
 
-
+add_definitions("-DTARGET_OS=Windows")
+add_definitions("-DTARGET_ARCH=X86_32")
 add_definitions("-DOS_WINDOWS")
 add_definitions("-DARCH_X86_32")
+
 add_definitions("-D_VARIADIC_MAX=10") #this is needed for compiling gtest with visual studio
11
+add_definitions("-D_WIN32_WINNT=0x0501")
+add_definitions("-DWINVER=0x0501")
 
 # enable the BUILD_CHECK_MEMORY flag if you would like to check for memory leaks with visual
leak detector
 #add_definitions("-DBUILD_CHECK_MEMORY")
+

Modified: etch/trunk/binding-cpp/runtime/toolchains/Windows_X86_64.toolchain
URL: http://svn.apache.org/viewvc/etch/trunk/binding-cpp/runtime/toolchains/Windows_X86_64.toolchain?rev=1460566&r1=1460565&r2=1460566&view=diff
==============================================================================
--- etch/trunk/binding-cpp/runtime/toolchains/Windows_X86_64.toolchain (original)
+++ etch/trunk/binding-cpp/runtime/toolchains/Windows_X86_64.toolchain Mon Mar 25 09:43:41
2013
@@ -29,8 +29,12 @@ SET(CMAKE_C_FLAGS_DEBUG "/MDd /Zi /Od /R
 SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} /W3")
 
 
+add_definitions("-DTARGET_OS=Windows")
+add_definitions("-DTARGET_ARCH=X86_64")
 add_definitions("-DOS_WINDOWS")
 add_definitions("-DARCH_X86_64")
 
+add_definitions("-D_VARIADIC_MAX=10") #this is needed for compiling gtest with visual studio
11
+
 # enable the BUILD_CHECK_MEMORY flag if you would like to check for memory leaks with visual
leak detector
 #add_definitions("-DBUILD_CHECK_MEMORY")

Modified: etch/trunk/examples/helloworld/cpp/CMakeLists.txt
URL: http://svn.apache.org/viewvc/etch/trunk/examples/helloworld/cpp/CMakeLists.txt?rev=1460566&r1=1460565&r2=1460566&view=diff
==============================================================================
--- etch/trunk/examples/helloworld/cpp/CMakeLists.txt (original)
+++ etch/trunk/examples/helloworld/cpp/CMakeLists.txt Mon Mar 25 09:43:41 2013
@@ -35,7 +35,7 @@ ENDIF (NOT ETCH_HOME)
 SET(ETCH_CPP_HOME ${ETCH_HOME}/binding-cpp)
 SET(ETCH_CPP_INCLUDE_DIR ${ETCH_CPP_HOME}/include)
 SET(ETCH_CPP_LIBRARY_DIR ${ETCH_CPP_HOME}/lib)
-SET(ETCH_CPP_LIBRARY_DIR_PLATFORM_SPECIFIC ${ETCH_CPP_LIBRARY_DIR}/${TARGET_OS}_${TARGET_ARCH}/${ETCH_BUILD_TARGET})
+SET(ETCH_CPP_LIBRARY_DIR_PLATFORM_SPECIFIC ${ETCH_CPP_LIBRARY_DIR}/${TARGET_OS}_${TARGET_ARCH}/${CMAKE_BUILD_TYPE})
 
 # set include dirs
 include_directories (${ETCH_CPP_INCLUDE_DIR})
@@ -48,7 +48,7 @@ link_directories(${ETCH_CPP_LIBRARY_DIR_
 #STATUS
 message(STATUS " ")
 message(STATUS "====================================================")
-message(STATUS "build target:            ${ETCH_BUILD_TARGET}")
+message(STATUS "build target:            ${CMAKE_BUILD_TYPE}")
 message(STATUS "using Etch home Dir:     ${ETCH_HOME}")
 message(STATUS "using include dir:       ${ETCH_CPP_INCLUDE_DIR}")
 message(STATUS "using library dir:       ${ETCH_CPP_LIBRARY_DIR_PLATFORM_SPECIFIC}")
@@ -83,7 +83,9 @@ add_executable(etch-cpp-helloworld-serve
 
 IF (TARGET_OS STREQUAL "Linux")
   target_link_libraries(etch-cpp-helloworld-server etch capu pthread rt)
-  set_target_properties(etch-cpp-helloworld-server PROPERTIES COMPILE_FLAGS "-m32 -g" LINK_FLAGS
"-m32")
+  IF (TARGET_ARCH STREQUAL "X86_64")
+    set_target_properties(etch-cpp-helloworld-server PROPERTIES COMPILE_FLAGS "-m32 -g" LINK_FLAGS
"-m32")
+  ENDIF()
 ELSEIF(TARGET_OS STREQUAL "Windows")
   target_link_libraries(etch-cpp-helloworld-server etch capu)
   IF (BUILD_CHECK_MEMORY)
@@ -122,7 +124,9 @@ add_executable(etch-cpp-helloworld-clien
 
 IF (TARGET_OS STREQUAL "Linux")
   target_link_libraries(etch-cpp-helloworld-client etch capu pthread rt)
-  set_target_properties(etch-cpp-helloworld-client PROPERTIES COMPILE_FLAGS "-m32 -g" LINK_FLAGS
"-m32")
+  IF (TARGET_ARCH STREQUAL "X86_64")
+    set_target_properties(etch-cpp-helloworld-client PROPERTIES COMPILE_FLAGS "-m32 -g" LINK_FLAGS
"-m32")
+  ENDIF()
 ELSEIF(TARGET_OS STREQUAL "Windows")
   target_link_libraries(etch-cpp-helloworld-client etch capu )
   IF (BUILD_CHECK_MEMORY)



Mime
View raw message