- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
Hi,
I'm building a Fortran project and get an error "LNK1112: module machine type 'x64' conflicts with target machine type 'X86'" I want to have the project built for 64-bit. I'm using Intel® Parallel Studio XE Composer Edition for Fortran with Rogue Wave IMSL 7.0 for Windows.
I also added paths to includes and libraries as recommended here https://software.intel.com/en-us/articles/installing-and-using-the-imsl-libraries/
In Configuration Manager Active solution platform is x64.
In the Linker->Advanced->Target Machine is "Not Set"
What could cause this error?
Thank you
링크가 복사됨
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
Look at the Linker > Command Prompt property page and see if /machine is specified under "Additional Options". This sometimes happens with projects that were converted from Compaq Visual Fortran (since that option was set there.) If it is there, remove it.
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
Please attach a ZIP file with: your Solution (.sln) and Project (.vfproj) files as well as the buildlog.htm from the failing build. If you are really building an x64 configuration, this would typically be in x64\Debug or x64\Release. When I look at those I may be able to identify the problem.
Do be sure that the "Solutions Platform" dropdown in the VS toolbar says x64 and not Win32. Also double-check Build > Configuration Manager for your x64 Solution Platform to be sure that the Platform for the project is set to x64.
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
In earlier versions of MS VS I've noticed in a 64-bit solution that at times if you add a project to a solution that has other projects in 64 bit (main solution toolbar pull-down has x64 selected), the newly added project can come in with only Win32 builds enabled. IOW when opening the Project Build properties, you will not have the x64 configuration listed. This is just one of those quirks that you get used to.
Jim Dempsey
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
Steve Lionel (Intel) wrote:
Do be sure that the "Solutions Platform" dropdown in the VS toolbar says x64 and not Win32. Also double-check Build > Configuration Manager for your x64 Solution Platform to be sure that the Platform for the project is set to x64.
Thank you, Steve
I checked the second option Build > Configuration Manager and the solution platform is x64. Also I see the "x64" is a small window on the toolbar, I guess this is the first thing you mention.
I'll ask the permission of the code owner to publish it (the code isn't mine).
I also got advice that I "have to rebuild all of the libraries you link to target x64". Do you think this can help? If yes, what should I do in order to rebuild them?
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
I don't want to see the code, just the project and solution files as well as the buildlog.htm. There's no code in those. No, I don't think that advice will help. The issue is that the project thinks that the executable target platform is x86.
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
jimdempseyatthecove wrote:
In earlier versions of MS VS I've noticed in a 64-bit solution that at times if you add a project to a solution that has other projects in 64 bit (main solution toolbar pull-down has x64 selected), the newly added project can come in with only Win32 builds enabled. IOW when opening the Project Build properties, you will not have the x64 configuration listed. This is just one of those quirks that you get used to.
Jim Dempsey
Thank you, Jim
I didn't modify the project in any way. It worked as is on the same system (Studio XE Composer Edition for Fortran with Rogue Wave IMSL 7.0 for Windows + VS 2015) on another desktop. The only difference in OS. The project builds correctly on Win7, but I have Win 8.1
It seems that the settings of the system cause the problem, not the project itself.
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
Steve Lionel (Intel) wrote:
I don't want to see the code, just the project and solution files as well as the buildlog.htm. There's no code in those. No, I don't think that advice will help. The issue is that the project thinks that the executable target platform is x86.
Please see the files enclosed
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
Thanks.
Your X64>Debug configuration has
/MACHINE:I386
in Additional Options for the linker. That's the main issue.
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
That was what I asked you to check in my first reply, though. Maybe you didn't look at the configuration that was giving you problems.
