Compile a 32-bit shared library from a 64-bit Linux machine with 64-bit MATLAB installed

조회 수: 2 (최근 30일)
Hi, I have a 64-bit MATLAB (with compiler) installed on a 64-bit Linux machine. I would like to compile my scripts into a 32-bit shared library so it can be deployed to a 32 bit linux machine. I have tried to pass -m32 to the gcc compiler by modifying the mbuild options file but that doesn't seem to work. I'm just wondering if it's possible to do what I just described? Or shall I just install a 32-bit MATLAB? Thank you.

채택된 답변

Titus Edelhofer
Titus Edelhofer 2012년 3월 30일
Hi,
it's at least difficult, but I guess probably not possible at all. It will definetely simpler to just install a 32 Bit MATLAB in parallel ...
Titus
  댓글 수: 2
Kaustubha Govind
Kaustubha Govind 2012년 3월 30일
I agree. 32-bit MATLAB is the way to do. Especially because the 32-bit library will need to link against MATLAB runtime libraries which also need to be 32-bit.
Weizhen
Weizhen 2012년 4월 10일
Thank you guys for your helpful suggestions.
I had also come to the conclusion that installing a 32-bit MATLAB is much easier than anything else.
Worth mentioning is my 64-bit machine runs a CentOS that comes with SELinux. SELinux prevents 32-bit MATLAB to start and here's a whole page dedicated on how to work around this problem.
http://www.mathworks.com.au/support/solutions/en/data/1-2SGOXN/index.html?solution=1-2SGOXN
Cheers,
Weizhen

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile 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!

Translated by