[piklab] * Thu Sep 20 2012 Alain Portal <alain.portal[AT]univ-montp2[DOT]fr> 0.16.1-2 - Report an error when
Alain Portal
dionysos at fedoraproject.org
Thu Sep 20 12:47:25 UTC 2012
commit 0e616af5028c06fb454756d768253b5a64f4f423
Author: Alain Portal <alain at super-phoenix.(none)>
Date: Thu Sep 20 14:47:00 2012 +0200
* Thu Sep 20 2012 Alain Portal <alain.portal[AT]univ-montp2[DOT]fr> 0.16.1-2
- Report an error when executable is not found (rev2928)
- Don't power target with ICD2 if device nominal VDD is not 5V (rev2930)
- Retry 10 times when setting serial port mode for ICD2 (rev2931-2932)
- Fix crash when changind watched variable value (rev2940)
- Fix hang with stop command in interactive command line programmer (rev2944)
- Fix sdcc generator for latest sdcc (since 3.1.0) (rev2953)
- Miscellaneous fixes (rev2956)
* Fri Sep 14 2012 Alain Portal <alain.portal[AT]univ-montp2[DOT]fr> 0.16.1-1
- Added OS conditional build
- Patch to use kde4.3 api instead of newest (Kevin Kofler is a guru!)
* Thu Sep 13 2012 Alain Portal <alain.portal[AT]univ-montp2[DOT]fr> 0.16.1-0
- New upstream version (KDE4 port)
- Updated patch 0
- Removed patch 1 (no more x-desktop)
- Remove patches 3, 4 and 5 (fixed upstream)
- Added patch to fix build with KDE4 (r2952)
- Added patch to fix kate-part files path (r2936)
- Used kde4_appsdir macro
- Fixed file permissions
- Added some required runtime dependencies
- Thanks to Branko, Kevin Kofler and Rex Dieter
.gitignore | 1 +
piklab-0.12.1.x-desktop-fr.patch | 12 -
piklab-0.15.12-cmake-readline.patch | 11 -
piklab-0.15.12-gcc47.patch | 10 -
piklab-0.15.12-sdcc-3.0.0.patch | 10 -
piklab-0.16.1-api-kde4.3.patch | 12 +
...ktop-fr.patch => piklab-0.16.1-desktop-fr.patch | 8 +-
piklab-0.16.1-dont-power-target.rev2930.patch | 66 +++
...ab-0.16.1-fix-compilation-with-kde4-r2952.patch | 11 +
piklab-0.16.1-fix-crash.rev2940.patch | 12 +
...fix-hang-with-stop-command-in-clp.rev2944.patch | 123 +++++
piklab-0.16.1-fix-kate-part-path-r2936.patch | 8 +
piklab-0.16.1-flag-no-access-control.patch | 10 +
piklab-0.16.1-misc-fixes.rev2956.patch | 75 +++
piklab-0.16.1-new-sdcc-syntax.rev2953.patch | 15 +
...report-error-executable-not-found.rev2928.patch | 534 ++++++++++++++++++++
...0.16.1-retry-icd2-serial-10-times.rev2931.patch | 46 ++
sources | 2 +-
18 files changed, 918 insertions(+), 48 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 2982c91..831bb23 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,3 +1,4 @@
piklab-0.15.8.tar.bz2
/piklab-0.15.10.tar.bz2
/piklab-0.15.12.tar.bz2
+/piklab-0.16.1.tar.bz2
diff --git a/piklab-0.16.1-api-kde4.3.patch b/piklab-0.16.1-api-kde4.3.patch
new file mode 100644
index 0000000..bdffb45
--- /dev/null
+++ b/piklab-0.16.1-api-kde4.3.patch
@@ -0,0 +1,12 @@
+--- src/libgui/text_editor.cpp.orig 2012-07-02 02:38:42.000000000 +0200
++++ src/libgui/text_editor.cpp 2012-09-14 09:20:33.485105676 +0200
+@@ -119,7 +119,8 @@
+ // prevent warning: No such XML file ".../.kde/share/apps/piklab/katepartui.rc"
+ QFile::copy(katePartUI, katePartLocalUI);
+ }
+- v->replaceXMLFile(katePartUI, katePartLocalUI);
++ v->setLocalXMLFile(katePartLocalUI);
++ v->setXMLFile(katePartUI);
+ }
+
+ if (_view == NULL) _view = v;
diff --git a/piklab-0.15.3.desktop-fr.patch b/piklab-0.16.1-desktop-fr.patch
similarity index 62%
rename from piklab-0.15.3.desktop-fr.patch
rename to piklab-0.16.1-desktop-fr.patch
index 659a852..e22f539 100644
--- a/piklab-0.15.3.desktop-fr.patch
+++ b/piklab-0.16.1-desktop-fr.patch
@@ -1,5 +1,5 @@
---- src/data/app_data/piklab.desktop.orig 2008-03-23 16:43:30.000000000 +0100
-+++ src/data/app_data/piklab.desktop 2010-02-07 12:17:37.000000000 +0100
+--- src/data/app_data/piklab.desktop.orig 2012-07-02 02:38:37.000000000 +0200
++++ src/data/app_data/piklab.desktop 2012-09-12 10:48:24.761107499 +0200
@@ -6,7 +6,10 @@
X-DocPath=piklab/index.html
Categories=Qt;KDE;Development;IDE;Electronics;
@@ -8,6 +8,6 @@
Terminal=false
Name=Piklab
+Name[fr]=Piklab
- GenericName=IDE
+ GenericName=Integrated Development Environment for PICs
+GenericName[fr]=Environnement de développement intégré
- MimeType=text/x-hex;application/x-piklab
+ MimeType=application/x-piklab;
diff --git a/piklab-0.16.1-dont-power-target.rev2930.patch b/piklab-0.16.1-dont-power-target.rev2930.patch
new file mode 100644
index 0000000..0adac65
--- /dev/null
+++ b/piklab-0.16.1-dont-power-target.rev2930.patch
@@ -0,0 +1,66 @@
+Index: src/devices/pic/base/pic.h
+===================================================================
+--- src/devices/pic/base/pic.h (révision 2929)
++++ src/devices/pic/base/pic.h (révision 2930)
+@@ -48,8 +48,7 @@
+ END_DECLARE_ENUM(MemoryRangeType, MemoryRangeTypeData)
+
+ enum ArchitectureProperty {
+- NoArchitectureProperty = 0, PackedHex = 1, RandomMemoryAccess = 2,
+- MaybeSelfWrite = 4, SelfWrite = 8, JFamily = 16, KFamily = 32
++ NoArchitectureProperty = 0, PackedHex = 1, RandomMemoryAccess = 2, MaybeSelfWrite = 4, SelfWrite = 8
+ };
+ Q_DECLARE_FLAGS(ArchitectureProperties, ArchitectureProperty)
+ Q_DECLARE_OPERATORS_FOR_FLAGS(ArchitectureProperties)
+Index: src/devices/pic/base/pic.cpp
+===================================================================
+--- src/devices/pic/base/pic.cpp (révision 2929)
++++ src/devices/pic/base/pic.cpp (révision 2930)
+@@ -37,18 +37,17 @@
+ // name family_label nbBytesPC nbBytesWord nbBitsRegister registerBankLength
+ // {Code, Cal, UserID, DevId, Conf, EEPROM, DebugVec, HardStack, CalBackup, Program Executive}
+ // properties nominalVdd
+- { "baseline", I18N_NOOP("Baseline Family"), 0, 2, 8, 0x020, { 12, 12, 12, 12, 12, 8, 12, 0, 12, 0 }, NoArchitectureProperty, 5.0 }, // 9, 10, 11 or 12-bit program counter
+- { "midrange", I18N_NOOP("Mid-Range Family"), 13, 2, 8, 0x080, { 14, 14, 14, 14, 14, 8, 14, 0, 14, 0 }, MaybeSelfWrite, 5.0 }, // max eeprom: 256 words
+- { "emidrange", I18N_NOOP("Enhance Mid-Range Family"), 13, 2, 8, 0x080, { 14, 14, 14, 14, 14, 8, 14, 0, 14, 0 }, MaybeSelfWrite, 5.0 }, // max eeprom: 256 words
+- { "17C", I18N_NOOP("17C Family"), 16, 2, 8, 0x100, { 16, 0, 0, 0, 16, 8, 0, 0, 0, 0 }, RandomMemoryAccess, 5.0 },
+- { "18C", I18N_NOOP("18C Family"), 21, 2, 8, 0x100, { 16, 8, 8, 8, 8, 8, 16, 0, 8, 0 }, PackedHex | RandomMemoryAccess, 5.0 },
+- { "18F", I18N_NOOP("18F Family"), 21, 2, 8, 0x100, { 16, 8, 8, 8, 8, 8, 16, 0, 8, 0 }, PackedHex | RandomMemoryAccess | MaybeSelfWrite, 5.0 },
+- { "18J", I18N_NOOP("18J Family"), 21, 2, 8, 0x100, { 16, 8, 8, 8, 8, 8, 16, 0, 8, 0 }, PackedHex | RandomMemoryAccess | SelfWrite | JFamily, 3.3 },
+-
+- { "24F", I18N_NOOP("24F Family"), 23, 4, 16, 0x800, { 24, 0, 0, 16, 16, 0, 24, 0, 0, 24 }, RandomMemoryAccess | SelfWrite | JFamily, 3.3 },
+- { "24H", I18N_NOOP("24H Family"), 23, 4, 16, 0x800, { 24, 0, 8, 16, 8, 0, 24, 0, 0, 24 }, RandomMemoryAccess | SelfWrite | JFamily, 3.3 },
+- { "30F", I18N_NOOP("30F Family"), 23, 4, 16, 0xA00, { 24, 0, 24, 16, 16, 16, 24, 0, 0, 24 }, RandomMemoryAccess | SelfWrite, 5.0 }, // dsPIC: eeprom max = 2 kwords = 4 kbytes
+- { "33F", I18N_NOOP("33F Family"), 23, 4, 16, 0x800, { 24, 0, 16, 16, 16, 0, 24, 0, 0, 24 }, RandomMemoryAccess | SelfWrite | JFamily, 3.3 }
++ { "baseline", I18N_NOOP("Baseline Family"), 0, 2, 8, 0x020, { 12, 12, 12, 12, 12, 8, 12, 0, 12, 0 }, NoArchitectureProperty, 5.0 }, // 9, 10, 11 or 12-bit program counter
++ { "midrange", I18N_NOOP("Mid-Range Family"), 13, 2, 8, 0x080, { 14, 14, 14, 14, 14, 8, 14, 0, 14, 0 }, MaybeSelfWrite, 5.0 }, // max eeprom: 256 words
++ { "emidrange", I18N_NOOP("Enhance Mid-Range Family"), 13, 2, 8, 0x080, { 14, 14, 14, 14, 14, 8, 14, 0, 14, 0 }, MaybeSelfWrite, 5.0 }, // max eeprom: 256 words
++ { "17C", I18N_NOOP("17C Family"), 16, 2, 8, 0x100, { 16, 0, 0, 0, 16, 8, 0, 0, 0, 0 }, RandomMemoryAccess, 5.0 },
++ { "18C", I18N_NOOP("18C Family"), 21, 2, 8, 0x100, { 16, 8, 8, 8, 8, 8, 16, 0, 8, 0 }, PackedHex | RandomMemoryAccess, 5.0 },
++ { "18F", I18N_NOOP("18F Family"), 21, 2, 8, 0x100, { 16, 8, 8, 8, 8, 8, 16, 0, 8, 0 }, PackedHex | RandomMemoryAccess | MaybeSelfWrite, 5.0 },
++ { "18J", I18N_NOOP("18J Family"), 21, 2, 8, 0x100, { 16, 8, 8, 8, 8, 8, 16, 0, 8, 0 }, PackedHex | RandomMemoryAccess | SelfWrite, 3.3 },
++ { "24F", I18N_NOOP("24F Family"), 23, 4, 16, 0x800, { 24, 0, 0, 16, 16, 0, 24, 0, 0, 24 }, RandomMemoryAccess | SelfWrite, 3.3 },
++ { "24H", I18N_NOOP("24H Family"), 23, 4, 16, 0x800, { 24, 0, 8, 16, 8, 0, 24, 0, 0, 24 }, RandomMemoryAccess | SelfWrite, 3.3 },
++ { "30F", I18N_NOOP("30F Family"), 23, 4, 16, 0xA00, { 24, 0, 24, 16, 16, 16, 24, 0, 0, 24 }, RandomMemoryAccess | SelfWrite, 5.0 }, // dsPIC: eeprom max = 2 kwords = 4 kbytes
++ { "33F", I18N_NOOP("33F Family"), 23, 4, 16, 0x800, { 24, 0, 16, 16, 16, 0, 24, 0, 0, 24 }, RandomMemoryAccess | SelfWrite, 3.3 }
+ };
+
+ const Pic::Checksum::Algorithm::Data Pic::Checksum::Algorithm::DATA[Nb_Types] = {
+Index: src/progs/icd2/base/icd2.cpp
+===================================================================
+--- src/progs/icd2/base/icd2.cpp (révision 2929)
++++ src/progs/icd2/base/icd2.cpp (révision 2930)
+@@ -274,6 +274,13 @@
+
+ bool Icd2::Hardware::setTargetPowerOn(bool on)
+ {
++ if (on) {
++ const double vdd = device().architecture().data().nominalVdd;
++ if (vdd != 5.0) {
++ log(Log::LineType::Warning, i18n("Set target power disabled because device does not support 5V supply (nomial vdd is %1V).").arg(vdd));
++ return true;
++ }
++ }
+ return command(QString("05") + (on ? "FF" : "00"), 0);
+ }
+
diff --git a/piklab-0.16.1-fix-compilation-with-kde4-r2952.patch b/piklab-0.16.1-fix-compilation-with-kde4-r2952.patch
new file mode 100644
index 0000000..9c545fb
--- /dev/null
+++ b/piklab-0.16.1-fix-compilation-with-kde4-r2952.patch
@@ -0,0 +1,11 @@
+--- cmake/Piklab.cmake.orig 2012-07-02 02:38:22.000000000 +0200
++++ cmake/Piklab.cmake 2012-09-12 10:28:55.723107474 +0200
+@@ -27,7 +27,7 @@
+ else(QT_ONLY)
+ find_package(KDE4 REQUIRED)
+ add_definitions(${QT_DEFINITIONS} ${KDE4_DEFINITIONS})
+- include_directories( ${KDE4_INCLUDE_DIRS})
++ include_directories( ${KDE4_INCLUDES})
+ set(EXE_LIBS ${QT_LIBRARIES} ${KDE4_KDECORE_LIBS} ${KDE4_KIO_LIBS} kde)
+ set(GUI_LIBS ${KDE4_KDEUI_LIBS} ${KDE4_KDE3SUPPORT_LIBS} ${EXE_LIBS} kde_gui ${KDE4_KTEXTEDITOR_LIBS} ${KDE4_KFILE_LIBS})
+ endif(QT_ONLY)
diff --git a/piklab-0.16.1-fix-crash.rev2940.patch b/piklab-0.16.1-fix-crash.rev2940.patch
new file mode 100644
index 0000000..3b32ace
--- /dev/null
+++ b/piklab-0.16.1-fix-crash.rev2940.patch
@@ -0,0 +1,12 @@
+Index: src/common/gui/list_view.cpp
+===================================================================
+--- src/common/gui/list_view.cpp (révision 2939)
++++ src/common/gui/list_view.cpp (révision 2940)
+@@ -174,6 +174,7 @@
+ _renaming = false;
+ bool resetFocus = false;
+ for (uint i=0; i<_editWidgets.size(); i++) {
++ if ( _editWidgets[i]==NULL ) continue;
+ if ( lv->viewport()->focusProxy()==_editWidgets[i] ) resetFocus = true;
+ lv->viewport()->setFocusProxy(NULL);
+ _editWidgets[i]->hide();
diff --git a/piklab-0.16.1-fix-hang-with-stop-command-in-clp.rev2944.patch b/piklab-0.16.1-fix-hang-with-stop-command-in-clp.rev2944.patch
new file mode 100644
index 0000000..baadba3
--- /dev/null
+++ b/piklab-0.16.1-fix-hang-with-stop-command-in-clp.rev2944.patch
@@ -0,0 +1,123 @@
+Index: src/piklab-prog/cli_prog_manager.cpp
+===================================================================
+--- src/piklab-prog/cli_prog_manager.cpp (révision 2943)
++++ src/piklab-prog/cli_prog_manager.cpp (révision 2944)
+@@ -54,9 +54,9 @@
+ if (!CLI::_firmwareDir.isEmpty()
+ && !(_programmer->group().properties() & ::Programmer::Custom)) {
+ typedef ::Programmer::Base Base; // for G++ 3.3.6
+- static_cast<Base*>(_programmer)->setFirmwareDirectory(CLI::_firmwareDir.path());
++ static_cast<Base*>(_programmer.get())->setFirmwareDirectory(CLI::_firmwareDir.path());
+ }
+- return _programmer;
++ return _programmer.get();
+ }
+
+ bool Programmer::CliManager::internalInitProgramming(ProgramAction action)
+Index: src/progs/manager/prog_manager.cpp
+===================================================================
+--- src/progs/manager/prog_manager.cpp (révision 2943)
++++ src/progs/manager/prog_manager.cpp (révision 2944)
+@@ -20,29 +20,22 @@
+ Programmer::Manager *Programmer::manager = 0;
+
+ Programmer::Manager::Manager(QObject *parent)
+- : QObject(parent, "programmer_manager"), _programmer(0)
++: QObject(parent, "programmer_manager"),
++ _halting(false)
+ {}
+
+-Programmer::Manager::~Manager()
+-{
+- delete _programmer;
+- _programmer = NULL;
+-}
+-
+ void Programmer::Manager::clear()
+ {
+- delete _programmer;
+- _programmer = NULL;
++ _programmer.reset(NULL);
+ }
+
+ void Programmer::Manager::internalCreateProgrammer(const Device::Data *data, const HardwareDescription &hd)
+ {
+- if (_programmer != NULL
++ if (_programmer.get() != NULL
+ && &_programmer->group() == group()
+ && _programmer->device() == data
+ && !hasError()) return;
+- delete _programmer;
+- _programmer = group()->createProgrammer(isTargetSelfPowered(), data, hd, this);
++ _programmer.reset(group()->createProgrammer(isTargetSelfPowered(), data, hd, this));
+ connect(&_programmer->progressMonitor(), SIGNAL(setLabel(const QString &)), SIGNAL(actionMessage(const QString &)));
+ connect(&_programmer->progressMonitor(), SIGNAL(setTotalProgress(uint)), SIGNAL(setTotalProgress(uint)));
+ connect(&_programmer->progressMonitor(), SIGNAL(setProgress(uint)), SIGNAL(setProgress(uint)));
+@@ -160,8 +153,7 @@
+ _programmer->setTargetPowerOn(false);
+ _programmer->disconnectHardware();
+ endProgramming();
+- delete _programmer;
+- _programmer = NULL;
++ _programmer.reset(NULL);
+ if (debugger) log(Log::LineType::Information, i18n("Stopped."));
+ return true;
+ }
+@@ -176,8 +168,11 @@
+
+ bool Programmer::Manager::halt()
+ {
+- if ( !initProgramming(ProgramAction::Halt) ) return false;
+- bool ok;
++ if (_halting) return true;
++ _halting = true;
++ bool ok = initProgramming(ProgramAction::Halt);
++ _halting = false;
++ if (!ok) return false;
+ if (group()->isDebugger()) {
+ ok = ::Debugger::manager->halt();
+ setState(Idle);
+@@ -191,7 +186,7 @@
+
+ void Programmer::Manager::stop()
+ {
+- if (_programmer) _programmer->disconnectHardware();
++ if (_programmer.get() != NULL) _programmer->disconnectHardware();
+ }
+
+ bool Programmer::Manager::restart()
+Index: src/progs/manager/prog_manager.h
+===================================================================
+--- src/progs/manager/prog_manager.h (révision 2943)
++++ src/progs/manager/prog_manager.h (révision 2944)
+@@ -29,8 +29,7 @@
+ Q_OBJECT
+ public:
+ Manager(QObject *parent);
+- virtual ~Manager();
+- ::Programmer::Generic *programmer() { return _programmer; }
++ ::Programmer::Generic *programmer() { return _programmer.get(); }
+ virtual ::Programmer::Generic *createProgrammer(const Device::Data *data) = 0;
+ bool initProgramming(ProgramAction action);
+ void endProgramming();
+@@ -60,7 +59,8 @@
+ void setProgress(uint steps);
+
+ protected:
+- ::Programmer::Generic *_programmer;
++ std::auto_ptr< ::Programmer::Generic> _programmer;
++ bool _halting;
+
+ virtual const Group *group() const = 0;
+ virtual bool internalInitProgramming(ProgramAction action);
+Index: src/libgui/gui_prog_manager.cpp
+===================================================================
+--- src/libgui/gui_prog_manager.cpp (révision 2943)
++++ src/libgui/gui_prog_manager.cpp (révision 2944)
+@@ -81,5 +81,5 @@
+ std::auto_ptr< ::Hardware::Config> hconfig(group()->hardwareConfig());
+ if (hconfig.get() != NULL) hd.name = hconfig->currentHardware(hd.port.type);
+ internalCreateProgrammer(data, hd);
+- return _programmer;
++ return _programmer.get();
+ }
diff --git a/piklab-0.16.1-fix-kate-part-path-r2936.patch b/piklab-0.16.1-fix-kate-part-path-r2936.patch
new file mode 100644
index 0000000..2f61ffb
--- /dev/null
+++ b/piklab-0.16.1-fix-kate-part-path-r2936.patch
@@ -0,0 +1,8 @@
+--- src/data/CMakeLists.txt.orig 2012-07-02 02:38:37.000000000 +0200
++++ src/data/CMakeLists.txt 2012-09-12 10:34:03.550106141 +0200
+@@ -13,4 +13,4 @@
+ DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/syntax_xml_generator
+ )
+ ADD_CUSTOM_TARGET(generate_coff-pic ALL DEPENDS coff-pic.xml)
+-install(FILES asm-pic.xml coff-pic.xml jal-pic.xml coff-c-pic.xml DESTINATION share/apps/katepart/syntax)
++install(FILES asm-pic.xml coff-pic.xml jal-pic.xml coff-c-pic.xml DESTINATION ${DATA_INSTALL_DIR}/katepart/syntax)
diff --git a/piklab-0.16.1-flag-no-access-control.patch b/piklab-0.16.1-flag-no-access-control.patch
new file mode 100644
index 0000000..d44f384
--- /dev/null
+++ b/piklab-0.16.1-flag-no-access-control.patch
@@ -0,0 +1,10 @@
+--- src/libgui/CMakeLists.txt.orig 2012-07-02 02:38:42.000000000 +0200
++++ src/libgui/CMakeLists.txt 2012-09-17 13:09:02.474093765 +0200
+@@ -1,5 +1,7 @@
+ include_directories(${CMAKE_SOURCE_DIR}/src ${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR} ${KDE3_INCLUDE_DIR} ${QT_INCLUDE_DIR} )
+
++set_source_files_properties(text_editor.cpp PROPERTIES COMPILE_FLAGS -fno-access-control)
++
+ # for messages extraction
+ FILE(GLOB RC_FILES RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}" "${CMAKE_CURRENT_SOURCE_DIR}/../data/app_data/*.rc")
+ ADD_CUSTOM_COMMAND(
diff --git a/piklab-0.16.1-misc-fixes.rev2956.patch b/piklab-0.16.1-misc-fixes.rev2956.patch
new file mode 100644
index 0000000..0910433
--- /dev/null
+++ b/piklab-0.16.1-misc-fixes.rev2956.patch
@@ -0,0 +1,75 @@
+Index: src/progs/gui/prog_config_widget.cpp
+===================================================================
+--- src/progs/gui/prog_config_widget.cpp (révision 2955)
++++ src/progs/gui/prog_config_widget.cpp (révision 2956)
+@@ -34,7 +34,7 @@
+
+ void Programmer::ConfigWidget::saveConfig()
+ {
+- if (_firmwareDir) GroupConfig::writeFirmwareDirectory(_group, _firmwareDir->url().url());
++ if (_firmwareDir) GroupConfig::writeFirmwareDirectory(_group, _firmwareDir->url().path());
+ }
+
+ bool Programmer::ConfigWidget::setPort(const HardwareDescription &)
+Index: src/progs/gui/prog_group_ui.cpp
+===================================================================
+--- src/progs/gui/prog_group_ui.cpp (révision 2955)
++++ src/progs/gui/prog_group_ui.cpp (révision 2956)
+@@ -46,10 +46,11 @@
+
+ //----------------------------------------------------------------------------
+ Programmer::AdvancedDialog::AdvancedDialog(Base &base, QWidget *parent, const char *name)
+- : PageDialog(parent, name, true, i18n("Advanced Dialog"), Close, Close, false),
+- _base(base), _calEditor(0)
++: PageDialog(parent, name, true, i18n("Advanced Dialog"), Close, Close, false),
++ _base(base), _calEditor(0)
+ {
+ setFaceType(List);
++
+ // programmer
+ _programmerContainer = new Container::Grid(this);
+ KPageWidgetItem* item = addPage(_programmerContainer, _base.group().label());
+Index: src/progs/base/generic_prog.cpp
+===================================================================
+--- src/progs/base/generic_prog.cpp (révision 2955)
++++ src/progs/base/generic_prog.cpp (révision 2956)
+@@ -158,11 +158,15 @@
+
+ PURL::Directory Programmer::Base::firmwareDirectory()
+ {
+- if ( _firmwareDirectory.isEmpty() ) _firmwareDirectory = GroupConfig::firmwareDirectory(group());
+- if ( !_firmwareDirectory.exists() ) {
+- log(Log::LineType::Error, i18n("Firmware directory is not configured or does not exist."));
++ if (_firmwareDirectory.isEmpty()) _firmwareDirectory = GroupConfig::firmwareDirectory(group());
++ if (_firmwareDirectory.isEmpty()) {
++ log(Log::LineType::Error, i18n("Firmware directory is not configured."));
+ return PURL::Directory();
+ }
++ if (!_firmwareDirectory.exists()) {
++ log(Log::LineType::Error, i18n("Firmware directory '%1' does not exist.").arg(_firmwareDirectory.pretty()));
++ return PURL::Directory();
++ }
+ return _firmwareDirectory;
+ }
+
+@@ -238,7 +242,7 @@
+ bool Programmer::Base::setTargetPowerOn(bool on)
+ {
+ _targetPowerOn = on;
+- return _deviceSpecific->setTargetPowerOn(on);
++ return _deviceSpecific.get() != NULL ? _deviceSpecific->setTargetPowerOn(on) : true;
+ }
+
+ void Programmer::Base::appendTask(Task task, const Device::MemoryRange& range)
+Index: src/libgui/log_view.cpp
+===================================================================
+--- src/libgui/log_view.cpp (révision 2955)
++++ src/libgui/log_view.cpp (révision 2956)
+@@ -27,6 +27,7 @@
+ setReadOnly(true);
+ setPalette(p);
+ setMinimumWidth(300);
++ setDebugLevel(GlobalConfig::debugLevel());
+
+ connect(this, SIGNAL(aboutToShowContextMenu(QMenu*)), this, SLOT(slotAboutToShowContextMenu(QMenu*)));
+ }
diff --git a/piklab-0.16.1-new-sdcc-syntax.rev2953.patch b/piklab-0.16.1-new-sdcc-syntax.rev2953.patch
new file mode 100644
index 0000000..6a9ab36
--- /dev/null
+++ b/piklab-0.16.1-new-sdcc-syntax.rev2953.patch
@@ -0,0 +1,15 @@
+Index: src/tools/sdcc/sdcc_generator.cpp
+===================================================================
+--- src/tools/sdcc/sdcc_generator.cpp (révision 2952)
++++ src/tools/sdcc/sdcc_generator.cpp (révision 2953)
+@@ -69,8 +69,8 @@
+ QStringList cnames = SourceLine::configNames(Pic::ConfigNameType::SDCC, pmemory, i, ok);
+ if ( cnames.isEmpty() ) continue;
+ QString code;
+- if ( data.is18Family() ) code += "code char at ";
+- else code += "word at ";
++ if ( data.is18Family() ) code += "__code char __at ";
++ else code += "word __at ";
+ if ( cword.name.isEmpty() ) code += toHexLabel(address, data.nbCharsAddress()) + " CONFIG";
+ else code += prefix + cword.name + " " + cword.name;
+ code += " = " + cnames.join(" & ") + ";";
diff --git a/piklab-0.16.1-report-error-executable-not-found.rev2928.patch b/piklab-0.16.1-report-error-executable-not-found.rev2928.patch
new file mode 100644
index 0000000..ea38493
--- /dev/null
+++ b/piklab-0.16.1-report-error-executable-not-found.rev2928.patch
@@ -0,0 +1,534 @@
+Index: src/tools/mpc/mpc_compile.cpp
+===================================================================
+--- src/tools/mpc/mpc_compile.cpp (révision 2927)
++++ src/tools/mpc/mpc_compile.cpp (révision 2928)
+@@ -28,11 +28,11 @@
+
+ void MPC::CompileFile::parseLine(const QString &line)
+ {
+- if ( parseErrorLine(line, Compile::ParseErrorData("(\\w+)\\s+(.*)\\s+(\\d+):\\d+:(.*)", 2, 3, 4, 1)) ) return;
++ if ( parseErrorLine(line, Compile::ParseErrorData("(\\w+)\\s+(.*)\\s+(\\d+):\\d+:(.*)", 2, 3, 4, 1, Log::LineType::Error)) ) return;
+ doLog(Log::LineType::Normal, line, QString::null, 0); // unrecognized
+ }
+
+-void MPC::CompileFile::done(int code)
++void MPC::CompileFile::done()
+ {
+ // rely on error file
+ PURL::Url url = PURL::Url(directory(), inputFilepath(0)).toExtension("err");
+@@ -43,7 +43,7 @@
+ QStringList lines = file.readLines();
+ for (int i=0; i<lines.count(); i++) parseLine(lines[i]);
+ }
+- Compile::Process::done(code);
++ Compile::Process::done();
+ }
+
+ QString MPC::CompileFile::outputFiles() const
+Index: src/tools/mpc/mpc_compile.h
+===================================================================
+--- src/tools/mpc/mpc_compile.h (révision 2927)
++++ src/tools/mpc/mpc_compile.h (révision 2928)
+@@ -24,7 +24,7 @@
+ virtual QString outputFiles() const;
+
+ protected slots:
+- virtual void done(int code);
++ virtual void done();
+
+ private:
+ void parseLine(const QString &line);
+Index: src/tools/gui/toolchain_config_widget.cpp
+===================================================================
+--- src/tools/gui/toolchain_config_widget.cpp (révision 2927)
++++ src/tools/gui/toolchain_config_widget.cpp (révision 2928)
+@@ -215,10 +215,14 @@
+ if ( !_group.base(k)->checkExecutable() ) _data[k].label->setText(i18n("Unknown"));
+ else {
+ _data[k].checkLines.clear();
+- delete _data[k].process;
++ if (_data[k].process != NULL) {
++ _data[k].process->blockSignals(true);
++ delete _data[k].process;
++ }
+ _data[k].process = checkExecutableProcess(k);
+ _data[k].command = _data[k].process->prettyCommand();
+- connect(_data[k].process, SIGNAL(done(int)), SLOT(checkExecutableDone()));
++ connect(_data[k].process, SIGNAL(done()), SLOT(checkExecutableDone()));
++ connect(_data[k].process, SIGNAL(error()), SLOT(checkExecutableDone()));
+ connect(_data[k].process, SIGNAL(timeout()), SLOT(checkExecutableDone()));
+ QString exec = baseExecutable(k);
+ if ( !_data[k].process->start(5000) ) _data[k].label->setText(i18n("\"%1\" not found").arg(exec));
+@@ -234,7 +238,8 @@
+ delete _devicesData[i].process;
+ _devicesData[i].process = checkDevicesProcess(i);
+ _devicesData[i].command = _devicesData[i].process->prettyCommand();
+- connect(_devicesData[i].process, SIGNAL(done(int)), SLOT(checkDevicesDone()));
++ connect(_devicesData[i].process, SIGNAL(done()), SLOT(checkDevicesDone()));
++ connect(_devicesData[i].process, SIGNAL(error()), SLOT(checkDevicesDone()));
+ connect(_devicesData[i].process, SIGNAL(timeout()), SLOT(checkDevicesDone()));
+ _devicesData[i].done = false;
+ _devicesData[i].checkLines.clear();
+Index: src/tools/boost/boostc_compile.cpp
+===================================================================
+--- src/tools/boost/boostc_compile.cpp (révision 2927)
++++ src/tools/boost/boostc_compile.cpp (révision 2928)
+@@ -14,7 +14,7 @@
+ //----------------------------------------------------------------------------
+ void Boost::Process::logLine(::Process::OutputType, const QString &line)
+ {
+- if ( parseErrorLine(line, Compile::ParseErrorData("(.*)\\((\\d+).*\\): (error|warning):(.*)", 1, 2, 4, 3)) ) return;
++ if ( parseErrorLine(line, Compile::ParseErrorData("(.*)\\((\\d+).*\\): (error|warning):(.*)", 1, 2, 4, 3, Log::LineType::Error)) ) return;
+ doLog(Log::LineType::Normal, line, QString::null, 0);
+ }
+
+Index: src/tools/gputils/gputils_compile.cpp
+===================================================================
+--- src/tools/gputils/gputils_compile.cpp (révision 2927)
++++ src/tools/gputils/gputils_compile.cpp (révision 2928)
+@@ -24,8 +24,8 @@
+ //-----------------------------------------------------------------------------
+ void GPUtils::AssembleFile::logLine(::Process::OutputType, const QString &line)
+ {
+- if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*):([0-9]+):(.+)\\[[0-9]+\\](.+)", 1, 2, 4, 3)) ) return;
+- if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*):([^:]+):([0-9]+):(.+)", 2, 3, 4, Log::LineType::Warning)) ) return;
++ if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*):([0-9]+):(.+)\\[[0-9]+\\](.+)", 1, 2, 4, 3, Log::LineType::Error)) ) return;
++ if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*):([^:]+):([0-9]+):(.+)", 2, 3, 4, -1, Log::LineType::Warning)) ) return;
+ doLog(Log::LineType::Normal, line, QString::null, 0); // unrecognized
+ }
+
+Index: src/tools/c18/c18_compile.cpp
+===================================================================
+--- src/tools/c18/c18_compile.cpp (révision 2927)
++++ src/tools/c18/c18_compile.cpp (révision 2928)
+@@ -34,8 +34,8 @@
+
+ void C18::CompileFile::logLine(::Process::OutputType, const QString &line)
+ {
+- if ( parseErrorLine(line, Compile::ParseErrorData("(.*):([0-9]+):([^:]+):\\s*(.+)", 1, 2, 4, 3)) ) return;
+- if ( parseErrorLine(line, Compile::ParseErrorData("(.*):([0-9]+):([^\\[]+)\\s*(.+)", 1, 2, 4, 3)) ) return;
++ if ( parseErrorLine(line, Compile::ParseErrorData("(.*):([0-9]+):([^:]+):\\s*(.+)", 1, 2, 4, 3, Log::LineType::Error)) ) return;
++ if ( parseErrorLine(line, Compile::ParseErrorData("(.*):([0-9]+):([^\\[]+)\\s*(.+)", 1, 2, 4, 3, Log::LineType::Error)) ) return;
+ doLog(Log::LineType::Normal, line, QString::null, 0);
+ }
+
+Index: src/tools/cc5x/cc5x_compile.cpp
+===================================================================
+--- src/tools/cc5x/cc5x_compile.cpp (révision 2927)
++++ src/tools/cc5x/cc5x_compile.cpp (révision 2928)
+@@ -28,7 +28,7 @@
+
+ void CC5X::CompileFile::logLine(::Process::OutputType, const QString &line)
+ {
+- if ( parseErrorLine(line, Compile::ParseErrorData("(.*):([0-9]+):(.+)\\[([0-9]+)\\](.+)", 1, 2, 5, 3)) ) return;
++ if ( parseErrorLine(line, Compile::ParseErrorData("(.*):([0-9]+):(.+)\\[([0-9]+)\\](.+)", 1, 2, 5, 3, Log::LineType::Error)) ) return;
+ doLog(Log::LineType::Normal, line, QString::null, 0); // unrecognized
+ }
+
+Index: src/tools/ccsc/ccsc_compile.cpp
+===================================================================
+--- src/tools/ccsc/ccsc_compile.cpp (révision 2927)
++++ src/tools/ccsc/ccsc_compile.cpp (révision 2928)
+@@ -73,12 +73,12 @@
+ doLog(Log::LineType::Normal, line, QString::null, 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;
++ if ( parseErrorLine(line, Compile::ParseErrorData("[*>-]+\\s\\w+\\s\\d+\\s\"([^\"]*)\"\\sLine\\s(\\d+)\\([^)]*\\):(.*)", 1, 2, 3, -1, type)) ) return;
++ if ( parseErrorLine(line, Compile::ParseErrorData("[*>-]+\\s\"([^\"]*)\"\\sLine\\s(\\d+):\\s\\w+\\s#\\d+:(.*)", 1, 2, 3, -1, type)) ) return;
+ doLog(type, line, QString::null, 0);
+ }
+
+-void CCSC::CompileFile::done(int code)
++void CCSC::CompileFile::done()
+ {
+ // with wine, rely on error file
+ if ( Compile::Config::executableType(group())==Tool::ExecutableType::Windows ) {
+@@ -91,7 +91,7 @@
+ for (int i=0; i<lines.count(); i++) parseLine(lines[i]);
+ }
+ }
+- Compile::Process::done(code);
++ Compile::Process::done();
+ }
+
+ PURL::Url CCSC::CompileFile::url(PURL::FileType type, uint i) const
+Index: src/tools/ccsc/ccsc_compile.h
+===================================================================
+--- src/tools/ccsc/ccsc_compile.h (révision 2927)
++++ src/tools/ccsc/ccsc_compile.h (révision 2928)
+@@ -26,7 +26,7 @@
+ virtual PURL::Url url(PURL::FileType type = PURL::Nb_FileTypes, uint i = 0) const;
+
+ protected slots:
+- virtual void done(int code);
++ virtual void done();
+
+ private:
+ void parseLine(const QString &line);
+Index: src/tools/list/compile_process.cpp
+===================================================================
+--- src/tools/list/compile_process.cpp (révision 2927)
++++ src/tools/list/compile_process.cpp (révision 2928)
+@@ -209,7 +209,8 @@
+ _stderr = QString::null;
+ delete _process;
+ _process = new ::Process::LineSignal;
+- connect(_process, SIGNAL(done(int)), SLOT(done(int)));
++ connect(_process, SIGNAL(done()), SLOT(done()));
++ connect(_process, SIGNAL(error()), SLOT(error()));
+ connect(_process, SIGNAL(timeout()), SLOT(timeout()));
+ connect(_process, SIGNAL(logLine(::Process::OutputType, const QString &)),
+ SLOT(logLine(::Process::OutputType, const QString &)));
+@@ -219,15 +220,26 @@
+ return _process->start();
+ }
+
+-void Compile::BaseProcess::done(int code)
++void Compile::BaseProcess::error()
+ {
++ _manager->log(Log::LineType::Error, i18n("*** Error executing command ***"));
++ _manager->processFailed();
++}
++
++void Compile::BaseProcess::done()
++{
++ int code = _process->exitCode();
+ if ( code!=0 ) {
+ _manager->log(Log::LineType::Error, i18n("*** Exited with status: %1 ***").arg(code));
+ _manager->processFailed();
+- } else if ( _manager->hasError() ) {
++ return;
++ }
++ if ( _manager->hasError() ) {
+ _manager->log(Log::LineType::Error, i18n("*** Error ***"));
+ _manager->processFailed();
+- } else _manager->processDone();
++ return;
++ }
++ _manager->processDone();
+ }
+
+ void Compile::BaseProcess::timeout()
+Index: src/tools/list/compile_process.h
+===================================================================
+--- src/tools/list/compile_process.h (révision 2927)
++++ src/tools/list/compile_process.h (révision 2928)
+@@ -72,11 +72,7 @@
+
+ class ParseErrorData {
+ public:
+- ParseErrorData(const QString &p, int iFile, int iLine, int iMessage, Log::LineType dLineType)
+- : pattern(p), indexFile(iFile), indexLine(iLine), indexMessage(iMessage), indexLogType(-1),
+- defaultLineType(dLineType) {}
+- ParseErrorData(const QString &p, int iFile, int iLine, int iMessage, uint iLogType,
+- Log::LineType dLineType = Log::LineType::Error)
++ ParseErrorData(const QString &p, int iFile, int iLine, int iMessage, uint iLogType, Log::LineType dLineType)
+ : pattern(p), indexFile(iFile), indexLine(iLine), indexMessage(iMessage), indexLogType(iLogType),
+ defaultLineType(dLineType) {}
+ QString pattern;
+@@ -189,7 +185,8 @@
+
+ protected slots:
+ virtual void logLine(::Process::OutputType type, const QString &line) = 0;
+- virtual void done(int code);
++ virtual void done();
++ void error();
+ void timeout();
+ };
+
+Index: src/tools/sdcc/sdcc_compile.cpp
+===================================================================
+--- src/tools/sdcc/sdcc_compile.cpp (révision 2927)
++++ src/tools/sdcc/sdcc_compile.cpp (révision 2928)
+@@ -43,13 +43,13 @@
+
+ void SDCC::Process::logLine(::Process::OutputType, const QString &line)
+ {
+- if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*):([0-9]+):( syntax error):(.+)", 1, 2, 4, -1)) ) return;
+- if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*):([0-9]+):( error)(.+)", 1, 2, 4, -1)) ) return;
+- if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*):([0-9]+):(error|warning|message):(.+)", 1, 2, 4, 3)) ) return;
+- if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*):([0-9]+):(\\w+)\\s*\\[[0-9]+\\](.+)", 1, 2, 4, 3)) ) return;
++ if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*):([0-9]+):( syntax error):(.+)", 1, 2, 4, -1, Log::LineType::Error)) ) return;
++ if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*):([0-9]+):( error)(.+)", 1, 2, 4, -1, Log::LineType::Error)) ) return;
++ if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*):([0-9]+):(error|warning|message):(.+)", 1, 2, 4, 3, Log::LineType::Error)) ) return;
++ if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*):([0-9]+):(\\w+)\\s*\\[[0-9]+\\](.+)", 1, 2, 4, 3, Log::LineType::Error)) ) return;
+ if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*)\\s*[0-9]+:(.+)", -1, -1, 2, 1, Log::LineType::Warning)) ) return;
+- if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*):([0-9]+):(.+)", 1, 2, 3, Log::LineType::Warning)) ) return;
+- if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*):([^:]+):([0-9]+):(.+)", 2, 3, 4, Log::LineType::Warning)) ) return;
++ if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*):([0-9]+):(.+)", 1, 2, 3, -1, Log::LineType::Warning)) ) return;
++ if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*):([^:]+):([0-9]+):(.+)", 2, 3, 4, -1, Log::LineType::Warning)) ) return;
+ if ( parseErrorLine(line, Compile::ParseErrorData("([^:]+):(.+)", -1, -1, 2, 1, Log::LineType::Warning)) ) return;
+ doLog(filterType(line), line, QString::null, 0);
+ }
+Index: src/tools/jalv2/jalv2.cpp
+===================================================================
+--- src/tools/jalv2/jalv2.cpp (révision 2927)
++++ src/tools/jalv2/jalv2.cpp (révision 2928)
+@@ -10,11 +10,11 @@
+
+ #include "jalv2_compile.h"
+ #include "jalv2_config.h"
++#include "jalv2_generator.h"
+ #include "devices/base/device_group.h"
+ #include "devices/pic/pic/pic_memory.h"
+ #include "devices/list/device_list.h"
+ #include "common/global/process.h"
+-#include "tools/jal/jal_generator.h"
+
+ //----------------------------------------------------------------------------
+ bool JALV2::Base::checkExecutableResult(Tool::ExecutableType, QStringList &lines) const
+@@ -64,5 +64,5 @@
+
+ Tool::SourceGenerator *JALV2::Group::sourceGeneratorFactory() const
+ {
+- return new JAL::SourceGenerator;
++ return new JALV2::SourceGenerator;
+ }
+Index: src/tools/jalv2/jalv2_generator.cpp
+===================================================================
+--- src/tools/jalv2/jalv2_generator.cpp (révision 0)
++++ src/tools/jalv2/jalv2_generator.cpp (révision 2928)
+@@ -0,0 +1,34 @@
++/***************************************************************************
++ * Copyright (C) 2012 Nicolas Hadacek <hadacek at kde.org> *
++ * *
++ * 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 "jalv2_generator.h"
++
++#include "devices/pic/base/pic.h"
++
++SourceLine::List JALV2::SourceGenerator::configLines(PURL::ToolType, const Device::Memory &, bool &) const
++{
++ // no config lines (?)
++ return SourceLine::List();
++}
++
++SourceLine::List JALV2::SourceGenerator::includeLines(PURL::ToolType, const Device::Data &data) const
++{
++ SourceLine::List lines;
++ lines.appendNotIndentedCode("include " + data.name().lower());
++ return lines;
++}
++
++SourceLine::List JALV2::SourceGenerator::sourceFileContent(PURL::ToolType, const Device::Data &, bool &) const
++{
++ SourceLine::List lines;
++ lines.appendTitle(i18n("main code"));
++ lines.appendNotIndentedCode(QString::null, "<< " + i18n("insert code") + " >>");
++ lines.appendNotIndentedCode("forever loop", i18n("loop forever"));
++ lines.appendNotIndentedCode("end loop");
++ return lines;
++}
+Index: src/tools/jalv2/jalv2_compile.cpp
+===================================================================
+--- src/tools/jalv2/jalv2_compile.cpp (révision 2927)
++++ src/tools/jalv2/jalv2_compile.cpp (révision 2928)
+@@ -33,8 +33,8 @@
+
+ void JALV2::CompileFile::logLine(::Process::OutputType, const QString &line)
+ {
+- if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*):([0-9]+):\\s*(warning)(.+)", 1, 2, 4, 3)) ) return;
+- if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*):([0-9]+):\\s*(.+)", 1, 2, 3, Log::LineType::Error)) ) return;
++ if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*):([0-9]+):\\s*(warning)(.+)", 1, 2, 4, 3, Log::LineType::Warning)) ) return;
++ if ( parseErrorLine(line, Compile::ParseErrorData("([^:]*):([0-9]+):\\s*(.+)", 1, 2, 3, -1, Log::LineType::Error)) ) return;
+ doLog(Log::LineType::Normal, line, QString::null, 0); // unrecognized
+ }
+
+Index: src/tools/jalv2/jalv2_generator.h
+===================================================================
+--- src/tools/jalv2/jalv2_generator.h (révision 0)
++++ src/tools/jalv2/jalv2_generator.h (révision 2928)
+@@ -0,0 +1,27 @@
++/***************************************************************************
++ * Copyright (C) 2012 Nicolas Hadacek <hadacek at kde.org> *
++ * *
++ * 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. *
++ ***************************************************************************/
++#ifndef JALV2_GENERATOR_H
++#define JALV2_GENERATOR_H
++
++#include "tools/base/tool_group.h"
++
++namespace JALV2
++{
++
++class SourceGenerator : public Tool::SourceGenerator
++{
++public:
++ virtual SourceLine::List configLines(PURL::ToolType type, const Device::Memory &memory, bool &ok) const;
++ virtual SourceLine::List sourceFileContent(PURL::ToolType type, const Device::Data &data, bool &ok) const;
++ virtual SourceLine::List includeLines(PURL::ToolType type, const Device::Data &data) const;
++};
++
++} // namespace
++
++#endif
+Index: src/tools/jalv2/CMakeLists.txt
+===================================================================
+--- src/tools/jalv2/CMakeLists.txt (révision 2927)
++++ src/tools/jalv2/CMakeLists.txt (révision 2928)
+@@ -6,6 +6,7 @@
+ jalv2_compile.cpp
+ jalv2_config.cpp
+ jalv2.cpp
++ jalv2_generator.cpp
+ )
+
+ automoc(${jalv2_STAT_SRCS})
+Index: src/common/global/process_kde.cpp
+===================================================================
+--- src/common/global/process_kde.cpp (révision 2927)
++++ src/common/global/process_kde.cpp (révision 2928)
+@@ -17,7 +17,8 @@
+ _kproc->setOutputChannelMode(KProcess::SeparateChannels);
+ connect(_kproc.get(), SIGNAL(readyReadStandardOutput()), SLOT(receivedStandardOutput()));
+ connect(_kproc.get(), SIGNAL(readyReadStandardError()), SLOT(receivedStandardError()));
+- connect(_kproc.get(), SIGNAL(stateChanged(QProcess::ProcessState)), SLOT(stateChanged(QProcess::ProcessState)));
++ connect(_kproc.get(), SIGNAL(error(QProcess::ProcessError)), SIGNAL(error()));
++ connect(_kproc.get(), SIGNAL(finished(int, QProcess::ExitStatus)), SIGNAL(finished()));
+ }
+
+ void Process::ProcessIO::setArguments(const QStringList &args)
+@@ -78,8 +79,3 @@
+ for (int i=0; i<data.size(); i++) _stderr[n+i] = data[i] != '\0' ? data[i] : ' ';
+ emit readyReadStderr();
+ }
+-
+-void Process::ProcessIO::stateChanged(QProcess::ProcessState state)
+-{
+- if (state == QProcess::NotRunning) emit processExited();
+-}
+Index: src/common/global/process_kde.h
+===================================================================
+--- src/common/global/process_kde.h (révision 2927)
++++ src/common/global/process_kde.h (révision 2928)
+@@ -28,12 +28,12 @@
+ private slots:
+ void receivedStandardOutput();
+ void receivedStandardError();
+- void stateChanged(QProcess::ProcessState);
+
+ signals:
+ void readyReadStdout();
+ void readyReadStderr();
+- void processExited();
++ void error();
++ void finished();
+
+ private:
+ std::auto_ptr<KProcess> _kproc;
+Index: src/common/global/process.cpp
+===================================================================
+--- src/common/global/process.cpp (révision 2927)
++++ src/common/global/process.cpp (révision 2928)
+@@ -23,7 +23,8 @@
+ _stopExecute(false)
+ {
+ _process = new ProcessIO(this);
+- connect(_process, SIGNAL(processExited()), SLOT(exitedSlot()));
++ connect(_process, SIGNAL(finished()), SLOT(finishedSlot()));
++ connect(_process, SIGNAL(error()), SLOT(errorSlot()));
+ connect(_process, SIGNAL(readyReadStdout()), SLOT(readyReadStdoutSlot()));
+ connect(_process, SIGNAL(readyReadStderr()), SLOT(readyReadStderrSlot()));
+ connect(&_timer, SIGNAL(timeout()), SLOT(timeoutSlot()));
+@@ -69,7 +70,7 @@
+ }
+
+ if ( !_process->start(env.isEmpty() ? 0 : &env) ) {
+- _state = StartFailed;
++ _state = Error;
+ return false;
+ }
+
+@@ -83,14 +84,21 @@
+ return _process->_kproc->exitCode();
+ }
+
+-void Process::Base::exitedSlot()
++void Process::Base::finishedSlot()
+ {
+ _timer.stop();
+ _state = Exited;
+ FOR_EACH(OutputType, type) readyRead(type);
+- emit done(exitCode());
++ emit done();
+ }
+
++void Process::Base::errorSlot()
++{
++ _timer.stop();
++ _state = Error;
++ emit error();
++}
++
+ void Process::Base::timeoutSlot()
+ {
+ kill();
+Index: src/common/global/process.h
+===================================================================
+--- src/common/global/process.h (révision 2927)
++++ src/common/global/process.h (révision 2928)
+@@ -27,7 +27,7 @@
+ //typedef Q3Process ProcessIO;
+
+ //----------------------------------------------------------------------------
+-enum State { Stopped, StartFailed, Running, Exited, Timedout, Killed };
++enum State { Stopped, Error, Running, Exited, Timedout, Killed, };
+
+ BEGIN_DECLARE_ENUM(OutputType)
+ Stdout = 0, Stderr
+@@ -55,7 +55,8 @@
+ bool execute(int msec); // -1 == no timeout
+
+ signals:
+- void done(int code);
++ void done();
++ void error();
+ void timeout();
+ void dataReceived(::Process::OutputType type);
+
+@@ -63,7 +64,8 @@
+ void kill();
+
+ protected slots:
+- void exitedSlot();
++ void finishedSlot();
++ void errorSlot();
+ void timeoutSlot();
+ void readyReadStdoutSlot() { readyRead(OutputType::Stdout); }
+ void readyReadStderrSlot() { readyRead(OutputType::Stderr); }
+Index: src/progs/custom/base/custom_prog.cpp
+===================================================================
+--- src/progs/custom/base/custom_prog.cpp (révision 2927)
++++ src/progs/custom/base/custom_prog.cpp (révision 2928)
+@@ -73,7 +73,7 @@
+ }
+ log(Log::LineType::Command, _process->arguments().join(" "));
+ Process::State state = Process::runSynchronouslyDialog(*_process, i18n("Executing '%1' command...").arg(action));
+- if (state == Process::StartFailed) {
++ if (state == Process::Error) {
+ log(Log::LineType::Error, i18n("*** Error executing command ***"));
+ return false;
+ }
+Index: Changelog
+===================================================================
+--- Changelog (révision 2927)
++++ Changelog (révision 2928)
+@@ -1,3 +1,8 @@
++0.16.2 (3 July 2012)
++* fixed toolchain output when executable cannot be found
++* fixed parsing for jalv2 [reported by biglacko]
++* fixed template generator for jalv2
++
+ 0.16.1 (1 July 2012)
+ * fixed command-line utilities compilation with Qt only
+ * fixed command-line utilities compilation on Windows
diff --git a/piklab-0.16.1-retry-icd2-serial-10-times.rev2931.patch b/piklab-0.16.1-retry-icd2-serial-10-times.rev2931.patch
new file mode 100644
index 0000000..ea73447
--- /dev/null
+++ b/piklab-0.16.1-retry-icd2-serial-10-times.rev2931.patch
@@ -0,0 +1,46 @@
+Index: src/progs/icd2/base/icd2_serial.cpp
+===================================================================
+--- src/progs/icd2/base/icd2_serial.cpp (révision 2930)
++++ src/progs/icd2/base/icd2_serial.cpp (révision 2932)
+@@ -31,16 +31,27 @@
+ {
+ if ( !static_cast<SerialPort *>(_port)->open(Port::Serial::S19200) ) return false;
+ if ( !reset() ) return false;
++ log(Log::DebugLevel::Max, QString("Send: \"%1\"").arg("Z"));
+ if ( !_port->send("Z", 1) ) return false;
+ QString s;
+ if ( !_port->receive(4, s) ) return false;
++ log(Log::DebugLevel::Max, QString("Received: \"%1\"").arg(s));
++
+ if ( !reset() ) return false;
+- QByteArray a = toAscii(mode);
+- if ( !_port->send(a.data(), a.count()) ) return false;
+- if ( !_port->receive(1, s) ) return false;
+- if ( s.upper()!=mode ) {
+- log(Log::LineType::Error, i18n("Failed to set port mode to '%1'.").arg(mode));
+- return false;
++ for (uint i = 0; ; ++i) {
++ const QByteArray a = toAscii(mode);
++ log(Log::DebugLevel::Max, QString("Send: \"%1\"").arg(mode));
++ if ( !_port->send(a.data(), a.count()) ) return false;
++ if ( !_port->receive(1, s) ) return false;
++ log(Log::DebugLevel::Max, QString("Received: \"%1\"").arg(s));
++ if ( s.upper()==mode ) {
++ break;
++ }
++ if (i == 10) {
++ log(Log::LineType::Error, i18n("Failed to set port mode to '%1'.").arg(mode));
++ return false;
++ }
++ Port::msleep(100);
+ }
+ //log(Log::Debug, "set fast speed");
+ //if ( !setFastSpeed() ) return false;
+@@ -49,6 +60,7 @@
+
+ bool Icd2::SerialHardware::reset()
+ {
++ log(Log::DebugLevel::Max, QString("Reset icd2 serial port"));
+ static_cast<Port::Serial *>(_port)->setPinOn(Port::Serial::DTR, false, Port::PositiveLogic); // Trigger DTR to reset icd2
+ Port::msleep(10);
+ static_cast<Port::Serial *>(_port)->setPinOn(Port::Serial::DTR, true, Port::PositiveLogic); // remove reset
diff --git a/sources b/sources
index 8a57aae..f70048a 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-7fa372b967e8a38108073bdaa80f1798 piklab-0.15.12.tar.bz2
+c8e33f5d7485fcb9877def78492cd5af piklab-0.16.1.tar.bz2
More information about the scm-commits
mailing list