Why does a LD_PRELOAD error appear when using MEX commands on Linux?
Mostrar comentarios más antiguos
I am working on Linux (Red Hat 7.8) and am experiencing errors while trying to run mex commands.
Below is the error log when setting up MEX compiler:
>> mex -setup
Segmentation fault (core dumped)
ERROR: ld.so: object '/raid/tools/MATLAB/R2021a/bin/glnxa64/glibc-2.17_shim.so' from LD_PRELOAD cannot be preloaded: ignored.
Segmentation fault (core dumped)
ERROR: ld.so: object '/raid/tools/MATLAB/R2021a/bin/glnxa64/glibc-2.17_shim.so' from LD_PRELOAD cannot be preloaded: ignored.
Segmentation fault (core dumped)
ERROR: ld.so: object '/raid/tools/MATLAB/R2021a/bin/glnxa64/glibc-2.17_shim.so' from LD_PRELOAD cannot be preloaded: ignored.
Segmentation fault (core dumped)
ERROR: ld.so: object '/raid/tools/MATLAB/R2021a/bin/glnxa64/glibc-2.17_shim.so' from LD_PRELOAD cannot be preloaded: ignored.
Segmentation fault (core dumped)
ERROR: ld.so: object '/raid/tools/MATLAB/R2021a/bin/glnxa64/glibc-2.17_shim.so' from LD_PRELOAD cannot be preloaded: ignored.
Segmentation fault (core dumped)
ERROR: ld.so: object '/raid/tools/MATLAB/R2021a/bin/glnxa64/glibc-2.17_shim.so' from LD_PRELOAD cannot be preloaded: ignored.
MEX configured to use 'gcc' for C language compilation.
Output for echo LD_PRELOAD in terminal:
LD_PRELOAD: Undefined variable.
Executing MCC command to compile a simple library:
>> mex -v -DMEX -outdir C_model/mex C_model/source/mex/encode_C.cpp C_model/source/Accessories.cpp C_model/source/Channel.cpp C_model/source/CoDec.cpp C_model/source/Encoder.cpp C_model/source/GF2.cpp C_model/source/Index.cpp
Verbose mode is on.
... Looking for compiler 'g++' ...
... Executing command 'which g++' ...Segmentation fault (core dumped)
ERROR: ld.so: object '/raid/tools/MATLAB/R2021a/bin/glnxa64/glibc-2.17_shim.so' from LD_PRELOAD cannot be preloaded: ignored.
Yes ('/home/liork/.local/bin/g++').
... Executing command 'g++ -print-file-name=libstdc++.so' ...Segmentation fault (core dumped)
ERROR: ld.so: object '/raid/tools/MATLAB/R2021a/bin/glnxa64/glibc-2.17_shim.so' from LD_PRELOAD cannot be preloaded: ignored.
Yes ('/usr/local/gcc/9.2.0/lib64/libstdc++.so').
... Executing command 'g++ -dumpversion' ...Segmentation fault (core dumped)
ERROR: ld.so: object '/raid/tools/MATLAB/R2021a/bin/glnxa64/glibc-2.17_shim.so' from LD_PRELOAD cannot be preloaded: ignored.
Yes ('9.2.0').
... Executing command 'which g++' ...Segmentation fault (core dumped)
ERROR: ld.so: object '/raid/tools/MATLAB/R2021a/bin/glnxa64/glibc-2.17_shim.so' from LD_PRELOAD cannot be preloaded: ignored.
Yes ('/home/liork/.local/bin/g++').
... Looking for folder '/usr/local/gcc/9.2.0' ...Yes.
... Executing command 'g++ -dumpmachine' ...Segmentation fault (core dumped)
ERROR: ld.so: object '/raid/tools/MATLAB/R2021a/bin/glnxa64/glibc-2.17_shim.so' from LD_PRELOAD cannot be preloaded: ignored.
Yes ('x86_64-pc-linux-gnu').
Found installed compiler 'g++'.
... Looking for compiler 'g++' ...
... Executing command 'which g++' ...Segmentation fault (core dumped)
I have everything installed correctly, including MATLAB and C compiler (GCC). I have also tried to set LY_PRELOAD using "setenv()", but the issue persists.
What can be the cause of the issue?
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Introduction to Installation and Licensing en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!