[CMake] Get rid of LLVM_DYLIB_EXPORT_ALL, and make it the default, add libLLVM-C...
authorChris Bieneman <beanz@apple.com>
Tue, 27 Oct 2015 16:02:04 +0000 (16:02 +0000)
committerChris Bieneman <beanz@apple.com>
Tue, 27 Oct 2015 16:02:04 +0000 (16:02 +0000)
commitcd9aae70e988dbd80af933bc144f1c8df431a0e9
tree61bfdab3405f93af8f67160755345d481dcc6241
parentcc4e8d7e1d66cddd7daa443aea22e83964c6ae1d
[CMake] Get rid of LLVM_DYLIB_EXPORT_ALL, and make it the default, add libLLVM-C on darwin to cover the C API needs.

Summary:
We've had a lot of discussion in the past about the meaningful and useful default behaviors for the llvm-shlib tool. The original implementation was heavily geared toward Apple's use, and I think that was wrong. This patch seeks to correct that.

I've removed the LLVM_DYLIB_EXPORT_ALL variable and made libLLVM export everything by default.

I've also added a new target that is only built on Darwin for libLLVM-C as a library that re-exports the LLVM-C API. This library is not built on Linux because ELF doesn't support re-export libraries in the same way MachO does.

Reviewers: chapuni, resistor, bogner, axw

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D13842

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@251411 91177308-0d34-0410-b5e6-96231b3b80d8
CMakeLists.txt
tools/llvm-shlib/CMakeLists.txt