Upstream version 9.38.198.0
[platform/framework/web/crosswalk.git] / src / testing / gmock / README
index e414f3a..0cb9123 100644 (file)
@@ -42,7 +42,7 @@ Requirements for End Users
 
 Google Mock is implemented on top of the Google Test C++ testing
 framework (http://code.google.com/p/googletest/), and includes the
 
 Google Mock is implemented on top of the Google Test C++ testing
 framework (http://code.google.com/p/googletest/), and includes the
-latter as part of the SVN repositary and distribution package.  You
+latter as part of the SVN repository and distribution package.  You
 must use the bundled version of Google Test when using Google Mock, or
 you may get compiler/linker errors.
 
 must use the bundled version of Google Test when using Google Mock, or
 you may get compiler/linker errors.
 
@@ -92,7 +92,7 @@ Getting the Source
 
 There are two primary ways of getting Google Mock's source code: you
 can download a stable source release in your preferred archive format,
 
 There are two primary ways of getting Google Mock's source code: you
 can download a stable source release in your preferred archive format,
-or directly check out the source from our Subversion (SVN) repositary.
+or directly check out the source from our Subversion (SVN) repository.
 The SVN checkout requires a few extra steps and some extra software
 packages on your system, but lets you track development and make
 patches much more easily, so we highly encourage it.
 The SVN checkout requires a few extra steps and some extra software
 packages on your system, but lets you track development and make
 patches much more easily, so we highly encourage it.
@@ -170,23 +170,31 @@ called by Visual Studio and Xcode) to compile
 
 with
 
 
 with
 
-  ${GTEST_DIR}/include, ${GTEST_DIR}, ${GMOCK_DIR}/include, and ${GMOCK_DIR}
+  ${GTEST_DIR}/include and ${GMOCK_DIR}/include
 
 
-in the header search path.  Assuming a Linux-like system and gcc,
+in the system header search path, and
+
+  ${GTEST_DIR} and ${GMOCK_DIR}
+
+in the normal header search path.  Assuming a Linux-like system and gcc,
 something like the following will do:
 
 something like the following will do:
 
-  g++ -I${GTEST_DIR}/include -I${GTEST_DIR} -I${GMOCK_DIR}/include \
-      -I${GMOCK_DIR} -c ${GTEST_DIR}/src/gtest-all.cc
-  g++ -I${GTEST_DIR}/include -I${GTEST_DIR} -I${GMOCK_DIR}/include \
-      -I${GMOCK_DIR} -c ${GMOCK_DIR}/src/gmock-all.cc
+  g++ -isystem ${GTEST_DIR}/include -I${GTEST_DIR} \
+      -isystem ${GMOCK_DIR}/include -I${GMOCK_DIR} \
+      -pthread -c ${GTEST_DIR}/src/gtest-all.cc
+  g++ -isystem ${GTEST_DIR}/include -I${GTEST_DIR} \
+      -isystem ${GMOCK_DIR}/include -I${GMOCK_DIR} \
+      -pthread -c ${GMOCK_DIR}/src/gmock-all.cc
   ar -rv libgmock.a gtest-all.o gmock-all.o
 
   ar -rv libgmock.a gtest-all.o gmock-all.o
 
+(We need -pthread as Google Test and Google Mock use threads.)
+
 Next, you should compile your test source file with
 ${GTEST_DIR}/include and ${GMOCK_DIR}/include in the header search
 path, and link it with gmock and any other necessary libraries:
 
 Next, you should compile your test source file with
 ${GTEST_DIR}/include and ${GMOCK_DIR}/include in the header search
 path, and link it with gmock and any other necessary libraries:
 
-  g++ -I${GTEST_DIR}/include -I${GMOCK_DIR}/include \
-      path/to/your_test.cc libgmock.a -o your_test
+  g++ -isystem ${GTEST_DIR}/include -isystem ${GMOCK_DIR}/include \
+      -pthread path/to/your_test.cc libgmock.a -o your_test
 
 As an example, the make/ directory contains a Makefile that you can
 use to build Google Mock on systems where GNU make is available
 
 As an example, the make/ directory contains a Makefile that you can
 use to build Google Mock on systems where GNU make is available