brettbode / wxmacmolplt

wxMacMolPlt is a graphical user interface principally for the GAMESS program
https://brettbode.github.io/wxmacmolplt/
Other
28 stars 9 forks source link

executable crashing at the start (Linux x86_64) #88

Closed miroi closed 8 years ago

miroi commented 8 years ago

Please describe the problem or enhancement:

Fresh compiled wxmacmolplt is crashing at the beginning. Why ?

If this is a bug report please list the steps required to reproduce the problem:

milias@lxir072.gsi.de:~/Work/qch/software/gamess/wxmacmolplt/bin/../wxmacmolplt 

(wxmacmolplt:11445): Gdk-WARNING **: /tmp/buildd/gtk+2.0-2.24.10/gdk/x11/gdkproperty-x11.c:325 invalid X atom: 475
The program 'wxmacmolplt' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadMatch (invalid parameter attributes)'.
  (Details: serial 1158 error_code 8 request_code 154 minor_code 11)
  (Note to programmers: normally, X errors are reported asynchronously;
   that is, you will receive the error a while after causing it.
   To debug your program, run it with the --sync command line
   option to change this behavior. You can then get a meaningful
   backtrace from your debugger if you break on the gdk_x_error() function.)
milias@lxir072.gsi.de:~/Work/qch/software/gamess/wxmacmolplt/bin/.

What version are you running?

Last commit:   Thu Mar 24 09:28:31 2016 -0500

What OS are you using? (please include 32/64 bit and if Linux the specific distribution)

Linux lxir072 3.2.0-4-amd64 #1 SMP Debian 3.2.68-1+deb7u5 x86_64 GNU/Linux
brettbode commented 8 years ago

Hi Mori, I will see if I can reproduce this issue. I just tried on my Debian Jesse VM but that seems to launch ok. It looks like you are running an older version so I will try again.

BTW did you install wxWidgets from source or via the distribution package?

Thanks, Brett

miroi commented 8 years ago

I installed it from wxWidgets from the source (I have no admin rights on this Debian)).

brettbode commented 8 years ago

Did you use the 3.0.2 stable release or the latest 3.1 release? I am testing both on my OS X development machine, but I don't regularly test custom builds on Linux now that most Linux distros have a wx 3.0 binary package.

miroi commented 8 years ago

Hi,

I used wxWidgets-3.1.0/

brettbode commented 8 years ago

Hmm... I have now confirmed that binaries built against the base Wheezy (wx 2.8) and Jesse (3.0) installations launch ok. Can you send me the config options you used on your wxWidgets build? At this point I suspect either a bug in wx 3.1 or something related to how it was built.

miroi commented 8 years ago

Hi,

in addition, also the fresh cloned software gives this error below.

This is config.log: config.log.gz

milias@lxir074.gsi.de:~/Work/qch/software/wxmacmolplt/build/bin/.wxmacmolplt             

(wxmacmolplt:28255): Gdk-WARNING **: /tmp/buildd/gtk+2.0-2.24.10/gdk/x11/gdkproperty-x11.c:325 invalid X atom: 475
The program 'wxmacmolplt' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadMatch (invalid parameter attributes)'.
  (Details: serial 1158 error_code 8 request_code 154 minor_code 11)
  (Note to programmers: normally, X errors are reported asynchronously;
   that is, you will receive the error a while after causing it.
   To debug your program, run it with the --sync command line
   option to change this behavior. You can then get a meaningful
   backtrace from your debugger if you break on the gdk_x_error() function.)
milias@lxir074.gsi.de:~/Work/qch/software/wxmacmolplt/build/bin/.

I have wxWidgets-3.1.0/

brettbode commented 8 years ago

Hi Miro, What options did you use to configure wxWidgets?

brettbode commented 8 years ago

Hi Miro, I have tried a fresh build of wxWidgets 3.1.0 (downloaded tar file, not the latest development source) and configured it as "./configure --prefix=/home/brett/wx/" so no meaningful options. Then I built wxmacmolplt against that target. That build seems to launch and work ok. That was on a Debian Jesse install so a bit of difference there.

miroi commented 8 years ago

Hi,

on my SMP Debian 3.2.68-1+deb7u5 x86_64 GNU/Linux wxwidgets/wxWidgets-3.1.0/. For $ ./configure --prefix=/u/milias/Work/qch/software/gamess/wxwidgets

I have this config.log file: config.log.gz

This is the wxmacmolplt-7.6.2 linking:

milias@lxir073.gsi.de:~/Work/qch/software/gamess/wxmacmolplt/bin/.ldd wxmacmolplt 
        linux-vdso.so.1 =>  (0x00007ffe549f6000)
        libwx_baseu-3.1.so.0 => /u/milias/Work/qch/software/gamess/wxwidgets/lib/libwx_baseu-3.1.so.0 (0x00007f3e8a696000)
        libwx_gtk2u_core-3.1.so.0 => /u/milias/Work/qch/software/gamess/wxwidgets/lib/libwx_gtk2u_core-3.1.so.0 (0x00007f3e89e95000)
        libwx_gtk2u_gl-3.1.so.0 => /u/milias/Work/qch/software/gamess/wxwidgets/lib/libwx_gtk2u_gl-3.1.so.0 (0x00007f3e89c7a000)
        libwx_gtk2u_adv-3.1.so.0 => /u/milias/Work/qch/software/gamess/wxwidgets/lib/libwx_gtk2u_adv-3.1.so.0 (0x00007f3e8987e000)
        libwx_gtk2u_html-3.1.so.0 => /u/milias/Work/qch/software/gamess/wxwidgets/lib/libwx_gtk2u_html-3.1.so.0 (0x00007f3e895a5000)
        libGLU.so.1 => /usr/lib/x86_64-linux-gnu/libGLU.so.1 (0x00007f3e89306000)
        libGL.so.1 => /usr/lib/x86_64-linux-gnu/libGL.so.1 (0x00007f3e890a6000)
        libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007f3e88d9e000)
        libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f3e88b1c000)
        libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007f3e88906000)
        libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f3e886e9000)
        libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f3e8835c000)
        libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007f3e88145000)
        libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f3e87f40000)
        /lib64/ld-linux-x86-64.so.2 (0x00007f3e8ab16000)
        libgtk-x11-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0 (0x00007f3e87901000)
        libgdk-x11-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgdk-x11-2.0.so.0 (0x00007f3e8764e000)
        libatk-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libatk-1.0.so.0 (0x00007f3e8742a000)
        libgio-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgio-2.0.so.0 (0x00007f3e870d7000)
        libpangoft2-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libpangoft2-1.0.so.0 (0x00007f3e86eac000)
        libpangocairo-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libpangocairo-1.0.so.0 (0x00007f3e86c9e000)
        libgdk_pixbuf-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgdk_pixbuf-2.0.so.0 (0x00007f3e86a7e000)
        libcairo.so.2 => /usr/lib/x86_64-linux-gnu/libcairo.so.2 (0x00007f3e86785000)
        libpango-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libpango-1.0.so.0 (0x00007f3e86537000)
        libfreetype.so.6 => /usr/lib/x86_64-linux-gnu/libfreetype.so.6 (0x00007f3e86298000)
        libfontconfig.so.1 => /usr/lib/x86_64-linux-gnu/libfontconfig.so.1 (0x00007f3e86061000)
        libgobject-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0 (0x00007f3e85e10000)
        libgthread-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgthread-2.0.so.0 (0x00007f3e85c0e000)
        librt.so.1 => /lib/x86_64-linux-gnu/librt.so.1 (0x00007f3e85a06000)
        libglib-2.0.so.0 => /lib/x86_64-linux-gnu/libglib-2.0.so.0 (0x00007f3e8570d000)
        libX11.so.6 => /usr/lib/x86_64-linux-gnu/libX11.so.6 (0x00007f3e853d2000)
        libSM.so.6 => /usr/lib/x86_64-linux-gnu/libSM.so.6 (0x00007f3e851cb000)
        libpng12.so.0 => /lib/x86_64-linux-gnu/libpng12.so.0 (0x00007f3e84fa3000)
        libjpeg.so.8 => /usr/lib/x86_64-linux-gnu/libjpeg.so.8 (0x00007f3e84d69000)
        libtiff.so.4 => /usr/lib/x86_64-linux-gnu/libtiff.so.4 (0x00007f3e84b03000)
        libglapi.so.0 => /usr/lib/x86_64-linux-gnu/libglapi.so.0 (0x00007f3e848dd000)
        libXext.so.6 => /usr/lib/x86_64-linux-gnu/libXext.so.6 (0x00007f3e846ca000)
        libXdamage.so.1 => /usr/lib/x86_64-linux-gnu/libXdamage.so.1 (0x00007f3e844c8000)
        libXfixes.so.3 => /usr/lib/x86_64-linux-gnu/libXfixes.so.3 (0x00007f3e842c2000)
        libX11-xcb.so.1 => /usr/lib/x86_64-linux-gnu/libX11-xcb.so.1 (0x00007f3e840c0000)
        libxcb-glx.so.0 => /usr/lib/x86_64-linux-gnu/libxcb-glx.so.0 (0x00007f3e83ea8000)
        libxcb.so.1 => /usr/lib/x86_64-linux-gnu/libxcb.so.1 (0x00007f3e83c88000)
        libXxf86vm.so.1 => /usr/lib/x86_64-linux-gnu/libXxf86vm.so.1 (0x00007f3e83a81000)
        libdrm.so.2 => /usr/lib/x86_64-linux-gnu/libdrm.so.2 (0x00007f3e83875000)
        libXcomposite.so.1 => /usr/lib/x86_64-linux-gnu/libXcomposite.so.1 (0x00007f3e83672000)
        libXrender.so.1 => /usr/lib/x86_64-linux-gnu/libXrender.so.1 (0x00007f3e83469000)
        libXinerama.so.1 => /usr/lib/x86_64-linux-gnu/libXinerama.so.1 (0x00007f3e83267000)
        libXi.so.6 => /usr/lib/x86_64-linux-gnu/libXi.so.6 (0x00007f3e83057000)
        libXrandr.so.2 => /usr/lib/x86_64-linux-gnu/libXrandr.so.2 (0x00007f3e82e4f000)
        libXcursor.so.1 => /usr/lib/x86_64-linux-gnu/libXcursor.so.1 (0x00007f3e82c45000)
        libgmodule-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgmodule-2.0.so.0 (0x00007f3e82a40000)
        libselinux.so.1 => /lib/x86_64-linux-gnu/libselinux.so.1 (0x00007f3e82820000)
        libresolv.so.2 => /lib/x86_64-linux-gnu/libresolv.so.2 (0x00007f3e82609000)
        libpixman-1.so.0 => /usr/lib/x86_64-linux-gnu/libpixman-1.so.0 (0x00007f3e82383000)
        libxcb-shm.so.0 => /usr/lib/x86_64-linux-gnu/libxcb-shm.so.0 (0x00007f3e8217f000)
        libxcb-render.so.0 => /usr/lib/x86_64-linux-gnu/libxcb-render.so.0 (0x00007f3e81f75000)
        libexpat.so.1 => /lib/x86_64-linux-gnu/libexpat.so.1 (0x00007f3e81d4a000)
        libffi.so.5 => /usr/lib/x86_64-linux-gnu/libffi.so.5 (0x00007f3e81b3d000)
        libpcre.so.3 => /lib/x86_64-linux-gnu/libpcre.so.3 (0x00007f3e81900000)
        libICE.so.6 => /usr/lib/x86_64-linux-gnu/libICE.so.6 (0x00007f3e816e4000)
        libuuid.so.1 => /lib/x86_64-linux-gnu/libuuid.so.1 (0x00007f3e814df000)
        libjbig.so.0 => /usr/lib/x86_64-linux-gnu/libjbig.so.0 (0x00007f3e812d0000)
        libXau.so.6 => /usr/lib/x86_64-linux-gnu/libXau.so.6 (0x00007f3e810cd000)
        libXdmcp.so.6 => /usr/lib/x86_64-linux-gnu/libXdmcp.so.6 (0x00007f3e80ec8000)
milias@lxir073.gsi.de:~/Work/qch/software/gamess/wxmacmolplt/bin/.

and this is the crash message:

milias@lxir073.gsi.de:~/Work/qch/software/gamess/wxmacmolplt/bin/.wxmacmolplt 

(wxmacmolplt:2590): Gdk-WARNING **: /tmp/buildd/gtk+2.0-2.24.10/gdk/x11/gdkproperty-x11.c:325 invalid X atom: 475
The program 'wxmacmolplt' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadMatch (invalid parameter attributes)'.
  (Details: serial 1158 error_code 8 request_code 154 minor_code 11)
  (Note to programmers: normally, X errors are reported asynchronously;
   that is, you will receive the error a while after causing it.
   To debug your program, run it with the --sync command line
   option to change this behavior. You can then get a meaningful
   backtrace from your debugger if you break on the gdk_x_error() function.)
milias@lxir073.gsi.de:~/Work/qch/software/gamess/wxmacmolplt/bin/.

Brett,

why does wxmacmolplt require iinput_file ? There is none in the build directory...

ilias@lxir073.gsi.de:~/Work/qch/software/gamess/wxmacmolplt/bin/.wxmacmolplt -v
The required parameter 'input file' was not specified.
Usage: wxmacmolplt [-h] [-v] [-b <str>] input file
  -h, --help            displays help on the command line parameters
  -v, --version         print version
  -b, --batch=<str>     export POV-Ray scene
milias@lxir073.gsi.de:~/Work/qch/software/gamess/wxmacmolplt/bin/.
brettbode commented 8 years ago

Hmm... The last bit about the command line parameter seems to be a bug in wxWidgets. Oddly the long version (--help or --version) work as expected, but the short version is not handled correctly. Wx provides a class that encapsulates all of that, so I will look to see if they provide a sample.

brettbode commented 8 years ago

Ok I have to take that back. I had forgotten there are two code paths for the command line parsing. I worked on that and have cleaned it up a bit so that it works as expected now.

miroi commented 8 years ago

Hi again,

no working.

milias@lxg1221.gsi.de:~/Work/qch/software/wxmacmolplt/build/bin/.wxmacmolplt -v
wxMacMolPlt, (c) Iowa State University, 2008-2012,
Version 7.6.2, Built on Apr  1 2016
milias@lxg1221.gsi.de:~/Work/qch/software/wxmacmolplt/build/bin/.wxmacmolplt -h
MacMolPlt usage includes opening one or more files for display or specifying
a single file for batch conversion to a POV file. The remaining options are
given by themselves.
Usage: wxmacmolplt [-h] [-v] [-b <str>] [input file...]
  -h, --help            displays help on the command line parameters
  -v, --version         print version
  -b, --batch=<str>     export POV-Ray scene
milias@lxg1221.gsi.de:~/Work/qch/software/wxmacmolplt/build/bin/.wxmacmolplt   

(wxmacmolplt:11979): Gdk-WARNING **: /tmp/buildd/gtk+2.0-2.24.10/gdk/x11/gdkproperty-x11.c:325 invalid X atom: 475
The program 'wxmacmolplt' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadMatch (invalid parameter attributes)'.
  (Details: serial 1149 error_code 8 request_code 154 minor_code 11)
  (Note to programmers: normally, X errors are reported asynchronously;
   that is, you will receive the error a while after causing it.
   To debug your program, run it with the --sync command line
   option to change this behavior. You can then get a meaningful
   backtrace from your debugger if you break on the gdk_x_error() function.)
milias@lxg1221.gsi.de:~/Work/qch/software/wxmacmolplt/build/bin/.
.
.
milias@lxir072.gsi.de:~/Work/qch/software/wxmacmolplt/build/bin/.wxmacmolplt 

(wxmacmolplt:20543): Gdk-WARNING **: /tmp/buildd/gtk+2.0-2.24.10/gdk/x11/gdkproperty-x11.c:325 invalid X atom: 475
The program 'wxmacmolplt' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadMatch (invalid parameter attributes)'.
  (Details: serial 1158 error_code 8 request_code 154 minor_code 11)
  (Note to programmers: normally, X errors are reported asynchronously;
   that is, you will receive the error a while after causing it.
   To debug your program, run it with the --sync command line
   option to change this behavior. You can then get a meaningful
   backtrace from your debugger if you break on the gdk_x_error() function.)
milias@lxir072.gsi.de:~/Work/qch/software/wxmacmolplt/build/bin/.

here is debugging:

milias@lxir072.gsi.de:~/Work/qch/software/wxmacmolplt/build/bin/.gdb wxmacmolplt       
GNU gdb (GDB) 7.4.1-debian
Copyright (C) 2012 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /u/milias/Work/qch/software/wxmacmolplt/build/bin/wxmacmolplt...done.
(gdb) r
Starting program: /u/milias/Work/qch/software/wxmacmolplt/build/bin/wxmacmolplt 
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7fffeab7e700 (LWP 20891)]
[New Thread 0x7fffea37d700 (LWP 20892)]
[New Thread 0x7fffe9b7c700 (LWP 20893)]
[New Thread 0x7fffe937b700 (LWP 20894)]
[New Thread 0x7fffe8b7a700 (LWP 20895)]
[New Thread 0x7fffe8379700 (LWP 20896)]
[New Thread 0x7fffe7b78700 (LWP 20897)]
[New Thread 0x7fffe7377700 (LWP 20898)]

(wxmacmolplt:20879): Gdk-WARNING **: /tmp/buildd/gtk+2.0-2.24.10/gdk/x11/gdkproperty-x11.c:325 invalid X atom: 475
The program 'wxmacmolplt' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadMatch (invalid parameter attributes)'.
  (Details: serial 1158 error_code 8 request_code 154 minor_code 11)
  (Note to programmers: normally, X errors are reported asynchronously;
   that is, you will receive the error a while after causing it.
   To debug your program, run it with the --sync command line
   option to change this behavior. You can then get a meaningful
   backtrace from your debugger if you break on the gdk_x_error() function.)
[Thread 0x7fffe7377700 (LWP 20898) exited]
[Thread 0x7fffe7b78700 (LWP 20897) exited]
[Thread 0x7fffe8b7a700 (LWP 20895) exited]
[Thread 0x7fffe937b700 (LWP 20894) exited]
[Thread 0x7fffe9b7c700 (LWP 20893) exited]
[Thread 0x7fffea37d700 (LWP 20892) exited]
[Thread 0x7fffeab7e700 (LWP 20891) exited]
[Thread 0x7ffff7faa9a0 (LWP 20879) exited]
[Inferior 1 (process 20879) exited with code 01]
(gdb) where
No stack.
(gdb) list
467         menuBar->Append(menuEdit, wxT("&Edit"));
468         menuBar->Append(menuHelp, wxT("&Help"));
469     }
470     #endif
471
472     // Tell wxWidgets to start the program:
473     #ifdef __WXMSW__
474     IMPLEMENT_APP(MpApp)
475     #else
476     int main(int argc, char **argv) {
(gdb) 
brettbode commented 8 years ago

Hi Miro, Good news and bad news. I have been able to reproduce the failure. It fails for me on a Debian Wheezy install when built against gtk 2 or 3 and wxWidgets 3.1. However, the wxWidgets OpenGL samples also fail (isosurf fails in exactly the same way) so I think this is an issue with the OpenGL support in wxWidgets 3.1 (not sure about 3.0) and GTK of that age. Under Debian Jesse a wxWidgets 3.1 built against GTK 3 works as expected.

There are Debain Wheezy wx 2.8 packages that appear to be built against gtk2 and those do work ok. So if you can't have someone install those I would suggest grabbing the wxWidgets 2.8 source and try building that.

Sorry I can't fully solve the problem, but I am out of time for this for now...

Brett