Building wxPython 2.8.8.0 on Suse Linux

I’m trying to build wxPython 2.8.8.0 on Suse Linux 10.3.
wxWidgets compiles, but tried to install wxPython it failed with the
following error:

WARNING: WXWIN not set in environment. Assuming ‘…’

Preparing CORE…

Preparing GLCANVAS…

Preparing STC…

Preparing GIZMOS…

running install

running build

running build_py

copying wx/version.py ->
build-gtk2.unicode/lib.linux-x86_64-2.5/wx

copying wx/build/build_options.py ->
build-gtk2.unicode/lib.linux-x86_64-2.5/wx/build

package init file ‘wx/tools/XRCed/plugins/init.py’ not
found (or not a regular file)

package init file ‘wx/tools/XRCed/plugins/init.py’ not
found (or not a regular file)

running build_ext

building ‘gdi’ extension

gcc -pthread -fno-strict-aliasing -DNDEBUG -O2
-fmessage-length=0 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector -g -fPIC
-DSWIG_TYPE_TABLE=wxPython_table -DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1
-UNDEBUG -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXDEBUG
_ -D__WXGTK__
-DPNG_NO_MMX_CODE -Iinclude -Isrc
-I/usr/local/lib/wx/include/gtk2-unicode-debug-2.8 -I/usr/local/include/wx-2.8
-I/usr/include/gtk-2.0 -I/usr/lib64/gtk-2.0/include -I/usr/include/atk-1.0
-I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/glib-2.0
-I/usr/lib64/glib-2.0/include -I/usr/include/freetype2 -I/usr/include/libpng12
-I/usr/include/python2.5 -c src/gtk/_gdi_wrap.cpp -o
build-gtk2.unicode/temp.linux-x86_64-2.5/src/gtk/_gdi_wrap.o -pthread -O3

In file included from src/gtk/_gdi_wrap.cpp:2737:

include/wx/wxPython/wxPython.h: In function ‘bool
wxPyCoreAPI_IMPORT()’:

include/wx/wxPython/wxPython.h:39: warning: deprecated
conversion from string constant to ‘char*’

include/wx/wxPython/wxPython.h:39: warning: deprecated
conversion from string constant to ‘char*’

src/gtk/_gdi_wrap.cpp: In function ‘wxPalette*
new_wxPalette(const wxArrayInt&, const wxArrayInt&, const
wxArrayInt&)’:

src/gtk/_gdi_wrap.cpp:2884: warning: comparison between
signed and unsigned integer expressions

src/gtk/_gdi_wrap.cpp:2884: warning: comparison between
signed and unsigned integer expressions

src/gtk/_gdi_wrap.cpp: In function ‘PyObject*
_wrap_new_GnomePrintDC(PyObject*, PyObject*, PyObject*)’:

src/gtk/_gdi_wrap.cpp:25351: error:
‘wxGnomePrintDC’ was not declared in this scope

src/gtk/_gdi_wrap.cpp:25351: error: ‘result’ was
not declared in this scope

src/gtk/_gdi_wrap.cpp:25370: error: expected
primary-expression before ‘)’ token

src/gtk/_gdi_wrap.cpp:25370: error: expected `;’ before
‘new’

src/gtk/_gdi_wrap.cpp: In function ‘PyObject* _wrap_GnomePrintDC_SetResolution(PyObject*,
PyObject*, PyObject*)’:

src/gtk/_gdi_wrap.cpp:25399: error:
‘wxGnomePrintDC’ has not been declared

src/gtk/_gdi_wrap.cpp: In function ‘PyObject*
_wrap_GnomePrintDC_GetResolution(PyObject*, PyObject*)’:

src/gtk/_gdi_wrap.cpp:25417: error:
‘wxGnomePrintDC’ was not declared in this scope

src/gtk/_gdi_wrap.cpp:25417: error: expected `;’ before
‘::’ token

src/gtk/_gdi_wrap.cpp: In function ‘PyObject*
_wrap_PenList_AddPen(PyObject*, PyObject*, PyObject*)’:

src/gtk/_gdi_wrap.cpp:32373: warning: ‘AddPen’
is deprecated (declared at /usr/local/include/wx-2.8/wx/gdicmn.h:516)

src/gtk/_gdi_wrap.cpp: In function ‘PyObject*
_wrap_PenList_RemovePen(PyObject*, PyObject*, PyObject*)’:

src/gtk/_gdi_wrap.cpp:32411: warning:
‘RemovePen’ is deprecated (declared at
/usr/local/include/wx-2.8/wx/gdicmn.h:517)

src/gtk/_gdi_wrap.cpp: In function ‘PyObject*
_wrap_BrushList_AddBrush(PyObject*, PyObject*, PyObject*)’:

src/gtk/_gdi_wrap.cpp:32504: warning: ‘AddBrush’
is deprecated (declared at /usr/local/include/wx-2.8/wx/gdicmn.h:526)

src/gtk/_gdi_wrap.cpp: In function ‘PyObject*
_wrap_BrushList_RemoveBrush(PyObject*, PyObject*, PyObject*)’:

src/gtk/_gdi_wrap.cpp:32542: warning:
‘RemoveBrush’ is deprecated (declared at
/usr/local/include/wx-2.8/wx/gdicmn.h:527)

src/gtk/_gdi_wrap.cpp: In function ‘PyObject*
_wrap_FontList_AddFont(PyObject*, PyObject*, PyObject*)’:

src/gtk/_gdi_wrap.cpp:32694: warning: ‘AddFont’
is deprecated (declared at /usr/local/include/wx-2.8/wx/gdicmn.h:539)

src/gtk/_gdi_wrap.cpp: In function ‘PyObject*
_wrap_FontList_RemoveFont(PyObject*, PyObject*, PyObject*)’:

src/gtk/_gdi_wrap.cpp:32732: warning:
‘RemoveFont’ is deprecated (declared at
/usr/local/include/wx-2.8/wx/gdicmn.h:540)

src/gtk/_gdi_wrap.cpp: In function ‘void*
_p_wxGnomePrintDCTo_p_wxDC(void*)’:

src/gtk/_gdi_wrap.cpp:39961: error:
‘wxGnomePrintDC’ was not declared in this scope

src/gtk/_gdi_wrap.cpp:39961: error: expected
primary-expression before ‘void’

src/gtk/_gdi_wrap.cpp:39961: error: expected `)’ before
‘void’

src/gtk/_gdi_wrap.cpp: In function ‘void*
_p_wxGnomePrintDCTo_p_wxObject(void*)’:

src/gtk/_gdi_wrap.cpp:40165: error:
‘wxGnomePrintDC’ was not declared in this scope

src/gtk/_gdi_wrap.cpp:40165: error: expected
primary-expression before ‘void’

src/gtk/_gdi_wrap.cpp:40165: error: expected `)’ before
‘void’

error: command ‘gcc’ failed with exit status 1

Build used the command: python2.5 setup.py install
WX_CONFIG=/usr/local/bin/wx-config

Thanks for your help.

Barry Newberger

···

Newberger, Barry wrote:

I'm trying to build wxPython 2.8.8.0 on Suse Linux 10.3. wxWidgets compiles, but tried to install wxPython it failed with the following error:

src/gtk/_gdi_wrap.cpp:25351: error: ‘wxGnomePrintDC’ was not declared in this scope

The fix for this is in the SVN repository already, or you can just ensure that you have the development packages installed for libgnomeprint and libgnomeprintui and then reconfigure and rebuild wxGTK.

···

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!