- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I'm trying to create an executable file from a debugged fortran file using Microsoft Visual Studio.
When I load my file I get no options in the Build Menu except "Run Code Analysis on Solution"
Also, when I have my file open in Microsoft Visual Studio this menu option (below) doesn't exist
Project > Intel Compiler > Use Intel Fortran
Project does not have an "Intel Compiler" option in the drop-down menu.
When I check my Build Log, there is a compiler there:
Compiling with Intel(R) Visual Fortran Compiler 19.1.1.216 [Intel(R) 64]... ifort /O2 /module:"x64\Release\\" /object:"x64\Release\\" /Fd"x64\Release\vc160.pdb" /libs:dll /threads /c /Qguide:1 /Qlocation,link,"C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\bin\HostX64\x64"
Intel(R) Visual Fortran Intel(R) 64 Compiler for applications running on Intel(R) 64, Version 19.1.1.216 Build 20200306
But it doesn't show up on the menus, and I can't create an .exe file -- which is the point of installing all this software in the first place.
I am running Parallel Studio XE 2020.1.086
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I suspect that you have not defined a solution and at least one project within that solution. That is the way Visual Studio works: you need to go through these motions before you can build a program. When I have a program in a single source file or just a small number, I quite often use the command-line instead of Visual Studio to build it. The drawback is that you do not have a debugging environment then, but that is my own fault ;).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Arjen Markus wrote:When I have a program in a single source file or just a small number, I quite often use the command-line instead of Visual Studio to build it. The drawback is that you do not have a debugging environment then...
If you have built an EXE or DLL with symbolic debugging enabled (using /Zi or similar options), at the command line, or using make/Cmake, you may open that EXE as an "EXE project" from the project tab, and start debugging inside Visual Studio. When you attempt to close the project later, VS will offer to save the solution (*.sln) file for you, and you can accept and reuse that solution file for subsequent debugging sessions.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Really? I never knew that - that opens new possibilities :). I find the setting up of a solution and then a project a nuisance for small programs, so I take the other route.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Visual Studio needs a solution to build an executable. There is however a shortcut you can use: File > New > New Fortran Project from Existing Code.
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page