Altera_Forum
Honored Contributor
10 years agoVisual studio 14.0 LNK2001 (unresolved external symbol ) with OpenCL
I am new to OpenCL. When I tried the examples from the website of Altera, I got LNK2001 errors as follows
Error LNK1120 1 unresolved externals hello_world C:\Users\S_KW\OpenCL\hello_world\bin\hello_world.exe 1 Error LNK2001 unresolved external symbol __imp_sprintf hello_world C:\Users\S_KW\OpenCL\hello_world\OpenCL.lib(icd_windows.obj) 1 Warning LNK4044 unrecognized option '/LC:\Users\S_KW\arrow_c5sockit_bsp\arm32\lib'; ignored hello_world C:\Users\S_KW\OpenCL\hello_world\LINK 1 Warning LNK4044 unrecognized option '/lalterahalmmd'; ignored hello_world C:\Users\S_KW\OpenCL\hello_world\LINK 1 Warning LNK4044 unrecognized option '/lalterammdpcie'; ignored hello_world C:\Users\S_KW\OpenCL\hello_world\LINK 1 I have already added path of the libs and head files. It seems that the OpenCL.lib cannot see the printf function. But I think the printf is built in C++. It is confusing. Someone know how to handle this? Thank you very much!!!