PGI User Forum
 SearchSearch   MemberlistMemberlist     RegisterRegister   ProfileProfile    Log inLog in 

CUDA-x86.

error LNK2019 compiling issue

 
Post new topic   Reply to topic    PGI User Forum Forum Index -> Programming and Compiling
View previous topic :: View next topic  
Author Message
ahmad adyleh



Joined: 21 Jun 2012
Posts: 6

PostPosted: Sun Oct 07, 2012 12:40 pm    Post subject: error LNK2019 compiling issue Reply with quote

hello ,
I have an old project written in FOR77 and I want to modify it to work with CUDA . it was very hard to compiling it with VS2008 but final i succeed , but now I have two problem :

1- when I am trying to compile it in command line I get these error
pgfortran7fve2-OlRjnDr.obj : error LNK2019: unresolved external symbol fortab_ r
eferenced in function MAIN_
pgfortran7fve2-OlRjnDr.obj : error LNK2019: unresolved external symbol wodat_ re
ferenced in function MAIN_
pgfortran7fve2-OlRjnDr.obj : error LNK2019: unresolved external symbol read_all_
referenced in function MAIN_
pgfortran7fve2-OlRjnDr.obj : error LNK2019: unresolved external symbol rodonce_
referenced in function MAIN_
pgfortran7fve2-OlRjnDr.obj : error LNK2019: unresolved external symbol heathydro
once_ referenced in function MAIN_
pgfortran7fve2-OlRjnDr.obj : error LNK2019: unresolved external symbol v_zblocka
de_ referenced in function MAIN_
pgfortran7fve2-OlRjnDr.obj : error LNK2019: unresolved external symbol write_all
_ referenced in function MAIN_
pgfortran7fve2-OlRjnDr.obj : error LNK2019: unresolved external symbol thehyco_
referenced in function MAIN_
pgfortran7fve2-OlRjnDr.obj : error LNK2019: unresolved external symbol v_full_ca
lc_ referenced in function MAIN_
pgfortran7fve2-OlRjnDr.obj : error LNK2019: unresolved external symbol vrfi_nm_
referenced in function MAIN_
pgfortran7fve2-OlRjnDr.obj : error LNK2019: unresolved external symbol lnas_ ref
erenced in function MAIN_
Main.exe : fatal error LNK1120: 11 unresolved externals
2- when I am trying to compile a simple CUDA example using VS2008
I get these errors
la1djag.obj : error LNK2019: unresolved external symbol cudaSetupArgument referenced in function mproc_la1djac___entry
la1djag.obj : error LNK2019: unresolved external symbol cudaLaunch referenced in function mproc_la1djac___entry
la1djag.obj : error LNK2019: unresolved external symbol __cudaRegisterFatBinary referenced in function mproc_la1djac___entry
la1djag.obj : error LNK2019: unresolved external symbol __cudaRegisterFunction referenced in function mproc_la1djac___entry
la1djag.obj : error LNK2019: unresolved external symbol __cudaUnregisterFatBinary referenced in function mproc_la1djac___entry
la1djag.obj : error LNK2019: unresolved external symbol pgf90_dev_auto_alloc referenced in function MAIN_
la1djag.obj : error LNK2019: unresolved external symbol pgf90_dev_copyin referenced in function MAIN_
la1djag.obj : error LNK2019: unresolved external symbol pgf90_dev_configure_call referenced in function MAIN_
la1djag.obj : error LNK2019: unresolved external symbol pgf90_dev_copyout referenced in function MAIN_
la1djag.obj : error LNK2019: unresolved external symbol pgf90_dev_auto_dealloc referenced in function MAIN_
la1djag.obj : error LNK2001: unresolved external symbol cudafor_
C:\Users\ASUS\Documents\Visual Studio 2008\Projects\PVFProject7\PVFProject7\x64\Debug\PVFProject7.exe : fatal error LNK1120: 11 unresolved externals

thank you in advance
Back to top
View user's profile
mkcolg



Joined: 30 Jun 2004
Posts: 6021
Location: The Portland Group Inc.

PostPosted: Mon Oct 08, 2012 9:03 am    Post subject: Reply with quote

Hi ahmad adyleh,

For the first set of unresolved external symbols, it looks like you're missing a library or object file.

For the second, you most likely didn't link with the "-Mcuda" flag.

Hope this helps,
Mat
Back to top
View user's profile
Display posts from previous:   
Post new topic   Reply to topic    PGI User Forum Forum Index -> Programming and Compiling All times are GMT - 7 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © phpBB Group