483725f83a47831f05a3a60a43c29e89c26be790
2 // BUILD: $CC main.c -o $BUILD_DIR/dlopen-prebuilt-dlopen-closure.exe
4 // RUN: ./dlopen-prebuilt-dlopen-closure.exe
6 // /usr/lib/libobjc-trampolines.dylib is not in the shared cache, but gets a prebuilt
7 // closure. On embedded platforms, this is validated using the cd-hash of the file vs
8 // what is in the pre-built closure.
15 printf("[BEGIN] dlopen-prebuilt-dlopen-closure\n");
17 void* handle
= dlopen("/usr/lib/libobjc-trampolines.dylib", RTLD_LAZY
);
18 if ( handle
== NULL
) {
19 printf("dlerror(): %s\n", dlerror());
20 printf("[FAIL] dlopen-prebuilt-dlopen-closure\n");
24 printf("[PASS] dlopen-prebuilt-dlopen-closure\n");