gparted/lib/gtest/Makefile.am

63 lines
2.7 KiB
Makefile
Raw Normal View History

# Nonstandard package files for distribution
Update to Google Test 1.10.0 (!117) So far GParted includes Google Test 1.8.1 [1], which was the latest release which supported pre-C++11 compilers [2]. Now that GParted requires C++11 compilation, update to Google Test 1.10.0. Replace the following files and directories from Google Test 1.10.0: LICENSE README.md include/ src/ Note the LICENSE file is identical, where as the other files have changed. This includes file additions and removals, hence the change to Makefile.am too. Even though Google Test releases up to and including 1.12.1 are compilable with C++11 compilers [3], it is not possible to upgrade beyond Google Test 1.10.0 at this time because later releases fail to compile on on still supported RHEL / CentOS 7 with this error: $ cd lib/gtest $ make check ... ./include/gtest/gtest-matchers.h:414:12: error: 'is_trivially_copy_constructible' is not a member of 'std' std::is_trivially_copy_constructible<M>::value && ^ This failure turns out to be because GCC libstdc++ 4.8.5 doesn't include is_trivially_copy_constructible et al [4][5]. [1] commit 2b222978f5e68964a3fa6d9e05e56bfdf6ab0526 Update to Google Test 1.8.1 [2] Google Test release v1.8.1 https://github.com/google/googletest/releases/tag/release-1.8.1 "The 1.8.x is the last release supporting pre-C++11 compilers." [3] Google Test release v1.12.1 https://github.com/google/googletest/releases/tag/release-1.12.1 "This will be the last release to support C++11. Future releases will require at least C++14." [4] 'is_trivially_copyable' is not a member of 'std' https://stackoverflow.com/questions/25123458/is-trivially-copyable-is-not-a-member-of-std/25123551#25123551 "Some of them are not implemented. If we look at libstdc++'s C++11 status page: Type properties are listed as partially implemented. They list as missing: ... is trivially_copy_constructible " [5] The GNU C++ Library, 1. Status, C++11 https://gcc.gnu.org/onlinedocs/gcc-4.8.3/libstdc++/manual/manual/status.html#status.iso.2011 " | Section | Description | Status | Comments ... | 20.9.4.3 | Type properties | Partial | Missing is_trivially_copyable, is_trivially_constructible, is_trivially_default_constructible, is_trivially_copy_constructible, is_trivially_move_constructible, is_trivially_assignable, is_trivially_default_assignable, is_trivially_copy_assignable, is_trivially_move_assignable | " Closes !117 - Require C++11 compilation
2023-09-03 04:35:51 -06:00
EXTRA_DIST = \
LICENSE \
README.md \
include/gtest/internal/custom/README.md \
include/gtest/internal/gtest-type-util.h.pump
Update to Google Test 1.10.0 (!117) So far GParted includes Google Test 1.8.1 [1], which was the latest release which supported pre-C++11 compilers [2]. Now that GParted requires C++11 compilation, update to Google Test 1.10.0. Replace the following files and directories from Google Test 1.10.0: LICENSE README.md include/ src/ Note the LICENSE file is identical, where as the other files have changed. This includes file additions and removals, hence the change to Makefile.am too. Even though Google Test releases up to and including 1.12.1 are compilable with C++11 compilers [3], it is not possible to upgrade beyond Google Test 1.10.0 at this time because later releases fail to compile on on still supported RHEL / CentOS 7 with this error: $ cd lib/gtest $ make check ... ./include/gtest/gtest-matchers.h:414:12: error: 'is_trivially_copy_constructible' is not a member of 'std' std::is_trivially_copy_constructible<M>::value && ^ This failure turns out to be because GCC libstdc++ 4.8.5 doesn't include is_trivially_copy_constructible et al [4][5]. [1] commit 2b222978f5e68964a3fa6d9e05e56bfdf6ab0526 Update to Google Test 1.8.1 [2] Google Test release v1.8.1 https://github.com/google/googletest/releases/tag/release-1.8.1 "The 1.8.x is the last release supporting pre-C++11 compilers." [3] Google Test release v1.12.1 https://github.com/google/googletest/releases/tag/release-1.12.1 "This will be the last release to support C++11. Future releases will require at least C++14." [4] 'is_trivially_copyable' is not a member of 'std' https://stackoverflow.com/questions/25123458/is-trivially-copyable-is-not-a-member-of-std/25123551#25123551 "Some of them are not implemented. If we look at libstdc++'s C++11 status page: Type properties are listed as partially implemented. They list as missing: ... is trivially_copy_constructible " [5] The GNU C++ Library, 1. Status, C++11 https://gcc.gnu.org/onlinedocs/gcc-4.8.3/libstdc++/manual/manual/status.html#status.iso.2011 " | Section | Description | Status | Comments ... | 20.9.4.3 | Type properties | Partial | Missing is_trivially_copyable, is_trivially_constructible, is_trivially_default_constructible, is_trivially_copy_constructible, is_trivially_move_constructible, is_trivially_assignable, is_trivially_default_assignable, is_trivially_copy_assignable, is_trivially_move_assignable | " Closes !117 - Require C++11 compilation
2023-09-03 04:35:51 -06:00
# Google Test source files that we don't compile directly. (Instead
# they are #included by gtest-all.cc).
# List files with:
# cd lib/gtest/
# find src include '(' -name '*.h' -o -name '*.cc' ')' -print | \
# egrep -v 'gtest-all.cc|gtest_main.cc' | sort
GTEST_SRC = \
include/gtest/gtest-death-test.h \
include/gtest/gtest.h \
include/gtest/gtest-matchers.h \
include/gtest/gtest-message.h \
include/gtest/gtest-param-test.h \
include/gtest/gtest_pred_impl.h \
include/gtest/gtest-printers.h \
include/gtest/gtest_prod.h \
include/gtest/gtest-spi.h \
include/gtest/gtest-test-part.h \
include/gtest/gtest-typed-test.h \
include/gtest/internal/custom/gtest.h \
include/gtest/internal/custom/gtest-port.h \
include/gtest/internal/custom/gtest-printers.h \
include/gtest/internal/gtest-death-test-internal.h \
include/gtest/internal/gtest-filepath.h \
include/gtest/internal/gtest-internal.h \
include/gtest/internal/gtest-param-util.h \
include/gtest/internal/gtest-port-arch.h \
include/gtest/internal/gtest-port.h \
include/gtest/internal/gtest-string.h \
include/gtest/internal/gtest-type-util.h \
src/gtest.cc \
src/gtest-death-test.cc \
src/gtest-filepath.cc \
src/gtest-internal-inl.h \
src/gtest-matchers.cc \
src/gtest-port.cc \
src/gtest-printers.cc \
src/gtest-test-part.cc \
src/gtest-typed-test.cc
EXTRA_DIST += $(GTEST_SRC)
# We define the global AM_CPPFLAGS as everything we compile includes from these
# directories.
AM_CPPFLAGS = -I$(srcdir) -I$(srcdir)/include $(GTEST_CPPFLAGS)
AM_CXXFLAGS = $(GTEST_CXXFLAGS)
AM_LDFLAGS = $(GTEST_LDFLAGS)
LDADD = $(GTEST_LIBS)
# Build rules for libraries.
check_LTLIBRARIES = lib/libgtest.la lib/libgtest_main.la
lib_libgtest_la_SOURCES = src/gtest-all.cc
lib_libgtest_main_la_SOURCES = src/gtest_main.cc
lib_libgtest_main_la_LIBADD = lib/libgtest.la