blob: 688a5bda812bebfa205cc4f7d219940ec068ff7d [file] [log] [blame]
Misha Brukman3aae44e2009-01-01 01:29:44 +00001##===- utils/unittest/googletest/Makefile ------------------*- Makefile -*-===##
2#
3# The LLVM Compiler Infrastructure
4#
5# This file is distributed under the University of Illinois Open Source
6# License. See LICENSE.TXT for details.
7#
8##===----------------------------------------------------------------------===##
9
10LEVEL := ../../..
Daniel Dunbar848454a2009-09-20 06:17:12 +000011
Misha Brukman3aae44e2009-01-01 01:29:44 +000012include $(LEVEL)/Makefile.config
Mike Stump44460da2009-02-05 20:45:27 +000013
Misha Brukman3aae44e2009-01-01 01:29:44 +000014LIBRARYNAME = GoogleTest
15BUILD_ARCHIVE = 1
Chris Lattner43b5f932010-01-24 20:43:08 +000016REQUIRES_RTTI = 1
Chandler Carruthf10e43e2010-03-09 19:24:49 +000017
18# Note that these flags are duplicated when building individual tests in
19# unittests/Makefile.unittest; ensure that any changes are made to both.
Benjamin Kramerb0d3f252009-07-27 09:39:18 +000020CPP.Flags += -I$(LLVM_SRC_ROOT)/utils/unittest/googletest/include
Mike Stumpd907e492009-02-05 20:49:49 +000021CPP.Flags += $(NO_MISSING_FIELD_INITIALIZERS) $(NO_VARIADIC_MACROS)
Chandler Carruthf10e43e2010-03-09 19:24:49 +000022CPP.Flags += -DGTEST_HAS_RTTI=0
23# libstdc++'s TR1 <tuple> header depends on RTTI and uses C++'0x features not
24# supported by Clang, so force googletest to use its own tuple implementation.
25# When we import googletest >=1.4.0, we can drop this line.
26CPP.Flags += -DGTEST_HAS_TR1_TUPLE=0
27
Misha Brukman3aae44e2009-01-01 01:29:44 +000028
Anton Korobeynikove55db742009-08-18 00:40:33 +000029ifeq ($(HOST_OS),MingW)
Julien Lerougee0a056b2009-02-12 08:02:35 +000030 CPP.Flags += -DGTEST_OS_WINDOWS=1
31endif
32
Chris Lattnerc8914652009-05-08 17:32:47 +000033NO_INSTALL = 1
34
Misha Brukman3aae44e2009-01-01 01:29:44 +000035include $(LEVEL)/Makefile.common