Topic: opencde seems to freeze.

All input to opencde seems to freeze, including in already opened windows (open terminals). to fix this, I just switch to a vt and restart X. If  you need more info, please ask for it. Surely this isn't just me since I read somewhere on the freebsd forums that someone else was experiencing the same problem.

edit: here is the link to the freebsd forum post http://forums.freebsd.org/showthread.php?t=11663

Last edited by gostrc (2010-07-14 15:48:26)

Re: opencde seems to freeze.

The freeze bug is  a common issue he knows about it smile

I am messing with it right now. I compiled from source and it still freezes, also it looks strange like I am missing some graphical library even though I installed WxWidgets, open-motif, xli, all that (except sudo). The power button on the panel freezes it just like you were wondering.

Re: opencde seems to freeze.

Hi guys,

Yes, this freezing bug is a slight pain. The problem being that I cannot reproduce it!

I have tried quite a few systems (FreeBSD 8.0 32/64, Debian 32, Ubuntu ssh/X11 to cygwinX) and they all seem to work without any freeze.

If either of you do not mind delving into the source, could you place a `cout` in...

src/dtpanel/Application.cpp/void Application::HandleEvent(...)

And let me know if this is being triggered. Try to remove the try/catch.
I would do this myself but everything seems to work horribly well sad

Could you please post your .xinitrc too, perhaps something in there might spark some ideas.

zspider: Is your wxWidgets built to use Motif, or GTK? Because if it is the latter, it will look very odd lol.

Thanks a lot for your feedback though, and I hope we can get this crippling bug removed!

Re: opencde seems to freeze.

Here is the .xinitrc I'm using right now.
http://omploader.org/vNHhoOQ

Here is my uname -a output:
Linux archlinux 2.6.34-ARCH #1 SMP PREEMPT Mon Jul 5 22:12:11 CEST 2010 x86_64 Intel(R) Core(TM)2 CPU T5500 @ 1.66GHz GenuineIntel GNU/Linux

Re: opencde seems to freeze.

Thanks

Ok, mine is simply...

/opt/opencde/bin/opencde

But nothing in yours looked as though it would cause conflict. (I assume you comment out exec wmii when running opencde)

I will give Arch a go in a vm. Perhaps it will give me an idea.

Re: opencde seems to freeze.

"I assume you comment out exec wmii when running opencde"
yes

"I will give Arch a go in a vm. Perhaps it will give me an idea."
cool, let me know how it goes smile if you have any problems specific to arch, I could probably help you with them.

Re: opencde seems to freeze.

void Application::HandleEvent(wxEvtHandler* handler, wxEventFunction func, wxEvent& event) const
{
  try
  {
    wxApp::HandleEvent(handler, func, event);
  }
  catch(exception& e)
  {
    wxMessageBox(e.what(), "Exception", wxICON_ERROR); cout << "cool";
  }
}

As I mentioned before I am not much of a programmer. I put that in and it compiled but it froze(when I ran it) without sending anything to the console. Tried taking out the try catch but it did not like that and refused to compile. My .xinitrc file is as such:

exec startxfce4 (commented out when running opencde obviously)
#/usr/home/beavis/Downloads/opencde/bin/opencde
#/usr/home/beavis/Downloads/opencde/bin/dtwm & xterm

My WxWidgets is compiled from the package on their official site http://www.wxwidgets.org/ if that is not the right package please show me where to find the motif version wink the one I downloaded is the all version at the top of the source archives list.

Last edited by zspider (2010-07-14 18:04:18)

Re: opencde seems to freeze.

I found something. I loaded dtpanel while in XFCE4 and it works. no freeze ups all the buttons do something, menus work (even though their hardcoded into the source). Makes me wonder if the issue is actually with the wm you have us using instead. Only the compiled from source version works like this though, the binary refuses to show anything.

Last edited by zspider (2010-07-14 18:19:08)

Re: opencde seems to freeze.

use wxmotif located here:
http://downloads.sourceforge.net/projec … 11.tar.bz2

Re: opencde seems to freeze.

gostrc wrote:

use wxmotif located here:
http://downloads.sourceforge.net/projec … 11.tar.bz2


thanks perhaps that will solve the mystery of the panel looking kind of strange


----

Update:

FreeBSD 8.0-4 does not seem to like WxMotif. Compiler bombs with ./include/wx/filedlg.h:101: error: 'HasFlag' was not declared in this scope
*** Error code 1

Last edited by zspider (2010-07-14 18:45:51)

Re: opencde seems to freeze.

zspider, use the full wxWidgets source (wxMotif seems to error on FreeBSD)

compile it like this...
./configure --prefix=/usr/local --with-motif --disable-shared

The menus are not hardcoded (just awfully undocumented tongue) You can find the .ini file at $HOME/.opencde/dtpanel/menus.ini

Edit:

Yes!! I finally saw the freeze bug firsthand!

I will try to fix it, although it looks like the whole of X11 is crashing... Worst case scenario is it is an upstream problem. Hopefully not.

It definitely seems an Archlinux specific bug.

Edit2:

After some playing about on arch linux, it seems that, once another window is opened (menu, exit) as soon as the user clicks on the panel frame, the whole thing freezes.

Edit3:

OK, by using twm rather than mwm (and changing the source to remove wxSIMPLE_BORDER), the freeze bug has been eliminated. Soooo, the problem lies with Mwm on archlinux's implementation of Xorg.

I will give the mwm provided by LessTif a go. Although that has other annoying bugs (though does not freeze)

Re: opencde seems to freeze.

did you see my earlier post about how it works on FreeBSD if I run it in XFCE4 without freezing. Also thanks for that bit of info on compiling WxMotif wink

Re: opencde seems to freeze.

zspider wrote:

did you see my earlier post about how it works on FreeBSD if I run it in XFCE4 without freezing. Also thanks for that bit of info on compiling WxMotif wink

Ah, does it freeze for you on FreeBSD? Damn, it might be a newer version of Xorg it is having trouble with.

But yes you are right, it does seem to be the WM. I am just using mwm provided by open-motif.

Re: opencde seems to freeze.

gonna test it out with WxMotif see if it freezes. Its weird though how the panel works fine if loaded into XFCE.

Re: opencde seems to freeze.

yep still freezing if I load in FreeBSD with binary. The code wont compile with WxMotif alot of WxGTK errors coming up. Cant load the binary in xfce4 it says xwininfo: error: No window with name dtpanel - Panel exists!
./../bin/mwmext: bad desktop number '0'

Re: opencde seems to freeze.

try to compile wxMotif using...

./configure --prefix=/usr/local --with-motif --disable-shared

Also, mwmext requires Mwm, so will not be very happy with most other window managers.

I am going to compile LessTif and use that with wxMotif to see if it helps. If so, I can separate the working (though buggy) mwm from that and include it with the opencde source.

Edit:

Mwm is 100% broken on arch.

Proof: Start mwm and xterm. In xterm, start another xterm. As soon as you click on the previous Xterm. The whole thing freezes. OpenCDE has not even been started.
Looks like lesstif is the only hope for now, until open-motif gets fixed upstream.

Re: opencde seems to freeze.

thats kind of what I was trying to point out heh that the freeze was not with your panel but seemed to be the underlying window manager causing it (mwm). Apparently my opencde source folder was corrupted now it compiled with openmotif.

Re: opencde seems to freeze.

Right if you want to use opencde on Arch Linux, this is the new plan... tongue

Delete wxMotif
Delete OpenCDE
Delete OpenMotif

Compile LessTif
Compile wxMotif
Compile OpenCDE

LessTif-mwm works fine, although without modification to the source, you will find that dtpanel starts in a wierd place (second virtual screen) and you can also resize "unresizable" dialogs.

Other than that, it works fine on Arch.

Re: opencde seems to freeze.

gonna try your steps on freebsd wink I just dumped arch last night. It was troubled, broken package manager and other annoyances.

Last edited by zspider (2010-07-14 21:18:01)

Re: opencde seems to freeze.

heh. big_smile i did your steps for arch on BSD and it works with no freezes tongue.

Re: opencde seems to freeze.

so the problem is with openmotif on arch and bsd then?

Re: opencde seems to freeze.

gostrc:

Yes it seems, though since I stick with FreeBSD 8.0-RELEASE I don't seem to have a problem. The problem seems to arise with later versions of xorg found in newer freebsd and arch.

By using LessTif, the problem can be avoided but LessTif is far too buggy and will cause too much trouble later on.

I will try to have a look at the OpenMotif mwm (hopefully be able to separate it too so I can customize it into dtwm) but the code is pretty archaic.

I wonder if the Arch linux OpenMotif maintainer (Andrwe?) aware of this freeze bug? When FreeBSD 8.1-RELEASE comes out, if the problem still exists I will talk to its maintainer.

Could you confirm that the bug is in Mwm by opening a few xterm windows (using an xterm window) and clicking on them all until it freezes

Edit:

I am pretty sure that the problem in mwm is going to be in openmotifsrc/client/mwm/WmEvent.cpp but there is more code in there than 10x OpenCDE tongue

Edit:

I realized that arch linux has an openmotif package.
http://www.archlinux.org/packages/commu … openmotif/

I installed that... ran mwm, opened up some xterms and.... freeze... Poor show.

Edit:

I have found a temporary solution.

in your .Xdefaults file (or the dtwm wrapper) add
Mwm*keyboardFocusPolicy: pointer
Dtwm*keyboardFocusPolicy: pointer

This will focus the window just before you click it, causing your X11 to remain unfrozen. The auto focusing is a little annoying but it will have to do until this gets fixed upstream.

Re: opencde seems to freeze.

Thank you very much for the workaround!
hope this gets fixed soon smile

Re: opencde seems to freeze.

hey, how goes your quest to reverse engineer (or whatever you want to call it) open-motif tongue

Re: opencde seems to freeze.

Reverse engineer?

OpenMotif is open source big_smile

Getting it to work well isn't going great, however after reading some of the mailing lists, it suggests some reasons why the update to xorg is causing trouble with mwm.

Looks like the pointer focus hack is still required for a while.

Regards,