[Interest] big trouble with QCoreApplication

Freddy Martinez freddy311082 at gmail.com
Sun Apr 10 00:33:32 CEST 2016


Hi Andy,  the output for the qt version qdebug is

Qt compile version: 5.5.1
Qt runtime version: 5.5.1

But, it doesn’t have any sense that the QCoreApplication constructor give me a segfault, at less for me…

regards

=============================================
"El tamaño de tus logros depende del tamaño de tus metas." 
C++ and Qt Senior Developer
B.S. Computer Science
Buenos Aires, Argentina

> On Apr 9, 2016, at 7:04 PM, Andy <asmaloney at gmail.com> wrote:
> 
> Freddy:
> 
> What you are suggesting about Qt versions sounds likely.
> 
> To see what versions are being used, you could try outputting the version used to compile and the runtime version in main() like this:
> 
>    qDebug().noquote() << "Qt compile version:" << QT_VERSION_STR;
>    qDebug().noquote() << "Qt runtime version:" << qVersion();
> 
> 
> 
> ---
> Andy Maloney  //  https://asmaloney.com <https://asmaloney.com/>
> twitter ~ @asmaloney <https://twitter.com/asmaloney>
> 
> On Sat, Apr 9, 2016 at 5:44 PM, Freddy Martinez <freddy311082 at gmail.com <mailto:freddy311082 at gmail.com>> wrote:
> Hi Mike, and thanks for your answer….
> 
> I had sent you a print screen, as you could see, the line 63 is
> 
> QCoreApplication a(argc,argv)
> 
> the only thing I suppose  that it’s happend is that in /usr/lib/x86_64/ I have other qt5 libraries installed but for qt 5.4.2 version… maybe when I’m trying to run the application is crahsed because is linking against 5.4.2 and I’m compiling with 5.5.1.
> 
> I had download the offline installer and i had create a Qt folder on my home directory, there I had installed Qt 5.5.1…
> 
> that is my environment 
> 
> any advise ?
> 
> regards
> 
> <Screen Shot 2016-04-09 at 6.38.07 PM.png>
> 
> 
> =============================================
> "El tamaño de tus logros depende del tamaño de tus metas." 
> C++ and Qt Senior Developer
> B.S. Computer Science
> Buenos Aires, Argentina
> 
>> On Apr 9, 2016, at 6:32 PM, Mike Chinander <chinander at gmail.com <mailto:chinander at gmail.com>> wrote:
>> 
>> What's on line 63 of main.cpp?
>> 
>> On Sat, Apr 9, 2016 at 4:18 PM, Freddy Martinez <freddy311082 at gmail.com <mailto:freddy311082 at gmail.com>> wrote:
>> Hi guys..
>> 
>> I’ve Kubuntu 15.10 and I’m working with qt 5.5.1…
>> 
>> this is may main.cpp
>> 
>> int main(int argc, char *argv[])
>> {
>>     QCoreApplication a(argc, argv);
>> 
>>     if (!checkConfigurationFiles())
>>     {
>>         qDebug()<<"Unable to start server.";
>> 
>>         return 1;
>>     }
>> 
>>     QSettings* settings = new QSettings(qApp->applicationDirPath()+"/config/server.ini",QSettings::IniFormat);
>> 
>>     QString lastError;
>> 
>>     NautamServer nautamServer(settings);
>> 
>>     ConsoleLoggerFactory loggerFactory;
>> 
>>     loggerFactory.setSettings(settings);
>> 
>>     nautamServer.setLoggerFactory(&loggerFactory);
>> 
>>     if (!nautamServer.startServer(lastError))
>>         qDebug()<<"Last error :"<<lastError;
>> 
>>     return a.exec();
>> }
>> 
>> the problem is taht i’m gettirn segmentation fault in the first line of the main function as you’ll see in the stack as folowed:
>> 
>> #0  0x00007ffff37616e7 in QOpenGLContext::create() () from /home/freddy/Qt5.5.1/5.5/gcc_64/lib/libQt5Gui.so.5 
>> #1  0x00007fffe9b1d9bd in QtWebEngine::initialize() () from /home/freddy/Qt5.5.1/5.5/gcc_64/lib/libQt5WebEngine.so.5 
>> #2  0x00007ffff4f63688 in QCoreApplication::init() () from /home/freddy/Qt5.5.1/5.5/gcc_64/lib/libQt5Core.so.5 
>> #3  0x00007ffff4f63b05 in QCoreApplication::QCoreApplication(int&, char**, int) () from /home/freddy/Qt5.5.1/5.5/gcc_64/lib/libQt5Core.so.5 
>> #4  0x000000000044935b in main (argc=1, argv=0x7fffffffdea8) at ../../nautam-kernel/nautam-server/main.cpp:63
>> 
>> well guys, I really don’t know what happend and I don’t have any idea about what is wrong
>> 
>> can you help me please?
>> 
>> regards
>> 
>> 
>> =============================================
>> "El tamaño de tus logros depende del tamaño de tus metas." 
>> C++ and Qt Senior Developer
>> B.S. Computer Science
>> Buenos Aires, Argentina
>> 
>> 
>> _______________________________________________
>> Interest mailing list
>> Interest at qt-project.org <mailto:Interest at qt-project.org>
>> http://lists.qt-project.org/mailman/listinfo/interest <http://lists.qt-project.org/mailman/listinfo/interest>
>> 
>> 
>> _______________________________________________
>> Interest mailing list
>> Interest at qt-project.org <mailto:Interest at qt-project.org>
>> http://lists.qt-project.org/mailman/listinfo/interest <http://lists.qt-project.org/mailman/listinfo/interest>
> 
> 
> _______________________________________________
> Interest mailing list
> Interest at qt-project.org <mailto:Interest at qt-project.org>
> http://lists.qt-project.org/mailman/listinfo/interest <http://lists.qt-project.org/mailman/listinfo/interest>
> 
> 
> _______________________________________________
> Interest mailing list
> Interest at qt-project.org
> http://lists.qt-project.org/mailman/listinfo/interest

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20160409/95411cf6/attachment.html>


More information about the Interest mailing list