OS X: Fix Argentina DST October 2009

Date%20&%20TimeWell, at almost the last minute, DST was cancelled in Argentina this year. And this broke things, mostly computers. (Not for the first time either, the same thing happened two years ago here).

The debian folk came out with a fix at the last minute: so that fixed the linux machines, but OS X is a slower beast to move, so it’ll be a while before any change works its way through. In the meantime, Mac users in Argentina are left with broken clocks.

If you just want your clock to show the correct time for Argentina again, and don’t really care about the why, then just download and install the following:
Argentina_DST_Update_2.pkg – for 10.6.x only!
(Updated 2010-03-15)

I am no Mac expert, and this isn’t entirely tested, so be warned.

Anywho, this is how to update the tz data (aka zoneinfo), which should, in theory, fix the problem:

mkdir tzfix
cd tzfix/
curl ftp://elsie.nci.nih.gov/pub/tzdata2009n.tar.gz | tar -zxvf -
vi +219 southamerica

Change the two lines:

Rule Arg 2008 max - Mar Sun>=15 0:00 0 -
Rule Arg 2008 max - Oct Sun>=15 0:00 1:00 S

to the following

Rule Arg 2008 2009 - Mar Sun>=15 0:00 0 -
Rule Arg 2008 only
- Oct Sun>=15 0:00 1:00 S

(i.e. just two words to change). If it makes you feel better, here’s a diff.

Ok, save & close, and then compile it as follows:

sudo zic southamerica
sudo cp /usr/share/zoneinfo/America/Argentina/Buenos_Aires /usr/share/zoneinfo/America/Buenos_Aires

The sudo is necessary because you’re changing /usr/share/zoneinfo.
And that’s mostly it. Verify that it worked as follows:

zdump America/Argentina/Buenos_Aires
America/Argentina/Buenos_Aires Sun Oct 18 20:43:42 2009 ART

(note that the timezone is now ART, not ARST as previously).

So that fixes things for most of the command-line stuff. But you’ll notice that the clock on your desktop, iCal, and others, are still incorrect. We need to fix the ICU database also. Thankfully the latest sources are available for this from apple itself:

curl -O http://www.opensource.apple.com/tarballs/ICU/ICU-400.37.tar.gz
tar -zxf ICU-400.37.tar.gz
cd ICU-400.37/icuSources

ICU doesn’t come with the tzdata, but the readme in tzcode helpfully notes that if we place the tzdata*.tar.gz file in tools/tzcode/ it will be compiled automatically. You can pack up your own tzdata2009n.tar.gz that we used earlier if you wish, or use the one I prepared here:

cd tools/tzcode/
curl -o
tzdata2009o.tar.gz http://brickybox.com/wp-content/uploads/2009/10/tzdata2009otar.gz
cd ../../
./runConfigureICU MacOSX --with-data-packaging=archive
sudo install -o root -g wheel -m 0644 -Sp data/out/icudt40l.dat /usr/share/icu/icudt40l.dat

And that’s it. We have a new ICU database. Reboot to see the changes.

Update (21st October): This technique works on the iPhone too. The iPhone already has zic (well, at least my one has), so you can simply copy your modified southamerica file onto the phone somewhere, and run (as root):

zic southamerica
cp /usr/share/zoneinfo/America/Argentina/Buenos_Aires /usr/share/zoneinfo/America/Buenos_Aires

And you can simply copy the data/out/icudt40l.dat you created for OS X into /usr/share/icu/icudt40l.dat on the iPhone. It causes Springboard to crash, but after a reboot everything works perfectly.

Update (10th November): I can’t believe it, today 10.6.2 update broke the damn icu stuff again.

mkdir 10_6_2_fix
cd 10_6_2_fix/
curl -O http://www.opensource.apple.com/tarballs/ICU/ICU-400.37.tar.gz
tar -zxf ICU-400.37.tar.gz
cd ICU-400.37/icuSources/tools/tzcode/
curl -O ftp://elsie.nci.nih.gov/pub/tzdata2009r.tar.gz
cd ../../
sudo install -o root -g wheel -m 0644 -Sp data/out/icudt40l.dat /usr/share/icu/icudt40l.dat

Thanks to Jonathan Tapicer for pointing out that the tzdata file name has been updated (now at version R).

Update (5th February): I’ve had several requests to package this up in an installer, so here goes:
Argentina_DST_Update.pkg – for 10.6.x only!
(I don’t have a 10.5.8 any longer, so I can’t compile for it, sorry)

Update (15th March 2010): Yes, the ICU fix is broken again today. The problem seems to be more to do with automatic timezone detection (which OS X is now seeing as GMT -4) than anything to do with zoneinfo. For now, to fix it:

  • Download and install the new Argentina_DST_Update_2.pkg – for 10.6.x only!
  • Open a terminal and type:
    systemsetup -setusingnetworktime off
    systemsetup -settimezone America/Argentina/Buenos_Aires

This is fairly straightforward: it disables automatic timezone detection, and sets the timezone manually (you can use the -listtimezones switch to see a list of available timezones). If anyone knows how to update DateAndTime.prefPane (which appears to use GeoKit) please let me know.

Update (4th April 2010): I’m pleased to announce that 10.6.3 includes updated tzdata for Argentina (and elsewhere) that fixes all this silliness. Get it now (via software update) to make this problem go away.

, , ,

  1. #1 by Frederic on October 24, 2009 - 11:26 am

    Thanks for this!

    I am running windows and was wondering how to get the data/out/icudt40l.dat file to copy on my iphone.

    Can you help me ?



  2. #2 by Bricky on October 27, 2009 - 1:27 pm

    The only way that I know is via ssh (on a jailbroken iphone). You can then
    scp data/out/icudt40l.dat root@your-iphone-ip-address:/usr/share/icu/icudt40l.dat
    to copy the file across.

    I guess you could probably do something using the iphone sdk tools too. Wouldn’t know where to start there though.

  3. #3 by Adrian M. on October 29, 2009 - 7:34 pm

    On 10.6 you could select Mendoza time which maps to ART (instead of ARST for Buenos Aires).

  4. #4 by Lionel on November 5, 2009 - 12:01 am

    @ Bricky
    Could you share the icudt40l.dat for my iphone? I need to fix my Argentina time but I don’t have MacOS.


  5. #5 by Bricky on November 5, 2009 - 3:15 pm



    This is the one I compiled on my mac (and subsequently put on the iPhone).


  6. #6 by Diego on November 5, 2009 - 8:33 pm

    I’ve run all the commands and nothing happens.
    This is what i see in Terminal:

    Snow:~ diego$ zdump America/Argentina/Buenos_AiresAmerica/Argentina/Buenos_Aires Thu Nov 5 19:16:49 2009 ART
    Snow:~ diego$

    But whe i try to change the Time zone in the System Preferences:

    Argentina Summer Time (GMT-02:00)

    and all my calendar applications show the hour wrong.
    If I choose Mendoza (in 10.6.1 is GMT-03:00), like Adrian said, when I recieve an invitation from Buenos Aires TZ, it creates with 1 hour difference.

    what can I do???
    BTW: I’ve copied the icudt40l.dat that you left for Lionel, but when reboot the finder relaunches constantly, so i reinstall the one that I’ve created.

  7. #7 by Bricky on November 6, 2009 - 10:56 am

    Hi Diego,

    There are a few things you can check.
    First, make certain that the icudt40l.dat file is not corrupted in any way:
    $ md5 icudt40l.dat
    MD5 (icudt40l.dat) = 252258445190565a121f7ebf356279b4

    If the md5 isn’t exactly the same, try downloading the file again.
    Next thing to check is the permissions. These should be:
    $ ls -alF /usr/share/icu/icudt40l.dat
    -rw-r--r-- 1 root wheel 13993024 21 Oct 17:49 /usr/share/icu/icudt40l.dat

    If these aren’t correct, you can fix them with chmod 0644, and chown root:wheel.


  8. #8 by Jonathan Tapicer on November 8, 2009 - 4:54 pm

    Hi, it works, thanks. ftp://elsie.nci.nih.gov/pub/tzdata2009n.tar.gz doesn’t exist anymore, you should change it to the new version of tzdata (2009q): ftp://elsie.nci.nih.gov/pub/tzdata2009q.tar.gz

  9. #9 by Lionel on November 10, 2009 - 9:17 am

    @ Bricky

    Thank you very much for the file! Works perfect!!!!

    Best Regards,


  10. #10 by Pablo on January 25, 2010 - 2:24 am

    Hi, reading this post I cloud change time correctly.

    $ zdump America/Argentina/Buenos_Aires
    America/Argentina/Buenos_Aires Mon Jan 25 02:07:44 2010 ART

    (no ARST time)

    But, when I enter the next commands, this is what I get:

    $ ./runConfigureICU MacOSX –with-data-packaging=archive
    Running ./configure –with-data-packaging=archive for MacOS X (Darwin) using the GNU C++ compiler

    checking for ICU version numbers… release 4.0, library 40.0
    checking build system type… i386-apple-darwin9.8.0
    checking host system type… i386-apple-darwin9.8.0
    checking for gcc… no
    checking for cc… no
    checking for cc… no
    checking for cl… no
    configure: error: no acceptable C compiler found in $PATH
    See `config.log’ for more details.

    If the result of the above commands looks okay to you, go to the directory
    source in the ICU distribution to build ICU. Please remember that ICU needs
    GNU make to build properly…

    I’m new to MacOS, so please tell me what I have to do.

    Thank you.



  11. #11 by Bricky on January 25, 2010 - 3:00 am

    Hi Pablo,

    You’ll need to download and install Xcode to compile ICU.


  12. #12 by Pablo on January 25, 2010 - 9:41 am

    @ Bricky
    Hi Bricky, thanks for your help.

    The strange thing is that I have wrong time only on the Menu Bar. Correct time is showed on my widgets and, on the zdump.

    Do you think I have to compile ICU? Is this the only way? I’m asking because I never compile a thing.

    Right now I’m downloading the Xcode (w/ iPhone sdk). I think this is what I need for my MacOS10.5.8.
    Can you send me the rights commands?

    Thanks again,


  13. #13 by Pablo on January 25, 2010 - 1:12 pm

    @ Bricky

    I installed Xcode and run these commands:
    ./runConfigureICU MacOSX –with-data-packaging=archive
    sudo install -o root -g wheel -m 0644 -Sp data/out/icudt40l.dat /usr/share/icu/icudt40l.dat

    Then I restarted my Mac and still have the wrong time.

    I don’t know what is happening, can you help me, please?


  14. #14 by Bricky on January 27, 2010 - 6:03 pm

    The instructions above are for 10.6 Pablo, I’m not sure if they’ll work the same for 10.5.8.

    I’d suggest you first check if the new ICU was installed correctly, run the following
    ls -l /usr/share/icu/icudt40l.dat
    if it says “No such file or directory”, or if the date on the file is wrong (not the date you compiled it), then that’s the problem.

    Maybe try downloading the ICU tarball for 10.5.8 instead

    curl -O http://www.opensource.apple.com/tarballs/ICU/ICU-8.11.4.tar.gz
    And proceed with the remainder of the instructions as above. I don’t know if it’ll work, but you may have better luck.

  15. #15 by Pablo on January 30, 2010 - 4:50 pm

    @ Bricky

    Thank you very much! It worked perfect!
    I was looking for a solution since three weeks.

    Thanks again…

  16. #16 by Gon on February 4, 2010 - 10:57 pm

    @ Bricky
    Sorry for bothering but I’m having this huge problem and I don’t know how to fix it. I read your instructions but I’m not familiarized with these sort of codes. All the instructions I need to type them in “Terminal” at a time? I’ll be very thankfull if you can help me with this and sorry for my ignorance.

    Thanks in advance!

  17. #17 by Bricky on February 5, 2010 - 6:56 am


    I’ve packaged this up as an installer Gon, try that.

  18. #18 by Gon on February 6, 2010 - 1:12 pm

    @ Bricky
    I really don’t know how to thank you. It works perfect and it was very extremely simple. THANK YOU VERY MUCH!!!

  19. #19 by Matias on November 29, 2010 - 3:00 am

    Dude, you rock! I’ve been struggling with this for a long time… I owe you a chilled Quilmes, at the least!

  20. #20 by damian on January 14, 2011 - 12:08 pm

    que loco, apple sigue con este problema en ipad, iphones, ipod touch, habra alguna manera de pedirles que lo actualizen en iOS 4.3 ?

  21. #21 by damian on January 17, 2011 - 12:22 pm

    try it on one of my servers, 10.5.8, and i only can use ICU-8.11.4.tar.gz woks perfect, remains iphone, ipad, etc without jailbreak!

(will not be published)