~ubuntu-branches/ubuntu/vivid/libusermetrics/vivid

« back to all changes in this revision

Viewing changes to cmake/FindLocalGTest.cmake

  • Committer: Package Import Robot
  • Author(s): Ubuntu daily release, Pete Woods, Ubuntu daily release
  • Date: 2013-07-11 02:03:59 UTC
  • mfrom: (1.1.8)
  • Revision ID: package-import@ubuntu.com-20130711020359-8uck7n6bikxlpxyn
Tags: 1.0.6+13.10.20130711-0ubuntu1
[ Pete Woods ]
* Merge didrocks' google-mock fix

[ Ubuntu daily release ]
* Automatic snapshot from revision 104

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
 
2
 
# Check for google test and build it locally
3
 
set(
4
 
 GTEST_ROOT_DIR
5
 
  "/usr/src/gtest" # Default value, adjustable by user with e.g., ccmake
6
 
  CACHE
7
 
  PATH
8
 
  "Path to Google test srcs"
9
 
)
10
 
 
11
 
set(
12
 
  GTEST_INCLUDE_DIR
13
 
  "/usr/include/gtest"
14
 
  CACHE
15
 
  PATH
16
 
  "Path to Google tests include"
17
 
)
18
 
 
19
 
find_path(GTEST_INCLUDE_DIR gtest/gtest.h)
20
 
if (GTEST_INCLUDE_DIR)
21
 
        set(GTEST_FOUND true)
22
 
        #FIXME - hardcoded is bad!
23
 
  add_subdirectory(
24
 
    ${GTEST_ROOT_DIR}
25
 
    gtest
26
 
  )
27
 
endif(GTEST_INCLUDE_DIR)
28
 
 
29
 
set(GTEST_INCLUDE_DIRS ${GTEST_INCLUDE_DIR})
30
 
set(GTEST_LIBRARIES gtest)
31
 
set(GTEST_MAIN_LIBRARIES gtest_main)
32
 
set(GTEST_BOTH_LIBRARIES ${GTEST_LIBRARIES} ${GTEST_MAIN_LIBRARIES})
33