Repository navigation
Description
when compiling the library for openSUSE it installs also the gmock and gtest libraries and sources:
Make install command:
make VERBOSE=1 DESTDIR=/home/abuild/rpmbuild/BUILDROOT/cpp-netlib-0.12.0-0.x86_64 install/fast -C build
Output:
[ 283s] make: Entering directory '/home/abuild/rpmbuild/BUILD/cpp-netlib-0.12.0-final/build'
[ 283s] /usr/bin/make -f CMakeFiles/Makefile2 preinstall
[ 283s] make[1]: Entering directory '/home/abuild/rpmbuild/BUILD/cpp-netlib-0.12.0-final/build'
[ 283s] make[1]: Nothing to be done for 'preinstall'.
[ 283s] make[1]: Leaving directory '/home/abuild/rpmbuild/BUILD/cpp-netlib-0.12.0-final/build'
[ 283s] Install the project...
[ 283s] /usr/bin/cmake -P cmake_install.cmake
[ 283s] -- Install configuration: "None"
[ 283s] -- Installing: /home/abuild/rpmbuild/BUILDROOT/cpp-netlib-0.12.0-0.x86_64/usr/include/boost
... more netlib things (correct) ...
[ 283s] -- Installing: /home/abuild/rpmbuild/BUILDROOT/cpp-netlib-0.12.0-0.x86_64/usr/lib/libgmock.so
[ 283s] -- Installing: /home/abuild/rpmbuild/BUILDROOT/cpp-netlib-0.12.0-0.x86_64/usr/lib/libgmock_main.so
[ 283s] -- Installing: /home/abuild/rpmbuild/BUILDROOT/cpp-netlib-0.12.0-0.x86_64/usr/include/gmock
[ 283s] -- Installing: /home/abuild/rpmbuild/BUILDROOT/cpp-netlib-0.12.0-0.x86_64/usr/include/gmock/gmock-generated-matchers.h
[ 283s] -- Installing: /home/abuild/rpmbuild/BUILDROOT/cpp-netlib-0.12.0-0.x86_64/usr/include/gmock/gmock-generated-actions.h.pump
[ 283s] -- Installing: /home/abuild/rpmbuild/BUILDROOT/cpp-netlib-0.12.0-0.x86_64/usr/include/gmock/internal
[ 283s] -- Installing: /home/abuild/rpmbuild/BUILDROOT/cpp-netlib-0.12.0-0.x86_64/usr/include/gmock/internal/gmock-internal-utils.h
[ 283s] -- Installing: /home/abuild/rpmbuild/BUILDROOT/cpp-netlib-0.12.0-0.x86_64/usr/include/gmock/internal/gmock-generated-internal-utils.h
[ 283s] -- Installing: /home/abuild/rpmbuild/BUILDROOT/cpp-netlib-0.12.0-0.x86_64/usr/include/gmock/internal/gmock-port.h
[ 283s] -- Installing: /home/abuild/rpmbuild/BUILDROOT/cpp-netlib-0.12.0-0.x86_64/usr/include/gmock/internal/custom
[ 283s] -- Installing: /home/abuild/rpmbuild/BUILDROOT/cpp-netlib-0.12.0-0.x86_64/usr/include/gmock/internal/custom/gmock-generated-actions.h.pump
... more gmock things ...
Result: A lot of not needed things got installed:
[ 284s] /usr/include/gmock/gmock-actions.h
[ 284s] /usr/include/gmock/gmock-cardinalities.h
[ 284s] /usr/include/gmock/gmock-generated-actions.h
[ 284s] /usr/include/gmock/gmock-generated-actions.h.pump
[ 284s] /usr/include/gmock/gmock-generated-function-mockers.h
[ 284s] /usr/include/gmock/gmock-generated-function-mockers.h.pump
[ 284s] /usr/include/gmock/gmock-generated-matchers.h
[ 284s] /usr/include/gmock/gmock-generated-matchers.h.pump
[ 284s] /usr/include/gmock/gmock-generated-nice-strict.h
[ 284s] /usr/include/gmock/gmock-generated-nice-strict.h.pump
[ 284s] /usr/include/gmock/gmock-matchers.h
[ 284s] /usr/include/gmock/gmock-more-actions.h
[ 284s] /usr/include/gmock/gmock-more-matchers.h
[ 284s] /usr/include/gmock/gmock-spec-builders.h
[ 284s] /usr/include/gmock/gmock.h
[ 284s] /usr/include/gmock/internal/custom/gmock-generated-actions.h
[ 284s] /usr/include/gmock/internal/custom/gmock-generated-actions.h.pump
[ 284s] /usr/include/gmock/internal/custom/gmock-matchers.h
[ 284s] /usr/include/gmock/internal/custom/gmock-port.h
[ 284s] /usr/include/gmock/internal/gmock-generated-internal-utils.h
[ 284s] /usr/include/gmock/internal/gmock-generated-internal-utils.h.pump
[ 284s] /usr/include/gmock/internal/gmock-internal-utils.h
[ 284s] /usr/include/gmock/internal/gmock-port.h
[ 284s] /usr/include/gtest/gtest-death-test.h
[ 284s] /usr/include/gtest/gtest-message.h
[ 284s] /usr/include/gtest/gtest-param-test.h
[ 284s] /usr/include/gtest/gtest-param-test.h.pump
[ 284s] /usr/include/gtest/gtest-printers.h
[ 284s] /usr/include/gtest/gtest-spi.h
[ 284s] /usr/include/gtest/gtest-test-part.h
[ 284s] /usr/include/gtest/gtest-typed-test.h
[ 284s] /usr/include/gtest/gtest.h
[ 284s] /usr/include/gtest/gtest_pred_impl.h
[ 284s] /usr/include/gtest/gtest_prod.h
[ 284s] /usr/include/gtest/internal/custom/gtest-port.h
[ 284s] /usr/include/gtest/internal/custom/gtest-printers.h
[ 284s] /usr/include/gtest/internal/custom/gtest.h
[ 284s] /usr/include/gtest/internal/gtest-death-test-internal.h
[ 284s] /usr/include/gtest/internal/gtest-filepath.h
[ 284s] /usr/include/gtest/internal/gtest-internal.h
[ 284s] /usr/include/gtest/internal/gtest-linked_ptr.h
[ 284s] /usr/include/gtest/internal/gtest-param-util-generated.h
[ 284s] /usr/include/gtest/internal/gtest-param-util-generated.h.pump
[ 284s] /usr/include/gtest/internal/gtest-param-util.h
[ 284s] /usr/include/gtest/internal/gtest-port-arch.h
[ 284s] /usr/include/gtest/internal/gtest-port.h
[ 284s] /usr/include/gtest/internal/gtest-string.h
[ 284s] /usr/include/gtest/internal/gtest-tuple.h
[ 284s] /usr/include/gtest/internal/gtest-tuple.h.pump
[ 284s] /usr/include/gtest/internal/gtest-type-util.h
[ 284s] /usr/include/gtest/internal/gtest-type-util.h.pump
[ 284s] /usr/lib/libgmock.so
[ 284s] /usr/lib/libgmock_main.so
[ 284s] /usr/lib/libgtest.so
[ 284s] /usr/lib/libgtest_main.so
Activity
deanberris commentedon Apr 8, 2016
Oh. Okay, this is because we've made googletest and googlemock part of the source for building tests. I think the best way to resolve this is to define
CPP-NETLIB_BUILD_TESTS=OFF. Does that solve the issue? If it doesn't then it should be something we fix in 0.12.1.susnux commentedon Apr 8, 2016
@deanberris Yes it works with that define.
But I think even with tests they should not get installed.
LiSongMWO commentedon Jun 15, 2019
I ran
make installand it installed both gtest, gmock and boost, overwriting my system files, uninstalling cpp-netlib will now break my system in subtle ways.This is unacceptable.
deanberris commentedon Jun 17, 2019
What version of the library are you using, @EmilyBjoerk? If this is the 0.13.x release, then that's certainly not intended. We still don't have a good way of properly isolating Google Test, and we definitely should be fixing this.
LiSongMWO commentedon Jun 19, 2019
@deanberris the latest version from the releases page (0.13.0 final I think)