From b47d3560938d37d7f0d68de7b3f559dfdfba8861 Mon Sep 17 00:00:00 2001 From: Frederic Riss Date: Tue, 16 Apr 2019 20:54:42 +0000 Subject: [debugserver] Relax the codesigning identity check In an effort to help new LLDB developers, we added checks and messaging around the selection of your codesigning identity on macOS. While helpful, it is not actually correct. It's perfectly valid to codesign with an identity that is not named lldb_codesign. Currently this fails the build. This patch keeps a warning that informs developers how to setup lldb_codesign and how to pass it to cmake, but it allows the build to proceed with a different identity. llvm-svn: 358525 --- lldb/tools/debugserver/source/CMakeLists.txt | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) diff --git a/lldb/tools/debugserver/source/CMakeLists.txt b/lldb/tools/debugserver/source/CMakeLists.txt index bbc2984c59a..ad7a3af915c 100644 --- a/lldb/tools/debugserver/source/CMakeLists.txt +++ b/lldb/tools/debugserver/source/CMakeLists.txt @@ -93,18 +93,14 @@ elseif(NOT LLDB_NO_DEBUGSERVER) # Default case: on Darwin we need the right code signing ID. # See lldb/docs/code-signing.txt for details. if(CMAKE_HOST_APPLE AND NOT LLVM_CODESIGNING_IDENTITY STREQUAL "lldb_codesign") - set(problem "Cannot code sign debugserver with LLVM_CODESIGNING_IDENTITY '${LLVM_CODESIGNING_IDENTITY}'.") - set(advice "Pass -DLLDB_CODESIGN_IDENTITY=lldb_codesign to override the LLVM value for debugserver.") - if(system_debugserver) - set(effect "Will fall back to system's debugserver.") - set(use_system_debugserver ON) - else() - set(effect "debugserver will not be available.") - endif() - message(WARNING "${problem} ${effect} ${advice}") - else() - set(build_and_sign_debugserver ON) + message(WARNING "Codesigning debugserver with identity ${LLVM_CODESIGNING_IDENTITY}. " + "The usual setup uses the \"lldb_codesign\" identity created with " + "scripts/macos-setup-codesign.sh. As a result your debugserver might " + "not be able to attach to processes.\n" + "Pass -DLLDB_CODESIGN_IDENTITY=lldb_codesign to use the development " + "signing identity.") endif() + set(build_and_sign_debugserver ON) endif() # TODO: We don't use the $ generator expression here, -- cgit v1.2.3