debian:mysql-workbench安装错误[找不到-lpython2.7.a]

时间:2013-01-03 09:47:05

标签: linux python-2.7 debian mysql-python mysql-workbench

我正在尝试从Linux debian 2.6.32-5-amd64上的源代码安装mysql-workbench-gpl-5.2.45。问题出现在“make”步骤,并显示错误消息:

/usr/bin/ld: cannot find -lpython2.7.a
collect2: ld returned 1 exit status
make[4]: *** [libgrt.la] Error 1
make[4]: Leaving directory `/home/user/data/workbench/mysql-workbench-gpl-5.2.45-src/library/grt/src'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/home/user/data/workbench/mysql-workbench-gpl-5.2.45-src/library/grt'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/user/data/workbench/mysql-workbench-gpl-5.2.45-src/library'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/user/data/workbench/mysql-workbench-gpl-5.2.45-src'
make: *** [all] Error 2

错误之前的最后一个make命令是:

make[4]: Entering directory `/home/user/data/workbench/mysql-workbench-gpl-5.2.45-src/library/grt/src'
/bin/bash ../../../libtool --tag=CXX   --mode=link g++  -Wextra -Wall -Wno-unused -Wno-deprecated    -DTIXML_USE_STL=1   -o libgrt.la -rpath /usr/local/lib/mysql-workbench grtpp_grt.lo grtpp_helper.lo grtpp_metaclass.lo grtpp_util.lo grtpp_value.lo grtpp_shell.lo grtpp_shell_lua.lo grtpp_shell_lua_help.lo grtpp_module.lo grtpp_module_cpp.lo grtpp_module_lua.lo grtpp_notifications.lo lua_context.lo serializer.lo unserializer.lo grtpp_undo_manager.lo changefactory.lo changelistobjects.lo diffchange.lo grtdiff.lo grtlistdiff.lo grtpp_module_python.lo grtpp_shell_python.lo grtpp_shell_python_help.lo python_context.lo python_grtdict.lo python_grtlist.lo python_grtobject.lo python_module.lo -llua5.1   -luuid -pthread -Wl,--export-dynamic -lgthread-2.0 -lgmodule-2.0 -lrt -lglib-2.0 -lxml2 -lsigc-2.0 -llua5.1   -luuid -L/usr/local/lib -lpython2.7.a ../../../library/base/libwbbase.la 

libtool: link: g++ -shared -nostdlib /usr/lib/gcc/x86_64-linux-gnu/4.4.5/../../../../lib/crti.o /usr/lib/gcc/x86_64-linux-gnu/4.4.5/crtbeginS.o  .libs/grtpp_grt.o .libs/grtpp_helper.o .libs/grtpp_metaclass.o .libs/grtpp_util.o .libs/grtpp_value.o .libs/grtpp_shell.o .libs/grtpp_shell_lua.o .libs/grtpp_shell_lua_help.o .libs/grtpp_module.o .libs/grtpp_module_cpp.o .libs/grtpp_module_lua.o .libs/grtpp_notifications.o .libs/lua_context.o .libs/serializer.o .libs/unserializer.o .libs/grtpp_undo_manager.o .libs/changefactory.o .libs/changelistobjects.o .libs/diffchange.o .libs/grtdiff.o .libs/grtlistdiff.o .libs/grtpp_module_python.o .libs/grtpp_shell_python.o .libs/grtpp_shell_python_help.o .libs/python_context.o .libs/python_grtdict.o .libs/python_grtlist.o .libs/python_grtobject.o .libs/python_module.o   -Wl,-rpath -Wl,/home/user/data/workbench/mysql-workbench-gpl-5.2.45-src/library/base/.libs -Wl,-rpath -Wl,/usr/local/lib/mysql-workbench /usr/lib/libgthread-2.0.so /usr/lib/libgmodule-2.0.so -lrt /usr/lib/libglib-2.0.so /usr/lib/libxml2.so /usr/lib/libsigc-2.0.so /usr/lib/liblua5.1.so -luuid -L/usr/local/lib -lpython2.7.a ../../../library/base/.libs/libwbbase.so -L/usr/lib/gcc/x86_64-linux-gnu/4.4.5 -L/usr/lib/gcc/x86_64-linux-gnu/4.4.5/../../../../lib -L/lib/../lib -L/usr/lib/../lib -L/usr/lib/gcc/x86_64-linux-gnu/4.4.5/../../.. -L/usr/lib/x86_64-linux-gnu -lstdc++ -lm -lc -lgcc_s /usr/lib/gcc/x86_64-linux-gnu/4.4.5/crtendS.o /usr/lib/gcc/x86_64-linux-gnu/4.4.5/../../../../lib/crtn.o  -pthread -Wl,--export-dynamic   -pthread -Wl,-soname -Wl,libgrt.so.0 -o .libs/libgrt.so.0.0.0

我检查了库位置:

locate lpython2.7.a

结果是:

/usr/local/lib/lpython2.7.a

这里下载了python2.7.3: http://www.python.org/ftp/python/2.7.3/Python-2.7.3.tar.bz2

python2.7.3安装步骤:

tar -xvjpf Python-2.7.3.tar.bz2 && cd Python-2.7.3 && ./configure && make && make install

为什么WB无法找到图书馆的任何想法?

1 个答案:

答案 0 :(得分:0)

问题解决了。在安装mysql-workbench之前,正确安装python2.7很重要。这里的安装说明:https://gist.github.com/1069219