1 #include <dlfcn.h>
dlopen_b()2 extern "C" void *dlopen_b() {
3   // Work around for http://b/20049306, which isn't going to be fixed.
4   static int defeat_sibling_call_optimization = 0;
5 
6   // This is supposed to succeed because this library has DT_RUNPATH
7   // for libtest_dt_runpath_x.so which should be taken into account
8   // by dlopen.
9   void *handle = dlopen("libtest_dt_runpath_x.so", RTLD_NOW);
10   if (handle != nullptr) {
11     defeat_sibling_call_optimization++;
12     return handle;
13   }
14   return nullptr;
15 }
16