Re: git: 28f6c2f29280 - main - Import GoogleTest 1.14.0

From: Dag-Erling_Smørgrav <des_at_FreeBSD.org>
Date: Mon, 14 Aug 2023 03:11:15 UTC
Enji Cooper <ngie@FreeBSD.org> writes:
> commit 28f6c2f292806bf31230a959bc4b19d7081669a7
> Author:     Enji Cooper <ngie@FreeBSD.org>
> AuthorDate: 2023-08-08 06:17:32 +0000
> Commit:     Enji Cooper <ngie@FreeBSD.org>
> CommitDate: 2023-08-10 09:32:33 +0000
>
>     Import GoogleTest 1.14.0

I haven't been able to build world since this went in.

===> tests/sys/fs/fusefs (all)
(cd /usr/src/tests/sys/fs/fusefs &&  DEPENDFILE=.depend.access  NO_SUBDIR=1 make -f /usr/src/tests/sys/fs/fusefs/Makefile _RECURSING_PROGS=t  PROG=access PROG_CXX=access)
c++ -target x86_64-unknown-freebsd14.0 --sysroot=/usr/obj/usr/src/amd64.amd64/tmp -B/usr/obj/usr/src/amd64.amd64/tmp/usr/bin -O2 -pipe -fno-common -fPIE -g -gz=zlib -Wno-format-zero-length -fstack-protector-strong -Wsystem-headers -Werror -Wall -Wno-format-y2k -W -Wno-unused-parameter -Wpointer-arith -Wreturn-type -Wcast-qual -Wwrite-strings -Wswitch -Wshadow -Wunused-parameter -Wcast-align -Wchar-subscripts -Wdate-time -Wmissing-variable-declarations -Wno-empty-body -Wno-string-plus-int -Wno-unused-const-variable -Wno-error=unused-but-set-parameter -Qunused-arguments -I/usr/src/tests -I/usr/src/sys/fs/fuse -I/usr/src/sbin/mount -I/usr/obj/usr/src/amd64.amd64/tmp/usr/include/private -DGTEST_HAS_POSIX_RE=1 -DGTEST_HAS_PTHREAD=1 -DGTEST_HAS_STREAM_REDIRECTION=1 -frtti -Wno-deprecated-copy -Wno-signed-unsigned-wchar -fPIE -std=c++14 -Wno-deprecated-copy -Wno-c++11-extensions  -Wl,-zrelro -pie  -o access.full  access.o getmntopts.o mockfs.o utils.o  -lprivategmock -lprivategtest -lprivategtest  -lutil -lpthread
ld: error: undefined symbol: testing::internal::g_linked_ptr_mutex
>>> referenced by gtest-port.h:2137 (/usr/obj/usr/src/amd64.amd64/tmp/usr/include/private/gtest/internal/gtest-port.h:2137)
>>>               mockfs.o:(testing::internal::linked_ptr_internal::depart())
>>> referenced by gtest-port.h:2139 (/usr/obj/usr/src/amd64.amd64/tmp/usr/include/private/gtest/internal/gtest-port.h:2139)
>>>               mockfs.o:(testing::internal::linked_ptr_internal::depart())
>>> referenced by gtest-port.h:2139 (/usr/obj/usr/src/amd64.amd64/tmp/usr/include/private/gtest/internal/gtest-port.h:2139)
>>>               mockfs.o:(testing::internal::linked_ptr_internal::depart())
>>> referenced 3 more times

ld: error: undefined symbol: testing::internal2::PrintBytesInObjectTo(unsigned char const*, unsigned long, std::__1::basic_ostream<char, std::__1::char_traits<char>>*)
>>> referenced by gtest-printers.h:155 (/usr/obj/usr/src/amd64.amd64/tmp/usr/include/private/gtest/gtest-printers.h:155)
>>>               mockfs.o:(void testing::internal::TuplePrefixPrinter<2ul>::PrintPrefixTo<std::__1::tuple<mockfs_buf_in const&, std::__1::vector<std::__1::unique_ptr<mockfs_buf_out, std::__1::default_delete<mockfs_buf_out>>, std::__1::allocator<std::__1::unique_ptr<mockfs_buf_out, s
td::__1::default_delete<mockfs_buf_out>>>>&>>(std::__1::tuple<mockfs_buf_in const&, std::__1::vector<std::__1::unique_ptr<mockfs_buf_out, std::__1::default_delete<mockfs_buf_out>>, std::__1::allocator<std::__1::unique_ptr<mockfs_buf_out, std::__1::default_delete<mockfs_buf_out>>>>&> 
const&, std::__1::basic_ostream<char, std::__1::char_traits<char>>*))
>>> referenced by gtest-printers.h:155 (/usr/obj/usr/src/amd64.amd64/tmp/usr/include/private/gtest/gtest-printers.h:155)
>>>               mockfs.o:(void testing::internal::TuplePrefix<1ul>::ExplainMatchFailuresTo<std::__1::tuple<testing::Matcher<mockfs_buf_in const&>, testing::Matcher<std::__1::vector<std::__1::unique_ptr<mockfs_buf_out, std::__1::default_delete<mockfs_buf_out>>, std::__1::allocator<s
td::__1::unique_ptr<mockfs_buf_out, std::__1::default_delete<mockfs_buf_out>>>>&>>, std::__1::tuple<mockfs_buf_in const&, std::__1::vector<std::__1::unique_ptr<mockfs_buf_out, std::__1::default_delete<mockfs_buf_out>>, std::__1::allocator<std::__1::unique_ptr<mockfs_buf_out, std::__1
::default_delete<mockfs_buf_out>>>>&>>(std::__1::tuple<testing::Matcher<mockfs_buf_in const&>, testing::Matcher<std::__1::vector<std::__1::unique_ptr<mockfs_buf_out, std::__1::default_delete<mockfs_buf_out>>, std::__1::allocator<std::__1::unique_ptr<mockfs_buf_out, std::__1::default_
delete<mockfs_buf_out>>>>&>> const&, std::__1::tuple<mockfs_buf_in const&, std::__1::vector<std::__1::unique_ptr<mockfs_buf_out, std::__1::default_delete<mockfs_buf_out>>, std::__1::allocator<std::__1::unique_ptr<mockfs_buf_out, std::__1::default_delete<mockfs_buf_out>>>>&> const&, s
td::__1::basic_ostream<char, std::__1::char_traits<char>>*))

ld: error: undefined symbol: testing::internal::UntypedFunctionMockerBase::UntypedInvokeWith(void*)
>>> referenced by gmock-spec-builders.h:1603 (/usr/obj/usr/src/amd64.amd64/tmp/usr/include/private/gmock/gmock-spec-builders.h:1603)
>>>               mockfs.o:(testing::internal::FunctionMockerBase<void (mockfs_buf_in const&, std::__1::vector<std::__1::unique_ptr<mockfs_buf_out, std::__1::de
fault_delete<mockfs_buf_out>>, std::__1::allocator<std::__1::unique_ptr<mockfs_buf_out, std::__1::default_delete<mockfs_buf_out>>>>&)>::InvokeWith(std::__1::tuple<mockfs_buf_in const&, std::__1::vector<std::__1::unique_ptr<mockfs_buf_out, std::__1::default_delete<mockfs_buf_out>>, std::__1::allocator<std::__1::unique_ptr<mockfs_buf_out, std::__1::default_delete<mockfs_buf_out>>>>&>&&))

ld: error: undefined symbol: testing::Expectation::Expectation(testing::internal::linked_ptr<testing::internal::ExpectationBase> const&)
>>> referenced by gmock-spec-builders.h:1634 (/usr/obj/usr/src/amd64.amd64/tmp/usr/include/private/gmock/gmock-spec-builders.h:1634)
>>>               utils.o:(testing::internal::FunctionMockerBase<void (mockfs_buf_in const&, std::__1::vector<std::__1::unique_ptr<mockfs_buf_out, std::__1::default_delete<mockfs_buf_out>>, std::__1::allocator<std::__1::unique_ptr<mockfs_buf_out, std::__1::default_delete<mockfs_buf_out>>>>&)>::AddNewExpectation(char const*, int, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&, std::__1::tuple<testing::Matcher<mockfs_buf_in const&>, testing::Matcher<std::__1::vector<std::__1::unique_ptr<mockfs_buf_out, std::__1::default_delete<mockfs_buf_out>>, std::__1::allocator<std::__1::unique_ptr<mockfs_buf_out, std::__1::default_delete<mockfs_buf_out>>>>&>> const&))
c++: error: linker command failed with exit code 1 (use -v to see invocation)
*** Error code 1

Stop.

DES
-- 
Dag-Erling Smørgrav - des@FreeBSD.org