Problem in running fortran mex example on Matlab R2012a
조회 수: 2 (최근 30일)
이전 댓글 표시
Hi,
I just installed Matlab R2012a on my 64bit Ubuntu Maverick machine. I have gcc-4.4, gfortran 4.4 and gfortran 4.3 on my machine. In this article http://www.mathworks.com/support/compilers/R2012a/glnxa64.html, it says only gfortran 4.3 is supported by using mex, so I changed the file /usr/local/MATLAB/R2012a/bin/mexopts.sh. In the section "glnxa64" in that file, I changed FC='gfortran-4.3'.
But when I try to run the mex examples in /extern/examples/mex as described in http://www.mathworks.com/support/tech-notes/1600/1605.html#testing, I can successfully run mex yprime.c and yprime(1,1:4), but mex does not compile yprime.F or yprimefg.F, it throws an exception "mex: yprime.F not a normal file or does not exist. Error using mex (line 206) Unable to complete successfully." What's the possible reason for this?
Thanks for your kind help!
Hongkai
댓글 수: 0
답변 (2개)
Octopode
2013년 7월 31일
편집: Octopode
2013년 7월 31일
I'm having the same problem under Ubuntu 13.04. I installed gcc 4.4, but cannot install gfortran 4.3. Following the above answer i couldn't install gcc-4.3 using apt-get. Got this error :
~$ sudo apt-get install gcc-4.3 Reading package lists... Done Building dependency tree Reading state information... Done Some packages could not be installed. This may mean that you have requested an impossible situation or if you are using the unstable distribution that some required packages have not yet been created or been moved out of Incoming. The following information may help to resolve the situation:
The following packages have unmet dependencies: gcc-4.3 : Depends: binutils (>= 2.19.1) but it is not going to be installed Depends: libgomp1 (>= 4.3.4-10ubuntu1) but it is not going to be installed libgcc1 : Breaks: gcc-4.3 (< 4.3.6-1) but 4.3.4-10ubuntu1 is to be installed libgtk2.0-0 : Depends: libpango1.0-0 (>= 1.28.3) but it is not going to be installed Recommends: libgtk2.0-bin libstdc++6 : Breaks: gcc-4.3 (< 4.3.6-1) but 4.3.4-10ubuntu1 is to be installed ure : Depends: uno-libs3 (= 4.0.2-0ubuntu1) but it is not going to be installed Breaks: openoffice.org-core (< 1:3.3~) but 1:3.2.0-7ubuntu4 is to be installed E: Error, pkgProblemResolver::Resolve generated breaks, this may be caused by held packages.
So I'm stuck. Any idea how i can install gcc-4.3 to make gfortran 4.3 happy ?
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Introduction to Installation and Licensing에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!