davide updated this revision to Diff 206475. davide added a comment. Address feedback from many.
Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63745/new/ https://reviews.llvm.org/D63745 Files: lldb/tools/debugserver/source/CMakeLists.txt Index: lldb/tools/debugserver/source/CMakeLists.txt =================================================================== --- lldb/tools/debugserver/source/CMakeLists.txt +++ lldb/tools/debugserver/source/CMakeLists.txt @@ -142,6 +142,21 @@ message(STATUS "lldb debugserver will not be available.") endif() +# On MacOS, debugserver needs to be codesigned when built. Check if we have +# a certificate instead of failing in the middle of the build. +if(build_and_sign_debugserver) + execute_process( + COMMAND security find-certificate -Z -p -c ${LLDB_CODESIGN_IDENTITY_USED} /Library/Keychains/System.keychain + RESULT_VARIABLE cert_return + OUTPUT_QUIET + ERROR_QUIET) + + if (cert_return) + message(FATAL_ERROR "Certificate for debugserver not found. Run scripts/macos-setup-codesign.sh or " + "use the system debugserver passing -DLLDB_USE_SYSTEM_DEBUGSERVER=ON to CMake") + endif() +endif() + if(APPLE) if(IOS) find_library(BACKBOARD_LIBRARY BackBoardServices
Index: lldb/tools/debugserver/source/CMakeLists.txt =================================================================== --- lldb/tools/debugserver/source/CMakeLists.txt +++ lldb/tools/debugserver/source/CMakeLists.txt @@ -142,6 +142,21 @@ message(STATUS "lldb debugserver will not be available.") endif() +# On MacOS, debugserver needs to be codesigned when built. Check if we have +# a certificate instead of failing in the middle of the build. +if(build_and_sign_debugserver) + execute_process( + COMMAND security find-certificate -Z -p -c ${LLDB_CODESIGN_IDENTITY_USED} /Library/Keychains/System.keychain + RESULT_VARIABLE cert_return + OUTPUT_QUIET + ERROR_QUIET) + + if (cert_return) + message(FATAL_ERROR "Certificate for debugserver not found. Run scripts/macos-setup-codesign.sh or " + "use the system debugserver passing -DLLDB_USE_SYSTEM_DEBUGSERVER=ON to CMake") + endif() +endif() + if(APPLE) if(IOS) find_library(BACKBOARD_LIBRARY BackBoardServices
_______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits