summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOleksiy Vyalov <ovyalov@google.com>2015-01-22 20:03:21 +0000
committerOleksiy Vyalov <ovyalov@google.com>2015-01-22 20:03:21 +0000
commit49b71c609c0f8c008ac8d7ea9d9cce69858047b5 (patch)
treec4278f93e1b924322a7df992a013e71f0f5a050f
parent753f7c306be17d9ad7d82ee586f80271d3b3687f (diff)
downloadbcm5719-llvm-49b71c609c0f8c008ac8d7ea9d9cce69858047b5.tar.gz
bcm5719-llvm-49b71c609c0f8c008ac8d7ea9d9cce69858047b5.zip
Make OSX test run firewall friendly.
http://reviews.llvm.org/D7115 llvm-svn: 226856
-rw-r--r--lldb/lldb.xcodeproj/project.pbxproj14
-rw-r--r--lldb/test/api/multiple-debuggers/TestMultipleDebuggers.py1
-rw-r--r--lldb/test/api/multithreaded/TestMultithreaded.py4
-rw-r--r--lldb/test/lldbtest.py5
4 files changed, 23 insertions, 1 deletions
diff --git a/lldb/lldb.xcodeproj/project.pbxproj b/lldb/lldb.xcodeproj/project.pbxproj
index b5cfbfc7668..05ed9c6d649 100644
--- a/lldb/lldb.xcodeproj/project.pbxproj
+++ b/lldb/lldb.xcodeproj/project.pbxproj
@@ -5282,6 +5282,7 @@
buildPhases = (
26F5C26710F3D9A4009D5894 /* Sources */,
26F5C26810F3D9A4009D5894 /* Frameworks */,
+ 25ED0ED41A70979C00E3DA2E /* ShellScript */,
);
buildRules = (
);
@@ -5412,6 +5413,19 @@
/* End PBXResourcesBuildPhase section */
/* Begin PBXShellScriptBuildPhase section */
+ 25ED0ED41A70979C00E3DA2E /* ShellScript */ = {
+ isa = PBXShellScriptBuildPhase;
+ buildActionMask = 2147483647;
+ files = (
+ );
+ inputPaths = (
+ );
+ outputPaths = (
+ );
+ runOnlyForDeploymentPostprocessing = 0;
+ shellPath = /bin/sh;
+ shellScript = "if [ \"${CONFIGURATION}\" != BuildAndIntegration ]\nthen\ncodesign -f -s lldb_codesign \"${TARGET_BUILD_DIR}/${PRODUCT_NAME}\"\nfi";
+ };
261B5A7511C3FA6F00AABD0A /* Fixup Framework Headers */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
diff --git a/lldb/test/api/multiple-debuggers/TestMultipleDebuggers.py b/lldb/test/api/multiple-debuggers/TestMultipleDebuggers.py
index c0510a1a9d8..c88c1abc64e 100644
--- a/lldb/test/api/multiple-debuggers/TestMultipleDebuggers.py
+++ b/lldb/test/api/multiple-debuggers/TestMultipleDebuggers.py
@@ -26,6 +26,7 @@ class TestMultipleSimultaneousDebuggers(TestBase):
self.driver_exe = os.path.join(os.getcwd(), "multi-process-driver")
self.buildDriver('multi-process-driver.cpp', self.driver_exe)
self.addTearDownHook(lambda: os.remove(self.driver_exe))
+ self.signBinary(self.driver_exe)
self.inferior_exe = os.path.join(os.getcwd(), "testprog")
self.buildDriver('testprog.cpp', self.inferior_exe)
diff --git a/lldb/test/api/multithreaded/TestMultithreaded.py b/lldb/test/api/multithreaded/TestMultithreaded.py
index a00e57408fe..4478a118ecc 100644
--- a/lldb/test/api/multithreaded/TestMultithreaded.py
+++ b/lldb/test/api/multithreaded/TestMultithreaded.py
@@ -66,7 +66,9 @@ class SBBreakpointCallbackCase(TestBase):
self.buildDriver(sources, test_name)
self.addTearDownHook(lambda: os.remove(test_name))
- exe = [os.path.join(os.getcwd(), test_name), self.inferior]
+ test_exe = os.path.join(os.getcwd(), test_name)
+ self.signBinary(test_exe)
+ exe = [test_exe, self.inferior]
env = {self.dylibPath : self.getLLDBLibraryEnvVal()}
if self.TraceOn():
diff --git a/lldb/test/lldbtest.py b/lldb/test/lldbtest.py
index 80d1d29efc2..c08fc8b4f52 100644
--- a/lldb/test/lldbtest.py
+++ b/lldb/test/lldbtest.py
@@ -1422,6 +1422,11 @@ class Base(unittest2.TestCase):
if not module.buildDwarf(self, architecture, compiler, dictionary, clean):
raise Exception("Don't know how to build binary with dwarf")
+ def signBinary(self, binary_path):
+ if sys.platform.startswith("darwin"):
+ codesign_cmd = "codesign --force --sign lldb_codesign %s" % (binary_path)
+ call(codesign_cmd, shell=True)
+
def findBuiltClang(self):
"""Tries to find and use Clang from the build directory as the compiler (instead of the system compiler)."""
paths_to_try = [
OpenPOWER on IntegriCloud