forums.silverfrost.com Forum Index forums.silverfrost.com
Welcome to the Silverfrost forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Problems with FUNCTON

 
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> ClearWin+
View previous topic :: View next topic  
Author Message
DonaldLopez



Joined: 12 Nov 2014
Posts: 1

PostPosted: Thu Nov 13, 2014 9:29 pm    Post subject: Problems with FUNCTON Reply with quote

Hi i need help, when i make a subroutine function it does not work whit my main program and the error showed is the next:

1.- when i compiling the main show:
Compiling and linking file: YinaPrinc.f95
WARNING the following symbols are missing:
MROOTTDAP C:\Users\Dell\Documents\Donald\Programas fortran\Programa Yina\lgotemp@.obj
(C:\USERS\DELL\DOCUMENTS\DONALD\PROGRAMAS FORTRAN\PROGRAMA YINA\YINAPRINC.F95)
Creating executable: C:\Users\Dell\Documents\Donald\Programas fortran\Programa Yina\YinaPrinc.EXE
Compilation and linking completed.

2 when i compiling the function:

Compiling and linking file: AREA.f95
*** No main, WinMain or LibMain function
*** Compilation abandoned
Compilation failed.

i dont now what i need do it to run.
Back to top
View user's profile Send private message
davidb



Joined: 17 Jul 2009
Posts: 560
Location: UK

PostPosted: Fri Nov 14, 2014 12:59 pm    Post subject: Reply with quote

Hard to tell without seeing the code. Could be anything.

Are you using modules?
If not, have you declared your function's type in the main program?

e.g. if the function is REAL you need the following in your main program.

REAL MROOTTDAP

If this doesn't help can you post some code.
_________________
Programmer in: Fortran 77/95/2003/2008, C, C++ (& OpenMP), java, Python, Perl
Back to top
View user's profile Send private message
LitusSaxonicum



Joined: 23 Aug 2005
Posts: 2388
Location: Yateley, Hants, UK

PostPosted: Mon Dec 01, 2014 12:20 am    Post subject: Reply with quote

Donald,

It looks to me that your main program routine is in the first file, and the missing subroutine is in the second file.

If you are compiling by issuing the commands manually, then you need to compile them without linking, i.e. using the token -c (for compile only):

Code:
FTN95 -c YinaPrinc
FTN95 -c Area


and then link with SLINK, as in:

Code:
SLINK YinaPrinc.obj Area.obj Yina


(Would create Yina.exe)

If you are using Plato, then you have to include both source code files in your project.

I think from what you posted you are trying to compile AND link each file separately.

Eddie
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> ClearWin+ All times are GMT + 1 Hour
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 © 2001, 2005 phpBB Group