summaryrefslogtreecommitdiff
path: root/cmake
diff options
context:
space:
mode:
authorAlexey Samsonov <samsonov@google.com>2013-10-01 12:52:15 +0000
committerAlexey Samsonov <samsonov@google.com>2013-10-01 12:52:15 +0000
commitc349466646968133e0bad48d24e267580bad6c07 (patch)
tree57201c4bd6830b4c84ac23138cc23b25acb6e167 /cmake
parent2946f13d6ca0cfc46d74c12e97dc40a17a7d232f (diff)
downloadcompiler-rt-c349466646968133e0bad48d24e267580bad6c07.tar.gz
compiler-rt-c349466646968133e0bad48d24e267580bad6c07.tar.bz2
compiler-rt-c349466646968133e0bad48d24e267580bad6c07.tar.xz
Add top-level CMake 'compiler-rt' target to build all compiler-rt libraries
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@191747 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'cmake')
-rw-r--r--cmake/Modules/AddCompilerRT.cmake3
-rw-r--r--cmake/Modules/SanitizerUtils.cmake1
2 files changed, 4 insertions, 0 deletions
diff --git a/cmake/Modules/AddCompilerRT.cmake b/cmake/Modules/AddCompilerRT.cmake
index 021920c9..def0c071 100644
--- a/cmake/Modules/AddCompilerRT.cmake
+++ b/cmake/Modules/AddCompilerRT.cmake
@@ -58,6 +58,7 @@ macro(add_compiler_rt_static_runtime name arch)
# Add installation command.
install(TARGETS ${name}
ARCHIVE DESTINATION ${COMPILER_RT_LIBRARY_INSTALL_DIR})
+ add_dependencies(compiler-rt ${name})
else()
message(FATAL_ERROR "Archtecture ${arch} can't be targeted")
endif()
@@ -80,6 +81,7 @@ macro(add_compiler_rt_osx_static_runtime name)
ARCHIVE_OUTPUT_DIRECTORY ${COMPILER_RT_LIBRARY_OUTPUT_DIR})
install(TARGETS ${name}
ARCHIVE DESTINATION ${COMPILER_RT_LIBRARY_INSTALL_DIR})
+ add_dependencies(compiler-rt ${name})
endmacro()
# Adds dynamic runtime library on osx, which supports multiple architectures.
@@ -100,6 +102,7 @@ macro(add_compiler_rt_osx_dynamic_runtime name)
LIBRARY_OUTPUT_DIRECTORY ${COMPILER_RT_LIBRARY_OUTPUT_DIR})
install(TARGETS ${name}
LIBRARY DESTINATION ${COMPILER_RT_LIBRARY_INSTALL_DIR})
+ add_dependencies(compiler-rt ${name})
endmacro()
# Unittests support.
diff --git a/cmake/Modules/SanitizerUtils.cmake b/cmake/Modules/SanitizerUtils.cmake
index aa7be300..0836edee 100644
--- a/cmake/Modules/SanitizerUtils.cmake
+++ b/cmake/Modules/SanitizerUtils.cmake
@@ -26,6 +26,7 @@ macro(add_sanitizer_rt_symbols name)
DEPENDS ${symsfile}
SOURCES ${SANITIZER_GEN_DYNAMIC_LIST} ${ARGN})
install(FILES ${symsfile} DESTINATION ${COMPILER_RT_LIBRARY_INSTALL_DIR})
+ add_dependencies(compiler-rt ${name}-symbols)
endmacro()
# Add target to check code style for sanitizer runtimes.