Error building wxPython 2.9.5.0 on Fedora 15

Hello,

I am experiencing and error when trying to build wxPython 2.9.5.0 on Fedora 15. When I build from source following the build instructions found here: http://www.wxpython.org/BUILD.html the build proceeds along fine for a while until I get this error message:

g++ -pthread -shared -g build/temp.linux-x86_64-2.7/src/helpers.o build/temp.linux-x86_64-2.7/src/gtk/_core_wrap.o -L/usr/X11R6/lib -L/home/nic47222/tmp/wxPython-src-2.9.5.0/bld/lib -L/usr/lib64 -lwx_gtk2u_xrc-2.9 -lwx_gtk2u_webview-2.9 -lwx_gtk2u_html-2.9 -lwx_gtk2u_adv-2.9 -lwx_gtk2u_core-2.9 -lwx_baseu_xml-2.9 -lwx_baseu_net-2.9 -lwx_baseu-2.9 -lpython2.7 -o /home/nic47222/tmp/wxPython-src-2.9.5.0/wxPython/wx/core.so -pthread -Wl,-rpath,/home/nic47222/tmp/wxPython-src-2.9.5.0/bld/lib
/usr/bin/ld: cannot find -lwx_gtk2u_xrc-2.9
/usr/bin/ld: cannot find -lwx_gtk2u_webview-2.9
/usr/bin/ld: cannot find -lwx_gtk2u_html-2.9
/usr/bin/ld: cannot find -lwx_gtk2u_adv-2.9
/usr/bin/ld: cannot find -lwx_gtk2u_core-2.9
/usr/bin/ld: cannot find -lwx_baseu_xml-2.9
/usr/bin/ld: cannot find -lwx_baseu_net-2.9
/usr/bin/ld: cannot find -lwx_baseu-2.9
collect2: ld returned 1 exit status
error: command ‘g++’ failed with exit status 1
ERROR: failed building wxPython.

I checked the bld/lib directory and verified that libwx_gtk2u_-2.9.so files are not present. What I find instead are files named libw_gtk2ud_-2.9.so. I looked into the wxWidgets documentation and from what I can tell the ‘d’ prefix in gtk2ud means that wxWidgets is being build with debug information while the wxPython build script thinks they are being built as a release build. I don’t see any options in he wxPython build script to disable this behavior.

I did see the option in wxPython to ENABLE debug, so I tried this just to see if I could get it built. Even with --debug, the linker was looking for gtk2u_ instead of gtk2ud_

You can see the contents of config.log here: http://pastebin.com/pReqt9S5

Can anyone provide any suggestions?

I’m not so interested in you logs first off. Check out this thread first, apply the patches and other manual additions first, try building again. And watch the terminal when it gets near the end. You might have to place a few well placed print statements in there to catch the error if one occurs.
Sometimes it is a bit different for different flavors of linux.
Anywho check this thread out first…

Regression in 2.9.5 source build - Google Groups

https://groups.google.com/forum/#!searchin/wxpython-users/regression/wxpython-users/kkdGqQmlWr4/d054eY8KEgUJ

Then if you are still having trouble post again with a bit more details.

···

On Wednesday, December 18, 2013 10:45:44 AM UTC-6, mj…@case.edu wrote:

Hello,

I am experiencing and error when trying to build wxPython 2.9.5.0 on Fedora 15. When I build from source following the build instructions found here: http://www.wxpython.org/BUILD.html the build proceeds along fine for a while until I get this error message:
Can anyone provide any suggestions?

mjn12@case.edu wrote:

Hello,

I am experiencing and error when trying to build wxPython 2.9.5.0 on
Fedora 15. When I build from source following the build instructions
found here: Phoenix/README.rst at master · wxWidgets/Phoenix · GitHub the build proceeds along
fine for a while until I get this error message:

g++ -pthread -shared -g build/temp.linux-x86_64-2.7/src/helpers.o
build/temp.linux-x86_64-2.7/src/gtk/_core_wrap.o -L/usr/X11R6/lib
-L/home/nic47222/tmp/wxPython-src-2.9.5.0/bld/lib -L/usr/lib64
-lwx_gtk2u_xrc-2.9 -lwx_gtk2u_webview-2.9 -lwx_gtk2u_html-2.9
-lwx_gtk2u_adv-2.9 -lwx_gtk2u_core-2.9 -lwx_baseu_xml-2.9
-lwx_baseu_net-2.9 -lwx_baseu-2.9 -lpython2.7 -o
/home/nic47222/tmp/wxPython-src-2.9.5.0/wxPython/wx/_core_.so -pthread
-Wl,-rpath,/home/nic47222/tmp/wxPython-src-2.9.5.0/bld/lib
/usr/bin/ld: cannot find -lwx_gtk2u_xrc-2.9
/usr/bin/ld: cannot find -lwx_gtk2u_webview-2.9
/usr/bin/ld: cannot find -lwx_gtk2u_html-2.9
/usr/bin/ld: cannot find -lwx_gtk2u_adv-2.9
/usr/bin/ld: cannot find -lwx_gtk2u_core-2.9
/usr/bin/ld: cannot find -lwx_baseu_xml-2.9
/usr/bin/ld: cannot find -lwx_baseu_net-2.9
/usr/bin/ld: cannot find -lwx_baseu-2.9
collect2: ld returned 1 exit status
error: command 'g++' failed with exit status 1
ERROR: failed building wxPython.

I checked the bld/lib directory and verified that libwx_gtk2u_*-2.9.so
files are not present. What I find instead are files named
libw_gtk2ud_*-2.9.so. I looked into the wxWidgets documentation and from
what I can tell the 'd' prefix in gtk2ud means that wxWidgets is being
build with debug information while the wxPython build script thinks they
are being built as a release build. I don't see any options in he
wxPython build script to disable this behavior.

This is strange. I just tried a build (on ubuntu) from the 2.9.5.0 tarball and it built and used the *u* version of the wx libs, not the *ud* version like yours did. What command-line args did you pass to build-wxpython.py? Did you get your source tree from the source repository or the released tarball? Can you clean your build dir and pastebin the output of the build-wxpython.py command (at least the first block up until the wxWidgets configure step)?

···

--
Robin Dunn
Software Craftsman

Metallicow wrote:

    Hello,

    I am experiencing and error when trying to build wxPython 2.9.5.0 on
    Fedora 15. When I build from source following the build instructions
    found here: Phoenix/README.rst at master · wxWidgets/Phoenix · GitHub
    <http://www.wxpython.org/BUILD.html&gt; the build proceeds along fine
    for a while until I get this error message:
    Can anyone provide any suggestions?

I'm not so interested in you logs first off. Check out this thread
first, apply the patches and other manual additions first, try building
again. And watch the terminal when it gets near the end. You might have
to place a few well placed print statements in there to catch the error
if one occurs.
Sometimes it is a bit different for different flavors of linux.
Anywho check this thread out first...

Regression in 2.9.5 source build - Google Groups
<Redirecting to Google Groups;

Redirecting to Google Groups

Well, considering that was for a completely unrelated problem I don't think it will help much.

Then if you are still having trouble post again with a bit more details.

There were at least enough details already to tell that it wasn't a problem building the html2 module. Please look before you leap.

···

On Wednesday, December 18, 2013 10:45:44 AM UTC-6, mj...@case.edu wrote:

--
Robin Dunn
Software Craftsman

I isolated the problem to the wxWidgets build and found that even when building wxWidgets myself (without the wxPython build script) I was still seeing the issue. It turns out the environment variable BUILD was set to ‘debug’ for our entire organization (our dev machines share a common configuration). This was causing wxWidgets to always build the libraries with debugging enabled, even when command line arguments told it to do otherwise. Un-setting the BUILD environment variable corrected this issue.

···

On Wednesday, December 18, 2013 3:40:04 PM UTC-5, Robin Dunn wrote:

Metallicow wrote:

On Wednesday, December 18, 2013 10:45:44 AM UTC-6, mj…@case.edu wrote:

Hello,
I am experiencing and error when trying to build wxPython 2.9.5.0 on
Fedora 15. When I build from source following the build instructions
found here: [http://www.wxpython.org/BUILD.html](http://www.wxpython.org/BUILD.html)
<[http://www.wxpython.org/BUILD.html](http://www.wxpython.org/BUILD.html)> the build proceeds along fine
for a while until I get this error message:
Can anyone provide any suggestions?

I’m not so interested in you logs first off. Check out this thread

first, apply the patches and other manual additions first, try building

again. And watch the terminal when it gets near the end. You might have

to place a few well placed print statements in there to catch the error

if one occurs.

Sometimes it is a bit different for different flavors of linux.

Anywho check this thread out first…

Regression in 2.9.5 source build - Google Groups

<https://groups.google.com/forum/#!searchin/wxpython-users/regression/wxpython-users/kkdGqQmlWr4/d054eY8KEgUJ>

https://groups.google.com/forum/#!searchin/wxpython-users/regression/wxpython-users/kkdGqQmlWr4/d054eY8KEgUJ

Well, considering that was for a completely unrelated problem I don’t
think it will help much.

Then if you are still having trouble post again with a bit more details.

There were at least enough details already to tell that it wasn’t a
problem building the html2 module. Please look before you leap.


Robin Dunn

Software Craftsman

http://wxPython.org

Well, other than the html2 patches there was other syntax errors I also posted about there that have failed linux builds for NoneType on a few other linux builds also.
And also a fixer for the -so stuff which might/probably not apply for a fedora to build.
This for me was with the src-build.tar from the wxPython Page, which houses the instructions everyone is most often linking to., not from repos readme.
Also, I recall lib_gtk might have needed a update, but IIRC that wasn’t necessary to sucessfully build(28lib stuff).
So are you saying the patches and syntax error corrections have made it into the repo yet? wxWidgets or RobinD repo? Haven’t build for a while on linux.
I’ve just been manually patching the tar when needed to new build.
Not sure, but didn’t recall fedora being ubuntu based, is it?

pps. looks like it has been resolved already.

···

On Wednesday, December 18, 2013 2:40:04 PM UTC-6, Robin Dunn wrote:

Metallicow wrote:

On Wednesday, December 18, 2013 10:45:44 AM UTC-6, mj…@case.edu wrote:

Hello,
I am experiencing and error when trying to build wxPython 2.9.5.0 on
Fedora 15. When I build from source following the build instructions
found here: [http://www.wxpython.org/BUILD.html](http://www.wxpython.org/BUILD.html)
<[http://www.wxpython.org/BUILD.html](http://www.wxpython.org/BUILD.html)> the build proceeds along fine
for a while until I get this error message:
Can anyone provide any suggestions?

I’m not so interested in you logs first off. Check out this thread

first, apply the patches and other manual additions first, try building

again. And watch the terminal when it gets near the end. You might have

to place a few well placed print statements in there to catch the error

if one occurs.

Sometimes it is a bit different for different flavors of linux.

Anywho check this thread out first…

Regression in 2.9.5 source build - Google Groups

<https://groups.google.com/forum/#!searchin/wxpython-users/regression/wxpython-users/kkdGqQmlWr4/d054eY8KEgUJ>

https://groups.google.com/forum/#!searchin/wxpython-users/regression/wxpython-users/kkdGqQmlWr4/d054eY8KEgUJ

Well, considering that was for a completely unrelated problem I don’t
think it will help much.

Then if you are still having trouble post again with a bit more details.

There were at least enough details already to tell that it wasn’t a
problem building the html2 module. Please look before you leap.


Robin Dunn

Software Craftsman

http://wxPython.org

I’m seeing more issues when trying to install

The NoneType issue was present but I fixed this (and then saw the patches you linked to, Metallicow).

I added the line DATA_FILES += [“src/wx.pth”] but I am now seeing the warnings:
warning: wx_smart_install_data: setup script did not provide a directory for ‘src/wx.pth’ – installing right in ‘/usr/lib64/python2.7/site-packages/wx-2.9.5-gtk2’
[ and a few lines later ]
warning: wx_install: path file ‘/usr/lib64/python2.7/site-packages/wx-2.9.5-gtk2.pth’ not created

I am also seeing the following warnings:
package init file ‘wx/lib/pubsub/pubsub2/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)
package init file ‘wx/lib/pubsub/pubsub2/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)

The install reports a success but if I run the the python REPL and run “import wx” it says it is not found.

···

On Wednesday, December 18, 2013 4:31:29 PM UTC-5, Metallicow wrote:

On Wednesday, December 18, 2013 2:40:04 PM UTC-6, Robin Dunn wrote:

Metallicow wrote:

On Wednesday, December 18, 2013 10:45:44 AM UTC-6, mj…@case.edu wrote:

Hello,
I am experiencing and error when trying to build wxPython 2.9.5.0 on
Fedora 15. When I build from source following the build instructions
found here: [http://www.wxpython.org/BUILD.html](http://www.wxpython.org/BUILD.html)
<[http://www.wxpython.org/BUILD.html](http://www.wxpython.org/BUILD.html)> the build proceeds along fine
for a while until I get this error message:
Can anyone provide any suggestions?

I’m not so interested in you logs first off. Check out this thread

first, apply the patches and other manual additions first, try building

again. And watch the terminal when it gets near the end. You might have

to place a few well placed print statements in there to catch the error

if one occurs.

Sometimes it is a bit different for different flavors of linux.

Anywho check this thread out first…

Regression in 2.9.5 source build - Google Groups

<https://groups.google.com/forum/#!searchin/wxpython-users/regression/wxpython-users/kkdGqQmlWr4/d054eY8KEgUJ>

https://groups.google.com/forum/#!searchin/wxpython-users/regression/wxpython-users/kkdGqQmlWr4/d054eY8KEgUJ

Well, considering that was for a completely unrelated problem I don’t
think it will help much.

Then if you are still having trouble post again with a bit more details.

There were at least enough details already to tell that it wasn’t a
problem building the html2 module. Please look before you leap.


Robin Dunn

Software Craftsman

http://wxPython.org

Well, other than the html2 patches there was other syntax errors I also posted about there that have failed linux builds for NoneType on a few other linux builds also.
And also a fixer for the -so stuff which might/probably not apply for a fedora to build.
This for me was with the src-build.tar from the wxPython Page, which houses the instructions everyone is most often linking to., not from repos readme.
Also, I recall lib_gtk might have needed a update, but IIRC that wasn’t necessary to sucessfully build(28lib stuff).
So are you saying the patches and syntax error corrections have made it into the repo yet? wxWidgets or RobinD repo? Haven’t build for a while on linux.
I’ve just been manually patching the tar when needed to new build.
Not sure, but didn’t recall fedora being ubuntu based, is it?

pps. looks like it has been resolved already.

Normally when I do some builds, I been doing them all in a virtual machine for basic testing of my app on a few different distros.
Loaded isos from scratch in virtualbox, usually.
Not sure how to install anything with fedora as I’m not familiar with that. Use your sudo magic words or whatever the distro lingo is.
But if it built, you should be able to add the 2 paths that the script spits out at the end to your terminal/konsole whatever’s environment variables and that should let you run wx in place then or after restarting the term/console.
So if you can run it in place, then the build part of the script worked, or maybe you don’t have sudo power to install, Idunno.
Or maybe the install part of the script needs looked at also. Or maybe you have to fiddle with the wx.pth.

Try running a small sample app in place first(wherever you built it/desktop/etc). Hopefully that will get you started. Then look into wherever the script is supposed to install it. At least make sure it runs fine. Usually the demo files should be in the src tar somewhere also.

The script output gives something like this.
To run the wxPython demo you may need to:

  • set your PYTHONPATH variable to /home/etc/etc/path
  • set your LD_LIBRARY_PATH to /home/etc/etc/path
···

On Wednesday, December 18, 2013 4:07:09 PM UTC-6, mj…@case.edu wrote:

I’m seeing more issues when trying to install

The NoneType issue was present but I fixed this (and then saw the patches you linked to, Metallicow).

I added the line DATA_FILES += [“src/wx.pth”] but I am now seeing the warnings:
warning: wx_smart_install_data: setup script did not provide a directory for ‘src/wx.pth’ – installing right in ‘/usr/lib64/python2.7/site-packages/wx-2.9.5-gtk2’
[ and a few lines later ]
warning: wx_install: path file ‘/usr/lib64/python2.7/site-packages/wx-2.9.5-gtk2.pth’ not created

I am also seeing the following warnings:
package init file ‘wx/lib/pubsub/pubsub2/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)
package init file ‘wx/lib/pubsub/pubsub2/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)

The install reports a success but if I run the the python REPL and run “import wx” it says it is not found.

Hi,

....

I am also seeing the following warnings:
package init file 'wx/lib/pubsub/pubsub2/__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)
package init file 'wx/lib/pubsub/pubsub2/__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)

2.9.5 should not have pubsub/pubsub2 anymore, that was only present up to 2.9.4, but why you get this error I don't know.

Werner

···

On 18/12/2013 23:07, mjn12@case.edu wrote:

I definitely have sudo access to run the install, the install script just appears broken. In order to use the module I have to be able to install it in a specific location both on my development machine and on a target machine (cross compiled). The build is automated so it must be repeatable.

I was trying to get 2.9.5 running because we have an application written for it that needs to run on an embedded linux platform. For some reason the developers of this application originally chose 2.9.5 instead of the latest stable 2.8 release when they wrote the application for windows. Since we already have 2.8 reliably cross compiling and running on the target it looks like it will be a lot less work to rewrite the 2.9 specific parts of the application than to fight to get the 2.9.5 build working.

In other words, I’m giving up on 2.9.5. Thank you guys for your help.

···

On Wednesday, December 18, 2013 6:46:00 PM UTC-5, Metallicow wrote:

On Wednesday, December 18, 2013 4:07:09 PM UTC-6, mj…@case.edu wrote:

I’m seeing more issues when trying to install

The NoneType issue was present but I fixed this (and then saw the patches you linked to, Metallicow).

I added the line DATA_FILES += [“src/wx.pth”] but I am now seeing the warnings:
warning: wx_smart_install_data: setup script did not provide a directory for ‘src/wx.pth’ – installing right in ‘/usr/lib64/python2.7/site-packages/wx-2.9.5-gtk2’
[ and a few lines later ]
warning: wx_install: path file ‘/usr/lib64/python2.7/site-packages/wx-2.9.5-gtk2.pth’ not created

I am also seeing the following warnings:
package init file ‘wx/lib/pubsub/pubsub2/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)
package init file ‘wx/lib/pubsub/pubsub2/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)

The install reports a success but if I run the the python REPL and run “import wx” it says it is not found.

Normally when I do some builds, I been doing them all in a virtual machine for basic testing of my app on a few different distros.
Loaded isos from scratch in virtualbox, usually.
Not sure how to install anything with fedora as I’m not familiar with that. Use your sudo magic words or whatever the distro lingo is.
But if it built, you should be able to add the 2 paths that the script spits out at the end to your terminal/konsole whatever’s environment variables and that should let you run wx in place then or after restarting the term/console.
So if you can run it in place, then the build part of the script worked, or maybe you don’t have sudo power to install, Idunno.
Or maybe the install part of the script needs looked at also. Or maybe you have to fiddle with the wx.pth.

Try running a small sample app in place first(wherever you built it/desktop/etc). Hopefully that will get you started. Then look into wherever the script is supposed to install it. At least make sure it runs fine. Usually the demo files should be in the src tar somewhere also.

The script output gives something like this.
To run the wxPython demo you may need to:

  • set your PYTHONPATH variable to /home/etc/etc/path
  • set your LD_LIBRARY_PATH to /home/etc/etc/path