Originally Posted by
fullmetalcoder
Really? Then make shouldn't cause any trouble... That's the way Edyuk recieve output from compilation and no problem has ever occured on any platform...
The following is pretty much the code. Can you take a look at it?
{
process.setWorkingDirectory(file.absolutePath());
QObject::connect(&process,
SIGNAL(readyReadStandardOutput
()),
this,SLOT(output()));
QObject::connect(&process,
SIGNAL(readyReadStandardError
()),
this,SLOT(output()));
process.start("make");
}
{
process.setWorkingDirectory(file.absolutePath());
QObject::connect(&process,SIGNAL(readyReadStandardOutput()),
this,SLOT(output()));
QObject::connect(&process,SIGNAL(readyReadStandardError()),
this,SLOT(output()));
process.start("make");
}
To copy to clipboard, switch view to plain text mode
The output() slot is:
output(){
out.
append(QString(process.
readAllStandardOutput()));
out.
append(QString(process.
readAllStandardError()));
}
output(){
out.append(QString(process.readAllStandardOutput()));
out.append(QString(process.readAllStandardError()));
}
To copy to clipboard, switch view to plain text mode
Bookmarks