diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-30 00:15:53 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-30 00:15:53 +0000 |
commit | 0aaa8e3fc8f8a1481333b564f0922277c8d8ad59 (patch) | |
tree | b95c0ca86c4876dd139af376b9f4afd8917cf0cd /src/tools/ccsc/ccsc_compile.cpp | |
parent | b79a2c28534cf09987eeeba3077fff9236df182a (diff) | |
download | piklab-0aaa8e3fc8f8a1481333b564f0922277c8d8ad59.tar.gz piklab-0aaa8e3fc8f8a1481333b564f0922277c8d8ad59.zip |
TQt4 port piklab
This enables compilation under both Qt3 and Qt4
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/piklab@1238822 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'src/tools/ccsc/ccsc_compile.cpp')
-rw-r--r-- | src/tools/ccsc/ccsc_compile.cpp | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/tools/ccsc/ccsc_compile.cpp b/src/tools/ccsc/ccsc_compile.cpp index 56897e8..15ccedf 100644 --- a/src/tools/ccsc/ccsc_compile.cpp +++ b/src/tools/ccsc/ccsc_compile.cpp @@ -14,7 +14,7 @@ #include "devices/list/device_list.h" #include "devices/pic/base/pic.h" -QString CCSC::CompileFile::familyName() const +TQString CCSC::CompileFile::familyName() const { const Pic::Data *pdata = static_cast<const Pic::Data *>(Device::lister().data(_data.device)); switch (pdata->architecture().type()) { @@ -31,13 +31,13 @@ QString CCSC::CompileFile::familyName() const case Pic::Architecture::Nb_Types: break; } Q_ASSERT(false); - return QString::null; + return TQString(); } -QStringList CCSC::CompileFile::genericArguments(const Compile::Config &config) const +TQStringList CCSC::CompileFile::genericArguments(const Compile::Config &config) const { bool isVersion3 = ( static_cast<const Group &>(Main::toolGroup()).version().majorNum()==3 ); - QStringList args; + TQStringList args; args += "+STDOUT"; // output messages on stdout if ( !isVersion3 ) args += "+EA"; // show all messages and warnings args += "-P"; // close compile windows after compilation done @@ -55,25 +55,25 @@ QStringList CCSC::CompileFile::genericArguments(const Compile::Config &config) c return args; } -void CCSC::CompileFile::logStderrLine(const QString &line) +void CCSC::CompileFile::logStderrLine(const TQString &line) { // ignore output for wine if ( !Compile::Config::withWine(group()) ) parseLine(line); } -void CCSC::CompileFile::parseLine(const QString &line) +void CCSC::CompileFile::parseLine(const TQString &line) { Log::LineType type; if ( line.startsWith(">>>") ) type = Log::LineType::Warning; else if ( line.startsWith("***") ) type = Log::LineType::Error; else if ( line.startsWith("---") ) type = Log::LineType::Information; else { - doLog(Log::LineType::Normal, line, QString::null, 0); // unrecognized + doLog(Log::LineType::Normal, line, TQString(), 0); // unrecognized return; } if ( parseErrorLine(line, Compile::ParseErrorData("[*>-]+\\s\\w+\\s\\d+\\s\"([^\"]*)\"\\sLine\\s(\\d+)\\([^)]*\\):(.*)", 1, 2, 3, type)) ) return; if ( parseErrorLine(line, Compile::ParseErrorData("[*>-]+\\s\"([^\"]*)\"\\sLine\\s(\\d+):\\s\\w+\\s#\\d+:(.*)", 1, 2, 3, type)) ) return; - doLog(type, line, QString::null, 0); + doLog(type, line, TQString(), 0); } void CCSC::CompileFile::done(int code) @@ -83,9 +83,9 @@ void CCSC::CompileFile::done(int code) PURL::Url url = PURL::Url(directory(), inputFilepath(0)).toExtension("err"); Log::StringView sview; PURL::File file(url, sview); - if ( !file.openForRead() ) doLog(Log::LineType::Error, i18n("Could not find error file (%1).").arg(url.pretty()), QString::null, 0); + if ( !file.openForRead() ) doLog(Log::LineType::Error, i18n("Could not find error file (%1).").tqarg(url.pretty()), TQString(), 0); else { - QStringList lines = file.readLines(); + TQStringList lines = file.readLines(); for (uint i=0; i<lines.count(); i++) parseLine(lines[i]); } } @@ -101,7 +101,7 @@ PURL::Url CCSC::CompileFile::url(PURL::FileType type, uint i) const return url.toFileType(type); } -QString CCSC::CompileFile::outputFiles() const +TQString CCSC::CompileFile::outputFiles() const { return "PURL::Lst PURL::Hex PURL::Coff PURL::Cod sym err esym occ"; } |