MEXコマンドで使用するコンパイラの設定するにはどうすればよいですか?
68 views (last 30 days)
Show older comments
MathWorks Support Team
on 25 Oct 2013
Answered: MathWorks Support Team
on 25 Oct 2013
MEXコマンドで使用するコンパイラの設定方法を教えてください。
Accepted Answer
MathWorks Support Team
on 25 Oct 2013
MEX コンパイラの設定方法は以下の通りです。
1. MATLABコマンドウィンドウに次のコマンドを入力します。
>> mex -setup
2. 次のメッセージが表示されたら、"y" と入力してEnterキーを押します。
Please choose your compiler for building external interface (MEX) files:
Would you like mex to locate installed compilers [y]/n? y
3. コンパイラの一覧が表示されますので、使用したいコンパイラの左横にある数字を入力し、Enterキーを押します。ここでは、Windows版MATLABに標準で付属するLccコンパイラを選択した例を示します。
Select a compiler:
[1] Compaq Visual Fortran version 6.6 in C:\Program Files\Microsoft Visual Studio
[2] Lcc C version 2.4 in C:\PROGRAM FILES\MATLAB704\sys\lcc
[3] Microsoft Visual C/C++ version 6.0 in C:\Program Files\Microsoft Visual Studio
[0] None
Compiler: 2
4. 次のメッセージが表示されたら、"y" と入力してEnterキーを押します。
Please verify your choices:
Compiler: Lcc C 2.4
Location: C:\PROGRAM FILES\MATLAB704\sys\lcc
Are these correct?([y]/n): y
次回のMATLAB起動以降も同じコンパイラ設定が反映されます。なお、使用コンパイラを変更したい場合は、再度同じ手順を実行してください。
0 Comments
More Answers (0)
See Also
Categories
Find more on C MEX ファイル アプリケーション in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!