Error using mex, LINK : fatal error LNK1104: cannot open file 'ifconsol.lib'
조회 수: 13 (최근 30일)
이전 댓글 표시
I used mex to build a Fortran timestwo.F with Intel Parallel Studio XE 2017 for Fortran and Microsoft Visual Studio 2017. It generated an error: LINK : fatal error LNK1104: cannot open file 'ifconsol.lib'. I set path to both x64 and x32 ifconsol.lib but it didn't work. What should I do to solve the problem? Thanks.
댓글 수: 0
답변 (2개)
Pruthvi Muppavarapu
2019년 5월 13일
편집: Pruthvi Muppavarapu
2019년 5월 13일
Hi Tuan,
The above error might be a result of not having the necessary libraries in the library path. Try running the following commands to add the libraries:
>> fortranRoot = getenv( 'IFORT_COMPILER17');
>> mex('timestwo.F', ['-L' fullfile(fortranRoot, 'compiler', 'lib', 'intel64_win') ]);
Regards,
Pruthvi
댓글 수: 0
Alejandro Pedrozo
2021년 7월 21일
Hi, I had this problem working with the mex function, Microsoft Visual Studio 2010, and Intel composer XE 13. I tried to find the missing libraries in the default folder of the compiler(C:\Program Files (x86)\Intel\Composer XE 2013\Compiler\lib), but they were not there. Fortunately, I have Intel composer XE 11 installed on another computer, its library folder had the missing libraries I needed. So, I copied the required ones from one folder to the other to run the example again. I noted that the error changed since the missing libraries were different this time. I iterated this procedure until the code ran successfully. I hope this information helps you!
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Fortran with MATLAB에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!