mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
This is the only dependency it has on libswiftCore. Looking this up at runtime allows its use in programs that don't link libswiftCore but might eventually load and run Swift code, such as xctest. While we're in there, enable tests in files ending with `.c`. rdar://problem/55274114
14 lines
531 B
C
14 lines
531 B
C
// RUN: %empty-directory(%t)
|
|
// RUN: %target-clang %s -all_load %test-resource-dir/%target-sdk-name/libswiftCompatibility50.a -lobjc -o %t/main
|
|
// RUN: %target-run %t/main
|
|
// REQUIRES: objc_interop
|
|
// REQUIRES: executable_test
|
|
|
|
// The compatibility library needs to have no build-time dependencies on
|
|
// libswiftCore so it can be linked into a program that doesn't link
|
|
// libswiftCore, but will load it at runtime, such as xctest.
|
|
//
|
|
// Test this by linking it into a plain C program and making sure it builds.
|
|
|
|
int main(void) {}
|