1 #include "../dlfcn/dlfcn.h"
4 #include <gnu/lib-names.h>
11 printf ("\nOpening pthread library.\n");
12 void *pthread
= dlopen (LIBPTHREAD_SO
, RTLD_LAZY
);
14 /* This is a test for correct DF_1_NODELETE clearing when dlopen failure
15 happens. We should clear DF_1_NODELETE for failed library only, because
16 doing this for others (e.g. libpthread) might cause them to be unloaded,
17 that may lead to some global references (e.g. __rtld_lock_unlock) to be
18 broken. The dlopen should fail because of undefined symbols in shared
19 library, that cause DF_1_NODELETE to be cleared. For libpthread, this
20 flag should be set, because if not, SIGSEGV will happen in dlclose. */
21 if (dlopen ("tst-nodelete2mod.so", RTLD_NOW
) != NULL
)
23 printf ("Unique symbols test failed\n");
36 #include <support/test-driver.c>