diff options
author | Nick Lewycky <nicholas@mxc.ca> | 2011-04-29 02:12:06 +0000 |
---|---|---|
committer | Nick Lewycky <nicholas@mxc.ca> | 2011-04-29 02:12:06 +0000 |
commit | bcffb1fbb85a88cb99f7c2115a5f78e860d7fc46 (patch) | |
tree | a7e400febef581e1c8ce058f0cc40e33c6a39993 /cmake/modules/AddLLVM.cmake | |
parent | 6344a5f1464dade7735ac440d7a3d24bf009f298 (diff) | |
download | llvm-bcffb1fbb85a88cb99f7c2115a5f78e860d7fc46.tar.gz llvm-bcffb1fbb85a88cb99f7c2115a5f78e860d7fc46.tar.bz2 llvm-bcffb1fbb85a88cb99f7c2115a5f78e860d7fc46.tar.xz |
Rename profile_rt.so to libprofile_rt.so under configure+make (it already was
under cmake).
Add libprofile_rt.a so that we can tell clang to link against it in --coverage
mode. Also turn it on by default in cmake builds.
Oscar, this touches a change you made for EXCLUDE_FROM_ALL support -- I think
I've done the right thing, but please let me know (or fix and commit) if not!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@130470 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'cmake/modules/AddLLVM.cmake')
-rwxr-xr-x | cmake/modules/AddLLVM.cmake | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/cmake/modules/AddLLVM.cmake b/cmake/modules/AddLLVM.cmake index 4152164a29..c13143bb0d 100755 --- a/cmake/modules/AddLLVM.cmake +++ b/cmake/modules/AddLLVM.cmake @@ -17,9 +17,13 @@ macro(add_llvm_library name) # list. Without this, linking the unit tests on MinGW fails. link_system_libs( ${name} ) - install(TARGETS ${name} - LIBRARY DESTINATION lib${LLVM_LIBDIR_SUFFIX} - ARCHIVE DESTINATION lib${LLVM_LIBDIR_SUFFIX}) + if( EXCLUDE_FROM_ALL ) + set_target_properties( ${name} PROPERTIES EXCLUDE_FROM_ALL ON) + else() + install(TARGETS ${name} + LIBRARY DESTINATION lib${LLVM_LIBDIR_SUFFIX} + ARCHIVE DESTINATION lib${LLVM_LIBDIR_SUFFIX}) + endif() # The LLVM Target library shall be built before its sublibraries # (asmprinter, etc) because those may use tablegenned files which # generation is triggered by the main LLVM target library. Necessary @@ -58,7 +62,7 @@ ${name} ignored.") endif() if( EXCLUDE_FROM_ALL ) - set_target_properties(profile_rt PROPERTIES EXCLUDE_FROM_ALL ON) + set_target_properties( ${name} PROPERTIES EXCLUDE_FROM_ALL ON) else() install(TARGETS ${name} LIBRARY DESTINATION lib${LLVM_LIBDIR_SUFFIX} |