/*************************************************************************** * Copyright (C) 2006 Nicolas Hadacek * * * * This program is free software; you can redistribute it and/or modify * * it under the terms of the GNU General Public License as published by * * the Free Software Foundation; either version 2 of the License, or * * (at your option) any later version. * ***************************************************************************/ #include "picc.h" #include #include "picc_compile.h" #include "picc_config.h" #include "devices/pic/pic/pic_memory.h" #include "devices/list/device_list.h" #include "common/global/process.h" //---------------------------------------------------------------------------- bool PICC::Base::checkExecutableResult(bool, QStringList &lines) const { return lines.join(" ").contains("HI-TECH"); } QString PICC::BaseLite::baseExecutable(bool, Tool::OutputExecutableType) const { if ( _category.type()==Tool::Category::Librarian ) return "libr"; return "picl"; } QString PICC::BaseNormal::baseExecutable(bool, Tool::OutputExecutableType) const { if ( _category.type()==Tool::Category::Librarian ) return "libr"; return "picc"; } QString PICC::Base18::baseExecutable(bool, Tool::OutputExecutableType) const { if ( _category.type()==Tool::Category::Librarian ) return "libr"; return "picc18"; } //---------------------------------------------------------------------------- QValueList PICC::Group::getSupportedDevices(const QString &s) const { QValueList list; QStringList lines = QStringList::split('\n', s); for (uint i=0; iPICC-Lite is a freeware C compiler distributed by HTSoft.").arg("http://www.htsoft.com"); } Tool::Group::BaseData PICC::PICCLiteGroup::baseFactory(Tool::Category category) const { if ( category==Tool::Category::Compiler || category==Tool::Category::Assembler ) return BaseData(new BaseLite, Both); if ( category==Tool::Category::Linker || category==Tool::Category::Librarian ) return BaseData(new BaseLite, ProjectOnly); return BaseData(); } //---------------------------------------------------------------------------- QString PICC::PICCGroup::informationText() const { return i18n("PICC is a C compiler distributed by HTSoft.").arg("http://www.htsoft.com"); } Tool::Group::BaseData PICC::PICCGroup::baseFactory(Tool::Category category) const { if ( category==Tool::Category::Compiler || category==Tool::Category::Assembler ) return BaseData(new BaseNormal, Both); if ( category==Tool::Category::Linker || category==Tool::Category::Librarian ) return BaseData(new BaseNormal, ProjectOnly); return BaseData(); } //---------------------------------------------------------------------------- QString PICC::PICC18Group::informationText() const { return i18n("PICC 18 is a C compiler distributed by HTSoft.").arg("http://www.htsoft.com"); } Tool::Group::BaseData PICC::PICC18Group::baseFactory(Tool::Category category) const { if ( category==Tool::Category::Compiler || category==Tool::Category::Assembler ) return BaseData(new Base18, Both); if ( category==Tool::Category::Linker || category==Tool::Category::Librarian ) return BaseData(new Base18, ProjectOnly); return BaseData(); }