Back to home page

sPhenix code displayed by LXR

 
 

    


File indexing completed on 2025-08-05 08:18:42

0001 # Automake file
0002 
0003 # Nonstandard package files for distribution.
0004 EXTRA_DIST = LICENSE
0005 
0006 # We may need to build our internally packaged gtest. If so, it will be
0007 # included in the 'subdirs' variable.
0008 SUBDIRS = $(subdirs)
0009 
0010 # This is generated by the configure script, so clean it for distribution.
0011 DISTCLEANFILES = scripts/gmock-config
0012 
0013 # We define the global AM_CPPFLAGS as everything we compile includes from these
0014 # directories.
0015 AM_CPPFLAGS = $(GTEST_CPPFLAGS) -I$(srcdir)/include
0016 
0017 # Modifies compiler and linker flags for pthreads compatibility.
0018 if HAVE_PTHREADS
0019   AM_CXXFLAGS = @PTHREAD_CFLAGS@ -DGTEST_HAS_PTHREAD=1
0020   AM_LIBS = @PTHREAD_LIBS@
0021 endif
0022 
0023 # Build rules for libraries.
0024 lib_LTLIBRARIES = lib/libgmock.la lib/libgmock_main.la
0025 
0026 lib_libgmock_la_SOURCES = src/gmock-all.cc
0027 
0028 pkginclude_HEADERS = \
0029   include/gmock/gmock-actions.h \
0030   include/gmock/gmock-cardinalities.h \
0031   include/gmock/gmock-generated-actions.h \
0032   include/gmock/gmock-generated-function-mockers.h \
0033   include/gmock/gmock-generated-matchers.h \
0034   include/gmock/gmock-generated-nice-strict.h \
0035   include/gmock/gmock-matchers.h \
0036   include/gmock/gmock-more-actions.h \
0037   include/gmock/gmock-more-matchers.h \
0038   include/gmock/gmock-spec-builders.h \
0039   include/gmock/gmock.h
0040 
0041 pkginclude_internaldir = $(pkgincludedir)/internal
0042 pkginclude_internal_HEADERS = \
0043   include/gmock/internal/gmock-generated-internal-utils.h \
0044   include/gmock/internal/gmock-internal-utils.h \
0045   include/gmock/internal/gmock-port.h \
0046   include/gmock/internal/custom/gmock-generated-actions.h \
0047   include/gmock/internal/custom/gmock-matchers.h \
0048   include/gmock/internal/custom/gmock-port.h
0049 
0050 lib_libgmock_main_la_SOURCES = src/gmock_main.cc
0051 lib_libgmock_main_la_LIBADD = lib/libgmock.la
0052 
0053 # Build rules for tests. Automake's naming for some of these variables isn't
0054 # terribly obvious, so this is a brief reference:
0055 #
0056 # TESTS -- Programs run automatically by "make check"
0057 # check_PROGRAMS -- Programs built by "make check" but not necessarily run
0058 
0059 TESTS=
0060 check_PROGRAMS=
0061 AM_LDFLAGS = $(GTEST_LDFLAGS)
0062 
0063 # This exercises all major components of Google Mock.  It also
0064 # verifies that libgmock works.
0065 TESTS += test/gmock-spec-builders_test
0066 check_PROGRAMS += test/gmock-spec-builders_test
0067 test_gmock_spec_builders_test_SOURCES = test/gmock-spec-builders_test.cc
0068 test_gmock_spec_builders_test_LDADD = $(GTEST_LIBS) lib/libgmock.la
0069 
0070 # This tests using Google Mock in multiple translation units.  It also
0071 # verifies that libgmock_main and libgmock work.
0072 TESTS += test/gmock_link_test
0073 check_PROGRAMS += test/gmock_link_test
0074 test_gmock_link_test_SOURCES = \
0075   test/gmock_link2_test.cc \
0076   test/gmock_link_test.cc \
0077   test/gmock_link_test.h
0078 test_gmock_link_test_LDADD = $(GTEST_LIBS) lib/libgmock_main.la  lib/libgmock.la
0079 
0080 if HAVE_PYTHON
0081   # Tests that fused gmock files compile and work.
0082   TESTS += test/gmock_fused_test
0083   check_PROGRAMS += test/gmock_fused_test
0084   test_gmock_fused_test_SOURCES = \
0085     fused-src/gmock-gtest-all.cc \
0086     fused-src/gmock/gmock.h \
0087     fused-src/gmock_main.cc \
0088     fused-src/gtest/gtest.h \
0089     test/gmock_test.cc
0090   test_gmock_fused_test_CPPFLAGS = -I"$(srcdir)/fused-src"
0091 endif
0092 
0093 # Google Mock source files that we don't compile directly.
0094 GMOCK_SOURCE_INGLUDES = \
0095   src/gmock-cardinalities.cc \
0096   src/gmock-internal-utils.cc \
0097   src/gmock-matchers.cc \
0098   src/gmock-spec-builders.cc \
0099   src/gmock.cc
0100 
0101 EXTRA_DIST += $(GMOCK_SOURCE_INGLUDES)
0102 
0103 # C++ tests that we don't compile using autotools.
0104 EXTRA_DIST += \
0105   test/gmock-actions_test.cc \
0106   test/gmock_all_test.cc \
0107   test/gmock-cardinalities_test.cc \
0108   test/gmock_ex_test.cc \
0109   test/gmock-generated-actions_test.cc \
0110   test/gmock-generated-function-mockers_test.cc \
0111   test/gmock-generated-internal-utils_test.cc \
0112   test/gmock-generated-matchers_test.cc \
0113   test/gmock-internal-utils_test.cc \
0114   test/gmock-matchers_test.cc \
0115   test/gmock-more-actions_test.cc \
0116   test/gmock-nice-strict_test.cc \
0117   test/gmock-port_test.cc \
0118   test/gmock_stress_test.cc
0119 
0120 # Python tests, which we don't run using autotools.
0121 EXTRA_DIST += \
0122   test/gmock_leak_test.py \
0123   test/gmock_leak_test_.cc \
0124   test/gmock_output_test.py \
0125   test/gmock_output_test_.cc \
0126   test/gmock_output_test_golden.txt \
0127   test/gmock_test_utils.py
0128 
0129 # Nonstandard package files for distribution.
0130 EXTRA_DIST += \
0131   CHANGES \
0132   CONTRIBUTORS \
0133   make/Makefile
0134 
0135 # Pump scripts for generating Google Mock headers.
0136 # TODO(chandlerc@google.com): automate the generation of *.h from *.h.pump.
0137 EXTRA_DIST += \
0138   include/gmock/gmock-generated-actions.h.pump \
0139   include/gmock/gmock-generated-function-mockers.h.pump \
0140   include/gmock/gmock-generated-matchers.h.pump \
0141   include/gmock/gmock-generated-nice-strict.h.pump \
0142   include/gmock/internal/gmock-generated-internal-utils.h.pump \
0143   include/gmock/internal/custom/gmock-generated-actions.h.pump
0144 
0145 # Script for fusing Google Mock and Google Test source files.
0146 EXTRA_DIST += scripts/fuse_gmock_files.py
0147 
0148 # The Google Mock Generator tool from the cppclean project.
0149 EXTRA_DIST += \
0150   scripts/generator/LICENSE \
0151   scripts/generator/README \
0152   scripts/generator/README.cppclean \
0153   scripts/generator/cpp/__init__.py \
0154   scripts/generator/cpp/ast.py \
0155   scripts/generator/cpp/gmock_class.py \
0156   scripts/generator/cpp/keywords.py \
0157   scripts/generator/cpp/tokenize.py \
0158   scripts/generator/cpp/utils.py \
0159   scripts/generator/gmock_gen.py
0160 
0161 # Script for diagnosing compiler errors in programs that use Google
0162 # Mock.
0163 EXTRA_DIST += scripts/gmock_doctor.py
0164 
0165 # CMake scripts.
0166 EXTRA_DIST += \
0167   CMakeLists.txt
0168 
0169 # Microsoft Visual Studio 2005 projects.
0170 EXTRA_DIST += \
0171   msvc/2005/gmock.sln \
0172   msvc/2005/gmock.vcproj \
0173   msvc/2005/gmock_config.vsprops \
0174   msvc/2005/gmock_main.vcproj \
0175   msvc/2005/gmock_test.vcproj
0176 
0177 # Microsoft Visual Studio 2010 projects.
0178 EXTRA_DIST += \
0179   msvc/2010/gmock.sln \
0180   msvc/2010/gmock.vcxproj \
0181   msvc/2010/gmock_config.props \
0182   msvc/2010/gmock_main.vcxproj \
0183   msvc/2010/gmock_test.vcxproj
0184 
0185 if HAVE_PYTHON
0186 # gmock_test.cc does not really depend on files generated by the
0187 # fused-gmock-internal rule.  However, gmock_test.o does, and it is
0188 # important to include test/gmock_test.cc as part of this rule in order to
0189 # prevent compiling gmock_test.o until all dependent files have been
0190 # generated.
0191 $(test_gmock_fused_test_SOURCES): fused-gmock-internal
0192 
0193 # TODO(vladl@google.com): Find a way to add Google Tests's sources here.
0194 fused-gmock-internal: $(pkginclude_HEADERS) $(pkginclude_internal_HEADERS) \
0195                       $(lib_libgmock_la_SOURCES) $(GMOCK_SOURCE_INGLUDES) \
0196                       $(lib_libgmock_main_la_SOURCES) \
0197                       scripts/fuse_gmock_files.py
0198         mkdir -p "$(srcdir)/fused-src"
0199         chmod -R u+w "$(srcdir)/fused-src"
0200         rm -f "$(srcdir)/fused-src/gtest/gtest.h"
0201         rm -f "$(srcdir)/fused-src/gmock/gmock.h"
0202         rm -f "$(srcdir)/fused-src/gmock-gtest-all.cc"
0203         "$(srcdir)/scripts/fuse_gmock_files.py" "$(srcdir)/fused-src"
0204         cp -f "$(srcdir)/src/gmock_main.cc" "$(srcdir)/fused-src"
0205 
0206 maintainer-clean-local:
0207         rm -rf "$(srcdir)/fused-src"
0208 endif
0209 
0210 # Death tests may produce core dumps in the build directory. In case
0211 # this happens, clean them to keep distcleancheck happy.
0212 CLEANFILES = core
0213 
0214 # Disables 'make install' as installing a compiled version of Google
0215 # Mock can lead to undefined behavior due to violation of the
0216 # One-Definition Rule.
0217 
0218 install-exec-local:
0219         echo "'make install' is dangerous and not supported. Instead, see README for how to integrate Google Mock into your build system."
0220         false
0221 
0222 install-data-local:
0223         echo "'make install' is dangerous and not supported. Instead, see README for how to integrate Google Mock into your build system."
0224         false