File: tzset.3

package info (click to toggle)
manpages-ja 0.5.0.0.20050315-1
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 18,620 kB
  • ctags: 4
  • sloc: sh: 12,675; perl: 157; makefile: 106
file content (210 lines) | stat: -rw-r--r-- 7,074 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
.\" Copyright 1993 David Metcalfe (david@prism.demon.co.uk)
.\"
.\" Permission is granted to make and distribute verbatim copies of this
.\" manual provided the copyright notice and this permission notice are
.\" preserved on all copies.
.\"
.\" Permission is granted to copy and distribute modified versions of this
.\" manual under the conditions for verbatim copying, provided that the
.\" entire resulting derived work is distributed under the terms of a
.\" permission notice identical to this one.
.\" 
.\" Since the Linux kernel and libraries are constantly changing, this
.\" manual page may be incorrect or out-of-date.  The author(s) assume no
.\" responsibility for errors or omissions, or for damages resulting from
.\" the use of the information contained herein.  The author(s) may not
.\" have taken the same level of care in the production of this manual,
.\" which is licensed free of charge, as they might when working
.\" professionally.
.\" 
.\" Formatted or processed versions of this manual, if unaccompanied by
.\" the source, must acknowledge the copyright and authors of this work.
.\"
.\" References consulted:
.\"     Linux libc source code
.\"     Lewine's _POSIX Programmer's Guide_ (O'Reilly & Associates, 1991)
.\"     386BSD man pages
.\" Modified Sun Jul 25 11:01:58 1993 by Rik Faith (faith@cs.unc.edu)
.\" Modified 2001-11-13, aeb
.\" Modified 2004-12-01 mtk and Martin Schulze <joey@infodrom.org>
.\"
.\" Japanese Version Copyright (c) 1998 NAKANO Takeo all rights reserved.
.\" Translated Sat 23 Mar 1998 by NAKANO Takeo <nakano@apm.seikei.ac.jp>
.\" Updated Fri Sep 14 2000 by Kentaro Shirakata <argrath@ub32.org>
.\" Updated Sun 6 Jan 2002 by NAKANO Takeo
.\"
.\" WORD:	Wall Clock Time			ɻ׻
.\" WORD:	Coordinated Universal Time	
.\" WORD:	daylight saving(s) time		ޡ
.\" WORD:	Prime Meridian			˥åҸ
.\"
.TH TZSET 3  2001-11-13 "" "Linux Programmer's Manual"
.SH ̾
tzset, tzname, timezone, daylight \- Ѵ
.SH 
.nf
.B #include <time.h>
.sp
.B void tzset (void);
.sp
.BI "extern char *" tzname [2];
.BI "extern long " timezone ;
.BI "extern int " daylight ;
.fi
.SH 
\fBtzset()\fP ؿ TZ ĶѿѤ \fItzname\fP ѿ롣
δؿϡॾ˰¸¾λѴؿ鼫ưŪ˸ƤӽФ롣
SysV ŪʴĶǤϡδؿѿ \fItimezone\fP (GMT ÿ) 
\fIdaylight\fP (Υॾ˥ޡ˴ؤ롼뤬ʤ 0
ޡ֤ǯΤɤˤ 0 ʳ) ꤹ롣
.PP
TZ ĶѿꤵƤʤˤϡ
\fItzname\fP ѿϥɻ׻ (wall clock time) 
Ǥᤤͤ˽롣
Υɻ׻ȤƤϡ
ƥΥॾǥ쥯ȥ () ˤ
.BR tzfile (5)
Υե \fIlocaltime\fP ǻꤵƤͤѤ롣
(κݤˤ
.I /etc/localtime
褯Ѥ롣
ϥƥΥॾǥ쥯ȥˤ
ŬڤʥեؤΥܥå󥯤ˤʤäƤ롣)
.PP
TZ Ķѿ¸ߤƤ뤬ͤäꡢ
ʲ˼Τɤˤ⤢ƤϤޤʤϡ
 (Coordinated Universal Time: UTC) Ѥ롣
.PP
TZ ͤϰʲ 3 ĤηΤ줫뤳ȤǤ롣
ǽηϥޡ (daylight saving time)
ʤ륿ॾФѤ롣
.sp
.RS
.I std offset
.RE
.sp
\fIstd\fP ʸϥॾ̾ꤹ롣
ե٥åȤʤ 3 ʸʾʸǤʤФʤʤ
\fIoffset\fP ʸ \fIstd\fP ľ³
 (UTC) 뤿
ʻ˲äʤФʤʤ֤ꤹ롣
.I offset
ϡ륿ॾ󤬥˥åҸ (Prime Meridian)
ʤ͡ʤͤ롣
 (hour)  0  24 δ֤ǤʤФʤʤ
ʬ (minute)  (second)  0  59 δ֤ǤʤФʤʤ
.PP
2 ܤηϥޡबѤ롣
.sp
.RS
.I std offset dst [offset],start[/time],end[/time]
.RE
.sp
ˤϥڡޤƤϤʤʤ
Ƭ \fIstd\fP  \fIoffset\fP  1 ܤηƱǡ
ɸΥॾꤹ롣
\fIdst\fP ʸ \fIoffset\fP ϡ
б륵ޡॾ̾ȥեåȤꤹ롣
եåȤάȡǥեȤǤɸΰȤʤ롣
.PP
\fIstart\fP եɤϥޡबͭˤʤ
\fIend\fP եɤɸǤ롣
Υեɤϰʲηǻꤹ롣
.TP
J\fIn\fP
ǯ (Julian day) ˤꤹ롣
\fIn\fP  1  365 δ֤ο͡
뤦ǯξǤ 2  29 ϥȤʤ
.TP 
.I n
ǯˤꤹ롣
\fIn\fP  1  365 δ֤ο͡
뤦ǯξˤ 2  29 Ȥ롣
.TP 
M\fIm\fP.\fIw\fP.\fId\fP
\fIm\fP Ϸ (1 <= \fIm\fP <= 12) 
\fIw\fP ϷΤν (1 <= \fIw\fP <= 5) 
\fId\fP ϽΤˤ (0 <= \fId\fP <= 6) 򼨤
\fIw\fP = 1 Ͻ° \fId\fP ¸ߤǽν
\fIw\fP = 5 ϺǸνǤ롣
\fId\fP = 0 Ǥ롣  
.PP
\fItime\fP եɤϡ륿ڤؤ
ѹΥ륿ɽΤǤ롣
ά줿ΥǥեȤ 02:00:00 Ǥ롣
.PP
3 ܤηϡॾξե뤫ɤ߹褦˻ꤹ롣
.sp
.RS
:[filespec]
.RE
.sp
եλ \fIfilespec\fP ά줿ϡ
ॾξϥƥॿॾǥ쥯ȥ
.I localtime
ե뤫ɤޤ롣
ǶǤϥƥॿॾǥ쥯ȥ
.I /usr/share/zoneinfo/localtime
Ǥ롣
Υե
.BR tzfile (5)
ǽ񤫤Ƥ롣 
\fIfilespec\fP Ϳ줿ϡ
ॾξ򤽤Υե뤫ɤ߹ࡣΥե
.BR tzfile (5)
ǽ񤫤Ƥɬפ롣
\fIfilespec\fP  `/' ǻϤޤʤäˤϡ
ƥॿॾǥ쥯ȥ꤫Хѥ
ե뤬ꤵ줿Ȥˤʤ롣
.SH ե
Ѥ륷ƥॿॾǥ쥯ȥ (g)libc ΥС˰¸롣
libc4  libc5  
.I /usr/lib/zoneinfo
Ѥ롣libc-5.4.6 ʹߤǤϡ줬Ȥʤäˤ
.I /usr/share/zoneinfo
ȤȤ롣
glibc2 ǤϴĶѿ TZDIR ¸ߤФѤ롣
ΥǥեȤϤɤΤ褦˥󥹥ȡ뤵줿ˤ뤬
̤
.I /usr/share/zoneinfo
Ǥ롣
.LP
Υॾǥ쥯ȥˤϰʲΥե뤬ޤޤ롣
.sp
.nf
localtime      륿ॾΥե
posixrules     POSIX  TZ 񼰥롼
.fi
.LP
.I /etc/localtime
ϡ
.I localtime
ե䡢
ƥΥॾǥ쥯ȥŬڤʥॾեؤ
ܥå󥯤Ǥ뤳Ȥ¿
.SH 
SVID 3, POSIX, 4.3BSD
.SH 
.I daylight
ѿϡߤޡǤ뤫ɤ򼨤ƤΤǤϤʤ
ϤĤ륢르ꥺΤֹͿ
(르ꥺˤĤƤ
.BR gettimeofday (2)

.I tz_dsttime
ѿ򸫤)
Ϥ⤦ǯȤƤʤSUSv2 ǤɬפȤƤ롣
.LP
4.3BSD ˤ
.BI "char *timezone(" zone ", " dst )
Ȥ롼󤬤ꡢ
ǽΰ (GMT ʬ) б륿ॾ֤̾
ܤΰ 0 ξɸ̾Ѥ졢
ʳϥޡǤ̾Ѥ롣
.SH Ϣ
.BR date (1),
.BR gettimeofday (2),
.BR time (2),
.BR ctime (3),
.BR getenv (3),
.BR tzfile (5)