Silverfrost Forums

Welcome to our forums

source file extension query

6 Jan 2024 11:07 #30920

I have been using ‘.for’ for my FORTRAN source files (i.e. not ‘.f’). After a recent system crash, every time I try to compile a ‘.for’ file I now get the message that 'the .f file’ cannot be found. Hardly surprising! So I am supposing that the appropriate fix to allow compiling ‘.for’ files has been wiped after the crash.

I recall getting round this problem in the past but I cannot recall how I did so. The ftn95 documentation must surely mention how to use ‘.for’ files but I cannot find such information there or in the forum. There is surely a simple solution....

Thanks

6 Jan 2024 2:00 #30921

Alangr, you did not state how you use the FTN95 tools to compile, but I suspect that you do your compilation, linking and debugging using the Plato IDE/Editor.

If so, open Tools: Settings: Text Editor: Language Settings: Fixed Format Fortran.

Do you see '.for' as one of the items in the 'File Filter' box? If not, add ';.for' at the end of what is already present.

If this procedure does not solve the problem, describe in detail the circumstances surrounding your attempts to compile, link and run.

6 Jan 2024 2:56 #30922

Thanks fr your reply.

I am not using Plato right now but simply a DOS command line such as

FTN95 %1 /CHECK /UNDEF /INTL /LIST /DEBUG

Where %1 is something like 'routine.for'.

I then use SLINK and, during development, SDBG to run.

Is there a file filter available somewhere in here I wonder?

6 Jan 2024 3:25 #30923

If you do not provide an extension to the file then FTN95 assumes .f90 is the extension.

For anything else you should provide the extension with the file name.

If you have provided the extension and FTN95 says it can't find it then the file is not in the current folder nor on the PATH.

7 Jan 2024 5:05 #30939

Thank you for your help. I have found my problem which was that I had removed the file extension altogether somehow, so it is not surprising that I was having problems.

Red face; thanks again.

Please login to reply.