3 ACLOCAL_AMFLAGS = -I m4
5 # Nonstandard package files for distribution
10 include/gtest/gtest-param-test.h.pump \
11 include/gtest/internal/gtest-param-util-generated.h.pump \
12 include/gtest/internal/gtest-tuple.h.pump \
13 include/gtest/internal/gtest-type-util.h.pump \
15 scripts/fuse_gtest_files.py \
16 scripts/gen_gtest_pred_impl.py \
20 # gtest source files that we don't compile directly. They are
21 # #included by gtest-all.cc.
23 src/gtest-death-test.cc \
24 src/gtest-filepath.cc \
25 src/gtest-internal-inl.h \
27 src/gtest-printers.cc \
28 src/gtest-test-part.cc \
29 src/gtest-typed-test.cc \
32 EXTRA_DIST += $(GTEST_SRC)
34 # Sample files that we don't compile.
36 samples/prime_tables.h \
37 samples/sample1_unittest.cc \
38 samples/sample2_unittest.cc \
39 samples/sample3_unittest.cc \
40 samples/sample4_unittest.cc \
41 samples/sample5_unittest.cc \
42 samples/sample6_unittest.cc \
43 samples/sample7_unittest.cc \
44 samples/sample8_unittest.cc \
45 samples/sample9_unittest.cc
47 # C++ test files that we don't compile directly.
49 test/gtest-death-test_ex_test.cc \
50 test/gtest-death-test_test.cc \
51 test/gtest-filepath_test.cc \
52 test/gtest-linked_ptr_test.cc \
53 test/gtest-listener_test.cc \
54 test/gtest-message_test.cc \
55 test/gtest-options_test.cc \
56 test/googletest-param-test2-test.cc \
57 test/googletest-param-test2-test.cc \
58 test/googletest-param-test-test.cc \
59 test/googletest-param-test-test.cc \
60 test/gtest-param-test_test.h \
61 test/gtest-port_test.cc \
62 test/gtest_premature_exit_test.cc \
63 test/gtest-printers_test.cc \
64 test/gtest-test-part_test.cc \
65 test/googletest-tuple-test.cc \
66 test/gtest-typed-test2_test.cc \
67 test/gtest-typed-test_test.cc \
68 test/gtest-typed-test_test.h \
69 test/gtest-unittest-api_test.cc \
70 test/googletest-break-on-failure-unittest_.cc \
71 test/googletest-catch-exceptions-test_.cc \
72 test/googletest-color-test_.cc \
73 test/googletest-env-var-test_.cc \
74 test/gtest_environment_test.cc \
75 test/googletest-filter-unittest_.cc \
76 test/gtest_help_test_.cc \
77 test/googletest-list-tests-unittest_.cc \
78 test/gtest_main_unittest.cc \
79 test/gtest_no_test_unittest.cc \
80 test/googletest-output-test_.cc \
81 test/gtest_pred_impl_unittest.cc \
82 test/gtest_prod_test.cc \
83 test/gtest_repeat_test.cc \
84 test/googletest-shuffle-test_.cc \
85 test/gtest_sole_header_test.cc \
86 test/gtest_stress_test.cc \
87 test/gtest_throw_on_failure_ex_test.cc \
88 test/googletest-throw-on-failure-test_.cc \
89 test/googletest-uninitialized-test_.cc \
90 test/gtest_unittest.cc \
91 test/gtest_unittest.cc \
92 test/gtest_xml_outfile1_test_.cc \
93 test/gtest_xml_outfile2_test_.cc \
94 test/gtest_xml_output_unittest_.cc \
98 # Python tests that we don't run.
100 test/googletest-break-on-failure-unittest.py \
101 test/googletest-catch-exceptions-test.py \
102 test/googletest-color-test.py \
103 test/googletest-env-var-test.py \
104 test/googletest-filter-unittest.py \
105 test/gtest_help_test.py \
106 test/googletest-list-tests-unittest.py \
107 test/googletest-output-test.py \
108 test/googletest-output-test_golden_lin.txt \
109 test/googletest-shuffle-test.py \
110 test/gtest_test_utils.py \
111 test/googletest-throw-on-failure-test.py \
112 test/googletest-uninitialized-test.py \
113 test/gtest_xml_outfiles_test.py \
114 test/gtest_xml_output_unittest.py \
115 test/gtest_xml_test_utils.py
120 cmake/internal_utils.cmake
124 msvc/2010/gtest-md.sln \
125 msvc/2010/gtest-md.vcxproj \
126 msvc/2010/gtest.sln \
127 msvc/2010/gtest.vcxproj \
128 msvc/2010/gtest_main-md.vcxproj \
129 msvc/2010/gtest_main.vcxproj \
130 msvc/2010/gtest_prod_test-md.vcxproj \
131 msvc/2010/gtest_prod_test.vcxproj \
132 msvc/2010/gtest_unittest-md.vcxproj \
133 msvc/2010/gtest_unittest.vcxproj
135 # xcode project files
137 xcode/Config/DebugProject.xcconfig \
138 xcode/Config/FrameworkTarget.xcconfig \
139 xcode/Config/General.xcconfig \
140 xcode/Config/ReleaseProject.xcconfig \
141 xcode/Config/StaticLibraryTarget.xcconfig \
142 xcode/Config/TestTarget.xcconfig \
143 xcode/Resources/Info.plist \
144 xcode/Scripts/runtests.sh \
145 xcode/Scripts/versiongenerate.py \
146 xcode/gtest.xcodeproj/project.pbxproj
150 xcode/Samples/FrameworkSample/Info.plist \
151 xcode/Samples/FrameworkSample/WidgetFramework.xcodeproj/project.pbxproj \
152 xcode/Samples/FrameworkSample/runtests.sh \
153 xcode/Samples/FrameworkSample/widget.cc \
154 xcode/Samples/FrameworkSample/widget.h \
155 xcode/Samples/FrameworkSample/widget_test.cc
157 # C++Builder project files
159 codegear/gtest.cbproj \
160 codegear/gtest.groupproj \
161 codegear/gtest_all.cc \
162 codegear/gtest_link.cc \
163 codegear/gtest_main.cbproj \
164 codegear/gtest_unittest.cbproj
166 # Distribute and install M4 macro
167 m4datadir = $(datadir)/aclocal
168 m4data_DATA = m4/gtest.m4
169 EXTRA_DIST += $(m4data_DATA)
171 # We define the global AM_CPPFLAGS as everything we compile includes from these
173 AM_CPPFLAGS = -I$(srcdir) -I$(srcdir)/include
175 # Modifies compiler and linker flags for pthreads compatibility.
177 AM_CXXFLAGS = @PTHREAD_CFLAGS@ -DGTEST_HAS_PTHREAD=1
178 AM_LIBS = @PTHREAD_LIBS@
180 AM_CXXFLAGS = -DGTEST_HAS_PTHREAD=0
183 # Build rules for libraries.
184 lib_LTLIBRARIES = lib/libgtest.la lib/libgtest_main.la
186 lib_libgtest_la_SOURCES = src/gtest-all.cc
188 pkginclude_HEADERS = \
189 include/gtest/gtest-death-test.h \
190 include/gtest/gtest-message.h \
191 include/gtest/gtest-param-test.h \
192 include/gtest/gtest-printers.h \
193 include/gtest/gtest-spi.h \
194 include/gtest/gtest-test-part.h \
195 include/gtest/gtest-typed-test.h \
196 include/gtest/gtest.h \
197 include/gtest/gtest_pred_impl.h \
198 include/gtest/gtest_prod.h
200 pkginclude_internaldir = $(pkgincludedir)/internal
201 pkginclude_internal_HEADERS = \
202 include/gtest/internal/gtest-death-test-internal.h \
203 include/gtest/internal/gtest-filepath.h \
204 include/gtest/internal/gtest-internal.h \
205 include/gtest/internal/gtest-linked_ptr.h \
206 include/gtest/internal/gtest-param-util-generated.h \
207 include/gtest/internal/gtest-param-util.h \
208 include/gtest/internal/gtest-port.h \
209 include/gtest/internal/gtest-port-arch.h \
210 include/gtest/internal/gtest-string.h \
211 include/gtest/internal/gtest-tuple.h \
212 include/gtest/internal/gtest-type-util.h \
213 include/gtest/internal/custom/gtest.h \
214 include/gtest/internal/custom/gtest-port.h \
215 include/gtest/internal/custom/gtest-printers.h
217 lib_libgtest_main_la_SOURCES = src/gtest_main.cc
218 lib_libgtest_main_la_LIBADD = lib/libgtest.la
220 # Build rules for samples and tests. Automake's naming for some of
221 # these variables isn't terribly obvious, so this is a brief
224 # TESTS -- Programs run automatically by "make check"
225 # check_PROGRAMS -- Programs built by "make check" but not necessarily run
228 TESTS_ENVIRONMENT = GTEST_SOURCE_DIR="$(srcdir)/test" \
229 GTEST_BUILD_DIR="$(top_builddir)/test"
232 # A simple sample on using gtest.
233 TESTS += samples/sample1_unittest \
234 samples/sample2_unittest \
235 samples/sample3_unittest \
236 samples/sample4_unittest \
237 samples/sample5_unittest \
238 samples/sample6_unittest \
239 samples/sample7_unittest \
240 samples/sample8_unittest \
241 samples/sample9_unittest \
242 samples/sample10_unittest
243 check_PROGRAMS += samples/sample1_unittest \
244 samples/sample2_unittest \
245 samples/sample3_unittest \
246 samples/sample4_unittest \
247 samples/sample5_unittest \
248 samples/sample6_unittest \
249 samples/sample7_unittest \
250 samples/sample8_unittest \
251 samples/sample9_unittest \
252 samples/sample10_unittest
254 samples_sample1_unittest_SOURCES = samples/sample1_unittest.cc samples/sample1.cc
255 samples_sample1_unittest_LDADD = lib/libgtest_main.la \
257 samples_sample2_unittest_SOURCES = samples/sample2_unittest.cc samples/sample2.cc
258 samples_sample2_unittest_LDADD = lib/libgtest_main.la \
260 samples_sample3_unittest_SOURCES = samples/sample3_unittest.cc
261 samples_sample3_unittest_LDADD = lib/libgtest_main.la \
263 samples_sample4_unittest_SOURCES = samples/sample4_unittest.cc samples/sample4.cc
264 samples_sample4_unittest_LDADD = lib/libgtest_main.la \
266 samples_sample5_unittest_SOURCES = samples/sample5_unittest.cc samples/sample1.cc
267 samples_sample5_unittest_LDADD = lib/libgtest_main.la \
269 samples_sample6_unittest_SOURCES = samples/sample6_unittest.cc
270 samples_sample6_unittest_LDADD = lib/libgtest_main.la \
272 samples_sample7_unittest_SOURCES = samples/sample7_unittest.cc
273 samples_sample7_unittest_LDADD = lib/libgtest_main.la \
275 samples_sample8_unittest_SOURCES = samples/sample8_unittest.cc
276 samples_sample8_unittest_LDADD = lib/libgtest_main.la \
279 # Also verify that libgtest works by itself.
280 samples_sample9_unittest_SOURCES = samples/sample9_unittest.cc
281 samples_sample9_unittest_LDADD = lib/libgtest.la
282 samples_sample10_unittest_SOURCES = samples/sample10_unittest.cc
283 samples_sample10_unittest_LDADD = lib/libgtest.la
285 # This tests most constructs of gtest and verifies that libgtest_main
287 TESTS += test/gtest_all_test
288 check_PROGRAMS += test/gtest_all_test
289 test_gtest_all_test_SOURCES = test/gtest_all_test.cc
290 test_gtest_all_test_LDADD = lib/libgtest_main.la \
293 # Tests that fused gtest files compile and work.
295 fused-src/gtest/gtest-all.cc \
296 fused-src/gtest/gtest.h \
297 fused-src/gtest/gtest_main.cc
300 TESTS += test/fused_gtest_test
301 check_PROGRAMS += test/fused_gtest_test
302 test_fused_gtest_test_SOURCES = $(FUSED_GTEST_SRC) \
303 samples/sample1.cc samples/sample1_unittest.cc
304 test_fused_gtest_test_CPPFLAGS = -I"$(srcdir)/fused-src"
306 # Build rules for putting fused Google Test files into the distribution
307 # package. The user can also create those files by manually running
308 # scripts/fuse_gtest_files.py.
309 $(test_fused_gtest_test_SOURCES): fused-gtest
311 fused-gtest: $(pkginclude_HEADERS) $(pkginclude_internal_HEADERS) \
312 $(GTEST_SRC) src/gtest-all.cc src/gtest_main.cc \
313 scripts/fuse_gtest_files.py
314 mkdir -p "$(srcdir)/fused-src"
315 chmod -R u+w "$(srcdir)/fused-src"
316 rm -f "$(srcdir)/fused-src/gtest/gtest-all.cc"
317 rm -f "$(srcdir)/fused-src/gtest/gtest.h"
318 "$(srcdir)/scripts/fuse_gtest_files.py" "$(srcdir)/fused-src"
319 cp -f "$(srcdir)/src/gtest_main.cc" "$(srcdir)/fused-src/gtest/"
321 maintainer-clean-local:
322 rm -rf "$(srcdir)/fused-src"
325 # Death tests may produce core dumps in the build directory. In case
326 # this happens, clean them to keep distcleancheck happy.
329 # Disables 'make install' as installing a compiled version of Google
330 # Test can lead to undefined behavior due to violation of the
331 # One-Definition Rule.
334 echo "'make install' is dangerous and not supported. Instead, see README for how to integrate Google Test into your build system."
338 echo "'make install' is dangerous and not supported. Instead, see README for how to integrate Google Test into your build system."