[CMake] Always build debugserver on Darwin and allow tests to use the system's one
authorStefan Granitz <stefan.graenitz@gmail.com>
Thu, 18 Jul 2019 13:30:37 +0000 (13:30 +0000)
committerStefan Granitz <stefan.graenitz@gmail.com>
Thu, 18 Jul 2019 13:30:37 +0000 (13:30 +0000)
commit0c4948455d353e4822fb69310893f281599050e5
treed8fbe6442155a00495c928ece8ffb4c0d0480c1c
parent6a61bea4d652442e43d41253c60604cb37b98b7a
[CMake] Always build debugserver on Darwin and allow tests to use the system's one

Summary:
We can always build debugserver, but we can't always sign it to be useable for testing. `LLDB_USE_SYSTEM_DEBUGSERVER` should only tell whether or not the system debugserver should be used for testing.
The old behavior complicated the logic around debugserver a lot. The new logic sorts out most of it.

Please note that this patch is in early stage and needs some more testing. It should not affect platfroms other than Darwin. It builds on Davide's approach to validate the code-signing identity at configuration time.

What do you think?

Reviewers: xiaobai, JDevlieghere, davide, compnerd, friss, labath, mgorny, jasonmolenda

Reviewed By: JDevlieghere

Subscribers: lldb-commits, #lldb

Tags: #lldb

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

llvm-svn: 366433
lldb/CMakeLists.txt
lldb/cmake/modules/AddLLDB.cmake
lldb/cmake/modules/LLDBConfig.cmake
lldb/test/CMakeLists.txt
lldb/tools/debugserver/source/CMakeLists.txt
lldb/unittests/CMakeLists.txt
lldb/unittests/tools/lldb-server/CMakeLists.txt