vlfeat-0.9.19 /工具箱/ MEX/mexa64/libvl.so:未定义符号:GOMP_parallel

问题描述:

我与在制备用于MEX MATLAB通过以下命令vlfeat-0.9.19 /工具箱/ MEX/mexa64/libvl.so:未定义符号:GOMP_parallel

make MEX=MATLABROOT/bin/mex 

编译在Linux(的archlinux)vlfeat VLFEATROOT目录。输出看起来很好,因为没有错误报告。顺便说一下,我使用gcc4.7来编译上面的东西。

我在MATLAB执行代码非常简单:

VLFEATROOT = '~/user-libs/vlfeat/vlfeat-0.9.19/'; 
path_vlfeat = [VLFEATROOT 'toolbox/vl_setup']; 
run(path_vlfeat); 
vl_version; 

MATLAB的报告如下红线:

Invalid MEX-file '/home/bingqingqu/user-libs/vlfeat/vlfeat-0.9.19/toolbox/mex/mexa64/vl_version.mexa64': 
/home/bingqingqu/user-libs/vlfeat/vlfeat-0.9.19/toolbox/mex/mexa64/libvl.so: undefined symbol: GOMP_parallel 

我不知道很多关于OpenMP的,但似乎这是关系到。我注意到,在vlfeat的makefile中有用于关闭OpenMP的一个选项:

# DISABLE_OPENMP=yes 

,我将它设置为“是”,编译和运行简单的代码。以上所有内容现在都可以执

但我想知道如果我将选项留给否,问题是什么。生成文件评论说:

# If defined to anything other than "no", the following falgs disable 
# specific features in the library. By defaults, all the features are 
# enabled. If the makefile finds that the environment is unable to 
# support some of them, it may decide to disable them automatically 
# (in this case it will print a message). This behaviour can be 
# overriden by defining the flag to be "no". 

我简要地搜索在谷歌的一些OpenMP的知识,它似乎是我所有的OpenMP或gomp安装罚款。见下面: ldconfig -p | grep的gomp 结果是:

libgomp.so.1 (libc6,x86-64) => /usr/lib/libgomp.so.1 
libgomp.so.1 (libc6) => /usr/lib32/libgomp.so.1 
libgomp.so (libc6,x86-64) => /usr/lib/libgomp.so 
libgomp.so (libc6) => /usr/lib32/libgomp.so 

预先感谢您的帮助!

请参考以下修复: https://github.com/vlfeat/vlfeat/pull/94