フィルターのクリア

Compiler error

3 ビュー (過去 30 日間)
Melissa
Melissa 2011 年 12 月 6 日
コメント済み: Martin Gulan 2015 年 1 月 9 日
Good Afternoon All,
I am having a problem when trying to run the compiler and have figured out it has something to do with VS2010 and matlab.
The error is: error lnk1112 module machine type 'x86' conflicts target machine type 'x64'
Error: An error occurred while shelling out to mbuild (error=2). Unable to build executable.
I cannot figure out how to change either setting and which setting I need to change. I have windows xp and the 64 bit version of both programs. Any help or suggestions are greatly appreciated.
Thanks!

採用された回答

Melissa
Melissa 2011 年 12 月 14 日
Problem solved. It was an error with Windows SDK 7.1. When installing you have to unclick the C++ tool kit and install and then download the update to fix the problem.

その他の回答 (1 件)

Kaustubha Govind
Kaustubha Govind 2011 年 12 月 7 日
Assuming that you have 64-bit Windows and 64-bit MATLAB, have you installed x64 compilers with your Visual Studio? By default, only the 32-bit compiler is installed - there is a checkbox during installation that you need to select to ensure that x64 Compilers are installed.
Once you have done this, run "mbuild -setup" and make sure that it automatically picks up the installed compiler.
  1 件のコメント
Martin Gulan
Martin Gulan 2015 年 1 月 9 日
Dear Kaustubha and others;
when I run
>>mex work/obj_target/test.obj work/interface/test_mex.c -output test
I receive almost the same output, i.e.:
Building with 'Microsoft Visual C++ 2012 (C)'. Error using mex work/obj_target/test.obj: fatal error LNK1112: module machine type 'X86' conflicts with target machine type 'x64'
on my x64-based machine with Win7_64bit, MATLAB2014a_64bit and Microsoft Visual Studio 2012 . Any advice here, please? I am trying to solve this for days and slowly runing out of time, hence I will appreciate any help a lot.
PS: Then I also get the same problem in Diagnostic Viewer (fatal error LNK1112:...) when trying to build my Simulink model (more precisely when Linking) for my target PC via Simulink Real-Time
Martin

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeIntroduction to Installation and Licensing についてさらに検索

タグ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by