On Thu, 11 Apr 2002, Thomas R Wyant_III wrote:
> I believe that the output of the time () function is what you want. Do not
> conclude that it is two hours off because CygWin prints 16:04 when your
> clock says 18:04. What this means is that CygWin and Perl do not know what
> time zone you are in.
>
> The output of
>
> C:\>perl -e "print scalar gmtime 1018541088"
> Thu Apr 11 16:04:48 2002
> C:\>perl -e "print scalar localtime 1018541088"
> Thu Apr 11 12:04:48 2002
> C:\>rem I'm in time zone -5, but it's summer time here.
>
> suggests that Perl and CygWin think you are in time zone 0.
that's it! It was bad configured. What I did is set the environment
variable TZ to what Markus Hoenicka told me:
C:\>set | grep TZ
TZ=CET-1CEST
And now works date.exe (cygwin) and time() in perl!!
Now it makes me wonder if perl needs TZ environment variable to show
time() in localtime.
>
> The thing is, the output of "time /t" suggests your net time zone is -2. I
> thought Spain was -1, but summer time should bring it back to 0. If you're
> actually in Spain, you might want to check your date/time control panel,
> and see what time zone it thinks you're in.
>
> Also, you might want to see if you have the TZ environment variable defined
> incorrectly. If so, either define it correctly or get rid of it. Perl and
> CygWin (both being Unix-y kinds of things) pay attention to this, but
> Windows native code frequently does not. This messed me up badly last
> November.
Then TZ variable is listened by perl?
Thanks a lot.
m4c.
_______________________________________________
Perl-Win32-Admin mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs