This is an archive of the discontinued LLVM Phabricator instance.

cmake: Do not install libgtest
AbandonedPublic

Authored by mgorny on Aug 23 2016, 1:59 PM.

Details

Summary

libgtest is an internal test dependency, and should not be installed to
the live system as a part of LLVM. Installing it top-level is just
asking for trouble, especially that LLVM has no right to claim that
specific filename and any other package may decide to install file with
the same name.

Bug: http://llvm.org/bugs/show_bug.cgi?id=18341

Diff Detail

Event Timeline

mgorny updated this revision to Diff 69031.Aug 23 2016, 1:59 PM
mgorny retitled this revision from to cmake: Do not install libgtest .
mgorny updated this object.
mgorny added a reviewer: Bigcheese.
mgorny added a subscriber: llvm-commits.
vsk accepted this revision.Aug 23 2016, 11:50 PM
vsk added a reviewer: vsk.
vsk added a subscriber: vsk.

I think this excludes the gtest_main library too. Which is fine by me. LGTM.

This revision is now accepted and ready to land.Aug 23 2016, 11:50 PM

Thanks for the review. Could you commit it, please? I don't have commit access.

Hold on. Why is r240981 not enough to fix the problem? Is it because we still append the gtest* libraries into LLVM_EXPORTS (cmake/modules/AddLLVM.cmake +577)?

Hmm, I'm going to recheck that and get back to you ASAP.

mgorny abandoned this revision.Aug 24 2016, 11:17 AM

I'm sorry, indeed it seems that this revision handles it, and my patch is not necessary anymore.