Show original line number for error messages

This commit is contained in:
Adam Dunlap 2012-08-17 11:50:05 -07:00 committed by Sudar
parent 3afe25ba5a
commit 9ebae306d0
2 changed files with 4 additions and 2 deletions

View file

@ -118,6 +118,7 @@ The following are the list of changes that I have made or merged in this fork. H
### 0.10.2 15.xii.2012 Sudar
- Added sketch size verification. (https://github.com/fornellas)
- Show original line number for error messages (https://github.com/WizenedEE)
## Know Issues
- Because of the way the makefile is structured, the configuration parameters gets printed twice.

View file

@ -143,6 +143,7 @@
#
# 0.10.2 15.xii.2012 Sudar
# - Added sketch size verification. (https://github.com/fornellas)
# - Show original line number for error messages (https://github.com/WizenedEE)
#
########################################################################
#
@ -812,12 +813,12 @@ $(OBJDIR)/%.d: %.s $(COMMON_DEPS)
# We should check for Arduino version, if the file is .pde because a .pde file might be used in Arduino 1.0
# the pde -> cpp -> o file
$(OBJDIR)/%.cpp: %.pde $(COMMON_DEPS)
$(ECHO) '#if ARDUINO >= 100\n #include "Arduino.h"\n#else\n #include "WProgram.h"\n#endif' > $@
$(ECHO) '#if ARDUINO >= 100\n #include "Arduino.h"\n#else\n #include "WProgram.h"\n#endif\n#line 1' > $@
$(CAT) $< >> $@
# the ino -> cpp -> o file
$(OBJDIR)/%.cpp: %.ino $(COMMON_DEPS)
$(ECHO) '#include <Arduino.h>' > $@
$(ECHO) '#include <Arduino.h>\n#line 1' > $@
$(CAT) $< >> $@
$(OBJDIR)/%.o: $(OBJDIR)/%.cpp $(COMMON_DEPS)