- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have a project that references an external.mod file, i.e., one that resides outside my project folder--because I wish to treat it like a library, and be able to link it into various projects. I wish to build the project using Developer Studio, rather than from a command line or an NMAKE file.
I can do this with a regular library file: Project > Add to project > Files, browse for *.lib, select the file. This appears to add a pointer to the .lib file into my project, after which BUILDingor LINKing the project works fine.
When I try this same technique with a .mod file, I get an error message "Cannot find file.mod.
I can use Windows explorer, outside of the Developer studio, to place a copy of the needed .mod file into my project folder, and then everything works fine. But this defeats the purpose of re-usable modules. Shurly there is a better way.
I have tried researching this question in the knowledge base, and I find a previous answer, suggesting I "need to spcify the path to where they (the modules) can be found under Project > Settings > Fortran > Processor > INCLUDE/USE paths. But this command tree does not exist in my Developer Studio.
OK, so I'm using an old developer studio (the one supplied with CVS) but I have too (a long story), and I should think there is still some way to accomplish this.
Daryl
I can do this with a regular library file: Project > Add to project > Files, browse for *.lib, select the file. This appears to add a pointer to the .lib file into my project, after which BUILDingor LINKing the project works fine.
When I try this same technique with a .mod file, I get an error message "Cannot find file
I can use Windows explorer, outside of the Developer studio, to place a copy of the needed .mod file into my project folder, and then everything works fine. But this defeats the purpose of re-usable modules. Shurly there is a better way.
I have tried researching this question in the knowledge base, and I find a previous answer, suggesting I "need to spcify the path to where they (the modules) can be found under Project > Settings > Fortran > Processor > INCLUDE/USE paths. But this command tree does not exist in my Developer Studio.
OK, so I'm using an old developer studio (the one supplied with CVS) but I have too (a long story), and I should think there is still some way to accomplish this.
Daryl
Link Copied
6 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
.mod files are not input to the linker. The way you have to do this is by adding the path to the folder containing the .mod files to Fortran >Preprocessor (not Processor) > Additional Include Directories.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks for the very quick reply, Steve.
Sorry I had mistyped: I meant that I had actually tried Preprocessor, but there is no further option to Additional Include Directories. Following is the screen I see after selecting Project > Settings Fortran.
...sorry, I don't know how to paste the image. But anyway, the only related thing in this dialog box is a box titled "Predefined Preprocessor Symbols" in which I can type a text string. According to the ? help, this is to create a preprocessor macro.
Daryl
Sorry I had mistyped: I meant that I had actually tried Preprocessor, but there is no further option to Additional Include Directories. Following is the screen I see after selecting Project > Settings Fortran.
...sorry, I don't know how to paste the image. But anyway, the only related thing in this dialog box is a box titled "Predefined Preprocessor Symbols" in which I can type a text string. According to the ? help, this is to create a preprocessor macro.
Daryl
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Which version of Intel Fortran are you using?
To show an image, you first have to add it as a file and then select "Add to editor". See the link below for how to attach files.
Here is what it should look like. I note that the Fortran > General page also has the entry.
To show an image, you first have to add it as a file and then select "Add to editor". See the link below for how to attach files.
Here is what it should look like. I note that the Fortran > General page also has the entry.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Steve, thanks for the instructions.
It looks like the CVF I am using, along with its Developer Studio, may just be too old to support what I want to do. I can't find a lead to the "Additional Include Directories" option. See attached file
If you think this may be the case, just say so (I can't blame you for not wanting to support a package this old). But for the record, there is a good reason why I can't upgrade to IVF (to make a long story short, we did upgrade to IVF9, but it is incompatible with the newer Visual Studio we had available, and attempts to load an older Visual Studio ran into compatibility problems with other software, so we really need to upgrade our IVF9, while the boss can't accept that we need to upgrade something we only got recently).
Anyway, thanks much for your efforts--I am truly thankful.
Daryl
It looks like the CVF I am using, along with its Developer Studio, may just be too old to support what I want to do. I can't find a lead to the "Additional Include Directories" option. See attached file
If you think this may be the case, just say so (I can't blame you for not wanting to support a package this old). But for the record, there is a good reason why I can't upgrade to IVF (to make a long story short, we did upgrade to IVF9, but it is incompatible with the newer Visual Studio we had available, and attempts to load an older Visual Studio ran into compatibility problems with other software, so we really need to upgrade our IVF9, while the boss can't accept that we need to upgrade something we only got recently).
Anyway, thanks much for your efforts--I am truly thankful.
Daryl
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I completely missed that you are using CVF. In that dialog you showed, use the dropdown box that currently says "General" and select "Preprocessor".
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
THANK YOU, I FOUND IT!
I had looked and looked, and others had looked with me, for anything leading to "preprocessor", "alternate paths", etc. I guess we go so far and then we are blind.
Daryl
I had looked and looked, and others had looked with me, for anything leading to "preprocessor", "alternate paths", etc. I guess we go so far and then we are blind.
Daryl
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