Why do I receive unresolved symbol errors when running a stand-alone application generated by MATLAB Compiler 4.0 (R14) on my HP-UX machine?

2 views (last 30 days)
On my HP-UX machine, I have used the MATLAB Compiler's MCC command to successfully generate a stand-alone application. However, when I run the application from my system command shell, I receive the following fatal errors:
/userName/matlab/releases/release_4.2Beta/compile>./loop
/usr/lib/dld.sl: Unresolved symbol: sem_post (code) from /userName/matlab/MCR/v72/bin/hpux/libut.sl
/usr/lib/dld.sl: Unresolved symbol: sem_destroy (code) from /userName/matlab/MCR/v72/bin/hpux/libut.sl
/usr/lib/dld.sl: Unresolved symbol: sem_trywait (code) from /userName/matlab/MCR/v72/bin/hpux/libut.sl
/usr/lib/dld.sl: Unresolved symbol: sem_wait (code) from /userName/matlab/MCR/v72/bin/hpux/libut.sl
/usr/lib/dld.sl: Unresolved symbol: sem_init (code) from /userName/matlab/MCR/v72/bin/hpux/libut.sl
/usr/lib/dld.sl: Unresolved symbol: U_get_previous_frame_x (code) from /usr/lib/libCsup_v2.2
Abort(coredump)

Accepted Answer

MathWorks Support Team
MathWorks Support Team on 27 Jan 2017
These errors generally indicate that the LD_PRELOAD environment variable has not been set correctly.
If the machine running the application has MATLAB installed, LD_PRELOAD can be set correctly using the following command at your system command shell:
setenv LD_PRELOAD <matlabroot>/sys/java/jre/hpux/jre1.4.1/lib/PA_RISC2.0/server/libjvm.sl
where _matlabroot _refers to the MATLAB installation directory, which can be determined by entering
matlabroot
at the MATLAB Command Prompt.
For more information on environment configuration for stand-alone applications running on machines that have MATLAB installed, enter the following at the MATLAB Command Prompt:
web([docroot,'/toolbox/compiler/ch04standalone5.html#995872'])'
If the machine in question does not have MATLAB installed but rather has the MATLAB Component Runtime (MCR) libraries installed, the following command will correctly set the LD_PRELOAD environment variable:
setenv LD_PRELOAD
<mcr_root>/<ver>/sys/java/jre/hpux/jre1.4.1/lib/PA_RISC2.0/server/libjvm.sl
where _mcr_root _refers to the MCR installation directory, and <ver> refers to the MCR version.
For more information on environment configuration for stand-alone applications running on machines that have the MCR libraries installed, enter the following at the MATLAB Command Prompt:
web([docroot,'/toolbox/compiler/ch04standalone7.html#995938'])

More Answers (0)

Categories

Find more on Introduction to Installation and Licensing in Help Center and File Exchange

Products

Community Treasure Hunt

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

Start Hunting!