[petsc-users] BuildSystem looks for libOpenCL.a

Barry Smith bsmith at petsc.dev
Tue Jun 25 17:19:21 CDT 2024


   Did you have a problem with the install? 

   Are you concerned with self.liblist          = [['libOpenCL.a'], ['-framework opencl'], ['libOpenCL.lib']]   ?

   Even though only the .a library is listed that should be a stand-in for both the static and shared library and it should automatically find the shared library for you.

   Barry


> On Jun 25, 2024, at 6:10 PM, David Andrs <andrsd at gmail.com> wrote:
> 
> This Message Is From an External Sender 
> This message came from outside your organization.
> Hello!
> 
> Is there a reason why the PETSc build system looks for libOpenCL.a, but not for libOpenCL.so <https://urldefense.us/v3/__http://libOpenCL.so__;!!G_uCfscf7eWS!aUphnoqlYDmqiqau_zLjz7XYVRCrIS7jxMEPFgTLd1sLr9q23CNw_4oCjg_wtfFJ9P9SzlfKpcPjVmRbGNc$> on linux platforms? I have a machine with debian 12.5 and nvidia card. It has these packages installed:
> 
> cuda-opencl-12-5/unknown,now 12.5.39-1 amd64 [installed,automatic]
> cuda-opencl-dev-12-5/unknown,now 12.5.39-1 amd64 [installed,automatic]
> nvidia-libopencl1/unknown,now 555.42.02-1 amd64 [installed,automatic]
> nvidia-opencl-common/unknown,now 555.42.02-1 amd64 [installed,automatic]
> nvidia-opencl-icd/unknown,now 555.42.02-1 amd64 [installed,automatic]
> opencl-c-headers/stable,now 3.0~2023.02.06-1 all [installed,automatic]
> opencl-clhpp-headers/stable,now 3.0~2023.02.06-1 all [installed,automatic]
> opencl-headers/stable,now 3.0~2023.02.06-1 all [installed]
> 
> It only has .so, but no .a
> 
> $ find /usr -iname 'libopencl*'
> /usr/local/cuda-12.5/targets/x86_64-linux/lib/libOpenCL.so <https://urldefense.us/v3/__http://libopencl.so/__;!!G_uCfscf7eWS!f3eQHr1WQlnK6grC_bOP4mq-M3wYiMpLKMG96GKHpCh13sgxSV_hfoT1sp6VF9_CGWhdwPsIisUu8LRSFrXlTk4$ >.1.0.0
> /usr/local/cuda-12.5/targets/x86_64-linux/lib/libOpenCL.so <https://urldefense.us/v3/__http://libopencl.so/__;!!G_uCfscf7eWS!f3eQHr1WQlnK6grC_bOP4mq-M3wYiMpLKMG96GKHpCh13sgxSV_hfoT1sp6VF9_CGWhdwPsIisUu8LRSFrXlTk4$ >.1
> /usr/local/cuda-12.5/targets/x86_64-linux/lib/libOpenCL.so <https://urldefense.us/v3/__http://libopencl.so/__;!!G_uCfscf7eWS!f3eQHr1WQlnK6grC_bOP4mq-M3wYiMpLKMG96GKHpCh13sgxSV_hfoT1sp6VF9_CGWhdwPsIisUu8LRSFrXlTk4$ >
> /usr/local/cuda-12.5/targets/x86_64-linux/lib/libOpenCL.so <https://urldefense.us/v3/__http://libopencl.so/__;!!G_uCfscf7eWS!f3eQHr1WQlnK6grC_bOP4mq-M3wYiMpLKMG96GKHpCh13sgxSV_hfoT1sp6VF9_CGWhdwPsIisUu8LRSFrXlTk4$ >.1.0
> /usr/lib/x86_64-linux-gnu/libOpenCL.so <https://urldefense.us/v3/__http://libopencl.so/__;!!G_uCfscf7eWS!f3eQHr1WQlnK6grC_bOP4mq-M3wYiMpLKMG96GKHpCh13sgxSV_hfoT1sp6VF9_CGWhdwPsIisUu8LRSFrXlTk4$ >.1.0.0
> /usr/lib/x86_64-linux-gnu/libOpenCL.so <https://urldefense.us/v3/__http://libopencl.so/__;!!G_uCfscf7eWS!f3eQHr1WQlnK6grC_bOP4mq-M3wYiMpLKMG96GKHpCh13sgxSV_hfoT1sp6VF9_CGWhdwPsIisUu8LRSFrXlTk4$ >.1
> 
> Are users supposed to use `--with-opencl-include=` and `--with-opencl-lib` switches in this case?
> 
> Thanks,
> 
> David

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20240625/06b42d33/attachment-0001.html>


More information about the petsc-users mailing list