[project @ 1997-09-03 23:18:41 by sof]
[ghc-hetmet.git] / configure.in
1 dnl == autoconf source for the Glasgow FP tools ==
2 dnl (grep for '^dnl' to see the outline of this file)
3 dnl
4 dnl * INITIAL SETUP, CHOICE OF PLATFORM(S)
5 #!/bin/sh
6 #
7 # (c) The AQUA Project, Glasgow University, 1994-1997
8 #
9 # Configure script for the Glasgow functional programming tools
10 # (created automagically by autoconf...do not edit by hand)
11 #
12 # Do "./configure --help" to see what flags are available.
13 # (Better yet, read the documentation!)
14 #
15 # First off, a distrib sanity check..
16 AC_INIT(mk/config.mk.in)
17
18 # -------------------------------------------------------------------------
19 # Prepare to generate the following header files
20 #
21 #
22 AC_CONFIG_HEADER(mk/config.h)
23
24 # No, we don't do `--srcdir'...
25 if test x"$srcdir" != 'x.' ; then
26     echo "This configuration does not support the \`--srcdir' option.."
27     exit 1
28 fi
29
30 #
31 # Remove some automounter nonsense (Glasgow specific gruff)
32 #
33 hardtop=`pwd`
34 hardtop=`echo $hardtop | sed 's|^/tmp_mnt/|/|' | sed 's|^/grasp_tmp|/local/grasp_tmp|'`
35
36 #OLD: hardtop=`echo $hardtop | sed 's|^/tmp_mnt/|/|' | sed 's|^/export/|/|' | sed 's|^/grasp_tmp|/local/grasp_tmp|'`
37
38 echo ''
39 echo "*** The top of your build tree is: $hardtop"
40 AC_SUBST(hardtop)
41
42 # -------------------------------------------------------------------------
43 dnl ** choose host(/target/build) platform
44 #
45 # Guess host/target/build platform(s) if necessary.
46 #
47 AC_CANONICAL_SYSTEM
48
49 # "$host" defaults to "$target"
50 if test "x$host" = xNONE ; then
51     host=$target
52 fi
53 # "$build" defaults to "$host"
54 #if test "x$build" = xNONE ; then
55 #    build=$host
56 #else
57 #    echo "This configuration does not support the \`--build' option."
58 #    exit 1
59 #fi
60
61 dnl ** canonicalize platform names
62 # Canonicali[sz]e those babies
63 BuildPlatform=`/bin/sh $srcdir/config.sub $build` || exit 1
64 HostPlatform=`/bin/sh $srcdir/config.sub $host` || exit 1
65 TargetPlatform=`/bin/sh $srcdir/config.sub $target` || exit 1
66
67 if test x"$TargetPlatform" != x"$HostPlatform" ; then
68     echo "GHC configuration does not support differing host/target (i.e., cross-compiling)"
69     exit 1
70 fi
71 #
72 # The following will be more difficult when we *are* cross-compiling.
73 # Suitable names to slam in *_CPP are in platform.h.in.
74 # We also record the architecture, vendor, and operating system (OS)
75 # separately.
76 case $HostPlatform in
77 alpha-dec-osf[[1234]]*)
78         HostPlatform=alpha-dec-osf1   # canonicalise for our purposes
79         TargetPlatform=alpha-dec-osf1 # this will work for now... (hack)
80         BuildPlatform=alpha-dec-osf1  # hack
81         HostPlatform_CPP='alpha_dec_osf1'
82         HostArch_CPP='alpha'
83         HostVendor_CPP='dec'
84         HostOS_CPP='osf1'
85         ;;
86 hppa1.1-hp-hpux*)
87         HostPlatform=hppa1.1-hp-hpux  # canonicalise for our purposes (hack)
88         TargetPlatform=hppa1.1-hp-hpux
89         BuildPlatform=hppa1.1-hp-hpux
90         HostPlatform_CPP='hppa1_1_hp_hpux'
91         HostArch_CPP='hppa1_1'
92         HostVendor_CPP='hp'
93         HostOS_CPP='hpux'
94         ;;
95 i[[3456]]86-*-linuxaout*)
96         HostPlatform=i386-unknown-linuxaout   # hack again
97         TargetPlatform=i386-unknown-linuxaout
98         BuildPlatform=i386-unknown-linuxaout
99         HostPlatform_CPP='i386_unknown_linuxaout'
100         HostArch_CPP='i386'
101         HostVendor_CPP='unknown'
102         HostOS_CPP='linuxaout'
103         ;;
104 i[[3456]]86-*-linux*)
105         HostPlatform=i386-unknown-linux # hack again
106         TargetPlatform=i386-unknown-linux
107         BuildPlatform=i386-unknown-linux
108         HostPlatform_CPP='i386_unknown_linux'
109         HostArch_CPP='i386'
110         HostVendor_CPP='unknown'
111         HostOS_CPP='linux'
112         ;;
113 i[[3456]]86-*-freebsd*)
114         HostPlatform=i386-unknown-freebsd # hack again
115         TargetPlatform=i386-unknown-freebsd
116         BuildPlatform=i386-unknown-freebsd
117         HostPlatform_CPP='i386_unknown_freebsd'
118         HostArch_CPP='i386'
119         HostVendor_CPP='unknown'
120         HostOS_CPP='freebsd'
121         ;;
122 i[[3456]]86-*-netbsd*)
123         HostPlatform=i386-unknown-netbsd # hack again
124         TargetPlatform=i386-unknown-netbsd
125         BuildPlatform=i386-unknown-netbsd
126         HostPlatform_CPP='i386_unknown_netbsd'
127         HostArch_CPP='i386'
128         HostVendor_CPP='unknown'
129         HostOS_CPP='netbsd'
130         ;;
131 i[[3456]]86-*-solaris2*)
132         HostPlatform=i386-unknown-solaris2 # hack again
133         TargetPlatform=i386-unknown-solaris2
134         BuildPlatform=i386-unknown-solaris2
135         HostPlatform_CPP='i386_unknown_solaris2'
136         HostArch_CPP='i386'
137         HostVendor_CPP='unknown'
138         HostOS_CPP='solaris2'
139         ;;
140 i[[3456]]86-*-cygwin32*)
141         HostPlatform=i386-unknown-cygwin32 # hack again
142         TargetPlatform=i386-unknown-cygwin32
143         BuildPlatform=i386-unknown-cygwin32
144         HostPlatform_CPP='i386_unknown_cygwin32'
145         HostArch_CPP='i386'
146         HostVendor_CPP='unknown'
147         HostOS_CPP='cygwin32'
148         ;;
149 m68k-next-nextstep2)
150         HostPlatform_CPP='m68k_next_nextstep2'
151         HostArch_CPP='m68k'
152         HostVendor_CPP='next'
153         HostOS_CPP='nextstep2'
154         ;;
155 m68k-next-nextstep3)
156         HostPlatform_CPP='m68k_next_nextstep3'
157         HostArch_CPP='m68k'
158         HostVendor_CPP='next'
159         HostOS_CPP='nextstep3'
160         ;;
161 i[[3456]]86-next-nextstep3)
162         HostPlatform=i386-next-nextstep3 # hack again
163         TargetPlatform=i386-next-nextstep3
164         BuildPlatform=i386-next-nextstep3
165         HostPlatform_CPP='i386_next_nextstep3'
166         HostArch_CPP='i386'
167         HostVendor_CPP='next'
168         HostOS_CPP='nextstep3'
169         ;;
170 m68k-sun-sunos4*)
171         HostPlatform=m68k-sun-sunos4
172         TargetPlatform=m68k-sun-sunos4 #hack
173         BuildPlatform=m68k-sun-sunos4 #hack
174         HostPlatform_CPP='m68k_sun_sunos4'
175         HostArch_CPP='m68k'
176         HostVendor_CPP='sun'
177         HostOS_CPP='sunos4'
178         ;;
179 mips-dec-ultrix*)
180         HostPlatform_CPP='mips_dec_ultrix'
181         HostArch_CPP='mipsel'   # NB a little different
182         HostVendor_CPP='dec'
183         HostOS_CPP='ultrix'
184         ;;
185 mips-sgi-irix*)
186         HostPlatform=mips-sgi-irix
187         TargetPlatform=mips-sgi-irix #hack
188         BuildPlatform=mips-sgi-irix #hack
189         HostPlatform_CPP='mips_sgi_irix'
190         HostArch_CPP='mipseb'   # NB a little different
191         HostVendor_CPP='sgi'
192         HostOS_CPP='irix'
193         ;;
194 rs6000-ibm-aix*)
195         HostPlatform=rs6000-ibm-aix
196         TargetPlatform=rs6000-ibm-aix #hack
197         BuildPlatform=rs6000-ibm-aix #hack
198         HostPlatform_CPP='rs6000_ibm_aix'
199         HostArch_CPP='rs6000'
200         HostVendor_CPP='ibm'
201         HostOS_CPP='aix'
202         ;;
203 powerpc-ibm-aix*)
204         HostPlatform=powerpc-ibm-aix
205         TargetPlatform=powerpc-ibm-aix #hack
206         BuildPlatform=powerpc-ibm-aix #hack
207         HostPlatform_CPP='powerpc_ibm_aix'
208         HostArch_CPP='powerpc'
209         HostVendor_CPP='ibm'
210         HostOS_CPP='aix'
211         ;;
212 sparc-sun-sunos4*)
213         HostPlatform=sparc-sun-sunos4
214         TargetPlatform=sparc-sun-sunos4 #hack
215         BuildPlatform=sparc-sun-sunos4 #hack
216         HostPlatform_CPP='sparc_sun_sunos4'
217         HostArch_CPP='sparc'
218         HostVendor_CPP='sun'
219         HostOS_CPP='sunos4'
220         ;;
221 sparc-sun-solaris2*)
222         HostPlatform=sparc-sun-solaris2
223         TargetPlatform=sparc-sun-solaris2 #hack
224         BuildPlatform=sparc-sun-solaris2 #hack
225         HostPlatform_CPP='sparc_sun_solaris2'
226         HostArch_CPP='sparc'
227         HostVendor_CPP='sun'
228         HostOS_CPP='solaris2'
229         ;;
230 *)
231         echo "Unrecognised platform: $HostPlatform"
232         exit 1
233         ;;
234 esac
235 echo "Canonicalised to: $HostPlatform"
236 test  x"$HostPlatform" != x"$TargetPlatform" && echo "Target platform set to $TargetPlatform"
237 test  x"$BuildPlatform" != x"$HostPlatform"  && echo "Build platform set to $BuildPlatform"
238
239 BuildPlatform_CPP=$HostPlatform_CPP
240 TargetPlatform_CPP=$HostPlatform_CPP
241 BuildArch_CPP=$HostArch_CPP
242 TargetArch_CPP=$HostArch_CPP
243 BuildOS_CPP=$HostOS_CPP
244 HostOS_Full=$host_os
245 TargetOS_CPP=$HostOS_CPP
246 BuildVendor_CPP=$HostVendor_CPP
247 TargetVendor_CPP=$HostVendor_CPP
248
249 dnl Cannot afford all these SUBSTs (because of braindead seds w/ 99 cmd limits)
250 dnl AC_SUBST(BuildPlatform)
251
252 AC_SUBST(HostPlatform)
253 AC_SUBST(TargetPlatform)
254 AC_SUBST(HostPlatform_CPP)
255 dnl AC_SUBST(BuildPlatform_CPP)
256 dnl AC_SUBST(TargetPlatform_CPP)
257
258 AC_SUBST(HostArch_CPP)
259 dnl AC_SUBST(BuildArch_CPP)
260 dnl AC_SUBST(TargetArch_CPP)
261
262 AC_SUBST(HostOS_CPP)
263 AC_SUBST(HostOS_Full)
264 dnl AC_SUBST(BuildOS_CPP)
265 dnl AC_SUBST(TargetOS_CPP)
266
267 AC_SUBST(HostVendor_CPP)
268 dnl AC_SUBST(BuildVendor_CPP)
269 dnl AC_SUBST(TargetVendor_CPP)
270
271 # -------------------------------------------------------------------------
272 dnl
273 dnl * _GENERAL_ CONFIGURATION CHECKS
274 #
275 dnl ** are we at Glasgow?
276 #
277 # This stuff is in danger of going away..
278 #
279 if test -d /local/fp -a -d /users/fp/simonpj; then
280     echo "Brilliant!  You must be a Glaswegian."
281     AT_GLASGOW=1
282     if test "x$prefix" = xNONE; then
283         prefix=/local/fp
284         echo "Assuming installation prefix of $prefix"
285     fi
286     if test "x$exec_prefix" = xNONE; then
287         # Sigh: the defn of exec_prefix does not include the bin* bit...
288         # WDP 94/07
289         exec_prefix=/local/fp
290         echo "Assuming binary installation prefix of $exec_prefix"
291     fi
292 else
293     AT_GLASGOW=0
294 fi
295 AC_SUBST(AT_GLASGOW)
296 test -n "$verbose" && echo "    setting AT_GLASGOW to $AT_GLASGOW"
297 #
298 #
299 #
300 dnl ** does #! work?
301 #
302 AC_SYS_INTERPRETER()
303 #
304 dnl ** look for `perl', but watch out for version 4.035
305 #
306 AC_CHECK_PROG(PerlCmd,perl,$ac_dir/$ac_word)
307 if test -z "$PerlCmd"; then
308     echo "You must install perl before you can continue"
309     echo "Perhaps it is already installed, but not in your PATH?"
310     exit 1
311 else
312     $PerlCmd -v >conftest.out 2>&1
313     if egrep "version 4" conftest.out >/dev/null 2>&1; then
314         if egrep "Patch level: 35" conftest.out >/dev/null 2>&1; then
315             echo "
316 ************************************************************************
317 Uh-oh...looks like you have Perl 4.035.
318
319 Perl version 4.035 has a bug to do with recursion that will bite if
320 you run the lit2texi script, when making Info files from
321 literate files of various sorts.  Either use the current version
322 (4.036), an older version (e.g., perl 4.019) or apply the patch in
323 glafp-utils/perl-4.035-fixes to your 4.035 perl.
324 ************************************************************************
325 "
326         fi
327     else
328         if egrep "version 5" conftest.out >/dev/null 2>&1; then
329             :
330         else
331             echo "I'm not sure if your version of perl will work,"
332             echo "but it's worth a shot, eh?"
333         fi
334     fi
335     rm -fr conftest*
336 fi
337 #
338 dnl ** does #!.../perl work? (sometimes it's too long...)
339 echo "checking if \`#!$PerlCmd' works in shell scripts"
340 echo "#!$PerlCmd"'
341 exit $1;
342 ' > conftest
343 chmod u+x conftest
344 (SHELL=/bin/sh; export SHELL; ./conftest 69 > /dev/null)
345 if test $? -ne 69; then
346    echo "It does!"
347 else
348    echo "It doesn't!  Perhaps \`#!$PerlCmd' is too long (often 32 characters max)"
349    exit 1
350 fi
351 rm -f conftest
352 #
353 dnl ** check if perl library is properly installed
354 # (by seeing if a "do 'getopts.pl'" works...
355 if $PerlCmd -e 'do "getopts.pl" || exit(1); exit(0);' > /dev/null 2>&1 ; then
356     :
357 else
358     echo "I think your perl library is misinstalled:"
359     echo "The following script did not work:"
360     echo '      do "getopts.pl" || exit(1); exit(0);'
361     echo 'But, anyway, we will continue in our quest..'
362 fi
363 #
364 #
365 dnl ** look for GCC and find out which version
366 # Figure out which C compiler to use.  Gcc is preferred.
367 # If gcc, make sure it's at least 2.1
368 #
369 AC_PROG_CC
370 if test -z "$GCC"; then
371     echo "You would be better off with gcc"
372     echo "Perhaps it is already installed, but not in your PATH?"
373     HaveGcc='NO'
374 else
375     gcc -v > conftest.out 2>&1
376     echo '/version (\d+)\.(\d+)/ && $1*10+$2 > 20 && print "YES";' > conftest.pl
377     HaveGcc=`eval $PerlCmd -n conftest.pl conftest.out`
378     if test -z "$HaveGcc"; then
379         echo "I'm not sure if your version of gcc will work,"
380         echo "but it's worth a shot, eh?"
381         HaveGcc='YES'
382     fi
383     rm -fr conftest*
384 fi
385 AC_SUBST(HaveGcc)
386
387 # Deprecated (AC_PROG_CC does it): AC_C_CROSS
388 #
389 dnl ** figure out how to do context diffs
390 # (NB: NeXTStep thinks diff'ing a file against itself is "trouble")
391 #
392 echo foo > conftest1
393 echo foo > conftest2
394 if diff -C 1 conftest1 conftest2 > /dev/null 2>&1 ; then
395     ContextDiffCmd='diff -C 1'
396 else
397     if diff -c1 conftest1 conftest2 > /dev/null 2>&1 ; then
398         ContextDiffCmd='diff -c1'
399     else
400         echo "Can't figure out how to do context diffs."
401         echo "Neither \`diff -C 1' nor \`diff -c1' works."
402         exit 1
403     fi
404 fi
405 rm -f conftest1 conftest2
406 AC_SUBST(ContextDiffCmd)
407 #
408 dnl ** look for a decent parser generator (bison preferred)
409 #
410 #
411 AC_CHECK_PROG(YaccCmd, bison, bison -y)
412 if test -z "$YaccCmd"; then
413     echo "Can't find bison out there..."
414     AC_CHECK_PROG(WhatCmd, what, what, :)
415     AC_CHECK_PROG(YaccCmd, yacc, $ac_dir/$ac_word)
416     if test -z "$YaccCmd"; then
417         echo "But that's okay...I can't find yacc either."
418         YaccCmd=:
419     else
420         $WhatCmd $YaccCmd > conftest.out
421         if egrep 'y1\.c 1\..*SMI' conftest.out >/dev/null 2>&1; then
422             echo "I don't trust your $YaccCmd; it looks like an old Sun yacc"
423             if test -f /usr/lang/yacc; then
424                 echo "I'm going to use /usr/lang/yacc instead"
425                 YaccCmd=/usr/lang/yacc
426             else
427                 echo "I'm assuming the worst...no parser generator at all"
428                 YaccCmd=:
429             fi
430         elif egrep 'y1\.c.*Revision: 4\.2\.6\.3.*DEC' conftest.out >/dev/null 2>&1; then
431             echo "I don't trust your $YaccCmd; it looks like a lame DEC yacc"
432             echo "I'm assuming the worst...no parser generator at all"
433             YaccCmd=:
434         else
435             echo "But that's okay...as far as I know, your yacc will work."
436         fi
437         rm -fr conftest*
438     fi
439 fi
440
441 dnl ** Find lex command (lex or flex) and library (-ll or -lfl)
442 #
443 AC_PROG_LEX
444
445 # -------------------------------------------------------------------------
446 #
447 dnl ** figure out how to invoke cpp directly (gcc -E is no good)
448 #
449 AC_PROG_CPP
450 if echo $CPP | egrep gcc >/dev/null 2>&1; then
451     echo > conftest.c
452     gcc -v -E conftest.c >/dev/null 2>conftest.out
453     echo '/(\S+\/cpp)/ && print "$1";' > conftest.pl
454     # GNUCPP: used in jmake.c (GnuCppCmd) and in mkdependC
455     # (where we could do with the usual pre-#defines)
456     GNUCPP="`eval $PerlCmd -n conftest.pl conftest.out`"
457     test -n "$verbose" && echo "        setting GNUCPP to $GNUCPP"
458     # RAWCPP: we do not want *any* pre-#defines...
459     # (e.g., hscpp, mkdependHS)
460     RAWCPP="`eval $PerlCmd -n conftest.pl conftest.out` -traditional"
461     test -n "$verbose" && echo "        setting RAWCPP to $RAWCPP"
462     rm -fr conftest*
463 fi
464 # ToDo: what are GNUCPP and RAWCPP if the above if didn't fire? WDP 95/02
465 AC_SUBST(GNUCPP)
466 AC_SUBST(RAWCPP)
467 #
468 dnl ** figure out how to do a BSD-ish install
469 #
470 AC_PROG_INSTALL
471 #
472 dnl ** figure out what arguments to feed to `ar'
473 #
474 AC_CHECK_PROG(ArCmd,ar,$ac_dir/$ac_word)
475 if test -z "$ArCmd"; then
476     echo "You don't seem to have ar...I have no idea how to make a library"
477     exit 1;
478 fi
479 if $ArCmd clqs conftest.a >/dev/null 2>/dev/null; then
480     ArCmd="$ArCmd clqs"
481     NeedRanLib=''
482 elif $ArCmd cqs conftest.a >/dev/null 2>/dev/null; then
483     ArCmd="$ArCmd cqs"
484     NeedRanLib=''
485 elif $ArCmd clq conftest.a >/dev/null 2>/dev/null; then
486     ArCmd="$ArCmd clq"
487     NeedRanLib='YES'
488 elif $ArCmd cq conftest.a >/dev/null 2>/dev/null; then
489     ArCmd="$ArCmd cq"
490     NeedRanLib='YES'
491 elif $ArCmd cq conftest.a 2>&1 | grep 'no archive members specified' >/dev/null 2>/dev/null; then
492     ArCmd="$ArCmd cq"
493     NeedRanLib='YES'
494 else
495     echo "I can't figure out how to use your $ArCmd"
496     exit 1
497 fi
498 rm -rf conftest*
499 test -n "$ArCmd" && test -n "$verbose" && echo "        setting ArCmd to $ArCmd"
500 AC_SUBST(ArCmd)
501 #
502 dnl ** figure out if we need `ranlib'
503 #
504 if test -z "$NeedRanLib"; then
505     # we hackily override a few platforms on a case-by-case basis
506     case $HostPlatform in
507     i386-*-linuxaout)
508         NeedRanLib='YES'
509         ;;
510     *)  RANLIB=':'
511         ;;
512     esac
513     test -n "$verbose" && echo "        setting RANLIB to $RANLIB"
514 fi
515 if test -n "$NeedRanLib"; then
516     AC_PROG_RANLIB
517 fi
518 AC_SUBST(RANLIB)
519 #
520 #
521 dnl ** Check to see whether ln -s works
522 #
523 AC_PROG_LN_S()
524 AC_SUBST(LN_S)
525 #
526 dnl ** Find the path to sed **
527 AC_PATH_PROG(SedCmd,sed,$ac_dir/$ac_word)
528
529 # It better be around somewhere (we wouldn't
530 # exec this script properly if it wasn't!)
531 #
532 AC_SUBST(SedCmd)
533 #
534 dnl ** check for time command **
535 AC_PATH_PROG(TimeCmd,time,$ac_dir/$ac_word)
536
537 AC_SUBST(TimeCmd)
538 #
539 dnl ** check for tar **
540 #
541 # if GNU tar is named gtar, look for it first.
542 #
543 AC_PATH_PROGS(TarCmd,gtar tar,tar)
544
545
546 #
547 dnl ** check for gzip/compress **
548 AC_PATH_PROGS(CompressCmd,gzip compress,gzip)
549
550 compress_nm=`basename $CompressCmd`
551
552 if test x"$compress_nm" = xgzip; then
553   CompressCmd="$CompressCmd -d"
554   CompressSuffix="gz"
555 else
556   CompressSuffix="Z"
557 fi
558 AC_SUBST(CompressCmd)
559 AC_SUBST(CompressSuffix)
560 #
561 dnl ** check for installed happy binary
562 #
563 AC_PATH_PROG(HappyCmd,happy)
564
565 #
566 #
567 dnl ** check for installed lx binary
568 #
569 AC_PATH_PROG(LxCmd,lx)
570
571 #
572 dnl ** check for installed green-card binary
573 #
574 AC_PATH_PROG(GreencardCmd,green-card)
575
576 dnl ** check for full ANSI header (.h) files
577 #
578 AC_HEADER_STDC
579
580 #
581 dnl ** check for specific header (.h) files that we are interested in
582 #
583 AC_CHECK_HEADERS(dirent.h fcntl.h grp.h malloc.h memory.h nlist.h pwd.h siginfo.h signal.h stdlib.h string.h sys/fault.h sys/file.h sys/mman.h sys/param.h sys/procfs.h sys/resource.h sys/signal.h sys/socket.h sys/stat.h sys/syscall.h sys/time.h sys/timeb.h sys/timers.h sys/times.h sys/types.h sys/utsname.h sys/vadvise.h sys/wait.h termios.h time.h types.h unistd.h utime.h vfork.h readline/readline.h )
584
585 #
586 dnl ** check if it is safe to include both <time.h> and <sys/time.h>
587 #
588 AC_HEADER_TIME
589 #
590 dnl ** how do we get a timezone name, and UTC offset ?
591 #
592 AC_STRUCT_TIMEZONE
593
594
595 dnl what's the type of timezone?
596 AC_TYPE_TIMEZONE
597
598 #
599 dnl do we have altzone?
600 AC_ALTZONE
601
602 #
603 dnl ** check for specific library functions that we are interested in
604 #
605 AC_CHECK_FUNCS(access ftime getclock getpagesize getrusage gettimeofday mktime mprotect setitimer stat sysconf timelocal times vadvise vfork)
606
607 #
608 # Misc
609 #
610 dnl ** can we get alloca?
611 AC_FUNC_ALLOCA
612 dnl ** determine whether or not const works
613 AC_C_CONST
614 dnl ** determine the type of signal()
615 AC_TYPE_SIGNAL
616
617 #
618 dnl ** check for leading underscores in symbol names
619 #
620 AC_UNDERSCORE
621
622 AC_OUTPUT(mk/config.mk, echo timestamp > mk/stamp-h )
623
624 #
625 # It'll break soon enough if it didn't, but we perform a sanity
626 # check here on the generated config.mk file to see if the
627 # sed that was used is of the well-behaved sort.
628 #
629 #grep @ mk/config.mk > conftest.out
630 #if grep -v '#     enclosed in @at-signs@.' conftest.out >/dev/null 2>&1; then
631 #   :
632 #else
633 #   echo 'Hmm..suspicious, did the configure script perform all the @..@ substitutions in mk/config.mk?..';
634 #   grep -v '#     enclosed in @at-signs@.' conftest.out /dev/null
635 #fi
636 #rm -f conftest*
637
638 echo ''
639 echo '************************************************'
640 echo '*** NOW DO: gmake boot followed by gmake all'
641 echo '************************************************'
642 exit 0