- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have a fortran project written in Fortran 77 originally by some old people. Now my boss has written some Fortran 90/95 routines and wanted me to combine them together. The new routines contain two modules that include global variables.
When I tried to compile this project, it always give me error message box said both two module files are configured to produce mod file with same name. Then the compilation was terminated.
I was using DVF 5.0 A.
Thank you all experts.
When I tried to compile this project, it always give me error message box said both two module files are configured to produce mod file with same name. Then the compilation was terminated.
I was using DVF 5.0 A.
Thank you all experts.
Link Copied
7 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
For the start, upgrade to 5.0D -- this version is much more stable than 5.0A.
It's not clear what you're trying to do -- I suspect you're replacing COMMONs with MODULEs. If I'm right, these are similar but not identical and you cannot just replace COMMON with MODULE and expect it to work.
There may be only one MODULE with one name within one application, e.g.
It's not clear what you're trying to do -- I suspect you're replacing COMMONs with MODULEs. If I'm right, these are similar but not identical and you cannot just replace COMMON with MODULE and expect it to work.
There may be only one MODULE with one name within one application, e.g.
MODULE something REAL:: r !a "global" variable INTEGER:: ii(100) !another "global" variable CONTAINS SUBROUTINE Foo() !a routine ... END SUBROUTINE Foo END MODULE somethingIf you want to access r, ii, or Foo, you must putUSE somethingas the very first line of the routine that uses it. But there may be only one definition of something.
Does it clear things up?
Jugoslav
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Well, simply speaking, this project was written in Fortran 77 before. Now we want to extend its function by writing some routine in Fortran 90/95. F77 use include files/COMMON to create global variables, while F90/95 uses MODULE. I was not trying to replace COMMON with MODULE. On the contrary, I want to keep the old part intact.
When I tried to update to 5.0D, I got an error message of: old file not found, DFORRT.DLL. However, this file is there, in winnt/system32. Anyway, it's nasty.
Thank you!
When I tried to update to 5.0D, I got an error message of: old file not found, DFORRT.DLL. However, this file is there, in winnt/system32. Anyway, it's nasty.
Thank you!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Note that upgrade program asks you to confirm whether it got the three directories right (DevStudio, DevStudioSharedIDE and system32). It usually gets it right, but it's worth rechecking.
As Steve said in another thread, it expects to find exactly the same versions of files from the original DVF 5.0A installation.
If it doesn't solve your module problem (and I guess it won't), you could attach a zip file containting your .for, .f90 files, and ProjectName.dsp file to your reply [hint: "Attach Files" Forum feature is problematic. Keep the post text short (<1 screen) and attach zip file after you type it].
Jugoslav
As Steve said in another thread, it expects to find exactly the same versions of files from the original DVF 5.0A installation.
If it doesn't solve your module problem (and I guess it won't), you could attach a zip file containting your .for, .f90 files, and ProjectName.dsp file to your reply [hint: "Attach Files" Forum feature is problematic. Keep the post text short (<1 screen) and attach zip file after you type it].
Jugoslav
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
see attached files
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
here are more
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Because the whole project is huge(~40MB), I only attached module file and .dsp file.
Thank you very much!
Thank you very much!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hmm, I don't get it -- flowdefs.f90 and leakoffdefs.f90 are not referenced at all in the .dsp file?
I have a hunch that you're trying to INCLUDE files which contain MODULEs. If that's the case, it's not a good idea -- you should add them to the project as source files.
Jugoslav
I have a hunch that you're trying to INCLUDE files which contain MODULEs. If that's the case, it's not a good idea -- you should add them to the project as source files.
Jugoslav

Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page