Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Fortran Unresolved external symbols program

Status
Not open for further replies.

wangl24

Programmer
Sep 10, 2010
2
US
I am working on an old Fortran program which is programed about ten years ago. I use both the Fortran powerstation 4.0 compiler and the Compaq Visual Fortran compiler to compile it, and it has no errors. But when I build it, following errors occured:

Text4.obj : error LNK2001: unresolved external symbol __f_settextposition
Text4.obj : error LNK2001: unresolved external symbol __f_outtext
Text4.obj : error LNK2001: unresolved external symbol __f_moveto
Text4.obj : error LNK2001: unresolved external symbol _ALSETA@16
Text4.obj : error LNK2001: unresolved external symbol _ALRELB@8
Text4.obj : error LNK2001: unresolved external symbol _ALDB@12
Text4.obj : error LNK2001: unresolved external symbol _ALWFC@4
Text4.obj : error LNK2001: unresolved external symbol _ALSB@4
Text4.obj : error LNK2001: unresolved external symbol _ALRETB@4
Text4.obj : error LNK2001: unresolved external symbol _ALLB@4
Text4.obj : error LNK2001: unresolved external symbol _ALFDL@8
Text4.obj : error LNK2001: unresolved external symbol _ALRSET@0
Text4.obj : error LNK2001: unresolved external symbol _ALTERM@0
Text4.obj : error LNK2001: unresolved external symbol _ALINIT@0


In the program, I included four files:INCLUDE 'FGRAPH.FI', INCLUDE 'ATLDEFS.FOR', INCLUDE 'ATLERRS.FOR' and INCLUDE 'FGRAPH.FD'. Both atldefs.for and atlerrs.for define some parameters for using a data collecting board.

I looked through the program, all the symbols above were defined either using "external" or using "interface to function". ( for example:
INTERFACE TO FUNCTION getcolor()
INTEGER*2 getcolor[FAR,C,ALIAS:"__getcolor"]
END)

I really donot what is happening and how to correct these errors now.
Any help are appreciated.

thanks.
 
Check the link lines on your powerstation and CVF builds. Does it include any external libraries?
 
I am sorry, I am new to Fortran.

When I bulid the program, there are four dependence( the four include files) shown in the progect workspace.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top