[builtins] Use libtool for builtins when building for Apple platform
authorPetr Hosek <phosek@chromium.org>
Tue, 4 Jun 2019 02:38:15 +0000 (02:38 +0000)
committerPetr Hosek <phosek@chromium.org>
Tue, 4 Jun 2019 02:38:15 +0000 (02:38 +0000)
commitd2d6c17760d59a3dcab722bea80663590a52fe2e
treec921d1250c0eff02480bb0aa7d677111286dff20
parentf67524d4006c1080997fdead8af9fcba6cfc7e6e
[builtins] Use libtool for builtins when building for Apple platform

compiler-rt already uses libtool instead of ar when building for
Apple platform, but that's not being used when builtins are being
built separately e.g. as part of the runtimes build. This change
extracts the logic setting up libtool into a separate file and uses
it from both the compiler-rt and standalone builtins build.

Differential Revision: https://reviews.llvm.org/D62820

llvm-svn: 362466
compiler-rt/CMakeLists.txt
compiler-rt/cmake/Modules/UseLibtool.cmake [new file with mode: 0644]
compiler-rt/lib/builtins/CMakeLists.txt