[PATCH 144/144] test_dlopen fix for ICD enabled
authorPekka Jääskeläinen <pekka.jaaskelainen@tuni.fi>
Thu, 6 Jan 2022 14:02:55 +0000 (16:02 +0200)
committerAndreas Beckmann <anbe@debian.org>
Fri, 7 Jan 2022 23:55:22 +0000 (23:55 +0000)
Gbp-Pq: Name 0144-test_dlopen-fix-for-ICD-enabled.patch

tests/runtime/test_dlopen.c

index b3b525e144fbc69a02a177c19beb7ebb23339e56..df0c2ff1464b9eb06594559994efe03ae01cf649 100644 (file)
@@ -23,6 +23,7 @@
 
 #include <dlfcn.h>
 #include <stdio.h>
+#include <config.h>
 
 #ifdef __APPLE__
 #define SHLIB_EXT "dylib"
@@ -43,7 +44,7 @@ main (int argc, char **argv)
               SHLIB_ORIGIN "/../../lib/CL/devices/%s/libpocl-devices-%s.so", argv[1],
               argv[1]);
 
-#ifdef ENABLE_ICD
+#ifdef BUILD_ICD
   void *handle_libpocl = dlopen (libpocl, RTLD_NOW | RTLD_GLOBAL);
   if (!handle_libpocl)
     {
@@ -66,7 +67,7 @@ main (int argc, char **argv)
         dlclose (handle_device);
     }
 
-#ifdef ENABLE_ICD
+#ifdef BUILD_ICD
   if (handle_libpocl)
     dlclose (handle_libpocl);
 #endif