Linux 与 wxWebConnect 的动态链接错误
我使用并为其开发 wxWebConnect 和 Python 绑定(请参阅 http://github.com/jonmmorgan/wxwebconnect/ 和 http://github.com/jonmmorgan/pywebconnect/)。这些之前已经在 Linux 上构建过。但是,添加对 XRC 处理程序的支持后,Python 程序在加载 .so 文件时崩溃,并显示错误:
undefined symbol: _ZN22wxWebControlXmlHandlerC1Ev
自从进行更改以支持 XRC 以来,该库已在 Mac OS X 和 Windows 上构建并正确运行。
这个问题的原因似乎是类wxWebControlXmlHandler的构造函数(参见https: //github.com/jonmmorgan/wxwebconnect/blob/master/xh_webcontrol.cpp)未包含在构建的共享对象文件中。在 xh_webcontrol.o 上运行 nm 显示该符号位于该目标文件的文本部分中,并且该目标文件是链接到共享目标的目标文件之一。然而,在共享对象文件上运行 nm 显示它是未定义的,这就是导致崩溃的原因。
我无法理解为什么构造函数没有包含在共享对象文件中,因为它显然是必需的(并且我知道构造函数是在 webcontrol.cpp 中调用的)。这有充分的理由吗?我可以或应该做些什么来强制将构造函数包含在共享对象文件中并导出?
用于构建的命令(生成的安装工具):
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -Iinclude -Isrc -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -Icontrib/wc -Icontrib/wc/webconnect -I/usr/include/xulrunner-1.9.2.11 -I/usr/include/python2.6 -c contrib/wc/gtk/wc_wrap.cpp -o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/gtk/wc_wrap.o -pthread -O3 -pthread
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -Iinclude -Isrc -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -Icontrib/wc -Icontrib/wc/webconnect -I/usr/include/xulrunner-1.9.2.11 -I/usr/include/python2.6 -c contrib/wc/webconnect/dom.cpp -o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/dom.o -pthread -O3 -pthread
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -Iinclude -Isrc -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -Icontrib/wc -Icontrib/wc/webconnect -I/usr/include/xulrunner-1.9.2.11 -I/usr/include/python2.6 -c contrib/wc/webconnect/nsimpl.cpp -o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/nsimpl.o -pthread -O3 -pthread
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -Iinclude -Isrc -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -Icontrib/wc -Icontrib/wc/webconnect -I/usr/include/xulrunner-1.9.2.11 -I/usr/include/python2.6 -c contrib/wc/webconnect/promptservice.cpp -o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/promptservice.o -pthread -O3 -pthread
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -Iinclude -Isrc -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -Icontrib/wc -Icontrib/wc/webconnect -I/usr/include/xulrunner-1.9.2.11 -I/usr/include/python2.6 -c contrib/wc/webconnect/protocolhandler.cpp -o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/protocolhandler.o -pthread -O3 -pthread
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -Iinclude -Isrc -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -Icontrib/wc -Icontrib/wc/webconnect -I/usr/include/xulrunner-1.9.2.11 -I/usr/include/python2.6 -c contrib/wc/webconnect/webcontrol.cpp -o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/webcontrol.o -pthread -O3 -pthread
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -Iinclude -Isrc -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -Icontrib/wc -Icontrib/wc/webconnect -I/usr/include/xulrunner-1.9.2.11 -I/usr/include/python2.6 -c contrib/wc/webconnect/webframe.cpp -o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/webframe.o -pthread -O3 -pthread
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -Iinclude -Isrc -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -Icontrib/wc -Icontrib/wc/webconnect -I/usr/include/xulrunner-1.9.2.11 -I/usr/include/python2.6 -c contrib/wc/webconnect/webprefs.cpp -o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/webprefs.o -pthread -O3 -pthread
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -Iinclude -Isrc -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -Icontrib/wc -Icontrib/wc/webconnect -I/usr/include/xulrunner-1.9.2.11 -I/usr/include/python2.6 -c contrib/wc/webconnect/xh_webcontrol.cpp -o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/xh_webcontrol.o -pthread -O3 -pthread
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -Iinclude -Isrc -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -Icontrib/wc -Icontrib/wc/webconnect -I/usr/include/xulrunner-1.9.2.11 -I/usr/include/python2.6 -c contrib/wc/pyprotocolhandler.cpp -o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/pyprotocolhandler.o -pthread -O3 -pthread
g++ -pthread -shared -Wl,-O1 -Wl,-Bsymbolic-functions build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/gtk/wc_wrap.o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/dom.o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/nsimpl.o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/promptservice.o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/protocolhandler.o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/webcontrol.o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/webframe.o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/webprefs.o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/xh_webcontrol.o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/pyprotocolhandler.o -L/usr/X11R6/lib -lwx_gtk2u_richtext-2.8 -lwx_gtk2u_aui-2.8 -lwx_gtk2u_xrc-2.8 -lwx_gtk2u_qa-2.8 -lwx_gtk2u_html-2.8 -lwx_gtk2u_adv-2.8 -lwx_gtk2u_core-2.8 -lwx_baseu_xml-2.8 -lwx_baseu_net-2.8 -lwx_baseu-2.8 -lwx_gtk2u_xrc-2.8 -o /home/jmmorgan/wxwebconnect/wxPython-src-2.8.11.0/wxPython/wx/_wc.so -pthread -Wl,-Bsymbolic-functions
I use and develop wxWebConnect and Python bindings for it (see http://github.com/jonmmorgan/wxwebconnect/ and http://github.com/jonmmorgan/pywebconnect/). These have built on Linux before. However, when support for XRC handlers was added Python programs crash when loading the .so file with the error:
undefined symbol: _ZN22wxWebControlXmlHandlerC1Ev
The library has been built and runs correctly on both Mac OS X and Windows since the change was made to support XRC.
The cause of this problem seems to be that the constructor for the class wxWebControlXmlHandler (see https://github.com/jonmmorgan/wxwebconnect/blob/master/xh_webcontrol.cpp) is not being included in the built shared object file. Running nm on xh_webcontrol.o shows that the symbol is in the text section of that object file, and that object file is one of the object files that is linked into the shared object. However, running nm on the shared object file shows that it is undefined, and that is what causes the crash.
I can't understand why the constructor is not being included in the shared object file, since it is obviously required (and I know the constructor is invoked in webcontrol.cpp). Is there a good reason for this? Is there anything I can or should do to force the constructor to be included in the shared object file and exported?
Commands used to build (setuptools generated):
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -Iinclude -Isrc -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -Icontrib/wc -Icontrib/wc/webconnect -I/usr/include/xulrunner-1.9.2.11 -I/usr/include/python2.6 -c contrib/wc/gtk/wc_wrap.cpp -o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/gtk/wc_wrap.o -pthread -O3 -pthread
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -Iinclude -Isrc -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -Icontrib/wc -Icontrib/wc/webconnect -I/usr/include/xulrunner-1.9.2.11 -I/usr/include/python2.6 -c contrib/wc/webconnect/dom.cpp -o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/dom.o -pthread -O3 -pthread
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -Iinclude -Isrc -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -Icontrib/wc -Icontrib/wc/webconnect -I/usr/include/xulrunner-1.9.2.11 -I/usr/include/python2.6 -c contrib/wc/webconnect/nsimpl.cpp -o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/nsimpl.o -pthread -O3 -pthread
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -Iinclude -Isrc -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -Icontrib/wc -Icontrib/wc/webconnect -I/usr/include/xulrunner-1.9.2.11 -I/usr/include/python2.6 -c contrib/wc/webconnect/promptservice.cpp -o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/promptservice.o -pthread -O3 -pthread
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -Iinclude -Isrc -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -Icontrib/wc -Icontrib/wc/webconnect -I/usr/include/xulrunner-1.9.2.11 -I/usr/include/python2.6 -c contrib/wc/webconnect/protocolhandler.cpp -o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/protocolhandler.o -pthread -O3 -pthread
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -Iinclude -Isrc -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -Icontrib/wc -Icontrib/wc/webconnect -I/usr/include/xulrunner-1.9.2.11 -I/usr/include/python2.6 -c contrib/wc/webconnect/webcontrol.cpp -o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/webcontrol.o -pthread -O3 -pthread
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -Iinclude -Isrc -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -Icontrib/wc -Icontrib/wc/webconnect -I/usr/include/xulrunner-1.9.2.11 -I/usr/include/python2.6 -c contrib/wc/webconnect/webframe.cpp -o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/webframe.o -pthread -O3 -pthread
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -Iinclude -Isrc -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -Icontrib/wc -Icontrib/wc/webconnect -I/usr/include/xulrunner-1.9.2.11 -I/usr/include/python2.6 -c contrib/wc/webconnect/webprefs.cpp -o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/webprefs.o -pthread -O3 -pthread
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -Iinclude -Isrc -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -Icontrib/wc -Icontrib/wc/webconnect -I/usr/include/xulrunner-1.9.2.11 -I/usr/include/python2.6 -c contrib/wc/webconnect/xh_webcontrol.cpp -o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/xh_webcontrol.o -pthread -O3 -pthread
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -Iinclude -Isrc -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -Icontrib/wc -Icontrib/wc/webconnect -I/usr/include/xulrunner-1.9.2.11 -I/usr/include/python2.6 -c contrib/wc/pyprotocolhandler.cpp -o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/pyprotocolhandler.o -pthread -O3 -pthread
g++ -pthread -shared -Wl,-O1 -Wl,-Bsymbolic-functions build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/gtk/wc_wrap.o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/dom.o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/nsimpl.o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/promptservice.o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/protocolhandler.o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/webcontrol.o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/webframe.o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/webprefs.o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/webconnect/xh_webcontrol.o build-gtk2.unicode/temp.linux-i686-2.6/contrib/wc/pyprotocolhandler.o -L/usr/X11R6/lib -lwx_gtk2u_richtext-2.8 -lwx_gtk2u_aui-2.8 -lwx_gtk2u_xrc-2.8 -lwx_gtk2u_qa-2.8 -lwx_gtk2u_html-2.8 -lwx_gtk2u_adv-2.8 -lwx_gtk2u_core-2.8 -lwx_baseu_xml-2.8 -lwx_baseu_net-2.8 -lwx_baseu-2.8 -lwx_gtk2u_xrc-2.8 -o /home/jmmorgan/wxwebconnect/wxPython-src-2.8.11.0/wxPython/wx/_wc.so -pthread -Wl,-Bsymbolic-functions
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
尝试将目标文件放入
-Wl,--whole-archive
-Wl,--no-whole-archive
部分。人ld
:Try putting your object files in
-Wl,--whole-archive
-Wl,--no-whole-archive
section.man ld
: