OSDN Git Service

* generic/tclIntDecls.h (TclIntStubs): Do not include definitions
[pf3gnuchains/sourceware.git] / tcl / win / tcl.m4
1 #------------------------------------------------------------------------
2 # SC_PATH_TCLCONFIG --
3 #
4 #       Locate the tclConfig.sh file and perform a sanity check on
5 #       the Tcl compile flags
6 #       Currently a no-op for Windows
7 #
8 # Arguments:
9 #       PATCH_LEVEL     The patch level for Tcl if any.
10 #
11 # Results:
12 #
13 #       Adds the following arguments to configure:
14 #               --with-tcl=...
15 #
16 #       Sets the following vars:
17 #               TCL_BIN_DIR     Full path to the tclConfig.sh file
18 #------------------------------------------------------------------------
19
20 AC_DEFUN(SC_PATH_TCLCONFIG, [
21     AC_MSG_CHECKING([the location of tclConfig.sh])
22
23 # CYGNUS LOCAL
24     if test -d ../../tcl8.1/win;  then
25         TCL_BIN_DIR_DEFAULT=../../tcl8.1/win
26     else
27         TCL_BIN_DIR_DEFAULT=../../tcl/win
28     fi
29 # END CYGNUS LOCAL
30     
31     AC_ARG_WITH(tcl, [  --with-tcl=DIR          use Tcl 8.3 binaries from DIR],
32             TCL_BIN_DIR=$withval, TCL_BIN_DIR=`cd $TCL_BIN_DIR_DEFAULT; pwd`)
33     if test ! -d $TCL_BIN_DIR; then
34         AC_MSG_ERROR(Tcl directory $TCL_BIN_DIR does not exist)
35     fi
36     if test ! -f $TCL_BIN_DIR/tclConfig.sh; then
37         AC_MSG_ERROR(There is no tclConfig.sh in $TCL_BIN_DIR:  perhaps you did not specify the Tcl *build* directory (not the toplevel Tcl directory) or you forgot to configure Tcl?)
38     fi
39     AC_MSG_RESULT($TCL_BIN_DIR/tclConfig.sh)
40 ])
41
42 #------------------------------------------------------------------------
43 # SC_PATH_TKCONFIG --
44 #
45 #       Locate the tkConfig.sh file
46 #       Currently a no-op for Windows
47 #
48 # Arguments:
49 #       none
50 #
51 # Results:
52 #
53 #       Adds the following arguments to configure:
54 #               --with-tk=...
55 #
56 #       Sets the following vars:
57 #               TK_BIN_DIR      Full path to the tkConfig.sh file
58 #------------------------------------------------------------------------
59
60 AC_DEFUN(SC_PATH_TKCONFIG, [
61     AC_MSG_CHECKING([the location of tkConfig.sh])
62
63     if test -d ../../tk8.3$1/win;  then
64         TK_BIN_DIR_DEFAULT=../../tk8.3$1/win
65     else
66         TK_BIN_DIR_DEFAULT=../../tk8.3/win
67     fi
68     
69     AC_ARG_WITH(tk, [  --with-tk=DIR          use Tk 8.3 binaries from DIR],
70             TK_BIN_DIR=$withval, TK_BIN_DIR=`cd $TK_BIN_DIR_DEFAULT; pwd`)
71     if test ! -d $TK_BIN_DIR; then
72         AC_MSG_ERROR(Tk directory $TK_BIN_DIR does not exist)
73     fi
74     if test ! -f $TK_BIN_DIR/tkConfig.sh; then
75         AC_MSG_ERROR(There is no tkConfig.sh in $TK_BIN_DIR:  perhaps you did not specify the Tk *build* directory (not the toplevel Tk directory) or you forgot to configure Tk?)
76     fi
77
78     AC_MSG_RESULT([$TK_BIN_DIR/tkConfig.sh])
79 ])
80
81 #------------------------------------------------------------------------
82 # SC_LOAD_TCLCONFIG --
83 #
84 #       Load the tclConfig.sh file
85 #       Currently a no-op for Windows
86 #
87 # Arguments:
88 #       
89 #       Requires the following vars to be set:
90 #               TCL_BIN_DIR
91 #
92 # Results:
93 #
94 #       Subst the following vars:
95 #               TCL_BIN_DIR
96 #               TCL_SRC_DIR
97 #               TCL_LIB_FILE
98 #
99 #------------------------------------------------------------------------
100
101 AC_DEFUN(SC_LOAD_TCLCONFIG, [
102     AC_MSG_CHECKING([for existence of $TCL_BIN_DIR/tclConfig.sh])
103
104     if test -f "$TCL_BIN_DIR/tclConfig.sh" ; then
105         AC_MSG_RESULT([loading])
106         . $TCL_BIN_DIR/tclConfig.sh
107     else
108         AC_MSG_RESULT([file not found])
109     fi
110
111     # The eval is required to do the TCL_DBGX substitution in the
112     # TCL_LIB_FILE variable.
113
114     eval TCL_LIB_FILE=${TCL_LIB_FILE}
115     eval TCL_LIB_FLAG=${TCL_LIB_FLAG}
116
117     AC_SUBST(TCL_BIN_DIR)
118     AC_SUBST(TCL_SRC_DIR)
119     AC_SUBST(TCL_LIB_FILE)
120 ])
121
122 #------------------------------------------------------------------------
123 # SC_LOAD_TKCONFIG --
124 #
125 #       Load the tkConfig.sh file
126 #       Currently a no-op for Windows
127 #
128 # Arguments:
129 #       
130 #       Requires the following vars to be set:
131 #               TK_BIN_DIR
132 #
133 # Results:
134 #
135 #       Sets the following vars that should be in tkConfig.sh:
136 #               TK_BIN_DIR
137 #------------------------------------------------------------------------
138
139 AC_DEFUN(SC_LOAD_TKCONFIG, [
140     AC_MSG_CHECKING([for existence of $TCLCONFIG])
141
142     if test -f "$TK_BIN_DIR/tkConfig.sh" ; then
143         AC_MSG_CHECKING([loading $TK_BIN_DIR/tkConfig.sh])
144         . $TK_BIN_DIR/tkConfig.sh
145     else
146         AC_MSG_RESULT([could not find $TK_BIN_DIR/tkConfig.sh])
147     fi
148
149
150     AC_SUBST(TK_BIN_DIR)
151     AC_SUBST(TK_SRC_DIR)
152     AC_SUBST(TK_LIB_FILE)
153 ])
154
155 #------------------------------------------------------------------------
156 # SC_ENABLE_SHARED --
157 #
158 #       Allows the building of shared libraries
159 #
160 # Arguments:
161 #       none
162 #       
163 # Results:
164 #
165 #       Adds the following arguments to configure:
166 #               --enable-shared=yes|no
167 #
168 #       Defines the following vars:
169 #               STATIC_BUILD    Used for building import/export libraries
170 #                               on Windows.
171 #
172 #       Sets the following vars:
173 #               SHARED_BUILD    Value of 1 or 0
174 #------------------------------------------------------------------------
175
176 AC_DEFUN(SC_ENABLE_SHARED, [
177     AC_MSG_CHECKING([how to build libraries])
178     AC_ARG_ENABLE(shared,
179         [  --enable-shared         build and link with shared libraries [--enable-shared]],
180     [tcl_ok=$enableval], [tcl_ok=yes])
181
182     if test "${enable_shared+set}" = set; then
183         enableval="$enable_shared"
184         tcl_ok=$enableval
185     else
186         tcl_ok=yes
187     fi
188
189     if test "$tcl_ok" = "yes" ; then
190         AC_MSG_RESULT([shared])
191         SHARED_BUILD=1
192     else
193         AC_MSG_RESULT([static])
194         SHARED_BUILD=0
195         AC_DEFINE(STATIC_BUILD)
196     fi
197 ])
198
199 #------------------------------------------------------------------------
200 # SC_ENABLE_THREADS --
201 #
202 #       Specify if thread support should be enabled
203 #
204 # Arguments:
205 #       none
206 #       
207 # Results:
208 #
209 #       Adds the following arguments to configure:
210 #               --enable-threads=yes|no
211 #
212 #       Defines the following vars:
213 #               TCL_THREADS
214 #------------------------------------------------------------------------
215
216 AC_DEFUN(SC_ENABLE_THREADS, [
217     AC_MSG_CHECKING(for building with threads)
218     AC_ARG_ENABLE(threads, [  --enable-threads        build with threads],
219         [tcl_ok=$enableval], [tcl_ok=no])
220
221     if test "$tcl_ok" = "yes"; then
222         AC_MSG_RESULT(yes)
223         TCL_THREADS=1
224         AC_DEFINE(TCL_THREADS)
225     else
226         TCL_THREADS=0
227         AC_MSG_RESULT([no (default)])
228     fi
229 ])
230
231 #------------------------------------------------------------------------
232 # SC_ENABLE_SYMBOLS --
233 #
234 #       Specify if debugging symbols should be used
235 #
236 # Arguments:
237 #       none
238 #       
239 #       Requires the following vars to be set in the Makefile:
240 #               CFLAGS_DEBUG
241 #               CFLAGS_OPTIMIZE
242 #               LDFLAGS_DEBUG
243 #               LDFLAGS_OPTIMIZE
244 #       
245 # Results:
246 #
247 #       Adds the following arguments to configure:
248 #               --enable-symbols
249 #
250 #       Defines the following vars:
251 #               CFLAGS_DEFAULT  Set to $(CFLAGS_DEBUG) if true
252 #                               Set to $(CFLAGS_OPTIMIZE) if false
253 #               LDFLAGS_DEFAULT Set to $(LDFLAGS_DEBUG) if true
254 #                               Set to $(LDFLAGS_OPTIMIZE) if false
255 #               DBGX            Debug library extension
256 #
257 #------------------------------------------------------------------------
258
259 AC_DEFUN(SC_ENABLE_SYMBOLS, [
260     AC_MSG_CHECKING([for build with symbols])
261     AC_ARG_ENABLE(symbols, [  --enable-symbols        build with debugging symbols [--disable-symbols]],    [tcl_ok=$enableval], [tcl_ok=no])
262
263     if test "$tcl_ok" = "yes"; then
264         CFLAGS_DEFAULT='$(CFLAGS_DEBUG)'
265         LDFLAGS_DEFAULT='$(LDFLAGS_DEBUG)'
266         DBGX=d
267         AC_MSG_RESULT([yes])
268     else
269         CFLAGS_DEFAULT='$(CFLAGS_OPTIMIZE)'
270         LDFLAGS_DEFAULT='$(LDFLAGS_OPTIMIZE)'
271         DBGX=""
272         AC_MSG_RESULT([no])
273     fi
274 ])
275
276
277 #--------------------------------------------------------------------
278 # SC_CONFIG_CFLAGS
279 #
280 #       Try to determine the proper flags to pass to the compiler
281 #       for building shared libraries and other such nonsense.
282 #
283 #       NOTE: The backslashes in quotes below are substituted twice
284 #       due to the fact that they are in a macro and then inlined
285 #       in the final configure script.
286 #
287 # Arguments:
288 #       none
289 #
290 # Results:
291 #
292 #       Can set the following vars:
293 #               EXTRA_CFLAGS
294 #               CFLAGS_DEBUG
295 #               CFLAGS_OPTIMIZE
296 #               CFLAGS_WARNING
297 #               LDFLAGS_DEBUG
298 #               LDFLAGS_OPTIMIZE
299 #               LDFLAGS_CONSOLE
300 #               LDFLAGS_WINDOW
301 #               CC_OBJNAME
302 #               CC_EXENAME
303 #               CYGPATH
304 #               STLIB_LD
305 #               SHLIB_LD
306 #               SHLIB_LD_LIBS
307 #               LIBS
308 #               AR
309 #               RC
310 #               RES
311 #
312 #               MAKE_LIB
313 #               MAKE_EXE
314 #               MAKE_DLL
315 #
316 #               LIBSUFFIX
317 #               LIBPREFIX
318 #               VENDORPREFIX
319 #               LIBRARIES
320 #               EXESUFFIX
321 #               DLLSUFFIX
322 #
323 #--------------------------------------------------------------------
324
325 AC_DEFUN(SC_CONFIG_CFLAGS, [
326     TCL_LIB_VERSIONS_OK=nodots
327
328     AC_CHECK_PROG(CYGPATH, cygpath, cygpath -w, echo)
329
330     # Check for a bug in gcc's windres that causes the
331     # compile to fail when a Windows native path is
332     # passed into windres. The mingw toolchain requires
333     # Windows native paths while Cygwin should work
334     # with both. Avoid the bug by passing a POSIX
335     # path when using the Cygwin toolchain.
336
337     if test "$GCC" = "yes" && test "$CYGPATH" != "echo" ; then
338         conftest=/tmp/conftest.rc
339         echo "STRINGTABLE BEGIN" > $conftest
340         echo "101 \"name\"" >> $conftest
341         echo "END" >> $conftest
342
343         AC_MSG_CHECKING([for Windows native path bug in windres])
344         cyg_conftest=`$CYGPATH $conftest`
345         if AC_TRY_COMMAND($RC -o conftest.res.o $cyg_conftest) ; then
346             AC_MSG_RESULT([no])
347         else
348             AC_MSG_RESULT([yes])
349             CYGPATH=echo
350         fi
351         conftest=
352         cyg_conftest=
353     fi
354
355     if test "$CYGPATH" = "echo" || test "$ac_cv_cygwin" = "yes"; then
356         DEPARG='"$<"'
357     else
358         DEPARG='"$(shell $(CYGPATH) $<)"'
359     fi
360
361     # CYGNUS LOCAL
362     VENDORPREFIX="rh"
363     # END CYGNUS LOCAL
364
365     # set various compiler flags depending on whether we are using gcc or cl
366
367     AC_MSG_CHECKING([compiler flags])
368     if test "${GCC}" = "yes" ; then
369
370         # CYGNUS LOCAL
371         if test "$ac_cv_cygwin" = "yes" ; then
372             VENDORPREFIX="cyg"
373         fi
374         # END CYGNUS LOCAL
375
376         SHLIB_LD=""
377         SHLIB_LD_LIBS=""
378         LIBS=""
379         LIBS_GUI="-lgdi32 -lcomdlg32"
380         STLIB_LD="${AR} cr"
381         RC_OUT=-o
382         RC_TYPE=
383         RC_INCLUDE=--include
384         RES=res.o
385         MAKE_LIB="\${STLIB_LD} \[$]@"
386         POST_MAKE_LIB="\${RANLIB} \[$]@"
387         MAKE_EXE="\${CC} -o \[$]@"
388         LIBPREFIX="lib${VENDORPREFIX}"
389
390         if test "${SHARED_BUILD}" = "0" ; then
391             # static
392             AC_MSG_RESULT([using static flags])
393             runtime=
394             MAKE_DLL="echo "
395             LIBSUFFIX="s\${DBGX}.a"
396             LIBRARIES="\${STATIC_LIBRARIES}"
397             EXESUFFIX="s\${DBGX}.exe"
398             DLLSUFFIX=""
399         else
400             # dynamic
401             AC_MSG_RESULT([using shared flags])
402
403             # ad-hoc check to see if CC supports -shared.
404             if "${CC}" -shared 2>&1 | egrep ': -shared not supported' >/dev/null; then
405                 AC_MSG_ERROR([${CC} does not support the -shared option.
406                 You will need to upgrade to a newer version of the toolchain.])
407             fi
408
409             runtime=
410             # Link with gcc since ld does not link to default libs like
411             # -luser32 and -lmsvcrt. We also need to add CFLAGS so important
412             # flags like -mno-cygwin get passed in to CC.
413             SHLIB_LD='${CC} -shared ${CFLAGS}'
414             # Add SHLIB_LD_LIBS to the Make rule, not here.
415             MAKE_DLL="\${SHLIB_LD} \$(LDFLAGS) -o \[$]@ ${extra_ldflags} \
416                 -Wl,--out-implib,\$(patsubst %.dll,lib%.a,\[$]@)"
417             TCL_DLL_BASE="-Wl,--image-base=0x66000000"
418             DDE_DLL_BASE="-Wl,--image-base=0x66100000"
419             REG_DLL_BASE="-Wl,--image-base=0x66200000"
420
421             LIBSUFFIX="\${DBGX}.a"
422             DLLSUFFIX="\${DBGX}.dll"
423             EXESUFFIX="\${DBGX}.exe"
424             LIBRARIES="\${SHARED_LIBRARIES}"
425         fi
426
427         CFLAGS_DEBUG=-g
428         CFLAGS_OPTIMIZE=-O
429         CFLAGS_WARNING="-Wall -Wconversion"
430         LDFLAGS_DEBUG=
431         LDFLAGS_OPTIMIZE=
432
433         # Specify the CC output file names based on the target name
434         CC_OBJNAME="-o \[$]@"
435         CC_EXENAME="-o \[$]@"
436
437         # Specify linker flags depending on the type of app being 
438         # built -- Console vs. Window.
439         LDFLAGS_CONSOLE="-mconsole ${extra_ldflags}"
440         LDFLAGS_WINDOW="-mwindows ${extra_ldflags}"
441     else
442         SHLIB_LD="link -dll -nologo"
443         SHLIB_LD_LIBS="user32.lib advapi32.lib"
444         LIBS="user32.lib advapi32.lib"
445         LIBS_GUI="gdi32.lib comdlg32.lib"
446         STLIB_LD="lib -nologo"
447         RC="rc"
448         RC_OUT=-fo
449         RC_TYPE=-r
450         RC_INCLUDE=-i
451         RES=res
452         MAKE_LIB="\${STLIB_LD} -out:\[$]@"
453         POST_MAKE_LIB=
454         MAKE_EXE="\${CC} -Fe\[$]@"
455         LIBPREFIX=${VENDORPREFIX}
456
457         if test "${SHARED_BUILD}" = "0" ; then
458             # static
459             AC_MSG_RESULT([using static flags])
460             runtime=-MT
461             MAKE_DLL="echo "
462             LIBSUFFIX="s\${DBGX}.lib"
463             LIBRARIES="\${STATIC_LIBRARIES}"
464             EXESUFFIX="s\${DBGX}.exe"
465             DLLSUFFIX=""
466         else
467             # dynamic
468             AC_MSG_RESULT([using shared flags])
469             runtime=-MD
470             # Add SHLIB_LD_LIBS to the Make rule, not here.
471             MAKE_DLL="\${SHLIB_LD} \$(LDFLAGS) -out:\[$]@"
472             LIBSUFFIX="\${DBGX}.lib"
473             DLLSUFFIX="\${DBGX}.dll"
474             EXESUFFIX="\${DBGX}.exe"
475             LIBRARIES="\${SHARED_LIBRARIES}"
476         fi
477
478         EXTRA_CFLAGS="-YX"
479         CFLAGS_DEBUG="-nologo -Z7 -Od -WX ${runtime}d"
480 #       CFLAGS_OPTIMIZE="-nologo -O2 -Gs -GD ${runtime}"
481         CFLAGS_OPTIMIZE="-nologo -Oti -Gs -GD ${runtime}"
482         CFLAGS_WARNING="-W3"
483         LDFLAGS_DEBUG="-debug:full -debugtype:cv"
484         LDFLAGS_OPTIMIZE="-release"
485
486         # Specify the CC output file names based on the target name
487         CC_OBJNAME="-Fo\[$]@"
488         CC_EXENAME="-Fe\"\$(shell \$(CYGPATH) '\[$]@')\""
489
490         # Specify linker flags depending on the type of app being 
491         # built -- Console vs. Window.
492         LDFLAGS_CONSOLE="-link -subsystem:console"
493         LDFLAGS_WINDOW="-link -subsystem:windows"
494     fi
495
496     # Define the same variables as used in tclConfig.sh so that macros
497     # that depend on these variables work for both Tcl and extensions.
498     TCL_LIB_SUFFIX=$LIBSUFFIX
499     TCL_VENDOR_PREFIX=$VENDORPREFIX
500 ])
501
502 #------------------------------------------------------------------------
503 # SC_WITH_TCL --
504 #
505 #       Location of the Tcl build directory.
506 #
507 # Arguments:
508 #       none
509 #
510 # Results:
511 #
512 #       Adds the following arguments to configure:
513 #               --with-tcl=...
514 #
515 #       Defines the following vars:
516 #               TCL_BIN_DIR     Full path to the tcl build dir.
517 #------------------------------------------------------------------------
518
519 AC_DEFUN(SC_WITH_TCL, [
520     if test -d ../../tcl8.3$1/win;  then
521         TCL_BIN_DEFAULT=../../tcl8.3$1/win
522     else
523         TCL_BIN_DEFAULT=../../tcl8.3/win
524     fi
525     
526     AC_ARG_WITH(tcl, [  --with-tcl=DIR          use Tcl 8.3 binaries from DIR],
527             TCL_BIN_DIR=$withval, TCL_BIN_DIR=`cd $TCL_BIN_DEFAULT; pwd`)
528     if test ! -d $TCL_BIN_DIR; then
529         AC_MSG_ERROR(Tcl directory $TCL_BIN_DIR does not exist)
530     fi
531     if test ! -f $TCL_BIN_DIR/Makefile; then
532         AC_MSG_ERROR(There is no Makefile in $TCL_BIN_DIR:  perhaps you did not specify the Tcl *build* directory (not the toplevel Tcl directory) or you forgot to configure Tcl?)
533     else
534         echo "building against Tcl binaries in: $TCL_BIN_DIR"
535     fi
536     AC_SUBST(TCL_BIN_DIR)
537 ])
538
539 #--------------------------------------------------------------------
540 # SC_TIME_HANLDER
541 #
542 #       Checks how the system deals with time.h, what time structures
543 #       are used on the system, and what fields the structures have.
544 #
545 # Arguments:
546 #       none
547 #       
548 # Results:
549 #
550 #       Defines some of the following vars:
551 #               USE_DELTA_FOR_TZ
552 #               HAVE_TM_GMTOFF
553 #               HAVE_TM_TZADJ
554 #               HAVE_TIMEZONE_VAR
555 #
556 #--------------------------------------------------------------------
557
558 AC_DEFUN(SC_TIME_HANDLER, [
559     AC_CHECK_HEADERS(sys/time.h)
560     AC_HEADER_TIME
561     AC_STRUCT_TIMEZONE
562
563     AC_MSG_CHECKING([tm_tzadj in struct tm])
564     AC_TRY_COMPILE([#include <time.h>], [struct tm tm; tm.tm_tzadj;],
565             [AC_DEFINE(HAVE_TM_TZADJ)
566             AC_MSG_RESULT(yes)],
567             AC_MSG_RESULT(no))
568
569     AC_MSG_CHECKING([tm_gmtoff in struct tm])
570     AC_TRY_COMPILE([#include <time.h>], [struct tm tm; tm.tm_gmtoff;],
571             [AC_DEFINE(HAVE_TM_GMTOFF)
572             AC_MSG_RESULT(yes)],
573             AC_MSG_RESULT(no))
574
575     #
576     # Its important to include time.h in this check, as some systems
577     # (like convex) have timezone functions, etc.
578     #
579     have_timezone=no
580     AC_MSG_CHECKING([long timezone variable])
581     AC_TRY_COMPILE([#include <time.h>],
582             [extern long timezone;
583             timezone += 1;
584             exit (0);],
585             [have_timezone=yes
586             AC_DEFINE(HAVE_TIMEZONE_VAR)
587             AC_MSG_RESULT(yes)],
588             AC_MSG_RESULT(no))
589
590     #
591     # On some systems (eg IRIX 6.2), timezone is a time_t and not a long.
592     #
593     if test "$have_timezone" = no; then
594     AC_MSG_CHECKING([time_t timezone variable])
595     AC_TRY_COMPILE([#include <time.h>],
596             [extern time_t timezone;
597             timezone += 1;
598             exit (0);],
599             [AC_DEFINE(HAVE_TIMEZONE_VAR)
600             AC_MSG_RESULT(yes)],
601             AC_MSG_RESULT(no))
602     fi
603
604     #
605     # On some systems (eg Solaris 2.5.1), timezone is not declared in
606     # time.h unless you jump through hoops.  Instead of that, we just
607     # declare it ourselves when necessary.
608     #
609     if test "$have_timezone" = yes; then
610         AC_MSG_CHECKING(for timezone declaration)
611         changequote(<<,>>)
612         tzrx='^[        ]*extern.*timezone'
613         changequote([,])
614         AC_EGREP_HEADER($tzrx, time.h, [
615         AC_DEFINE(HAVE_TIMEZONE_DECL)
616         AC_MSG_RESULT(found)], AC_MSG_RESULT(missing))
617     fi
618
619     #
620     # AIX does not have a timezone field in struct tm. When the AIX bsd
621     # library is used, the timezone global and the gettimeofday methods are
622     # to be avoided for timezone deduction instead, we deduce the timezone
623     # by comparing the localtime result on a known GMT value.
624     #
625
626     if test "`uname -s`" = "AIX" ; then
627         AC_CHECK_LIB(bsd, gettimeofday, libbsd=yes)
628         if test $libbsd = yes; then
629             AC_DEFINE(USE_DELTA_FOR_TZ)
630         fi
631     fi
632 ])
633