diff --git a/test-static-executable/dispatch-static-executable.swift b/test-static-executable/dispatch-static-executable.swift new file mode 100644 index 0000000..8eb485c --- /dev/null +++ b/test-static-executable/dispatch-static-executable.swift @@ -0,0 +1,6 @@ +import Dispatch + +let queue = DispatchQueue(label: "queuename", attributes: .concurrent) +queue.sync { + print("Dispatch") +} diff --git a/test-static-executable/dispatch-static-executable.test b/test-static-executable/dispatch-static-executable.test new file mode 100644 index 0000000..b9ee063 --- /dev/null +++ b/test-static-executable/dispatch-static-executable.test @@ -0,0 +1,9 @@ +REQUIRES: platform=Linux +RUN: rm -rf %t +RUN: mkdir -p %t +RUN: %{swiftc} -static-executable -lDispatchStubs -lbsd -o %t/dispatch_test %S/dispatch-static-executable.swift +RUN: %t/dispatch_test | %{FileCheck} %s +RUN: file %t/dispatch_test | %{FileCheck} %s --check-prefix=FILE +CHECK: Dispatch +FILE: , statically linked, + diff --git a/test-static-executable/static-executable.swift b/test-static-executable/static-executable.swift new file mode 100644 index 0000000..01d9c80 --- /dev/null +++ b/test-static-executable/static-executable.swift @@ -0,0 +1 @@ +print("OK") diff --git a/test-static-executable/static-executable.test b/test-static-executable/static-executable.test new file mode 100644 index 0000000..43b88c1 --- /dev/null +++ b/test-static-executable/static-executable.test @@ -0,0 +1,8 @@ +REQUIRES: platform=Linux +RUN: rm -rf %t +RUN: mkdir -p %t +RUN: %{swiftc} -static-executable -o %t/static_executable %S/static-executable.swift +RUN: %t/static_executable | %{FileCheck} %s +RUN: file %t/static_executable | %{FileCheck} %s --check-prefix=FILE +CHECK: OK +FILE: , statically linked,