richelbilderbeek / BrainWeaver

BrainWeaver, tool for teacher education
https://github.com/richelbilderbeek/tools
GNU General Public License v3.0
5 stars 1 forks source link

BrainWeaver QtPrintConceptMap crashes under Wine #161

Closed richelbilderbeek closed 6 years ago

richelbilderbeek commented 6 years ago

2018-07-11-112349_1920x1080_scrot

richelbilderbeek commented 6 years ago

Weird, item 6. QtPrintConceptMap and D. QtPrintRatingDialog crash, where H. ProgramOverview works fine!

Hypotheses of the cause:

richelbilderbeek commented 6 years ago

This screenshot allows to rule out much:

2018-07-11-113156_1920x1080_scrot

richelbilderbeek commented 6 years ago

Meeting with Toine, perhaps he can help me rule out things.

richelbilderbeek commented 6 years ago

Toine has exactly the same problems. Als the overview works at his native Windows laptop :confused:

richelbilderbeek commented 6 years ago

The Wine error messages are not helpful. I suppose qDebug is the way to go :persevere:

richelbilderbeek commented 6 years ago

When I cross-compile, I do get mentions that MXE misses:

richel@winloos:~/GitHubs/Brainweaver/scripts$ ./cross-compile_all 
Displaying cross compiler version (if it is not found, set the path to YourFolder/mxe/usr/bin
QMake version 3.1
Using Qt version 5.11.1 in /home/richel/GitHubs/RibiLibraries/mxe/usr/i686-w64-mingw32.static/qt5/lib
=========================================
Working on .pro file: BrainweaverAssessor.pro
=========================================
[...]
Start make
make[1]: *** No rule to make target '/home/richel/GitHubs/RibiLibraries/mxe/usr/i686-w64-mingw32.static/qt5/lib/libQt5OpenGLd.a', needed by 'debug/BrainweaverAssessor.exe'.  Stop.
Makefile:50: recipe for target 'debug' failed
make: *** [debug] Error 2
BrainweaverAssessor.pro, : SUCCESS
=========================================
Working on .pro file: BrainweaverConsoleTest.pro
=========================================
[...]
Start make
make[1]: *** No rule to make target '/home/richel/GitHubs/RibiLibraries/mxe/usr/i686-w64-mingw32.static/qt5/lib/libQt5PrintSupportd.a', needed by 'debug/BrainweaverConsoleTest.exe'.  Stop.
Makefile:50: recipe for target 'debug' failed
make: *** [debug] Error 2
BrainweaverConsoleTest.pro, : FAIL (executable not found)
=========================================
Working on .pro file: BrainweaverDesktopTest.pro
=========================================
[...]
Start make
make[1]: *** No rule to make target '/home/richel/GitHubs/RibiLibraries/mxe/usr/i686-w64-mingw32.static/qt5/lib/libQt5OpenGLd.a', needed by 'debug/BrainweaverDesktopTest.exe'.  Stop.
[...]
BrainweaverDesktopTest.pro, : SUCCESS
=========================================
Working on .pro file: BrainweaverDeveloper.pro
=========================================
[...]
Start make
make[1]: *** No rule to make target '/home/richel/GitHubs/RibiLibraries/mxe/usr/i686-w64-mingw32.static/qt5/lib/libQt5OpenGLd.a', needed by 'debug/BrainweaverDeveloper.exe'.  Stop.
[...]
BrainweaverDeveloper.pro, : SUCCESS
=========================================
Working on .pro file: BrainweaverStudent.pro
=========================================
[...]
Start make
make[1]: *** No rule to make target '/home/richel/GitHubs/RibiLibraries/mxe/usr/i686-w64-mingw32.static/qt5/lib/libQt5PrintSupportd.a', needed by 'debug/BrainweaverStudent.exe'.  Stop.
[...]
BrainweaverStudent.pro, : SUCCESS
richelbilderbeek commented 6 years ago

OK, debug mode does not work with MXE:

Start make
make[1]: *** No rule to make target '/home/richel/GitHubs/RibiLibraries/mxe/usr/i686-w64-mingw32.static/qt5/lib/libQt5OpenGLd.a', needed by 'debug/BrainweaverAssessor.exe'.  Stop.
Makefile:50: recipe for target 'debug' failed
richelbilderbeek commented 6 years ago

OK, my MXE only has release builds, using std::clog, which works fine under Wine:

richel@winloos:~/GitHubs/Brainweaver$ wine BrainweaverDeveloper.exe 
000b:fixme:winediag:start_process Wine Staging 3.7 is a testing version containing experimental patches.
000b:fixme:winediag:start_process Please mention your exact version when filing bug reports on winehq.org.
RELEASE mode
0009:fixme:font:get_outline_text_metrics failed to read full_nameW for font L"Ani"!
0009:fixme:font:get_nearest_charset TCI failing on 20000000
0009:fixme:font:get_nearest_charset returning DEFAULT_CHARSET face->fs.fsCsb[0] = 20000000 file = L"/usr/share/fonts/truetype/fonts-gujr-extra/aakar-medium.ttf"
0009:fixme:dwmapi:DwmIsCompositionEnabled 0x1aada50
DEBUG: 38
DEBUG: 40
DEBUG: 46
DEBUG: 48
DEBUG: 53
DEBUG: 60
wine: Unhandled page fault on read access to 0x00000012 at address 0x8093c9 (thread 0009), starting debugger...
richelbilderbeek commented 6 years ago

Culprit was the emit_me signal in the main menu, for both print dialogs:

void ribi::braw::QtMenuDialog::on_button_print_concept_map_clicked() noexcept
{
  auto * const d{
    new QtPrintConceptMapDialog(FileFactory().Get5())
  };
  d->exec();
  //emit add_me(d); //Causes this crash!
}