Help : Segmentation fault when using a 3rd library
-
wrote on 25 Jan 2014, 07:42 last edited by
I have some basic knowledge in C++ programming and one semester's course in data structure and algorithm, but I'm ignorant in interface development.
I downloaded my library on this website:
http://genie.sis.pitt.edu/index.php/downloads
followed tutorial on this website:
http://genie.sis.pitt.edu/wiki/SMILE_Documentation
and wrote my own code:
@#include "widget.h"
#include <QApplication>
#include "smile.h"int main(int argc, char *argv[])
{
DSL_network myNetwork;
QApplication a(argc, argv);
Widget w;
w.show();return a.exec();
}
@Debugging process stopped at
@DSL_network myNetwork;@ -
And what error are you getting ?
-
wrote on 27 Jan 2014, 12:45 last edited by
A message box with a title "Signal received", reading
The inferior stopped because it received a signal from the Operating System.
Signal name: SIGSEGV
Signal meaning: Segmentatio fault -
Since you are using MinGW, your should already have a debugger then just click on the other green arrow, then one with the little bug, you should get more information
-
wrote on 28 Jan 2014, 02:01 last edited by
Application Output:
Debugging starts
can't find linker symbol for virtual table for 'QApplication' valueThere are many warnings. Some read 'ignoring #pragma comment' while others 'unused parameter'. What is the problem?
-
Did you download the MinGW version ? If so, it's been compiled with MinGW 4.6.2 which is not compatible with 4.8
-
wrote on 29 Jan 2014, 01:33 last edited by
Oh, I am now using Qt creator 5.2.0 and MinGW4.8. How can I reduce MinGW to a 4.6.2 version?
-
You would need to install it by hand and also recompile Qt with it
-
However, the download page also mention that you can request a build, so you could try to ask them about a version using MinGW 4.8
-
wrote on 29 Jan 2014, 11:34 last edited by
Thx for your reply! I have downloaded Mingw32 4.6.2, but I want to ask how to recompile Qt with it.
-
Just follow the "documentation":http://qt-project.org/doc/qt-5/windows-building.html
However, I would recommend trying to ask a build for MinGW 4.8
-
wrote on 1 Feb 2014, 12:55 last edited by
I've tried to follow the instruction, but it is complex for me. I just copied and pasted MinGW4.6.2 in the directory, and compiled the program. Now it stops at the very beginning and the Application Output window says
Debugging starts
(Internal error: pc 0x54f558 in read in psymtab, but not in symtab.)
(Internal error: pc 0x54f615 in read in psymtab, but not in symtab.)
(Internal error: pc 0x54f616 in read in psymtab, but not in symtab.)
(Internal error: pc 0x406adb in read in psymtab, but not in symtab.)
(Internal error: pc 0x54f615 in read in psymtab, but not in symtab.)
(Internal error: pc 0x54f615 in read in psymtab, but not in symtab.)
(Internal error: pc 0x406adb in read in psymtab, but not in symtab.)
(Internal error: pc 0x406a80 in read in psymtab, but not in symtab.)
(Internal error: pc 0x406adb in read in psymtab, but not in symtab.)
(Internal error: pc 0x406adc in read in psymtab, but not in symtab.)
(Internal error: pc 0x406adb in read in psymtab, but not in symtab.)
(Internal error: pc 0x406adb in read in psymtab, but not in symtab.)
(Internal error: pc 0x54f615 in read in psymtab, but not in symtab.)
(Internal error: pc 0x54f558 in read in psymtab, but not in symtab.)
(Internal error: pc 0x54f615 in read in psymtab, but not in symtab.)
(Internal error: pc 0x54f616 in read in psymtab, but not in symtab.)
(Internal error: pc 0x406adb in read in psymtab, but not in symtab.)
(Internal error: pc 0x54f615 in read in psymtab, but not in symtab.)
(Internal error: pc 0x54f615 in read in psymtab, but not in symtab.)
(Internal error: pc 0x406adb in read in psymtab, but not in symtab.)
(Internal error: pc 0x406a80 in read in psymtab, but not in symtab.)
(Internal error: pc 0x406adb in read in psymtab, but not in symtab.)
(Internal error: pc 0x406adc in read in psymtab, but not in symtab.)
(Internal error: pc 0x406adb in read in psymtab, but not in symtab.)
(Internal error: pc 0x406adb in read in psymtab, but not in symtab.) -
Did you also compile Qt with that version of MinGW ?
17/20