void generateCode (void) { FILE* spec, *opcodes, *code, *table; /* ----- Read the specification ----- */ printf("Reading specification..."); spec = openOrDie(OPCODES_SPEC, "rb"); if (!readSpec(spec)) fatal("Error reading the specification"); fclose(spec); printf("done\n"); opcodes = openOrDie(OPCODES_LIST, "rb"); code = openOrDie(OPCODES_IMPL, "wb"); generateCodeTable(opcodes, code); fclose(opcodes); fclose(code); }
TirFwExtractor::TirFwExtractor(QWidget *parent) : Extractor(parent), et(NULL) { et = new TirFwExtractThread(); QObject::connect(et, SIGNAL(progress(const QString &)), this, SLOT(progress(const QString &))); QObject::connect(et, SIGNAL(finished()), this, SLOT(threadFinished())); QObject::connect(wine, SIGNAL(finished(bool)), this, SLOT(wineFinished(bool))); QObject::connect(dl, SIGNAL(done(bool, QString)), this, SLOT(downloadDone(bool, QString))); QObject::connect(dl, SIGNAL(msg(const QString &)), this, SLOT(progress(const QString &))); QObject::connect(dl, SIGNAL(msg(qint64, qint64)), progressDlg, SLOT(message(qint64, qint64))); haveSpec = readSpec(); #ifndef DARWIN QString sources = QString::fromUtf8("sources.txt"); #else QString sources = QString::fromUtf8("sources_mac.txt"); #endif readSources(sources); QString dbg = QProcessEnvironment::systemEnvironment().value(QString::fromUtf8("LINUXTRACK_DBG")); if(!dbg.contains(QChar::fromLatin1('d'))){ ui.AnalyzeSourceButton->setVisible(false); } }