4 messages in net.sourceforge.lists.courier-sqwebmailRe: [sqwebmail] sv-make_timezonelist....
FromSent OnAttachments
Timothy Lee RodenNov 28, 2006 11:47 am 
Timothy Lee RodenNov 28, 2006 11:51 am 
Sam VarshavchikNov 28, 2006 3:17 pm 
Timothy Lee RodenNov 28, 2006 3:50 pm 
Actions with this message:
Paste this link in email or IM:
Paste this link in email or IM:
Atom feed for this thread
Paste this URL into your reader:
Subject:Re: [sqwebmail] sv-make_timezonelist.pl now with NetBSD support!Actions...
From:Timothy Lee Roden (di@nixsys.bz)
Date:Nov 28, 2006 3:50:38 pm
List:net.sourceforge.lists.courier-sqwebmail

On Tue, Nov 28, 2006 at 06:18:16PM -0500, Sam Varshavchik wrote:

Timothy Lee Roden writes:

Hello again,

I'm far from fluent in PERL; however, this seems to work:

diro@asche% diff sv-make_timezonelist.pl new_sv-make_timezonelist.pl

Do it again, this time with the -U 3 option.

diro@asche% diff -U 3 sv-make_timezonelist.pl new_sv-make_timezonelist.pl --- sv-make_timezonelist.pl 2005-05-06 16:20:49.000000000 +0000 +++ new_sv-make_timezonelist.pl 2006-11-28 19:38:04.000000000 +0000 @@ -55,6 +55,10 @@ { $iso3166tab = "/usr/share/misc/iso3166"; } +elsif ( $^O eq "netbsd" ) +{ + $iso3166tab = "/usr/share/misc/domains" +} else { $iso3166tab = "$zoneinfo_dir/iso3166.tab"; @@ -90,8 +94,17 @@ # Correct the entry for GB. $countries{GB} = 'United Kingdom';

-open(ZONES, $zonetab) || - die "Could not open '$zonetab' for reading ($!)\n"; +if ( open(ZONES, $zonetab) == 0 ) +{ + if ( $^O eq "netbsd" ) + { + die "Could not open '$zonetab' for reading ($!). Currently, NetBSD does not install zone.tab by default. You must manually fetch sharesrc.tgz from the source of your version and extract zone.tab into /usr/share/zoneinfo\n"; + } + else + { + die "Could not open '$zonetab' for reading ($!)\n"; + } +} @lines = <ZONES>; close(ZONES);

!tr