| 1 |
27 |
unneback |
# ====================================================================
|
| 2 |
|
|
#
|
| 3 |
|
|
# time.cdl
|
| 4 |
|
|
#
|
| 5 |
|
|
# C library time related configuration data
|
| 6 |
|
|
#
|
| 7 |
|
|
# ====================================================================
|
| 8 |
|
|
#####ECOSGPLCOPYRIGHTBEGIN####
|
| 9 |
|
|
## -------------------------------------------
|
| 10 |
|
|
## This file is part of eCos, the Embedded Configurable Operating System.
|
| 11 |
|
|
## Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc.
|
| 12 |
|
|
##
|
| 13 |
|
|
## eCos is free software; you can redistribute it and/or modify it under
|
| 14 |
|
|
## the terms of the GNU General Public License as published by the Free
|
| 15 |
|
|
## Software Foundation; either version 2 or (at your option) any later version.
|
| 16 |
|
|
##
|
| 17 |
|
|
## eCos is distributed in the hope that it will be useful, but WITHOUT ANY
|
| 18 |
|
|
## WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
| 19 |
|
|
## FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
| 20 |
|
|
## for more details.
|
| 21 |
|
|
##
|
| 22 |
|
|
## You should have received a copy of the GNU General Public License along
|
| 23 |
|
|
## with eCos; if not, write to the Free Software Foundation, Inc.,
|
| 24 |
|
|
## 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
|
| 25 |
|
|
##
|
| 26 |
|
|
## As a special exception, if other files instantiate templates or use macros
|
| 27 |
|
|
## or inline functions from this file, or you compile this file and link it
|
| 28 |
|
|
## with other works to produce a work based on this file, this file does not
|
| 29 |
|
|
## by itself cause the resulting work to be covered by the GNU General Public
|
| 30 |
|
|
## License. However the source code for this file must still be made available
|
| 31 |
|
|
## in accordance with section (3) of the GNU General Public License.
|
| 32 |
|
|
##
|
| 33 |
|
|
## This exception does not invalidate any other reasons why a work based on
|
| 34 |
|
|
## this file might be covered by the GNU General Public License.
|
| 35 |
|
|
##
|
| 36 |
|
|
## Alternative licenses for eCos may be arranged by contacting Red Hat, Inc.
|
| 37 |
|
|
## at http://sources.redhat.com/ecos/ecos-license/
|
| 38 |
|
|
## -------------------------------------------
|
| 39 |
|
|
#####ECOSGPLCOPYRIGHTEND####
|
| 40 |
|
|
# ====================================================================
|
| 41 |
|
|
######DESCRIPTIONBEGIN####
|
| 42 |
|
|
#
|
| 43 |
|
|
# Author(s): jlarmour
|
| 44 |
|
|
# Contributors:
|
| 45 |
|
|
# Date: 2000-04-14
|
| 46 |
|
|
#
|
| 47 |
|
|
#####DESCRIPTIONEND####
|
| 48 |
|
|
#
|
| 49 |
|
|
# ====================================================================
|
| 50 |
|
|
|
| 51 |
|
|
cdl_package CYGPKG_LIBC_TIME {
|
| 52 |
|
|
display "ISO C library date and time functions"
|
| 53 |
|
|
description "
|
| 54 |
|
|
This package provides time functions specified by the
|
| 55 |
|
|
ISO C standard - ISO/IEC 9899:1990."
|
| 56 |
|
|
doc ref/libc.html
|
| 57 |
|
|
include_dir cyg/libc/time
|
| 58 |
|
|
parent CYGPKG_LIBC
|
| 59 |
|
|
implements CYGINT_ISO_C_TIME_TYPES
|
| 60 |
|
|
implements CYGINT_ISO_C_CLOCK_FUNCS
|
| 61 |
|
|
requires { CYGBLD_ISO_C_TIME_TYPES_HEADER == "" }
|
| 62 |
|
|
requires { CYGBLD_ISO_C_CLOCK_FUNCS_HEADER == \
|
| 63 |
|
|
"" }
|
| 64 |
|
|
requires CYGPKG_ISOINFRA
|
| 65 |
|
|
requires CYGINT_ISO_DIV
|
| 66 |
|
|
requires CYGINT_ISO_ABS
|
| 67 |
|
|
|
| 68 |
|
|
compile asctime.cxx clock.cxx \
|
| 69 |
|
|
ctime.cxx difftime.cxx \
|
| 70 |
|
|
gmtime.cxx localtime.cxx \
|
| 71 |
|
|
mktime.cxx settime.cxx \
|
| 72 |
|
|
strftime.cxx time.cxx \
|
| 73 |
|
|
timeutil.cxx
|
| 74 |
|
|
|
| 75 |
|
|
|
| 76 |
|
|
# ====================================================================
|
| 77 |
|
|
|
| 78 |
|
|
cdl_option CYGSEM_LIBC_TIME_CLOCK_WORKING {
|
| 79 |
|
|
display "Working clock() function"
|
| 80 |
|
|
requires CYGFUN_KERNEL_THREADS_TIMER
|
| 81 |
|
|
requires CYGVAR_KERNEL_COUNTERS_CLOCK
|
| 82 |
|
|
default_value 1
|
| 83 |
|
|
description "
|
| 84 |
|
|
This option controls whether clock() will
|
| 85 |
|
|
actually try and determine the process time
|
| 86 |
|
|
usage. With this option disabled, clock() does
|
| 87 |
|
|
not disappear, but will permanently return
|
| 88 |
|
|
(clock_t)-1 as mandated by the ISO C standard."
|
| 89 |
|
|
}
|
| 90 |
|
|
|
| 91 |
|
|
cdl_option CYGSEM_LIBC_TIME_TIME_WORKING {
|
| 92 |
|
|
display "Working time() function"
|
| 93 |
|
|
requires CYGPKG_IO_WALLCLOCK
|
| 94 |
|
|
default_value 1
|
| 95 |
|
|
description "
|
| 96 |
|
|
This option controls whether time() will
|
| 97 |
|
|
actually try and determine the current calendar
|
| 98 |
|
|
time. With this option disabled, time() does
|
| 99 |
|
|
not disappear, but will permanently return
|
| 100 |
|
|
(time_t)-1 as mandated by the ISO C standard."
|
| 101 |
|
|
}
|
| 102 |
|
|
|
| 103 |
|
|
cdl_option CYGSEM_LIBC_TIME_SETTIME_WORKING {
|
| 104 |
|
|
display "Working cyg_libc_time_settime() function"
|
| 105 |
|
|
requires CYGPKG_IO_WALLCLOCK
|
| 106 |
|
|
default_value 1
|
| 107 |
|
|
description "
|
| 108 |
|
|
This option controls whether cyg_libc_time_settime()
|
| 109 |
|
|
will actually try and set the current calendar
|
| 110 |
|
|
time. With this option disabled,
|
| 111 |
|
|
cyg_libc_time_settime() does not disappear, but
|
| 112 |
|
|
will permanently return an error."
|
| 113 |
|
|
}
|
| 114 |
|
|
|
| 115 |
|
|
cdl_option CYGFUN_LIBC_TIME_POSIX {
|
| 116 |
|
|
display "POSIX time functions"
|
| 117 |
|
|
default_value 1
|
| 118 |
|
|
requires CYGFUN_LIBC_STRING_BSD_FUNCS
|
| 119 |
|
|
compile asctime_r.cxx ctime_r.cxx gmtime_r.cxx \
|
| 120 |
|
|
localtime_r.cxx strptime.cxx
|
| 121 |
|
|
description "
|
| 122 |
|
|
Enabling this option allows the use of the
|
| 123 |
|
|
following functions defined in POSIX 1003.1:
|
| 124 |
|
|
asctime_r(), ctime_r(), gmtime_r(), strptime(), and
|
| 125 |
|
|
localtime_r()."
|
| 126 |
|
|
}
|
| 127 |
|
|
|
| 128 |
|
|
cdl_option CYGFUN_LIBC_TIME_SUS_EXTNS {
|
| 129 |
|
|
display "Single UNIX extensions"
|
| 130 |
|
|
default_value 0
|
| 131 |
|
|
description "
|
| 132 |
|
|
Enabling this option allows the use of
|
| 133 |
|
|
certain additional conversion specifiers
|
| 134 |
|
|
in the strftime function."
|
| 135 |
|
|
}
|
| 136 |
|
|
|
| 137 |
|
|
cdl_component CYGPKG_LIBC_TIME_ZONES {
|
| 138 |
|
|
display "Time zone offsets"
|
| 139 |
|
|
flavor none
|
| 140 |
|
|
description "
|
| 141 |
|
|
These options control the default STandarD (STD)
|
| 142 |
|
|
and Daylight Savings Time (DST)
|
| 143 |
|
|
time offsets so that dates can be set correctly
|
| 144 |
|
|
for the local environment."
|
| 145 |
|
|
|
| 146 |
|
|
cdl_option CYGNUM_LIBC_TIME_DST_DEFAULT_STATE {
|
| 147 |
|
|
display "Default Daylight Savings Time state"
|
| 148 |
|
|
flavor data
|
| 149 |
|
|
legal_values -- -1 to 1
|
| 150 |
|
|
default_value -- -1
|
| 151 |
|
|
description "
|
| 152 |
|
|
This option controls whether the initial
|
| 153 |
|
|
time environment is set up as STD, DST or
|
| 154 |
|
|
unknown. Use the value 1 for DST, 0 for STD,
|
| 155 |
|
|
and (-1) for unknown. This can also be set at
|
| 156 |
|
|
runtime using the cyg_libc_time_setdst()
|
| 157 |
|
|
function."
|
| 158 |
|
|
}
|
| 159 |
|
|
|
| 160 |
|
|
cdl_option CYGNUM_LIBC_TIME_STD_DEFAULT_OFFSET {
|
| 161 |
|
|
display "Default Standard Time offset"
|
| 162 |
|
|
flavor data
|
| 163 |
|
|
legal_values -- -90000 to 90000
|
| 164 |
|
|
default_value -- 0
|
| 165 |
|
|
description "
|
| 166 |
|
|
This option controls the offset from UTC in
|
| 167 |
|
|
seconds when in local Standard Time. This
|
| 168 |
|
|
value can be positive or negative. It
|
| 169 |
|
|
can also be set at run time using the
|
| 170 |
|
|
cyg_libc_time_setzoneoffsets() function."
|
| 171 |
|
|
}
|
| 172 |
|
|
|
| 173 |
|
|
cdl_option CYGNUM_LIBC_TIME_DST_DEFAULT_OFFSET {
|
| 174 |
|
|
display "Default Daylight Savings Time offset"
|
| 175 |
|
|
flavor data
|
| 176 |
|
|
legal_values -- -90000 to 90000
|
| 177 |
|
|
default_value -- 3600
|
| 178 |
|
|
description "
|
| 179 |
|
|
This option controls the offset from UTC in
|
| 180 |
|
|
seconds when in local Daylight Savings Time. This
|
| 181 |
|
|
value can be positive or negative. It
|
| 182 |
|
|
can also be set at run time using the
|
| 183 |
|
|
cyg_libc_time_setzoneoffsets() function."
|
| 184 |
|
|
}
|
| 185 |
|
|
}
|
| 186 |
|
|
|
| 187 |
|
|
cdl_component CYGPKG_LIBC_TIME_INLINES {
|
| 188 |
|
|
display "Inline functions"
|
| 189 |
|
|
flavor none
|
| 190 |
|
|
description "
|
| 191 |
|
|
These options control whether certain functions
|
| 192 |
|
|
are available in inline form. This may lead to
|
| 193 |
|
|
faster code at the expense of code space. But for
|
| 194 |
|
|
some functions, or some functions with constant
|
| 195 |
|
|
arguments, it may in fact lead to smaller code."
|
| 196 |
|
|
|
| 197 |
|
|
cdl_option CYGIMP_LIBC_TIME_ASCTIME_INLINE {
|
| 198 |
|
|
display "asctime()"
|
| 199 |
|
|
default_value 1
|
| 200 |
|
|
description "
|
| 201 |
|
|
Allow the asctime() function to be inlined"
|
| 202 |
|
|
}
|
| 203 |
|
|
|
| 204 |
|
|
cdl_option CYGIMP_LIBC_TIME_CTIME_INLINE {
|
| 205 |
|
|
display "ctime()"
|
| 206 |
|
|
default_value 1
|
| 207 |
|
|
description "
|
| 208 |
|
|
Allow the ctime() function to be inlined"
|
| 209 |
|
|
}
|
| 210 |
|
|
|
| 211 |
|
|
cdl_option CYGIMP_LIBC_TIME_DIFFTIME_INLINE {
|
| 212 |
|
|
display "difftime()"
|
| 213 |
|
|
default_value 1
|
| 214 |
|
|
description "
|
| 215 |
|
|
Allow the difftime() function to be inlined"
|
| 216 |
|
|
}
|
| 217 |
|
|
|
| 218 |
|
|
cdl_option CYGIMP_LIBC_TIME_GMTIME_INLINE {
|
| 219 |
|
|
display "gmtime()"
|
| 220 |
|
|
default_value 1
|
| 221 |
|
|
description "
|
| 222 |
|
|
Allow the gmtime() function to be inlined"
|
| 223 |
|
|
}
|
| 224 |
|
|
|
| 225 |
|
|
cdl_option CYGIMP_LIBC_TIME_LOCALTIME_INLINE {
|
| 226 |
|
|
display "localtime()"
|
| 227 |
|
|
default_value 1
|
| 228 |
|
|
description "
|
| 229 |
|
|
Allow the localtime() function to be inlined"
|
| 230 |
|
|
}
|
| 231 |
|
|
|
| 232 |
|
|
cdl_option CYGIMP_LIBC_TIME_MKTIME_INLINE {
|
| 233 |
|
|
display "mktime()"
|
| 234 |
|
|
default_value 1
|
| 235 |
|
|
description "
|
| 236 |
|
|
Allow the mktime() function to be inlined"
|
| 237 |
|
|
}
|
| 238 |
|
|
|
| 239 |
|
|
cdl_option CYGIMP_LIBC_TIME_ASCTIME_R_INLINE {
|
| 240 |
|
|
display "asctime_r()"
|
| 241 |
|
|
requires CYGFUN_LIBC_TIME_POSIX
|
| 242 |
|
|
default_value 1
|
| 243 |
|
|
description "
|
| 244 |
|
|
Allow the asctime_r() function to be inlined"
|
| 245 |
|
|
}
|
| 246 |
|
|
|
| 247 |
|
|
cdl_option CYGIMP_LIBC_TIME_CTIME_R_INLINE {
|
| 248 |
|
|
display "ctime_r()"
|
| 249 |
|
|
requires CYGFUN_LIBC_TIME_POSIX
|
| 250 |
|
|
default_value 1
|
| 251 |
|
|
description "
|
| 252 |
|
|
Allow the ctime_r() function to be inlined"
|
| 253 |
|
|
}
|
| 254 |
|
|
|
| 255 |
|
|
cdl_option CYGIMP_LIBC_TIME_GMTIME_R_INLINE {
|
| 256 |
|
|
display "gmtime_r()"
|
| 257 |
|
|
requires CYGFUN_LIBC_TIME_POSIX
|
| 258 |
|
|
default_value 1
|
| 259 |
|
|
description "
|
| 260 |
|
|
Allow the gmtime_r() function to be inlined"
|
| 261 |
|
|
}
|
| 262 |
|
|
|
| 263 |
|
|
cdl_option CYGIMP_LIBC_TIME_LOCALTIME_R_INLINE {
|
| 264 |
|
|
display "localtime_r()"
|
| 265 |
|
|
requires CYGFUN_LIBC_TIME_POSIX
|
| 266 |
|
|
default_value 1
|
| 267 |
|
|
description "
|
| 268 |
|
|
Allow the localtime_r() function to be inlined"
|
| 269 |
|
|
}
|
| 270 |
|
|
}
|
| 271 |
|
|
# FIXME: Also want "inline all" and "don't inline any" options which requires
|
| 272 |
|
|
# (or not) all the above, but
|
| 273 |
|
|
# if we do that then we will require the ones that also depend on
|
| 274 |
|
|
# CYGFUN_LIBC_TIME_POSIX :-( Wait for full CDL to fix this
|
| 275 |
|
|
|
| 276 |
|
|
cdl_option CYGNUM_LIBC_TIME_CLOCK_TRACE_LEVEL {
|
| 277 |
|
|
display "clock() tracing level"
|
| 278 |
|
|
flavor data
|
| 279 |
|
|
legal_values 0 to 1
|
| 280 |
|
|
default_value 0
|
| 281 |
|
|
description "
|
| 282 |
|
|
Trace verbosity level for debugging the clock()
|
| 283 |
|
|
function. Increase this value to get
|
| 284 |
|
|
additional trace output when tracing is enabled."
|
| 285 |
|
|
}
|
| 286 |
|
|
|
| 287 |
|
|
cdl_component CYGPKG_LIBC_TIME_OPTIONS {
|
| 288 |
|
|
display "C library time functions build options"
|
| 289 |
|
|
flavor none
|
| 290 |
|
|
no_define
|
| 291 |
|
|
description "
|
| 292 |
|
|
Package specific build options including control over
|
| 293 |
|
|
compiler flags used only in building this package,
|
| 294 |
|
|
and details of which tests are built."
|
| 295 |
|
|
|
| 296 |
|
|
|
| 297 |
|
|
cdl_option CYGPKG_LIBC_TIME_CFLAGS_ADD {
|
| 298 |
|
|
display "Additional compiler flags"
|
| 299 |
|
|
flavor data
|
| 300 |
|
|
no_define
|
| 301 |
|
|
default_value { "-Wno-format" }
|
| 302 |
|
|
description "
|
| 303 |
|
|
This option modifies the set of compiler flags for
|
| 304 |
|
|
building the C library. These flags are used in addition
|
| 305 |
|
|
to the set of global flags."
|
| 306 |
|
|
}
|
| 307 |
|
|
|
| 308 |
|
|
cdl_option CYGPKG_LIBC_TIME_CFLAGS_REMOVE {
|
| 309 |
|
|
display "Suppressed compiler flags"
|
| 310 |
|
|
flavor data
|
| 311 |
|
|
no_define
|
| 312 |
|
|
default_value { "" }
|
| 313 |
|
|
description "
|
| 314 |
|
|
This option modifies the set of compiler flags for
|
| 315 |
|
|
building the C library. These flags are removed from
|
| 316 |
|
|
the set of global flags if present."
|
| 317 |
|
|
}
|
| 318 |
|
|
|
| 319 |
|
|
cdl_option CYGPKG_LIBC_TIME_TESTS {
|
| 320 |
|
|
display "C library time and date function tests"
|
| 321 |
|
|
flavor data
|
| 322 |
|
|
no_define
|
| 323 |
|
|
calculated {
|
| 324 |
|
|
"tests/asctime tests/clock tests/ctime tests/gmtime tests/localtime tests/mktime tests/strftime tests/time "
|
| 325 |
|
|
. (CYGFUN_LIBC_TIME_POSIX ? "tests/strptime" : "")
|
| 326 |
|
|
}
|
| 327 |
|
|
description "
|
| 328 |
|
|
This option specifies the set of tests for the C library
|
| 329 |
|
|
time and date functions."
|
| 330 |
|
|
}
|
| 331 |
|
|
}
|
| 332 |
|
|
}
|
| 333 |
|
|
|
| 334 |
|
|
# ====================================================================
|
| 335 |
|
|
# EOF time.cdl
|