[PATCH] D12292: [CMake] merge add_compiler_rt_runtime and add_compiler_rt_darwin_runtime into a single function
Alexey Samsonov via llvm-commits
llvm-commits at lists.llvm.org
Mon Aug 24 14:54:58 PDT 2015
samsonov added inline comments.
================
Comment at: cmake/Modules/AddCompilerRT.cmake:63
@@ +62,3 @@
+function(add_compiler_rt_runtime name)
+ cmake_parse_arguments(LIB "SHARED;STATIC"
+ "OUTPUT_NAME;PARENT_TARGET"
----------------
beanz wrote:
> samsonov wrote:
> > I would leave SHARED/STATIC as `type` argument of `add_compiler_rt_runtime` function. Otherwise you can specify both STATIC and SHARED, which makes no sense. You should also diagnose if none is specified.
> There are situations where we build both static and dynamic libs. tsan/dd/CMakeLists.txt is one example. I was hoping to collapse that all down to one call to `add_compiler_rt_runtime`
>
> If you think it is better to support only one type I can do that. It will allow me to simplify some of the body of `add_compiler_t_runtime` too.
Yes, let's just support one type for now. If absolutely necessary, we could just call add_compiler_rt_runtime twice (we most likely would need to do it anyway, because CFLAGS/DEFS would be different in that case).
http://reviews.llvm.org/D12292
More information about the llvm-commits
mailing list