dyld-625.13.tar.gz
[apple/dyld.git] / testing / test-cases / dlopen-rpath-from-dylib.dtest / test.c
1
2 #include <stdio.h>
3 #include <dlfcn.h>
4 #include <stdbool.h>
5
6 bool test_dlopen()
7 {
8 void* handle = dlopen("@rpath/libbar.dylib", RTLD_LAZY);
9 if ( handle == NULL ) {
10 printf("[FAIL] dlopen-rpath-from-dylib: dlopen(@rpath/libbar.dylib) failed: %s\n", dlerror());
11 return false;
12 }
13
14 dlclose(handle);
15
16 return true;
17 }
18
19