CMakeLists.txt 687 Bytes
Newer Older
1
cmake_minimum_required(VERSION 2.8.8)
Fábio Junqueira's avatar
Fábio Junqueira committed
2

Joel Laity's avatar
Joel Laity committed
3
if (POLICY CMP0048)
4
  cmake_policy(SET CMP0048 NEW)
Joel Laity's avatar
Joel Laity committed
5
endif (POLICY CMP0048)
6

7
8
project(googletest-distribution)
set(GOOGLETEST_VERSION 1.9.0)
9
10
<<<<<<< HEAD
=======
11
12

add_compile_options(-std=c++11)
13
>>>>>>> 1e893191c0a72f6c94bbd69acc39ce425594f36d
Fábio Junqueira's avatar
Fábio Junqueira committed
14
15
16

enable_testing()

17
include(CMakeDependentOption)
18
include(GNUInstallDirs)
19

Fábio Junqueira's avatar
Fábio Junqueira committed
20
21
#Note that googlemock target already builds googletest
option(BUILD_GMOCK "Builds the googlemock subproject" ON)
Stefano Soffia's avatar
Stefano Soffia committed
22
option(INSTALL_GTEST "Enable installation of googletest. (Projects embedding googletest may want to turn this OFF.)" ON)
23

Fábio Junqueira's avatar
Fábio Junqueira committed
24
25
if(BUILD_GMOCK)
  add_subdirectory( googlemock )
Stefano Soffia's avatar
Stefano Soffia committed
26
else()
Fábio Junqueira's avatar
Fábio Junqueira committed
27
28
  add_subdirectory( googletest )
endif()