Version: 60963 (using KDE KDE 3.5.5) Installed from: SuSE RPMs When creating or opening a QMake project KDevelop stalls. The window repaints OK, but It doesn't respond to user input. After about a minute, it starts taking user input, and there is a message on the command line "Couldn't start gcc". Here's what stderr has to say: QObject::connect: (sender name: 'gdbBreakpointWidget') QObject::connect: (receiver name: 'gdbBreakpointWidget') kio (KTrader): WARNING: Parsing ' and [X-KDevelop-Version] == 4' gave syntax error kio (KTrader): WARNING: Parsing ' and [X-KDevelop-Version] == 4' gave syntax error kdevelop: ProjectDocumentationPlugin::ProjectDocumentationPlugin for type 0 kdevelop: creating user manual for type: 1 kdevelop: ProjectDocumentationPlugin::ProjectDocumentationPlugin for type 1 kdevelop: DocDoxygenPlugin::createCatalog: url=/home/hattons/code/c++/gs/xmlvariant/xmlvariant.tag QObject::disconnect: No such slot Scope::emitFinished(Scope*) QObject::disconnect: (sender name: 'unnamed') QObject::disconnect: (receiver name: 'unnamed') ASSERT: "part && parent" in /download/org/kdevelop/repository/root/kdevelop/parts/fileview/partwidget.cpp (41) kio (KTrader): WARNING: Parsing ' and [X-KDevelop-Version] == 4' gave syntax error kio (KTrader): WARNING: Parsing ' and [X-KDevelop-Version] == 4' gave syntax error Couldn't start gcc kdevelop: kdevelop: reparsing the following group: : kdevelop: /home/hattons/code/c++/gs/xmlvariant/src/main.cpp
Do you have gcc installed and if yes where it is installed (is in your path?)? The "Couldn't start gcc" appears after 60 second of the rest, right?
SVN commit 609706 by apaku: Use KProcess instead of QProcess to not break the BlockingKProcess from amantia Repair disconnect BUG:138215 M +18 -18 qmakedefaultopts.cpp M +4 -4 qmakedefaultopts.h M +1 -1 scope.cpp --- branches/kdevelop/3.4/buildtools/qmake/qmakedefaultopts.cpp #609705:609706 @@ -15,7 +15,7 @@ #include <ktempfile.h> #include <qdir.h> #include <qregexp.h> -#include <qprocess.h> +#include <kprocess.h> #include <kmessagebox.h> #include <klocale.h> @@ -34,23 +34,23 @@ makefile->close(); qmakefile->close(); - proc = new QProcess(); - kdDebug(9024) << "Working dir:" << projdir << endl; + proc = new KProcess(); + kdDebug(9024) << "KProc Working dir:" << projdir << endl; proc->setWorkingDirectory( projdir ); - proc->addArgument( qmake ); - proc->addArgument( "-d" ); - proc->addArgument( "-o" ); - proc->addArgument( makefile->name() ); - proc->addArgument( qmakefile->name() ); - kdDebug(9024) << "Executing:" << proc->arguments() << endl; - connect( proc, SIGNAL( processExited( ) ), this, SLOT( slotFinished( ) ) ); - connect( proc, SIGNAL( readyReadStderr( ) ), - this, SLOT( slotReadStderr( ) ) ); - proc->setCommunication( QProcess::Stderr ); - proc->start(); + *proc << qmake; + *proc << "-d"; + *proc << "-o"; + *proc << makefile->name(); + *proc << qmakefile->name(); + kdDebug(9024) << "Executing:" << proc->args() << endl; + connect( proc, SIGNAL( processExited( KProcess* ) ), this, SLOT( slotFinished( KProcess* ) ) ); + connect( proc, SIGNAL( receivedStderr( KProcess*, char*, int ) ), + this, SLOT( slotReadStderr( KProcess*, char*, int ) ) ); +// proc->setCommunication( QProcess::Stderr ); + proc->start( KProcess::NotifyOnExit, KProcess::Stderr ); if( !proc->isRunning() && !proc->normalExit() ) { - kdDebug(9024) << "Couldn't execute qmake: " << proc->arguments() << endl; + kdDebug(9024) << "Couldn't execute qmake: " << proc->args() << endl; // kdDebug(9024) << "message box" << endl; // KMessageBox::error( 0, i18n("Error running QMake.\nTried to execute:\n%1\n\nPlease check the path to Qt under Project Options->C++ Support->Qt tab.").arg(proc->arguments().join(" ")), i18n("Couldn't execute qmake") ); makefile->unlink(); @@ -79,9 +79,9 @@ qmakefile = 0; } -void QMakeDefaultOpts::slotReadStderr() +void QMakeDefaultOpts::slotReadStderr( KProcess* , char* buf, int len ) { - QString buffer = QString::fromLocal8Bit( proc->readStderr() ); + QString buffer = QString::fromLocal8Bit( buf, len ); QStringList lines = QStringList::split( "\n", buffer ); for ( QStringList::const_iterator it = lines.begin(); it != lines.end(); ++it) { @@ -96,7 +96,7 @@ } } -void QMakeDefaultOpts::slotFinished() +void QMakeDefaultOpts::slotFinished( KProcess* ) { kdDebug(9024) << "Proc finished" << endl; makefile->unlink(); --- branches/kdevelop/3.4/buildtools/qmake/qmakedefaultopts.h #609705:609706 @@ -17,7 +17,7 @@ #include <qobject.h> class KTempFile; -class QProcess; +class KProcess; class QMakeDefaultOpts : public QObject { @@ -36,14 +36,14 @@ void variablesRead(); private slots: - void slotReadStderr( ); - void slotFinished( ); + void slotReadStderr( KProcess*, char*, int ); + void slotFinished( KProcess* ); private: QMap<QString, QStringList> m_variables; KTempFile* makefile; KTempFile* qmakefile; - QProcess* proc; + KProcess* proc; QStringList m_keys; }; --- branches/kdevelop/3.4/buildtools/qmake/scope.cpp #609705:609706 @@ -1448,7 +1448,7 @@ { if( m_unfinishedScopes ) m_unfinishedScopes->remove( s ); - disconnect( s, SIGNAL( initializationFinished( Scope* ) ), this, SLOT( emitFinished( Scope* ) ) ); + disconnect( s, SIGNAL( initializationFinished( Scope* ) ), this, SLOT( emitInitFinished( Scope* ) ) ); } if( !m_unfinishedScopes || m_unfinishedScopes->isEmpty() ) {