Forum Discussion
Altera_Forum
Honored Contributor
11 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\...
Altera_Forum
Honored Contributor
8 years agoI have had success compiling the vector_add test code with Visual Studio v14.0 (aka 2015)
1) change Project vector_add properties Additional Depenancies "OpenCL.lib;legacy_stdio_definitions.lib;%(AdditionalDependencies)" 2) change the main.cpp program, at top of file after includes FILE _iob[] = { *stdin, *stdout, *stderr }; extern "C" FILE * __cdecl __iob_func(void) { return _iob; } extern "C" void __imp__set_output_format(void) {}; This may break other things, but the vector_add test works with these changes. (refs https://stackoverflow.com/questions/31242820 , https://stackoverflow.com/questions/30412951 )