Как установить fortran в visual studio
As of today Fortran is still one of the leading programming languages for high performance and scientific computing; on the other hand HPC and scientific computing are still a highly specialized niche and, as a result, not many user friendly tools are available for Fortran development.
In this guide Visual Studio 2019 combined with the Intel Fortran compiler is proposed as a do-it-all Fortran IDE for Windows. On Linux many different, arguably better, alternatives are available.
Fortran compilers
Various Fortran compilers are available, a comprehensive list is available on the web site of the Fortran Programming Language.
I used the following two compilers
- GNU Fortran, or gfortran, part of the GNU Compiler Collection (GCC), is a Free and Open Source Fortran compiler which is still under active development and supports all the features of the latest Fortran 2018 standard. gfortran is natively available on Linux and MacOS; it is possible to get it on Windows with Windows Subsystem for Linux (WSL) and other workarounds.
- The Intel Fortran Compiler (ifort) is a proprietary compiler developed by Intel; it can be used free of charge for non commercial uses as a part of the Intel oneAPI HPC Toolkit. Intel Fortran is natively available on all platforms; but on Windows is virtually the only free option, thanks to the integration with Visual Studio.
The Visual Studio IDE
Microsoft Visual Studio 2019 (VS for now on) is a complete and feature rich general purpose IDE; being general purpose it does not natively support Fortran development or other features which might be of interest in the context of scientific computing and, in particular, development of numerical analysis codes. Fortunately though the integration with Intel compiler and diagnostics tools makes it a viable option for our use case. VS is closed source and commercial software, but the community edition is free to use for non commercial purpose with a Microsoft account, the minimal functional limitation of this edition are not of any relevance for our use case.
Key features
- Automatic determination of compilation order: on Linux I used the make utility to compile and link the various components of my code; on Windows, due to my poor knowledge of its shell and lack of basic tools, I was not able to use make . This was the main reason I resorted to Visual Studio in the first place.
- Support for debugging, signally
- Execution pause
- Break point support
- Variable inspector
These tools are also available on Linux as separate applications, but on Windows they integrate in the IDE
Key annoyances
- There is support for syntax highlighting, but absolutely no support for statement autocompletion
- There is no support for any kind of code exploration
- I suggest to write the code in a more feature rich text editor (here are some very useful suggestions) and use VS only for compilation and debugging.
Installation
The installation process involves the installation of VS and the Intel HPC Toolkit. It is important to follow the prescribed installation order to get out-of-the-box support.
Installing Visual Studio
Installing Intel Fortran
- The intel fortran compiler is part of the oneAPI HPC Toolkit. On the download page we suggest to select an Online installer.
- Launch the installer and follow the directions:
- Proceed with a default install (all components are installed)
- Be sure to check the box Microsoft Visual Studio 2019 in the Integrate IDE step
Checking the configuration
At this point creating a new project in VS an option for Fortran language should appear. We can test the configuration creating a simple `Hello World!" program:
- From the templates, select Empty Project
- In the next screen give it a name and a directory to save it.
- Create a new file in the project:
- Project > Add New Item (Ctrl + Shift + A)
- Select the kind of Fortran file you want to create
Keep in mind that there is no difference between these choices a part from the file extension, all files are simply plain text files. The extension is used by the IDE to chose what format, syntax highlighting or compiler options to use…
General guidelines about Visual Studio 2019
The way Visual Studio manages files, directories, projects, solutions, libraries…is quite messy, and gave me a headache at first, mainly because the file structure in VS does not reflect at all in the filesystem, which is quite uncanny from a Linux user perspective… So I try to summarize the main working concepts and jargon:
- The biggest units are solutions, which can contain many projects
- A project is the basic unit and corresponds to a program or library
- A project can contain at most one main program unit
- All source files for modules used by the main program can be contained in the project
- Modules that we intend to use in more than one main program need to be compiled in a dedicated project
- such project needs to be a static library
- It is possible to create dynamically-linked libraries ( dll s), but more configuration is necessary
- The dependency of the project containing the main program on the project containing the modules needs to be set in the solution properties to let the compiler know
- all the directories and files in the project are virtual, that is they do not reflect their location in the filesystem (for some reason 🤔), so the source files can be kept all in a single directory and assigned to different project
- Similarly files that in the filesystem are in the same folder as the source files or the project will not appear in the project in VS
- The modifications to the files are, of course, reflected in the original files whatever their location in the filesystem
Note that all setting in the project properties are relative to a single configuration, so pay attention what configuration is being used… I suggest selecting All Configurations when changing project properties
Compiling a complex code library
Here I illustrate how to get code compiled and running in Visual Studio 2019 through examples based on my experience with my IgA-based Energetic BEM library IgA-EnergeticBEM.
In all the example we are located in a solution named, for example IgA-EBEM
Program unit and subroutines are all in one file
In this case the compilation is very simple: hitting Start should do it, if it does not there might be some error in the code.
Code with modules in separate files
This case is again pretty simple: within the same project, Visual Studio automatically determines the dependencies and the right compile order. So we just press F5
Code with modules in a shared library
If we want the modules to be accessible to more than one main program, we can compile them in a static library and link it to the main program.
Let us assume that the main program source file IgaEBEM_2D_matrix.f90 is contained in a project named matrix and the modules are in a project named lib_static
- We can check that the modules compile building just the lib_static project with the corresponding item of the context menu of the project.
In Project > Project Dependencies we select matrix and in Depends on check lib_static
We can now open the main program source file and press Start
In the output log we should see that all modules are being compiled
After all the modules the main program gets compiled and executed
We can now create other projects for other main program, and link them against the library with the same procedure
- In our code library such programs programs would be
- IgaEBEM_2D_rhs.f90 , for the computation of the right-hand side
- IgaEBEM_2D_solver.f90 , which implements the time marching solver.
Programs exchanging files
- Our programs are designed to exchange data saved on files, we therefore need to set the same working directory for all the projects tht contain a program unit.
- To do so in each project properties under Debugging we set Working Directory to $(SolutionDir)/run_dir , so the programs are executed in a subdirectory run_dir of the directory containing all the solution.
Compilation of parallel code using MPI
To compile the code taking advantage of the parallel implementation
In each project properties under Configuration Properties > Fortran > Language > Process OpenMP Directives we select Generate Parallel Code
- Note that also the library needs to be compiled with the \Qopenmp flag
Conclusion
In this article I hopefully gave a complete introduction to the usage of Visual Studio 2019 and Intel Fortran Compiler aimed at numerical analysts and Fortran developers who need or want to work on Windows.
I will continue to do my coding on Linux, as more powerful tools are freely available, many HPC centers, including the one at my University, ase Linux systems, and I have more control on what I am doing, instead of needing to look for mysterious options and learning funny file structures with their own lexicon.
сначала я устанавливаю MS Visual Studio Community 2017 с официального сайта.
Отлично работает.далее я устанавливаю Intel ® Parallel Studio XE Cluster Edition (включая Fortran и C/C++) с сайта Intel Developer Zone. На этом сайте было бесплатное предложение инструмент для студентов.
установки был установлен следующий софт:
но когда я пытаюсь создать новый проект Fortran я не нашел вариант на Visual Studio Community 2017.
затем я ищу в интернете об этой проблеме, и я нашел эту статью:Устранение неполадок интеграции Fortran с Visual Studio
Который гласит:Если используется Intel Parallel Studio XE 2017 (версия компилятора
17.0), поддерживаются версии Visual Studio 2012, 2013 и 2015.поэтому я попытался загрузить MS Visual Studio Сообщество 2015 но я не могу.
В настоящее время веб-сайт Microsoft предлагает только Visual Studio Community 2017.Я хочу построить Fortran или C / C++ проект, используя библиотеку математического ядра или Blas, Linpack или Lapack.
Что я могу сделать?
Есть ли способ решить эту проблему интеграции, должен ли я найти VS Community 2015 или, может быть, попробовать компилятор GNU-GCC, но в этом случае, как использовать LINPACK?в то время решение состояло в том, чтобы установить VS Community 2015, как прокомментировал @Ramhound, и после переустановки Intel Parallel Studio XE 2017. В настоящее время Intel Parallel Studio XE 2018 поддерживает Visual Studio 2017.
но в будущем, эта проблема может повториться, то следующие шаги для установки последней Visual Studio поддерживается Intel Parallel Studio XE.
сначала проверьте версию Visual Studio, поддерживаемую Доступна Intel Parallel Studio XE. Вы можете проверить на этом сайте Устранение неполадок интеграции Fortran с Microsoft Visual Studio*
установите Visual Studio, поддерживаемую Intel Parallel Studio XE, которую вы собираетесь установить. Если поддерживаемая версия Visual Studio не является последней, можно загрузить более старую версию из против старых загрузок
наконец, установите Parallel Studio КСЕНОН.
сообщество VS2015 поддерживает Intel Fortran, и я действительно тестировал эту точную комбинацию на днях. Необходимо выбрать пользовательскую установку VS2015 и установить флажок для языков программирования > C++. Если вы не сделали этого раньше, повторно запустите VS install, измените параметр, затем повторно запустите Parallel Studio XE install (2015 Update 4 или более поздней версии), чтобы выбрать интеграцию VS2015.
Если это не помогает, возможно, вам придется найти, где был установлен Windows SDK как часть VS, и добавить его двоичный путь к списку исполняемых файлов в разделе Инструменты > Параметры > компиляторы и библиотеки Intel > Visual Fortran > компиляторы. В моей системе это C:\Program файлы (x86)\комплекты Windows\8.1\bin\x64\rc.exe (для 64-разрядной версии) и C:\Program файлы (x86)\комплекты Windows\8.1\bin\x86\rc.exe для 32-разрядных
Fortran is not well supported by a lot of IDEs. Microsoft Visual Studio has syntax highlighting but missing a lot of great features, when it comes to auto completion, signature help, find and peek references. Visual Studio Code in comparison has some great extensions and is running on MacOs, Linux and Windows.
This small Guide should help you to setup a full development environment for Fortran.
Visual Studio Code
If you are working with Fortran in the fixed-column format it is useful to setup rulers at the relevant columns. Add this to your settings.json :
Cursive italics and Ligature
Some might like this and some wont: Using cursive italics and programming symbol ligatures.
Activate font ligatures and select the font:
In the standard settings for fortran syntax highlighting nothing more then paramter are italic and therefore then cursive. You can customize this quite easy:
To find out the scope you can type in the command palette ( ctrl + shift + p ): Developer: Inspect Editor Tokens and Scopes and hover over your source code.
Visual Studio Code Extensions
There are some extensions that are very useful. Modern Fortran can be used for syntax highlighting and snippets. For features like Signature help or GoTo/Peek definition and much more FORTRAN IntelliSense should be installed. If you also want to debug, you have to download the extension Fortran Breakpoint Support .
Basic symbol functionality or hover information is also provided by Modern Fortran . Using Modern Fortran and FORTRAN IntelliSense simultaneously those should be deactivated in your settings.json :
This Extension needs fortls (not maintained original version: fortran-language-server) to operate because it is just an interface for the language server which can be used by different IDEs. It is written in python.
- Install python
- Install pip
- Install fortls
To setup fortls a file named .fortls is needed in your workspace in Visual Studio Code. It is written in JSON. Example .fortls :
Fortran Breakpoint Support
In general you have to define a tasks.json for the build and link process and a launch.json to start to debug.
- Windows: gfortran via MinGW for example
- Linux: sudo apt-get install gfortran , sudo pacman -S gcc-fortran
- OSX:
The gfortran compiler should be accessible via the command line.
Click on the debug symbol in Visual Studio Code, choose the debug configuration and press start.
About
A comprehensive guide on how to set up a complete development environment for Fortran in Visual Studio Code.
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Open with Desktop
- View raw
- Copy raw contents Copy raw contents
Copy raw contents
Copy raw contents
Смешанное программирование: C++ вызывает FORTRAN
Положим, вам нужно из приложения, написанного на C++ , вызвать подпрограммы, написанные на FORTRAN ’е. Да, такое может легко с вами случиться. Сначала о том, зачем это понадобилось мне. Если вам хочется сразу к делу, пропускайте следующий пункт.
В проекте CATS’ PDEs часто приходится работать с большими разреженными матрицами — матрицами, большинство элементов которых равно нулю и не хранится. Существует, вообще говоря, довольно много 1 форматов хранения для таких матриц.
CSC–формат (Comressed Sparse Column, разреженно–столбцовый) является наиболее гибким и популярным в МКЭ форматом. На нём же и основан не менее популярный стандарт хранения матриц в виде ASCII–текста Harwell–Boeing 2 (да-да, те самые боинги).
Матрицы в HB–формате нынешний софт понимает и любит. Например, та же Mathematica умеет в импорт/экспорт HB–матриц в свой SparseArray, который, кстати, использует CSR–формат (Comressed Sparse Row, разреженно–строчный) андерхуд.
Очевидно 3 , что хороший тулкит вроде CATS’ PDEs, в котором предполагается работа с разреженными матрицами, должен поддерживать i/o стандартных форматов типа Harwell–Boeing, Matrix Market и так далее:
- Ввод. Чтобы тестировать решатели систем на матрицах, полученных из реальных задач моделирования течения жидкостей, акустики, экономики и так далее. Вот ссылка на коллекцию Harwell–Boeing.
- Вывод. Чтобы с собранными в вашем приложении матрицами мог работать другой софт — например, чтобы тот же MatrixPlot в Математике нарисовать. Конечно, вы можете передать вашу матрицу и в плотном виде. Если она поместится в оперативную память и у вас есть желание подождать 1000 лет.
CATS’ PDEs написан преимущественно на C++11 . Существуют готовые библиотеки ввода/вывода для Harwell–Boeing, написанные на C / C++ :
Однако ввод/вывод делать я решил на FORTRAN ’е и сейчас объясню, наконец, зачем. Так уж вышло, что Harwell–Boeing придумали в далёком 1992-м; если вы посмотрите в [2, с. 9], как он устроен, то довольно быстро поймёте, что формат очень FORTRAN –ориентирован — уже по первому предложению:
Our collection is held in an 80–column, fixed–length format for portability…
В отличие от C / C++ , FORTRAN очень богат на форматы ввода/вывода. Поэтому чтобы написать i/o на C / C++ … придётся писать свой FORTRAN –like форматный i/o! Что, кстати, обе вышеуказанные библиотеки и делают: первая — 4 226 строк, вторая — 1 604. И это против элегантных 129, написанных на FORTRAN ’е
Впрочем, свой FORTRAN на C / C++ — это ещё половина беды. Например, вот эту матрицу первое решение вообще не прочитает, потому что поддержку дескриптора P автор не сделал (упс, не дописали свой FORTRAN ).
А ещё в этом же решении мной был найден баг (смотрите 1232-ю строчку здесь или просто поищите “Alexander” — зачем мне врать). Короче, сами понимаете…
Надеюсь, на вопрос зачем я ответил.
С чем будем работать
- платформа: Windows 10 x64,
- компилятор C++ : MSVC (Visual Studio 2015),
- компилятор FORTRAN : ifort.
Вероятно, Visual Studio* у вас уже есть. Intel Fortran суть часть Intel Parallel Studio, купить её можно здесь. Если вы студент, ресёрчер и т.п., можете забрать бесплатно — достаточно иметь вузовскую почту.
Скорее всего вам не захочется устанавливать все модули Intel Parallel Studio — оставьте чекбоксы только на ifort. Крайне советую установить их расширение для работы с FORTRAN ’ом для Visual Studio* (нажать чекбокс во время установки). Дальше я объясню, почему это удобно.
Вызывать будем подпрограммы FORTRAN ’а из C++ –приложения. Точка входа в sln/C++ Sources/user.cpp , подпрограммы — в sln/FORTRAN Static Lib/add.f90 и ″/square.f90 .
Есть два пути: создать статическую (в Windows обычно имеет расширение .lib) или динамическую (shared) библиотеку (″ .dll). По своей природе статическая библиотека суть объектный файл (.o, .obj) и подключается к приложению во время линковки, динамическая — исполняемый файл (.exe), подключается в рантайме.
Для наших целей достаточно написать (возможно, много) подпрограмм на FORTRAN ’е, скормить их ifort’рану и собрать статическую библиотеку, которую затем успешно линковать к C++ . На времени компиляции основного приложения это не отразится и все будут счастливы.
Игрушечный пример: компиляция из терминала
Запускаем терминал ifort: [Start] — All Apps — Intel Parallel Studio* — Compiler* . Соберём и прилинкуем статическую библиотеку.
Получаем объектные файлы:
> ifort /c add.f90 square.f90
> lib /out:f.lib add.obj square.obj
Компилируем приложение с MSVC и запускаем:
> cl /EHsc /Ox user.cpp f.lib
Ту же штуку вне среды ifort у вас так просто провернуть не получится, потому что MSVC понятия не имеет, где искать FORTRAN ’онские библиотеки (типа ifconsol.lib и т.д., как предупреждает документация):
Проблему можно решить, прилинковав вручную недостающие библиотеки. Дефолтно искать их стоит где-то в C:\Program Files*\IntelSWTools\compilers_and_libraries*\windows\compiler\lib .
Легко догадаться, что то же веселье вас ждёт и при работе из Visual Studio* (а бог не зря вам её послал — едва ли вы будете компилировать и дебажить большой проект вручную из терминала). Ну и ещё добавится возня с разными платформами — Win32 / x64, разными конфигурациями — Release / Debug и конфликтами C Run–Time Library — добавленные вручную библиотеки могут быть скомпилированы с разными ключами CRT.
Чтобы сего веселья избежать, удобно использовать интеловское расширение для Visual Studio*, которое в предыдущем пункте я советовал установить.
Положим, у нас есть в решении два проекта: пустой проект Visual C++ для user.cpp (C++ Sources в этом репозитории) и статическая библиотека Visual Fortran для add.f90 и square.f90 (FORTRAN Static Lib ″).
Второй создать очень просто (я предполагаю, что расширение установлено) — File — New Project — Intel(R) Visual Fortran — Library — Static Library .
Головной модуль расположен в C++ Sources, поэтому необходимо, чтобы компилировался именно этот проект: Right Click — Set as SrartUp Project .
Для настройки (почти) достаточно прочитать эту и эту странички документации и посмотреть примеры проектов, дефолтно расположенных примерно в C:\Program Files*\IntelSWTools\samples*\en\compiler_f\psxe\MixedLanguage . Однако имеют место небольшие опечатки и недосказанности, поэтому я лучше здесь об этом напишу.
Теперь попробуйте билдить FORTRAN Static Lib, переключая платформы. Если всё верно, в режиме x64 в окошке с логами вы заметите что-то вроде Compiling with Intel(R) Visual Fortran Compiler* [Intel(R) 64]. , а в режиме Win32 — Compiling with Intel(R) Visual Fortran Compiler* [IA-32]. .
Осталось научить C++ Sources искать FORTRAN ’онские библиотеки (см. предыдущий пункт) в нужных местах. Настройка выполняется один раз для всех Visual C++–проектов.
Далее идём в VC++ Directories . В Include Directories добавляем $(IFORT_COMPILER[VERSION])compiler\include (юху, Intel и макросы сделали для пути!). Вместо [VERSION] поставьте версию, у меня на момент написания стоит 16. Проверьте, что в Evaluated value: стоит что-то вменяемое типа C:\Program Files (x86)\IntelSWTools\compilers_and_libraries_2016.3.207\windows\compiler\include — скопируйте в проводник и откройте эту папку.
В Library Directories добавляем $(IFORT_COMPILER[VERSION])compiler\lib\ia32 и $(IFORT_COMPILER[VERSION])compiler\lib\intel64 для Win32 и x64 соответственно.
Сбилдите FORTRAN Static Lib–проект и добавьте FORTRAN Static Lib.lib в C++ Sources (я предпочитаю вручную, но можно и в Project Properties подключить). Готово, можно компилировать.
Удобно, что исходники теперь аккуратно расфасованы по разным проектам и код можно редактировать в любимой IDE. Более того, дебаг работает привычным образом:
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
Success! Subscription added.
Success! Subscription removed.
Sorry, you must verify to complete this action. Please click the verification link in your email. You may re-send via your profile.
- Intel Communities
- Developer Software Forums
- Software Development Tools
- Intel® Fortran Compiler
- Visual Studio 2015 / Fortran 2017
Visual Studio 2015 / Fortran 2017
- Mark as New
- Bookmark
- Subscribe
- Mute
- Email to a Friend
I tried to use compile Fortran projects as static libraries with Microsoft VS 2015 and the latest Intel Fortran Compilers. Therefore we create the vfproj-Files and start devenv.exe to compile them as "Debug|Win32" or "Release|x64". We do so with VS2010 and Fortran 2011 which works fine so far.
We want to upgrade, unfortunately I cannot get this to work. Whenever I call devenv from my batch file with my vfproj-Project it works with "*|x64" and compiles the x64 static libraries to the configured x64 directories. If I try to compile "*|Win32" a Window opens which tells me I did the call incorrectly. Apparently "Win32" is the problem, which works fine with VS2010/IF2011. So we tried "*|x86" which works fine. It uses the Win32 configuration, unfortunately fortran compiles x64 objects into the x86 directories.
When compiling inside devenv we can create x86 and x64 files as desired.
But we cannot start Visual Studio on our build server and do this by hand for more than 90 static libs.Additionally, last friday my evaluation period is expired. We don't have a running system so far and we're running out of ideas how to manage this.
So currently we cannot upgrade.Maybe someone can give me the hint how to successfully compile fortran projects from comand line?
Thank you in advance
- Mark as New
- Bookmark
- Subscribe
- Mute
- Email to a Friend
Based on the description it sounds like there is a possible defect with our Fortran integrations in our 2017 release. I have to try recreating the scenario and then have our integrations developers investigate further.
If your support services for your what I presume is your default production configuration (VS2010/IVF2011) is not expired then you can use that with the VS2015/IVF2017 test environment also. If needed, we can discuss the evaluation expiration after we have an understanding the issue and determine whether there is a usable solution/work around.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Email to a Friend
I have installed it on my development machine (W10, VS2015 Up1, Fortran 2015/4) last year. I had big problems with the 2016 version, even VS2015 crashed all the time, so I installed the 2015 version, which works better. I canceled this so far and restarted last month.
This year I reinstalled everything on a fresh Win10 virtual machine. I installed VS2015 Up3 and the latest Version of IF 2017 Up 1. Here I got the described errors. I moved back to my real machine, deinstalled VS 2015/1 and IF 2015 and installed VS2015/3 and IF 2017/1 which was updated to IF 2017/2. On both machines I have the identical behavior as described above.We have one year of support, so currently I cannot do anything.
I personally would like to upgrade to VS2017 if IF would work reliably there.- Mark as New
- Bookmark
- Subscribe
- Mute
- Email to a Friend
I can reproduce this behavior with VS2015. More annoyingly, if I use /log to capture what is going on, no log is created.
It then gives the devenv /? output. But.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Email to a Friend
Well, is here any progress?
May I reckon that the Update 3 appears in May and will work?
Should I start writing make skripts because of this?
Or should we stay on Visual Studio 2010/Intel Fortran until Microsoft does not allow to install it anymore?What should I tell the people who have to pay for a new Intel Fortran licence? Currently I have to say: It does not work in the way it did. So we have to change something or we're stucked. We put already a lot of afford to make it run. So the update is already quite expensive and does not work.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Email to a Friend
I apologize for the delay. I was unable to recreate everything you described and then became distracted with other issues.
I looked at two different static Fortran library solutions 1) “x86 and x64” configurations (lib1 – no Win32 configuration), 2) “Win32 and x64” configurations (lib2 – no x86 configuration)
For lib2, I was unable to build the Win32 configuration. For unknown reasons, the devenv does not accept the “Win32” configuration argument and always reports the error “The parameter is incorrect”. When using “x86”, not surprising, nothing is built.
It seems devenv only accepts the “x86” configuration argument. This is something I need to discuss with our Integration developers.
As an aside, I tried building a MS C++ static library and it too does not build with the “Win32” configuration argument. It returns the same “The parameter is incorrect” error so I do not know if what we’re seeing with that is the cause of our integrations with VS.
For my lib1 solution/project, which has x86 and x64 configurations (no Win32), I can successfully build all configuration combinations of x86/x64 and Debug/Release.
I cannot reproduce all of what you described though.
When using “x86|Debug”, that’s accepted and the project builds. I can do this for both the Debug and Release configurations. I can also do the same with the x64 configuration. I’m am seeing no problems using devenv with any of those combinations.
However, when building the “x86” (either Debug or Release), what is odd/confusing is that the build output suggests the “|Win32” configuration is built, but it still does build. Ex.
I also confirmed (you can also see in the output above) that the IA-32 compiler is used for the x86 builds and via dumpbin I confirmed the resulting object files are x86 (not x64) and the build places them into the expected Debug/Release directories for the x86 configuration.
So, I am unable to re-create the aspect of the issue that you described where x64 objects are created in the x86 build directories. If that is not actually happening then it would seem the x86 configuration should be usable despite it reporting “Win32” being built.
If you have an example that can demonstrate the x64 objects being created in the x86 directories then we can investigate this further.
Читайте также: