diff options
author | johnmartin-oracle <john.m.martin@oracle.com> | 2019-12-20 16:04:40 +0000 |
---|---|---|
committer | Aaron Plattner <aplattner@nvidia.com> | 2019-12-20 16:04:40 +0000 |
commit | 61d045c0d9ce9aa9e395f331b19581d9297796d2 (patch) | |
tree | 8ee33273d3eb2c10049fcd68690b624d71932361 /test | |
parent | f1fa72e9be216bbe7e7af3c11e9f2aed5524dce2 (diff) |
test: Use libXext.so.0 instead of libXext.so.6 on Solaris
Reviewed-by: Aaron Plattner <aplattner@nvidia.com>
Diffstat (limited to 'test')
-rw-r--r-- | test/dlclose.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/test/dlclose.c b/test/dlclose.c index 0830c8d..4d34453 100644 --- a/test/dlclose.c +++ b/test/dlclose.c @@ -28,13 +28,19 @@ static int countOpenFDs(void) return count; } +#if defined(__sun) +static const char libXext_so[] = "libXext.so.0"; +#else +static const char libXext_so[] = "libXext.so.6"; +#endif + int main(void) { // Work around a bug in libXext: dlclosing it after it has registered the // Generic Event Extension causes an identical bug to the one this program // is trying to test for. int nOpenFDs = countOpenFDs(); - void *libXext = dlopen("libXext.so.6", RTLD_LAZY); + void *libXext = dlopen(libXext_so, RTLD_LAZY); void *libvdpau = dlopen("src/libvdpau.so", RTLD_LAZY); Display *dpy = XOpenDisplay(NULL); VdpDeviceCreateX11 *pvdp_device_create_x11; @@ -43,7 +49,7 @@ int main(void) VdpStatus status; if (!libXext) { - fprintf(stderr, "Failed to open libXext.so.6: %s", dlerror()); + fprintf(stderr, "Failed to open %s: %s", libXext_so, dlerror()); return SKIP; } |