Can I override the /etc/OpenCL/vendors ICD dir on Linux?

Discussion created by alx on Apr 20, 2011
Latest reply on Apr 21, 2011 by alx

It's nice that OpenCL allows to drive any compute device, but under Linux the fixed /etc/OpenCL/vendors ICD dir is a problem for me.

I'd like to run my code on the CPU of (cluster) machines that have no OpenCL installed, or on any device in a system with OpenCL installed, but using another (tested/newer) version of OpenCL. For a "run anywhere" approach where you cannot (reasonably ask to) update system files regularly (think HPC or grid computing) this is a real problem.

Is there a way to override the hardcoded(?) /etc/OpenCL/vendors dir under Linux, e.g. using an env var? As a normal user, I cannot use chroot to trick it. Do I need to find/write a custom with e.g. an env var check?