我正在尝试在RHEL5.5上构建omniORB库。
我尝试使用以下命令运行配置
CC=gcc和CXX=g++和PYTHON=bin/omnipython
我遇到了这个问题,它抱怨说
gmake[3]: Entering directory `/home/local/NT/jayanthv/omniORB-4.1.4/src/lib/omniORB'
../../../bin/omniidl -bcxx -p../../../src/lib/omniORB -Wbdebug -Wba -p../../../src/lib/omniORB -Wbdebug -v -ComniORB4 ../../../idl/Naming.idl
omniidl: ERROR!
omniidl: Could not open IDL compiler module _omniidlmodule.so
omniidl: Please make sure it is in directory /home/local/NT/jayanthv/omniORB-4.1.4/lib
omniidl: (or set the PYTHONPATH environment variable)
omniidl: (The error was '/home/local/NT/jayanthv/omniORB-4.1.4/lib/_omniidlmodule.so: wrong ELF class: ELFCLASS64')因此,我尝试使用英特尔C++编译器,
export CXX=/opt/intel/Compiler/11.1/080/bin/ia32/icc
export LD_LIBRARY_PATH=/opt/intel/Compiler/11.1/080/lib/ia32
export PYTHON=/home/local/NT/jayanthv/omniORB-4.1.4/bin/omnipython但是,现在它抱怨../../../bin/omniidl -bcxx -p../../../src/lib/omniORB -Wbdebug -Wba -p../src/lib/omniORB -Wbdebug -v -ComniORB4 ../idl/naming.idl
omniidl: ERROR!
omniidl: Could not open IDL compiler module _omniidlmodule.so
omniidl: Please make sure it is in directory /home/local/NT/jayanthv/omniORB-4.1.4/lib
omniidl: (or set the PYTHONPATH environment variable)
omniidl: (The error was '/home/local/NT/jayanthv/omniORB-4.1.4/lib/_omniidlmodule.so: undefined symbol: __cxa_pure_virtual')操作系统是带有x86_64架构的RHEL5.5,我正在尝试构建32位二进制文件。对这个问题的任何见解都将不胜感激。
发布于 2012-09-06 04:18:01
我终于找到了在Linux上使用英特尔编译器构建omniORB的神奇组合。
您可以看到它在哪里抱怨没有找到'__cxa_pure_virtual‘,这发生在gcc的下面,因为它找不到一个名为libstdc++的库
因此,根据您使用的编译器来选择CC="icc -lstdc++"或CC="gcc -lstdc++"。对CXX执行相同的操作(如果使用g++,则在g++中指定它)
对于Python,我使用了omnipython,它是python1.5,PYTHON=bin/omnipython
这意味着它是相对于omniORB根路径进行查找的。
你可以看到它在哪里抱怨“错误的ELF类:ELFCLASS64”,这是因为你试图使用64位链接器链接一个32位二进制文件。
因此,强制将编译器和链接器标志设置为32。
CFLAGS=-m32 CXXFLAGS=-m32 LDFLAGS=-m32
完成后,运行您的配置
./configure --prefix=/opt/omniInst --build=i686-pc-linux-gnu
运行gmake,然后运行gmake install,您将看到omniInst或您建议的任何前缀目录下的所有二进制文件和库。
发布于 2012-08-27 23:19:38
这是因为omniidl是作为Python扩展模块实现的。您正在使用的Python可执行文件是64位可执行文件,因此它不能加载32位库。
请查看此http://objectmix.com/object/196129-compiling-omniorb-32bits-libraries-64bits-machine-suse.html
https://stackoverflow.com/questions/12143049
复制相似问题