pyuno libreoffice中缺少符号,无法使用python2

2024-05-29 01:45:35 发布

您现在位置:Python中文网/ 问答频道 /正文

我已经在Linux上使用GCC4.9.1从源代码安装了Libreoffice版本6.0.4.2 当我试图在python2中导入uno时,我得到了一条错误消息。动态模块未定义init函数(initpyuno)

Python 2.7.11 |Anaconda custom (64-bit)| (default, Dec  6 2015, 18:08:32) 
[GCC 4.4.7 20120313 (Red Hat 4.4.7-1)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
Anaconda is brought to you by Continuum Analytics.
Please check out: http://continuum.io/thanks and https://anaconda.org
>>> import pyuno
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: dynamic module does not define init function (initpyuno)
>>> 

但这对python3很有效。你知道吗

Python 3.6.5 |Anaconda custom (64-bit)| (default, Apr 29 2018, 16:14:56) 
[GCC 7.2.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import pyuno
>>> exit()

经过调查,我发现符号initpyuno在平野.so. 你知道吗

programnm -D pyuno.so 
                 U abort
0000000000201078 B __bss_start
                 w __cxa_finalize
                 U dladdr
                 U dlclose
                 U dlerror
                 U dlopen
                 U dlsym
0000000000201078 D _edata
0000000000201080 B _end
0000000000000b2c T _fini
                 U fprintf
                 U free
                 w __gmon_start__
00000000000007f0 T _init
                 w _ITM_deregisterTMCloneTable
                 w _ITM_registerTMCloneTable
                 w _Jv_RegisterClasses
                 U malloc
0000000000000b0c T PyInit_pyuno
                 U stderr
                 U strncpy
                 U strrchr

有人能帮我怎么处理图书馆里丢失的符号吗?你知道吗


Tags: ordefaultinitlicenseontypecustombit

热门问题