In IDE 1:1.0.5+dsfg2.2 (on a Linux laptop), I get the following error:
In file included from /home/mint/sketchbook/libraries/Time/DateStrings.cpp:10:0:
/home/mint/sketchbook/libraries/Time/DateStrings.cpp:18:18: error: variable ‘monthStr1’ must be const in order to be put into read-only section by means of ‘attribute((progmem))’
char monthStr1[] PROGMEM = "January";
This error is repeated for each month name and day name, plus two more times for strings.
I do not get this error in when I compile in 1.6.4, using the same libraries. It's beyond me to understand why the earlier complier sees the month/day names as variables and the 1.6.4 version does not. Have I missed including some library in my 1.0.5 install?
I'd just use 1.6.4, but currently it has problem uploading (another topic).
Your 1.0.5 IDE came from your Linux distro's repository. It is unlikely that it has the same compiler and toolchain that Arduino furnished. They will have "improved" things by using the latest avr-gcc release. In the IDE turn on verbose output (File/Preferences) and you can see which compiler they are using. If you want the old compiler use the tarball from:
This fixes the source code:
DateStrings.cpp
Line 41.
From: PGM_P monthNames_P[] PROGMEM =
To: PGM_P const monthNames_P[] PROGMEM =
Line 58.
From: PGM_P dayNames_P[] PROGMEM =
To: PGM_P const dayNames_P[] PROGMEM =
Line 59.
From: char dayShortNames_P[] PROGMEM =
To: const char dayShortNames_P[] PROGMEM =
There must be several versions of DateStrings.ccp circulating. None of my copies had anything like you posted at those line numbers, or even within a few lines, plus or minus. But it did get me thinking. I had several copies that had "const" in the variable declaration lines, but not in the copy that was in the library.
Cleaned up all my libraries, got the new version of DateStrings.ccp in the Time.h library, and, viola, compilation proceeded without error.