This file contains diffs from version 3.72.1 of GNU Make to version 3.73. Changes in files that are generated by etags, TeX, or Makeinfo have been omitted. diff -ruN make-3.72.1/ChangeLog make-3.73/ChangeLog --- make-3.72.1/ChangeLog Sun Nov 6 18:34:54 1994 +++ make-3.73/ChangeLog Wed Apr 5 00:20:51 1995 @@ -1,3 +1,262 @@ +Wed Apr 5 00:20:24 1995 Roland McGrath + + * Version 3.73 released. + +Tue Mar 28 13:25:46 1995 Roland McGrath + + * main.c (main): Fixed braino in assert. + + * Version 3.72.13. + +Mon Mar 27 05:29:12 1995 Roland McGrath + + * main.c: Avoid string in assert expression. Some systems are broken. + +Fri Mar 24 00:32:32 1995 Roland McGrath + + * main.c (main): Handle 1 and 2 returns from update_goal_chain + makefile run properly. + + * Version 3.72.12. + + * main.c (handle_non_switch_argument): New function, broken out of + decode_switches. + (decode_switches): Set optind to 0 to reinitialize getopt, not to 1. + When getopt_long returns EOF, break the loop and handle remaining args + with a simple second loop. + + * remake.c (remake_file): Set update_status to 2 instead of 1 for + no rule to make. Mention parent (dependent) in error message. + (update_file_1): Handle FILE->update_status == 2 in -d printout. + * job.c (start_job_command, reap_children): Set update_status to 2 + instead of 1 for failed commands. + +Tue Mar 21 16:23:38 1995 Roland McGrath + + * job.c (search_path): Function removed (was already #if 0'd out). + * configure.in: Remove AC_TYPE_GETGROUPS; nothing needs it any more. + +Fri Mar 17 15:57:40 1995 Roland McGrath + + * configure.bat: Write @CPPFLAGS@ translation. + +Mon Mar 13 00:45:59 1995 Roland McGrath + + * read.c (parse_file_seq): Rearranged `l(a b)' -> `l(a) l(b)' loop + to not skip the elt immediately preceding `l(...'. + +Fri Mar 10 13:56:49 1995 Roland McGrath + + * Version 3.72.11. + + * read.c (find_char_unquote): Make second arg a string of stop + chars instead of a single stop char. Stop when any char in the + string is hit. All callers changed. + (find_semicolon): Pass stop chars "#;" to one find_char_unquote call, + instead of using two calls. If the match is not a ; but a #, + return zero. + * misc.c: Changed find_char_unquote callers here too. + + * Version 3.72.10. + + * read.c (read_makefile, parse_file_seq): Fix typo __MS_DOS__ -> + __MSDOS__. + + * GNUmakefile (globfiles): Add glob/configure.bat. + (distfiles): Add configh.dos, configure.bat. + +Wed Mar 8 13:10:57 1995 Roland McGrath + + Fixes for MS-DOS from DJ Delorie. + * read.c (read_makefile, parse_file_seq) [__MS_DOS__]: Don't see : + as separator in "C:\...". + * configh.dos (STDC_HEADERS): Define only if undefined. + (HAVE_SYS_PARAM_H): Don't define this. + (HAVE_STRERROR): Define this. + * job.c (construct_command_argv_internal) [__MSDOS__]: Fix typos. + + * Version 3.72.9. + + * main.c (decode_switches): Reset optind to 1 instead of 0. + +Tue Mar 7 17:31:06 1995 Roland McGrath + + * main.c (decode_switches): If non-option arg is "-", ignore it. + +Mon Mar 6 23:57:38 1995 Roland McGrath + + * Version 3.72.8. + +Wed Feb 22 21:26:36 1995 Roland McGrath + + * Version 3.72.7. + +Tue Feb 21 22:10:43 1995 Roland McGrath + + * main.c (main): Pass missing arg to tmpnam. + + * configure.in: Check for strsignal. + * job.c (child_error): Use strsignal. + * main.c (main): Don't call signame_init #ifdef HAVE_STRSIGNAL. + + * misc.c (strerror): Fix swapped args in sprintf. + +Mon Feb 13 11:50:08 1995 Roland McGrath + + * configure.in (CFLAGS, LDFLAGS): Don't set these variables. + +Fri Feb 10 18:44:12 1995 Roland McGrath + + * main.c (print_version): Add 95 to copyright years. + + * Version 3.72.6. + + * job.c (start_job_command): Remember to call notice_finished_file + under -n when not recursing. To do this, consolidate that code + under the empty command case and goto there for the -n case. + +Tue Feb 7 13:36:03 1995 Roland McGrath + + * make.h [! STDC_HEADERS]: Don't declare qsort. Sun headers + declare it int. + +Mon Feb 6 17:37:01 1995 Roland McGrath + + * read.c (read_makefile): For bogus line starting with tab, ignore + it if blank after removing comments. + + * main.c: Cast results of `alloca' to `char *'. + * expand.c: Likewise. + +Sun Feb 5 18:35:46 1995 Roland McGrath + + * Version 3.72.5. + + * configure.in: Check for mktemp. + * main.c (main) [! HAVE_MKTEMP]: Use tmpnam instead of mktemp. + + * configure.in (make_cv_sysconf_open_max): New check for `sysconf + (_SC_OPEN_MAX)'. + * acconfig.h: Added #undef HAVE_SYSCONF_OPEN_MAX. + * job.c [HAVE_SYSCONF_OPEN_MAX] (getdtablesize): Define as macro + using sysconf. + +Fri Jan 27 04:42:09 1995 Roland McGrath + + * remake.c (update_file_1): When !MUST_MAKE, don't set + FILE->update_status to zero before calling notice_finished_file. + (notice_finished_file): Touch only when FILE->update_status is zero. + (remake_file): Set FILE->update_status to zero after not calling + execute_file_command and deciding to touch instead. + +Thu Jan 26 01:29:32 1995 Roland McGrath + + * main.c (debug_signal_handler): New function; toggles debug_flag. + (main): Handle SIGUSR1 with that. + +Mon Jan 16 15:46:56 1995 Roland McGrath + + * compatMakefile (realclean): Remove Info files. + +Sun Jan 15 08:23:09 1995 Roland McGrath + + * Version 3.72.4. + + * job.c (start_job_command): Save and restore environ around vfork + call. + (search_path): Function #if 0'd out. + (exec_command): Use execvp instead of search_path. + + * expand.c (variable_expand): Rewrote computed variable name and + substitution reference handling to be simpler. First expand the + entire text between the parens if it contains any $s, then examine + the result of that for subtitution references and do no further + expansion while parsing them. + + * job.c (construct_command_argv_internal): Handle " quoting too, + when no backslash, $ or ` characters appear inside the quotes. + + * configure.in (union wait check): If WEXITSTATUS and WTERMSIG are + defined, just use int. + +Tue Jan 10 06:27:27 1995 Roland McGrath + + * default.c (default_variables) [__hpux]: Remove special + definition of ARFLAGS. Existence of the `f' flag is not + consistent across HPUX versions; and one might be using GNU ar + anyway. + + * compatMakefile (clean): Don't remove Info files. + + * compatMakefile (check): Remove gratuitous target declaration. + +Sat Jan 7 11:38:23 1995 Roland McGrath + + * compatMakefile (ETAGS, CTAGS): Don't use -t. + + * arscan.c (ar_name_equal) [cray]: Subtract 1 like [__hpux]. + + * main.c (decode_switches): For --help, print usage to stdout. + +Mon Dec 5 12:42:18 1994 Roland McGrath + + * Version 3.72.3. + + * remake.c (update_file_1): Do set_command_state (FILE, + cs_not_started) only if old state was deps_running. + +Mon Nov 28 14:24:03 1994 Roland McGrath + + * job.c (start_waiting_job): Use set_command_state. + + * build.template (CPPFLAGS): New variable. + (prefix, exec_prefix): Set from @...@. + (compilation loop): Pass $CPPFLAGS to compiler. + + * GNUmakefile (build.sh.in): Make it executable. + + * GNUmakefile (globfiles): Add configure.in, configure. + + * Version 3.72.2. + + * configure.in (AC_OUTPUT): Don't write glob/Makefile. + + * configure.in (AC_CHECK_SYMBOL): Use AC_DEFINE_UNQUOTED. + + * configure.in: Don't check for ranlib. + +Tue Nov 22 22:42:40 1994 Roland McGrath + + * remake.c (notice_finished_file): Only mark also_make's as + updated if really ran cmds. + +Tue Nov 15 06:32:46 1994 Roland McGrath + + * configure.in: Put dnls before random whitespace. + +Sun Nov 13 05:02:25 1994 Roland McGrath + + * compatMakefile (CPPFLAGS): New variable, set from @CPPFLAGS@. + (RANLIB): Variable removed. + (prefix, exec_prefix): Set these from @...@. + (.c.o): Use $(CPPFLAGS). + (glob/libglob.a): Don't pass down variables to sub-make. + glob/Makefile should be configured properly by configure. + (distclean): Remove config.log and config.cache (autoconf stuff). + +Mon Nov 7 13:58:06 1994 Roland McGrath + + * acconfig.h: Add #undef HAVE_UNION_WAIT. + * configure.in: Converted to Autoconf v2. + * dir.c: Test HAVE_DIRENT_H, HAVE_SYS_DIR_H, HAVE_NDIR_H instead + of DIRENT, SYSDIR, NDIR. + * build.sh.in (prefix, exec_prefix): Set these from @...@. + (CPPFLAGS): New variable, set from @CPPFLAGS@. + (compiling loop): Pass $CPPFLAGS before $CFLAGS. + * install.sh: File renamed to install-sh. + + * main.c (define_makeflags): When no flags, set WORDS to zero. + Sun Nov 6 18:34:01 1994 Roland McGrath * Version 3.72.1. diff -ruN make-3.72.1/INSTALL make-3.73/INSTALL --- make-3.72.1/INSTALL Tue Oct 18 16:30:28 1994 +++ make-3.73/INSTALL Wed Feb 8 10:10:46 1995 @@ -43,9 +43,13 @@ documentation. 5. You can remove the program binaries and object files from the - source directory by typing `make clean'. To also remove the files - that `configure' created (so you can compile the package for a - different kind of computer), type `make distclean'. + source code directory by typing `make clean'. To also remove the + files that `configure' created (so you can compile the package for + a different kind of computer), type `make distclean'. There is + also a `make maintainer-clean' target, but that is intended mainly + for the package's developers. If you use it, you may have to get + all sorts of other programs in order to regenerate files that came + with the distribution. Compilers and Options ===================== @@ -60,17 +64,22 @@ Or on systems that have the `env' program, you can do it like this: env CPPFLAGS=-I/usr/local/include LDFLAGS=-s ./configure -Using a Different Build Directory -================================= +Compiling For Multiple Architectures +==================================== - You can compile the package in a different directory from the one -containing the source code. Doing so allows you to compile it on more -than one kind of computer at the same time. To do this, you must use a -version of `make' that supports the `VPATH' variable, such as GNU -`make'. `cd' to the directory where you want the object files and -executables to go and run the `configure' script. `configure' -automatically checks for the source code in the directory that -`configure' is in and in `..'. + You can compile the package for more than one kind of computer at the +same time, by placing the object files for each architecture in their +own directory. To do this, you must use a version of `make' that +supports the `VPATH' variable, such as GNU `make'. `cd' to the +directory where you want the object files and executables to go and run +the `configure' script. `configure' automatically checks for the +source code in the directory that `configure' is in and in `..'. + + If you have to use a `make' that does not supports the `VPATH' +variable, you have to compile the package for one architecture at a time +in the source code directory. After you have installed the package for +one architecture, use `make distclean' before reconfiguring for another +architecture. Installation Names ================== @@ -143,9 +152,9 @@ operates. `--cache-file=FILE' - Save the results of the tests in FILE instead of `config.cache'. - Set FILE to `/dev/null' to disable caching, for debugging - `configure'. + Use and save the results of the tests in FILE instead of + `./config.cache'. Set FILE to `/dev/null' to disable caching, for + debugging `configure'. `--help' Print a summary of the options to `configure', and exit. diff -ruN make-3.72.1/Makefile.in make-3.73/Makefile.in --- make-3.72.1/Makefile.in Sun Nov 6 18:35:49 1994 +++ make-3.73/Makefile.in Wed Apr 5 00:41:26 1995 @@ -1,7 +1,7 @@ # NOTE: If you have no `make' program at all to process this makefile, run # `build.sh' instead. # -# Copyright (C) 1988, 1989, 1991, 1992, 1993, 1994 Free Software Foundation, Inc. +# Copyright (C) 1988, 89, 91, 92, 93, 94, 1995 Free Software Foundation, Inc. # This file is part of GNU Make. # # GNU Make is free software; you can redistribute it and/or modify @@ -30,11 +30,9 @@ CC = @CC@ CFLAGS = @CFLAGS@ +CPPFLAGS = @CPPFLAGS@ LDFLAGS = @LDFLAGS@ -# How to invoke ranlib. This is only used by the `glob' subdirectory. -RANLIB = @RANLIB@ - # Define these for your system as follows: # -DNO_ARCHIVES To disable `ar' archive support. # -DNO_FLOAT To avoid using floating-point numbers. @@ -77,9 +75,9 @@ extras = @LIBOBJS@ # Common prefix for machine-independent installed files. -prefix = /usr/local +prefix = @prefix@ # Common prefix for machine-dependent installed files. -exec_prefix = $(prefix) +exec_prefix = @exec_prefix@ # Directory to install `make' in. bindir = $(exec_prefix)/bin @@ -119,8 +117,8 @@ TEXI2DVI = texi2dvi # Programs to make tags files. -ETAGS = etags -tw -CTAGS = ctags -tw +ETAGS = etags -w +CTAGS = ctags -w objs = commands.o job.o dir.o file.o misc.o main.o read.o remake.o \ rule.o implicit.o default.o variable.o expand.o function.o \ @@ -144,10 +142,9 @@ .SUFFIXES: .o .c .h .ps .dvi .info .texinfo all: make -check: # No tests. info: make.info dvi: make.dvi -# Some makes apparently use .PHONY as the default goal is it is before `all'. +# Some makes apparently use .PHONY as the default goal if it is before `all'. .PHONY: all check info dvi make.info: make.texinfo @@ -166,17 +163,14 @@ # -I. is needed to find config.h in the build directory. .c.o: $(CC) $(defines) -c -I. -I$(srcdir) -I$(srcdir)/glob \ - $(CFLAGS) $< $(OUTPUT_OPTION) + $(CPPFLAGS) $(CFLAGS) $< $(OUTPUT_OPTION) # For some losing Unix makes. SHELL = /bin/sh @SET_MAKE@ glob/libglob.a: FORCE config.h - cd glob; $(MAKE) CC='$(CC)' CFLAGS='$(CFLAGS) -I..' \ - CPPFLAGS='$(CPPFLAGS) -DHAVE_CONFIG_H' \ - RANLIB='$(RANLIB)' \ - libglob.a + cd glob; $(MAKE) libglob.a FORCE: tagsrcs = $(srcs) $(srcdir)/remote-*.c @@ -201,7 +195,7 @@ else \ echo "$@ needs to be owned by group $(group) and setgid;"; \ echo "otherwise the \`-l' option will probably not work."; \ - echo "You may need special priveleges to install $@."; \ + echo "You may need special privileges to install $@."; \ fi; \ else true; fi # Some systems can't deal with renaming onto a running binary. @@ -247,13 +241,15 @@ .PHONY: clean realclean distclean mostlyclean clean: glob-clean - -rm -f make loadavg *.o core make.info* make.dvi + -rm -f make loadavg *.o core make.dvi distclean: clean glob-realclean -rm -f Makefile config.h config.status build.sh stamp-config + -rm -f config.log config.cache -rm -f TAGS tags -rm -f make.?? make.??s make.log make.toc make.*aux -rm -f loadavg.c realclean: distclean + -rm -f make.info* mostlyclean: clean .PHONY: glob-clean glob-realclean @@ -269,11 +265,10 @@ $(SHELL) config.status touch stamp-config -# These rules cause too much trouble. -#configure: configure.in -# autoconf $(ACFLAGS) -#config.h.in: configure.in -# autoheader $(ACFLAGS) +#configure: configure.in aclocal.m4 +# cd $(srcdir) && autoconf $(ACFLAGS) +#config.h.in: configure.in aclocal.m4 +# cd $(srcdir) && autoheader $(ACFLAGS) # This tells versions [3.59,3.63) of GNU make not to export all variables. .NOEXPORT: @@ -287,25 +282,25 @@ # Automatically generated dependencies. commands.o : commands.c make.h dep.h commands.h file.h variable.h job.h -job.o : job.c make.h commands.h job.h file.h variable.h -dir.o : dir.c make.h +job.o: job.c make.h commands.h job.h file.h variable.h +dir.o: dir.c make.h file.o : file.c make.h commands.h dep.h file.h variable.h -misc.o : misc.c make.h dep.h -main.o : main.c make.h commands.h dep.h file.h variable.h job.h getopt.h -read.o : read.c make.h commands.h dep.h file.h variable.h glob/glob.h -remake.o : remake.c make.h commands.h job.h dep.h file.h +misc.o: misc.c make.h dep.h +main.o: main.c make.h commands.h dep.h file.h variable.h job.h getopt.h +read.o: read.c make.h commands.h dep.h file.h variable.h glob/glob.h +remake.o: remake.c make.h commands.h job.h dep.h file.h rule.o : rule.c make.h config.h commands.h dep.h file.h variable.h rule.h implicit.o : implicit.c make.h rule.h dep.h file.h -default.o : default.c make.h rule.h dep.h file.h commands.h variable.h +default.o: default.c make.h rule.h dep.h file.h commands.h variable.h variable.o : variable.c make.h commands.h variable.h dep.h file.h -expand.o : expand.c make.h config.h commands.h file.h variable.h +expand.o: expand.c make.h commands.h file.h variable.h function.o : function.c make.h variable.h dep.h commands.h job.h vpath.o : vpath.c make.h file.h variable.h -version.o : version.c +version.o: version.c ar.o : ar.c make.h file.h dep.h -arscan.o : arscan.c make.h -signame.o : signame.c signame.h +arscan.o: arscan.c make.h +signame.o: signame.c signame.h remote-stub.o : remote-stub.c make.h commands.h -getopt.o : getopt.c getopt.h +getopt.o: getopt.c getopt.h getopt1.o : getopt1.c getopt.h -getloadavg.o : getloadavg.c +getloadavg.o: getloadavg.c diff -ruN make-3.72.1/NEWS make-3.73/NEWS --- make-3.72.1/NEWS Wed Oct 26 02:15:40 1994 +++ make-3.73/NEWS Thu Jan 26 01:30:38 1995 @@ -1,10 +1,18 @@ -GNU make NEWS -- history of user-visible changes. 24 October 1994 +GNU make NEWS -- history of user-visible changes. 26 January 1995 -Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc. +Copyright (C) 1992, 1993, 1994, 1995 Free Software Foundation, Inc. See the end for copying conditions. Please send GNU make bug reports to bug-gnu-utils@prep.ai.mit.edu. +Version 3.73 + +* Converted to use Autoconf version 2, so `configure' has some new options. + See INSTALL for details. + +* You can now send a SIGUSR1 signal to Make to toggle printing of debugging + output enable by -d, at any time during the run. + Version 3.72 * DJ Delorie has ported Make to MS-DOS using the GO32 extender. @@ -532,7 +540,7 @@ ---------------------------------------------------------------------- Copyright information: -Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc. +Copyright (C) 1992, 1993, 1994, 1995 Free Software Foundation, Inc. Permission is granted to anyone to make or distribute verbatim copies of this document as received, in any medium, provided that the diff -ruN make-3.72.1/README make-3.73/README --- make-3.72.1/README Sun Nov 6 18:35:42 1994 +++ make-3.73/README Wed Apr 5 00:41:12 1995 @@ -1,4 +1,4 @@ -This directory contains the 3.72.1 test release of GNU Make. +This directory contains the 3.73 test release of GNU Make. All bugs reported for previous test releases have been fixed. Some bugs surely remain. diff -ruN make-3.72.1/acconfig.h make-3.73/acconfig.h --- make-3.72.1/acconfig.h Fri Sep 9 03:16:54 1994 +++ make-3.73/acconfig.h Sun Feb 5 18:36:04 1995 @@ -9,3 +9,9 @@ /* Define this if the C library defines the variable `_sys_siglist'. */ #undef HAVE__SYS_SIGLIST + +/* Define this if you have the `union wait' type in . */ +#undef HAVE_UNION_WAIT + +/* Define this if the POSIX.1 call `sysconf (_SC_OPEN_MAX)' works properly. */ +#undef HAVE_SYSCONF_OPEN_MAX diff -ruN make-3.72.1/arscan.c make-3.73/arscan.c --- make-3.72.1/arscan.c Mon Jul 4 17:51:49 1994 +++ make-3.73/arscan.c Sat Jan 7 11:55:30 1995 @@ -429,11 +429,11 @@ struct ar_hdr hdr; return !strncmp (name, mem, sizeof (hdr.ar_name) - -#ifndef __hpux +#if !defined (__hpux) && !defined (cray) 1 #else 2 -#endif /* __hpux */ +#endif /* !__hpux && !cray */ ); #endif } diff -ruN make-3.72.1/build.sh.in make-3.73/build.sh.in --- make-3.72.1/build.sh.in Sat May 21 16:48:46 1994 +++ make-3.73/build.sh.in Wed Mar 8 13:18:10 1995 @@ -1,8 +1,8 @@ #!/bin/sh - # Shell script to build GNU Make in the absence of any `make' program. +# @configure_input@ -# Copyright (C) 1993 Free Software Foundation, Inc. +# Copyright (C) 1993, 1994 Free Software Foundation, Inc. # This file is part of GNU Make. # # GNU Make is free software; you can redistribute it and/or modify @@ -24,6 +24,7 @@ srcdir='@srcdir@' CC='@CC@' CFLAGS='@CFLAGS@' +CPPFLAGS='@CPPFLAGS@' LDFLAGS='@LDFLAGS@' defines='@DEFS@ -DLIBDIR="${libdir}" -DINCLUDEDIR="${includedir}"' ALLOCA='@ALLOCA@' @@ -32,9 +33,9 @@ REMOTE='@REMOTE@' # Common prefix for machine-independent installed files. -prefix=/usr/local +prefix='@prefix@' # Common prefix for machine-dependent installed files. -exec_prefix=/usr/local +exec_prefix='@exec_prefix@' # Directory to find libraries in for `-lXXX'. libdir=${exec_prefix}/lib # Directory to search by default for included makefiles. @@ -49,7 +50,8 @@ # Compile the source files into those objects. for file in `echo ${objs} | sed 's/\.o/.c/g'`; do echo compiling ${file}... - $CC $CFLAGS $defines -c -I. -I${srcdir} -I${srcdir}/glob ${srcdir}/$file + $CC $defines $CPPFLAGS $CFLAGS \ + -c -I. -I${srcdir} -I${srcdir}/glob ${srcdir}/$file done # The object files were actually all put in the current directory. diff -ruN make-3.72.1/config.h.in make-3.73/config.h.in --- make-3.72.1/config.h.in Fri Sep 9 03:18:33 1994 +++ make-3.73/config.h.in Fri Mar 24 02:30:37 1995 @@ -20,44 +20,87 @@ /* Define for DGUX with . */ #undef DGUX -/* Define if you have dirent.h. */ -#undef DIRENT - -/* Define to the type of elements in the array set by `getgroups'. - Usually this is either `int' or `gid_t'. */ -#undef GETGROUPS_T - /* Define if the `getloadavg' function needs to be run setuid or setgid. */ #undef GETLOADAVG_PRIVILEGED /* Define to `int' if doesn't define. */ #undef gid_t -/* Define if you have alloca.h and it should be used (not Ultrix). */ +/* Define if you have alloca, as a function or macro. */ +#undef HAVE_ALLOCA + +/* Define if you have and it should be used (not on Ultrix). */ #undef HAVE_ALLOCA_H +/* Define if you don't have vprintf but do have _doprnt. */ +#undef HAVE_DOPRNT + /* Define if your system has its own `getloadavg' function. */ #undef HAVE_GETLOADAVG +/* Define if you have the getmntent function. */ +#undef HAVE_GETMNTENT + +/* Define if the `long double' type works. */ +#undef HAVE_LONG_DOUBLE + +/* Define if you support file names longer than 14 characters. */ +#undef HAVE_LONG_FILE_NAMES + +/* Define if you have a working `mmap' system call. */ +#undef HAVE_MMAP + +/* Define if system calls automatically restart after interruption + by a signal. */ +#undef HAVE_RESTARTABLE_SYSCALLS + +/* Define if your struct stat has st_blksize. */ +#undef HAVE_ST_BLKSIZE + +/* Define if your struct stat has st_blocks. */ +#undef HAVE_ST_BLOCKS + /* Define if you have the strcoll function and it is properly defined. */ #undef HAVE_STRCOLL -/* Define if `union wait' is the type of the first arg to wait functions. */ -#undef HAVE_UNION_WAIT +/* Define if your struct stat has st_rdev. */ +#undef HAVE_ST_RDEV + +/* Define if you have the strftime function. */ +#undef HAVE_STRFTIME + +/* Define if you have that is POSIX.1 compatible. */ +#undef HAVE_SYS_WAIT_H + +/* Define if your struct tm has tm_zone. */ +#undef HAVE_TM_ZONE -/* Define if you have vfork.h. */ +/* Define if you don't have tm_zone but do have the external array + tzname. */ +#undef HAVE_TZNAME + +/* Define if you have . */ +#undef HAVE_UNISTD_H + +/* Define if utime(file, NULL) sets file's timestamp to the present. */ +#undef HAVE_UTIME_NULL + +/* Define if you have . */ #undef HAVE_VFORK_H +/* Define if you have the vprintf function. */ +#undef HAVE_VPRINTF + +/* Define if you have the wait3 system call. */ +#undef HAVE_WAIT3 + /* Define if on MINIX. */ #undef _MINIX -/* Define if you don't have dirent.h, but have ndir.h. */ -#undef NDIR - /* Define if your struct nlist has an n_un member. */ #undef NLIST_NAME_UNION -/* Define if you have nlist.h. */ +/* Define if you have . */ #undef NLIST_STRUCT /* Define if your C compiler doesn't accept -c and -o together. */ @@ -99,12 +142,6 @@ /* Define on System V Release 4. */ #undef SVR4 -/* Define if you don't have dirent.h, but have sys/dir.h. */ -#undef SYSDIR - -/* Define if you don't have dirent.h, but have sys/ndir.h. */ -#undef SYSNDIR - /* Define if `sys_siglist' is declared by . */ #undef SYS_SIGLIST_DECLARED @@ -121,9 +158,6 @@ /* Define vfork as fork if vfork does not work. */ #undef vfork -/* Define if the closedir function returns void instead of int. */ -#undef VOID_CLOSEDIR - /* Define to the name of the SCCS `get' command. */ #undef SCCS_GET @@ -136,48 +170,63 @@ /* Define this if the C library defines the variable `_sys_siglist'. */ #undef HAVE__SYS_SIGLIST -/* Define if you have dup2. */ +/* Define this if you have the `union wait' type in . */ +#undef HAVE_UNION_WAIT + +/* Define this if the POSIX.1 call `sysconf (_SC_OPEN_MAX)' works properly. */ +#undef HAVE_SYSCONF_OPEN_MAX + +/* Define if you have the dup2 function. */ #undef HAVE_DUP2 -/* Define if you have getcwd. */ +/* Define if you have the getcwd function. */ #undef HAVE_GETCWD -/* Define if you have getdtablesize. */ +/* Define if you have the getdtablesize function. */ #undef HAVE_GETDTABLESIZE -/* Define if you have getgroups. */ +/* Define if you have the getgroups function. */ #undef HAVE_GETGROUPS -/* Define if you have psignal. */ +/* Define if you have the mktemp function. */ +#undef HAVE_MKTEMP + +/* Define if you have the psignal function. */ #undef HAVE_PSIGNAL -/* Define if you have setegid. */ +/* Define if you have the setegid function. */ #undef HAVE_SETEGID -/* Define if you have seteuid. */ +/* Define if you have the seteuid function. */ #undef HAVE_SETEUID -/* Define if you have setlinebuf. */ +/* Define if you have the setlinebuf function. */ #undef HAVE_SETLINEBUF -/* Define if you have setregid. */ +/* Define if you have the setregid function. */ #undef HAVE_SETREGID -/* Define if you have setreuid. */ +/* Define if you have the setreuid function. */ #undef HAVE_SETREUID -/* Define if you have sigsetmask. */ +/* Define if you have the sigsetmask function. */ #undef HAVE_SIGSETMASK -/* Define if you have strerror. */ +/* Define if you have the strerror function. */ #undef HAVE_STRERROR -/* Define if you have wait3. */ +/* Define if you have the strsignal function. */ +#undef HAVE_STRSIGNAL + +/* Define if you have the wait3 function. */ #undef HAVE_WAIT3 -/* Define if you have waitpid. */ +/* Define if you have the waitpid function. */ #undef HAVE_WAITPID +/* Define if you have the header file. */ +#undef HAVE_DIRENT_H + /* Define if you have the header file. */ #undef HAVE_FCNTL_H @@ -190,9 +239,18 @@ /* Define if you have the header file. */ #undef HAVE_MEMORY_H +/* Define if you have the header file. */ +#undef HAVE_NDIR_H + /* Define if you have the header file. */ #undef HAVE_STRING_H +/* Define if you have the header file. */ +#undef HAVE_SYS_DIR_H + +/* Define if you have the header file. */ +#undef HAVE_SYS_NDIR_H + /* Define if you have the header file. */ #undef HAVE_SYS_PARAM_H @@ -208,20 +266,5 @@ /* Define if you have the dgc library (-ldgc). */ #undef HAVE_LIBDGC -/* Define if you have the elf library (-lelf). */ -#undef HAVE_LIBELF - -/* Define if you have the getloadavg library (-lgetloadavg). */ -#undef HAVE_LIBGETLOADAVG - -/* Define if you have the kvm library (-lkvm). */ -#undef HAVE_LIBKVM - -/* Define if you have the seq library (-lseq). */ -#undef HAVE_LIBSEQ - /* Define if you have the sun library (-lsun). */ #undef HAVE_LIBSUN - -/* Define if you have the util library (-lutil). */ -#undef HAVE_LIBUTIL diff -ruN make-3.72.1/configh.dos make-3.73/configh.dos --- make-3.72.1/configh.dos Wed Dec 31 19:00:00 1969 +++ make-3.73/configh.dos Wed Mar 8 20:11:28 1995 @@ -0,0 +1,68 @@ +/* Generated automatically from configure.in by autoheader. DO NOT EDIT! */ + +#define INCLUDEDIR "c:/djgpp/include" +#define LIBDIR "c:/djgpp/lib" + +/* Define if you have dirent.h. */ +#define DIRENT + +/* Define if you have the strcoll function and it is properly defined. */ +#define HAVE_STRCOLL + +/* Define if you have unistd.h. */ +#define HAVE_UNISTD_H + +/* Define as the return type of signal handlers (int or void). */ +#define RETSIGTYPE void + +/* Define if you have the ANSI C header files. */ +#ifndef STDC_HEADERS +#define STDC_HEADERS +#endif + +/* Define if `sys_siglist' is declared by . */ +#define SYS_SIGLIST_DECLARED + +/* Define if you have getdtablesize. */ +#define HAVE_GETDTABLESIZE + +/* Define if you have dup2. */ +#define HAVE_DUP2 + +/* Define if you have sys_siglist. */ +#undef HAVE_SYS_SIGLIST + +/* Define if you have _sys_siglist. */ +#undef HAVE__SYS_SIGLIST + +/* Define if you have psignal. */ +#define HAVE_PSIGNAL + +/* Define if you have getcwd. */ +#define HAVE_GETCWD + +/* Define if you have sigsetmask. */ +#define HAVE_SIGSETMASK + +/* Define if you have setlinebuf. */ +#define HAVE_SETLINEBUF + +/* Define if you have the header file. */ +#define HAVE_LIMITS_H + +/* Define if you have the header file. */ +#undef HAVE_SYS_PARAM_H + +/* Define if you have the header file. */ +#define HAVE_FCNTL_H + +/* Define if you have the header file. */ +#define HAVE_STRING_H + +/* Define if you have the header file. */ +#define HAVE_MEMORY_H + +/* Define if you have the `strerror' function. */ +#define HAVE_STRERROR + +#define SCCS_GET "get" diff -ruN make-3.72.1/configure.in make-3.73/configure.in --- make-3.72.1/configure.in Sat Jun 4 01:11:12 1994 +++ make-3.73/configure.in Tue Mar 21 16:23:26 1995 @@ -1,78 +1,102 @@ dnl Process this file with autoconf to produce a configure script. -AC_REVISION([$Id: configure.in,v 1.37 1994/06/04 05:11:12 roland Beta $]) -AC_INIT(vpath.c) dnl A distinctive file to look for in srcdir. +AC_REVISION([$Id: configure.in,v 1.48 1995/03/21 21:23:26 roland Exp $]) +AC_PREREQ(2.1)dnl dnl Minimum Autoconf version required. +AC_INIT(vpath.c)dnl dnl A distinctive file to look for in srcdir. AC_CONFIG_HEADER(config.h) +AC_CONFIG_SUBDIRS(glob) dnl Run configure in glob subdirectory. -# We want these before the checks, so the checks can modify their values. -test -z "$CFLAGS" && CFLAGS=-g AC_SUBST(CFLAGS) -test -z "$LDFLAGS" && LDFLAGS=-g AC_SUBST(LDFLAGS) - -AC_SET_MAKE +AC_PROG_MAKE_SET AC_PROG_CC AC_PROG_INSTALL -AC_PROG_RANLIB AC_PROG_CPP dnl Later checks need this. AC_AIX AC_ISC_POSIX AC_MINIX -AC_STDC_HEADERS -AC_DIR_HEADER -AC_UID_T dnl Also does gid_t. -AC_GETGROUPS_T -AC_PID_T -AC_RETSIGTYPE -AC_HAVE_HEADERS(unistd.h limits.h sys/param.h fcntl.h string.h memory.h \ - sys/timeb.h) -AC_MINUS_C_MINUS_O -AC_CONST dnl getopt needs this. -AC_STAT_MACROS_BROKEN +AC_HEADER_STDC +AC_HEADER_DIRENT +AC_TYPE_UID_T dnl Also does gid_t. +AC_TYPE_PID_T +AC_TYPE_SIGNAL +AC_CHECK_HEADERS(unistd.h limits.h sys/param.h fcntl.h string.h memory.h \ + sys/timeb.h) +AC_PROG_CC_C_O +AC_C_CONST dnl getopt needs this. +AC_HEADER_STAT AC_SUBST(LIBOBJS) -AC_HAVE_FUNCS(getdtablesize psignal \ - dup2 getcwd sigsetmask getgroups setlinebuf \ - seteuid setegid setreuid setregid strerror) -AC_COMPILE_CHECK(sys_siglist, , - [extern char *sys_siglist[]; puts(*sys_siglist);], - AC_DEFINE(HAVE_SYS_SIGLIST)) -AC_COMPILE_CHECK(_sys_siglist, , - [extern char *_sys_siglist[]; puts(*_sys_siglist);], - AC_DEFINE(HAVE__SYS_SIGLIST)) -AC_ALLOCA -AC_VFORK -AC_SETVBUF_REVERSED -AC_GETLOADAVG -AC_STRCOLL - -dnl Check out the wait reality. -AC_HAVE_HEADERS(sys/wait.h) AC_HAVE_FUNCS(waitpid wait3) -AC_COMPILE_CHECK(union wait, [#include +AC_DEFUN(AC_CHECK_SYMBOL, [dnl +AC_MSG_CHECKING(for $1) +AC_CACHE_VAL(ac_cv_check_symbol_$1, [dnl +AC_TRY_LINK(, [extern char *sys_siglist[]; puts(*sys_siglist);], + ac_cv_check_symbol_$1=yes, ac_cv_check_symbol_$1=no)]) +if test "$ac_cv_check_symbol_$1" = yes; then +changequote(,)dnl + ac_tr_symbol=`echo $1 | tr '[a-z]' '[A-Z]'` +changequote([,])dnl + AC_DEFINE_UNQUOTED(HAVE_${ac_tr_symbol}) +fi +AC_MSG_RESULT($ac_cv_check_symbol_$1)])dnl + +AC_CHECK_FUNCS(getdtablesize psignal mktemp \ + dup2 getcwd sigsetmask getgroups setlinebuf \ + seteuid setegid setreuid setregid strerror strsignal) +AC_CHECK_SYMBOL(sys_siglist) +AC_CHECK_SYMBOL(_sys_siglist) +AC_FUNC_ALLOCA +AC_FUNC_VFORK +AC_FUNC_SETVBUF_REVERSED +AC_FUNC_GETLOADAVG +AC_FUNC_STRCOLL + +if test $ac_cv_func_getdtablesize = no; then + AC_MSG_CHECKING(for sysconf (_SC_OPEN_MAX)) + AC_CACHE_VAL(make_cv_sysconf_open_max, [dnl + AC_TRY_LINK([#include ], [int max = sysconf (_SC_OPEN_MAX);], + [make_cv_sysconf_open_max=yes], [make_cv_sysconf_open_max=no])]) + if test $make_cv_sysconf_open_max = yes; then + AC_DEFINE(HAVE_SYSCONF_OPEN_MAX) + fi + AC_MSG_RESULT($make_cv_sysconf_open_max) +fi + +# Check out the wait reality. +AC_CHECK_HEADERS(sys/wait.h) AC_CHECK_FUNCS(waitpid wait3) +AC_MSG_CHECKING(for union wait) +AC_CACHE_VAL(make_cv_union_wait, [dnl +AC_TRY_LINK([#include #include ], - [union wait status; int pid; pid = wait (&status); + [union wait status; int pid; pid = wait (&status); #ifdef WEXITSTATUS /* Some POSIXoid systems have both the new-style macros and the old union wait type, and they do not work together. If union wait conflicts with WEXITSTATUS et al, we don't want to use it at all. */ if (WEXITSTATUS (status) != 0) pid = -1; +#ifdef WTERMSIG +/* If we have WEXITSTATUS and WTERMSIG, just use them on ints. */ +-- blow chunks here -- +#endif #endif #ifdef HAVE_WAITPID /* Make sure union wait works with waitpid. */ pid = waitpid (-1, &status, 0); #endif ], - AC_DEFINE(HAVE_UNION_WAIT)) + [make_cv_union_wait=yes], [make_cv_union_wait=no])]) +if test "$make_cv_union_wait" = yes; then + AC_DEFINE(HAVE_UNION_WAIT) +fi +AC_MSG_RESULT($make_cv_union_wait) -AC_SYS_SIGLIST_DECLARED +AC_DECL_SYS_SIGLIST # The presence of the following is not meant to imply # that make necessarily works on those systems. -AC_DYNIX_SEQ -AC_XENIX_DIR -AC_IRIX_SUN +AC_CHECK_LIB(sun, getpwnam) AC_SUBST(REMOTE) REMOTE=stub -AC_WITH(customs, [REMOTE=cstms -LIBS="$LIBS libcustoms.a"]) +AC_ARG_WITH(customs, [export jobs with the Customs daemon (NOT SUPPORTED)], +[REMOTE=cstms LIBS="$LIBS libcustoms.a"]) echo checking for location of SCCS get command if test -f /usr/sccs/get; then @@ -94,7 +118,7 @@ fi rm -f s.conftest conftoast -AC_OUTPUT(Makefile build.sh glob/Makefile, [ +AC_OUTPUT(Makefile build.sh, [ # Makefile uses this timestamp file to know when to remake Makefile, # build.sh, and glob/Makefile. touch stamp-config]) diff -ruN make-3.72.1/configure make-3.73/configure --- make-3.72.1/configure Fri Sep 9 03:10:11 1994 +++ make-3.73/configure Tue Mar 28 13:03:34 1995 @@ -1,67 +1,44 @@ -#!/bin/sh -# From configure.in I"cfiguei +#! /bin/sh -#!/bin/sh +# From configure.in Id: configure.in,v 1.48 1995/03/21 21:23:26 roland Exp # Guess values for system-dependent variables and create Makefiles. -# Generated automatically using autoconf version 1.11 -# Copyright (C) 1991, 1992, 1993, 1994 Free Software Foundation, Inc. - -# This configure script is free software; you can redistribute it and/or -# modify it under the terms of the GNU General Public License as published -# by the Free Software Foundation; either version 2, or (at your option) -# any later version. - -# This script is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General -# Public License for more details. - -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. - -# Save the original args to write them into config.status later. -configure_args="$*" +# Generated automatically using autoconf version 2.3 +# Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc. +# +# This configure script is free software; the Free Software Foundation +# gives unlimited permission to copy, distribute and modify it. -# Only options that might do something get documented. -ac_usage="Usage: configure [options] [host] -Options: [defaults in brackets after descriptions] ---build=BUILD configure for building on BUILD [BUILD=HOST] ---disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) ---enable-FEATURE[=ARG] include FEATURE [ARG=yes] ---exec-prefix=PREFIX install host dependent files in PREFIX [/usr/local] ---help print this message ---host=HOST configure for HOST [guessed] ---prefix=PREFIX install host independent files in PREFIX [/usr/local] ---quiet, --silent do not print \`checking for...' messages ---srcdir=DIR find the sources in DIR [configure dir or ..] ---target=TARGET configure for TARGET [TARGET=HOST] ---verbose print results of checks ---version print the version of autoconf that created configure ---with-PACKAGE[=ARG] use PACKAGE [ARG=yes] ---without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) ---x-includes=DIR X include files are in DIR ---x-libraries=DIR X library files are in DIR" +# Defaults: +ac_help= +ac_default_prefix=/usr/local +# Any additions from configure.in: +ac_help="$ac_help +export jobs with the Customs daemon (NOT SUPPORTED)" # Initialize some variables set by options. # The variables have the same names as the options, with # dashes changed to underlines. build=NONE -exec_prefix= +cache_file=./config.cache +exec_prefix=NONE host=NONE no_create= nonopt=NONE -norecursion= -prefix= -program_prefix= -program_suffix= -program_transform_name= +no_recursion= +prefix=NONE +program_prefix=NONE +program_suffix=NONE +program_transform_name=s,x,x, silent= +site= srcdir= target=NONE verbose= -x_includes= -x_libraries= +x_includes=NONE +x_libraries=NONE + +# Initialize some other variables. +subdirs= ac_prev= for ac_option @@ -74,14 +51,13 @@ continue fi - # Accept (but ignore some of) the important Cygnus configure - # options, so we can diagnose typos. - case "$ac_option" in -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; *) ac_optarg= ;; esac + # Accept the important Cygnus configure options, so we can diagnose typos. + case "$ac_option" in -build | --build | --buil | --bui | --bu | --b) @@ -89,20 +65,27 @@ -build=* | --build=* | --buil=* | --bui=* | --bu=* | --b=*) build="$ac_optarg" ;; + -cache-file | --cache-file | --cache-fil | --cache-fi \ + | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) + ac_prev=cache_file ;; + -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ + | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) + cache_file="$ac_optarg" ;; + -disable-* | --disable-*) ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` - # Reject names that aren't valid shell variable names. + # Reject names that are not valid shell variable names. if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then - echo "configure: $ac_feature: invalid feature name" >&2; exit 1 + { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } fi ac_feature=`echo $ac_feature| sed 's/-/_/g'` eval "enable_${ac_feature}=no" ;; -enable-* | --enable-*) ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` - # Reject names that aren't valid shell variable names. + # Reject names that are not valid shell variable names. if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then - echo "configure: $ac_feature: invalid feature name" >&2; exit 1 + { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } fi ac_feature=`echo $ac_feature| sed 's/-/_/g'` case "$ac_option" in @@ -111,7 +94,6 @@ esac eval "enable_${ac_feature}='$ac_optarg'" ;; - # For backward compatibility, recognize -exec-prefix and --exec_prefix. -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | --exec | --exe | --ex) @@ -122,11 +104,42 @@ exec_prefix="$ac_optarg" ;; -gas | --gas | --ga | --g) - with_gas=yes ;; # Obsolete; use --with-gas. + # Obsolete; use --with-gas. + with_gas=yes ;; -help | --help | --hel | --he) + # Omit some internal or obsolete options to make the list less imposing. + # This message is too long to be a string in the A/UX 3.1 sh. cat << EOF -$ac_usage +Usage: configure [options] [host] +Options: [defaults in brackets after descriptions] +Configuration: + --cache-file=FILE cache test results in FILE + --help print this message + --no-create do not create output files + --quiet, --silent do not print \`checking...' messages + --version print the version of autoconf that created configure +Directory and file names: + --prefix=PREFIX install architecture-independent files in PREFIX + [$ac_default_prefix] + --exec-prefix=PREFIX install architecture-dependent files in PREFIX + [same as prefix] + --srcdir=DIR find the sources in DIR [configure dir or ..] + --program-prefix=PREFIX prepend PREFIX to installed program names + --program-suffix=SUFFIX append SUFFIX to installed program names + --program-transform-name=PROGRAM run sed PROGRAM on installed program names +Host type: + --build=BUILD configure for building on BUILD [BUILD=HOST] + --host=HOST configure for HOST [guessed] + --target=TARGET configure for TARGET [TARGET=HOST] +Features and packages: + --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) + --enable-FEATURE[=ARG] include FEATURE [ARG=yes] + --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] + --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) + --x-includes=DIR X include files are in DIR + --x-libraries=DIR X library files are in DIR +--enable and --with options recognized:$ac_help EOF exit 0 ;; @@ -136,15 +149,16 @@ host="$ac_optarg" ;; -nfp | --nfp | --nf) - with_fp=no ;; # Obsolete; use --without-fp. + # Obsolete; use --without-fp. + with_fp=no ;; -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | --no-cr | --no-c) no_create=yes ;; - -norecursion | --norecursion | --norecursio | --norecursi \ - | --norecurs | --norecur | --norecu | --norec | --nore | --nor) - norecursion=yes ;; + -no-recursion | --no-recursion | --no-recursio | --no-recursi \ + | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) + no_recursion=yes ;; -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) ac_prev=prefix ;; @@ -186,6 +200,11 @@ | -silent | --silent | --silen | --sile | --sil) silent=yes ;; + -site | --site | --sit) + ac_prev=site ;; + -site=* | --site=* | --sit=*) + site="$ac_optarg" ;; + -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) ac_prev=srcdir ;; -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) @@ -200,14 +219,14 @@ verbose=yes ;; -version | --version | --versio | --versi | --vers) - echo "configure generated by autoconf version 1.11" + echo "configure generated by autoconf version 2.3" exit 0 ;; -with-* | --with-*) ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` - # Reject names that aren't valid shell variable names. + # Reject names that are not valid shell variable names. if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then - echo "configure: $ac_package: invalid package name" >&2; exit 1 + { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } fi ac_package=`echo $ac_package| sed 's/-/_/g'` case "$ac_option" in @@ -218,14 +237,16 @@ -without-* | --without-*) ac_package=`echo $ac_option|sed -e 's/-*without-//'` - # Reject names that aren't valid shell variable names. + # Reject names that are not valid shell variable names. if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then - echo "configure: $ac_package: invalid package name" >&2; exit 1 + { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } fi ac_package=`echo $ac_package| sed 's/-/_/g'` eval "with_${ac_package}=no" ;; - --x) with_x=yes ;; # Obsolete; use --with-x. + --x) + # Obsolete; use --with-x. + with_x=yes ;; -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | --x-incl | --x-inc | --x-in | --x-i) @@ -241,15 +262,15 @@ | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) x_libraries="$ac_optarg" ;; - -*) echo "configure: $ac_option: invalid option; use --help to show usage" >&2; exit 1 + -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; } ;; *) if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then - echo "configure: warning: $ac_option: invalid host type" >&2 + echo "configure: warning: $ac_option: invalid host type" 1>&2 fi if test "x$nonopt" != xNONE; then - echo "configure: can only configure for one host and one target at a time" >&2; exit 1 + { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } fi nonopt="$ac_option" ;; @@ -258,31 +279,53 @@ done if test -n "$ac_prev"; then - echo "configure: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" >&2; exit 1 + { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; } fi -trap 'rm -fr conftest* confdefs* core $ac_clean_files; exit 1' 1 2 15 -trap 'rm -fr confdefs* $ac_clean_files' 0 +trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 -# Save the original args if we used an alternate arg parser. -ac_configure_temp="${configure_args-$*}" -# Strip out --no-create and --norecursion so they don't pile up. -configure_args= -for ac_arg in $ac_configure_temp; do +# File descriptor usage: +# 0 standard input +# 1 file creation +# 2 errors and warnings +# 3 some systems may open it to /dev/tty +# 4 used on the Kubota Titan +# 6 checking for... messages and results +# 5 compiler messages saved in config.log +if test "$silent" = yes; then + exec 6>/dev/null +else + exec 6>&1 +fi +exec 5>./config.log + +echo "\ +This file contains any messages produced by compilers while +running configure, to aid debugging if configure makes a mistake. +" 1>&5 + +# Strip out --no-create and --no-recursion so they do not pile up. +# Also quote any args containing shell metacharacters. +ac_configure_args= +for ac_arg +do case "$ac_arg" in -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | --no-cr | --no-c) ;; - -norecursion | --norecursion | --norecursio | --norecursi \ - | --norecurs | --norecur | --norecu | --norec | --nore | --nor) ;; - *) configure_args="$configure_args $ac_arg" ;; + -no-recursion | --no-recursion | --no-recursio | --no-recursi \ + | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; + *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) + ac_configure_args="$ac_configure_args '$ac_arg'" ;; + *) ac_configure_args="$ac_configure_args $ac_arg" ;; esac done # NLS nuisances. +# Only set LANG and LC_ALL to C if already set. # These must not be set unconditionally because not all systems understand # e.g. LANG=C (notably SCO). -if test "${LC_ALL+set}" = 'set'; then LC_ALL=C; export LC_ALL; fi -if test "${LANG+set}" = 'set'; then LANG=C; export LANG; fi +if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi +if test "${LANG+set}" = set; then LANG=C; export LANG; fi # confdefs.h avoids OS command line length limits that DEFS can exceed. rm -rf conftest* confdefs.h @@ -296,7 +339,7 @@ # Find the source files, if location was not specified. if test -z "$srcdir"; then ac_srcdir_defaulted=yes - # Try the directory containing this script, then `..'. + # Try the directory containing this script, then its parent. ac_prog=$0 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. @@ -304,89 +347,203 @@ if test ! -r $srcdir/$ac_unique_file; then srcdir=.. fi +else + ac_srcdir_defaulted=no fi if test ! -r $srcdir/$ac_unique_file; then - if test x$ac_srcdir_defaulted = xyes; then - echo "configure: can not find sources in ${ac_confdir} or .." >&2; exit 1 + if test "$ac_srcdir_defaulted" = yes; then + { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; } + else + { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; } + fi +fi +srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` + +# Prefer explicitly selected file to automatically selected ones. +if test -z "$CONFIG_SITE"; then + if test "x$prefix" != xNONE; then + CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" else - echo "configure: can not find sources in ${srcdir}" >&2; exit 1 + CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" fi fi +for ac_site_file in $CONFIG_SITE; do + if test -r "$ac_site_file"; then + echo "loading site script $ac_site_file" + . "$ac_site_file" + fi +done + +if test -r "$cache_file"; then + echo "loading cache $cache_file" + . $cache_file +else + echo "creating cache $cache_file" + > $cache_file +fi + ac_ext=c # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. -ac_cpp='${CPP}' -ac_compile='${CC-cc} $CFLAGS $LDFLAGS conftest.${ac_ext} -o conftest $LIBS >/dev/null 2>&1' +ac_cpp='$CPP $CPPFLAGS' +ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5 2>&5' +ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5 2>&5' + +if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then + # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. + if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then + ac_n= ac_c=' +' ac_t=' ' + else + ac_n=-n ac_c= ac_t= + fi +else + ac_n= ac_c='\c' ac_t= +fi - -# We want these before the checks, so the checks can modify their values. -test -z "$CFLAGS" && CFLAGS=-g -test -z "$LDFLAGS" && LDFLAGS=-g +ac_aux_dir= +for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do + if test -f $ac_dir/install-sh; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/install-sh -c" + break + elif test -f $ac_dir/install.sh; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/install.sh -c" + break + fi +done +if test -z "$ac_aux_dir"; then + { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; } +fi +ac_config_guess=$ac_aux_dir/config.guess +ac_config_sub=$ac_aux_dir/config.sub +ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. -cat > conftestmake <<'EOF' +subdirs="glob" + +echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 +set dummy ${MAKE-make}; ac_make=$2 +if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftestmake <<\EOF all: @echo 'ac_maketemp="${MAKE}"' EOF # GNU make sometimes prints "make[1]: Entering...", which would confuse us. eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=` -if test -n "$ac_maketemp"; then SET_MAKE= -else SET_MAKE="MAKE=${MAKE-make}"; fi +if test -n "$ac_maketemp"; then + eval ac_cv_prog_make_${ac_make}_set=yes +else + eval ac_cv_prog_make_${ac_make}_set=no +fi rm -f conftestmake - -if test -z "$CC"; then - # Extract the first word of `gcc', so it can be a program name with args. - set ac_dummy gcc; ac_word=$2 - test -n "$silent" || echo "checking for $ac_word" +fi +if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then + echo "$ac_t""yes" 1>&6 + SET_MAKE= +else + echo "$ac_t""no" 1>&6 + SET_MAKE="MAKE=${MAKE-make}" +fi + +# Extract the first word of "gcc", so it can be a program name with args. +set dummy gcc; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" for ac_dir in $PATH; do test -z "$ac_dir" && ac_dir=. if test -f $ac_dir/$ac_word; then - CC="gcc" + ac_cv_prog_CC="gcc" break fi done IFS="$ac_save_ifs" + test -z "$ac_cv_prog_CC" && ac_cv_prog_CC="cc" +fi +fi +CC="$ac_cv_prog_CC" +if test -n "$CC"; then + echo "$ac_t""$CC" 1>&6 +else + echo "$ac_t""no" 1>&6 fi -test -z "$CC" && CC="cc" -test -n "$CC" && test -n "$verbose" && echo " setting CC to $CC" -# Find out if we are using GNU C, under whatever name. -cat > conftest.c <&6 +if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.c < conftest.out 2>&1 -if egrep yes conftest.out >/dev/null 2>&1; then - GCC=1 # For later tests. +if ${CC-cc} -E conftest.c 2>&5 | egrep yes >/dev/null 2>&1; then + ac_cv_prog_gcc=yes +else + ac_cv_prog_gcc=no +fi +fi +echo "$ac_t""$ac_cv_prog_gcc" 1>&6 +if test $ac_cv_prog_gcc = yes; then + GCC=yes + if test "${CFLAGS+set}" != set; then + echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_prog_gcc_g'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + echo 'void f(){}' > conftest.c +if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then + ac_cv_prog_gcc_g=yes +else + ac_cv_prog_gcc_g=no fi rm -f conftest* -# Make sure to not get the incompatible SysV /etc/install and -# /usr/sbin/install, which might be in PATH before a BSD-like install, -# or the SunOS /usr/etc/install directory, or the AIX /bin/install, -# or the AFS install, which mishandles nonexistent args, or -# /usr/ucb/install on SVR4, which tries to use the nonexistent group -# `staff', or /sbin/install on IRIX which has incompatible command-line -# syntax. Sigh. -# -# On most BSDish systems install is in /usr/bin, not /usr/ucb -# anyway. -# This turns out not to be true, so the mere pathname isn't an indication -# of whether the program works. What we really need is a set of tests for -# the install program to see if it actually works in all the required ways. -# -# Avoid using ./install, which might have been erroneously created -# by make from ./install.sh. -if test -z "${INSTALL}"; then - test -n "$silent" || echo "checking for a BSD compatible install" - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" +fi + echo "$ac_t""$ac_cv_prog_gcc_g" 1>&6 + if test $ac_cv_prog_gcc_g = yes; then + CFLAGS="-g -O" + else + CFLAGS="-O" + fi + fi +else + GCC= + test "${CFLAGS+set}" = set || CFLAGS="-g" +fi + +# Find a good install program. We prefer a C program (faster), +# so one script is as good as another. But avoid the broken or +# incompatible versions: +# SysV /etc/install, /usr/sbin/install +# SunOS /usr/etc/install +# IRIX /sbin/install +# AIX /bin/install +# AFS /usr/afsws/bin/install, which mishandles nonexistent args +# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" +# ./install, which can be erroneously created by make from ./install.sh. +echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 +if test -z "$INSTALL"; then +if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" for ac_dir in $PATH; do - case "$ac_dir" in - ''|.|/etc|/sbin|/usr/sbin|/usr/etc|/usr/afsws/bin|/usr/ucb) ;; + # Account for people who put trailing slashes in PATH elements. + case "$ac_dir/" in + /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;; *) # OSF1 and SCO ODT 3.0 have their own names for install. - for ac_prog in installbsd scoinst install; do + for ac_prog in ginstall installbsd scoinst install; do if test -f $ac_dir/$ac_prog; then if test $ac_prog = install && grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then @@ -394,7 +551,7 @@ # OSF/1 installbsd also uses dspmsg, but is usable. : else - INSTALL="$ac_dir/$ac_prog -c" + ac_cv_path_install="$ac_dir/$ac_prog -c" break 2 fi fi @@ -403,633 +560,586 @@ esac done IFS="$ac_save_ifs" -fi - -if test -z "$INSTALL"; then # As a last resort, use the slow shell script. - for ac_dir in ${srcdir} ${srcdir}/.. ${srcdir}/../..; do - if test -f $ac_dir/install.sh; then - INSTALL="$ac_dir/install.sh -c"; break - fi - done + test -z "$ac_cv_path_install" && ac_cv_path_install="$ac_install_sh" fi -if test -z "$INSTALL"; then - echo "configure: can not find install.sh in ${srcdir} or ${srcdir}/.. or ${srcdir}/../.." >&2; exit 1 + INSTALL="$ac_cv_path_install" fi -test -n "$verbose" && echo " setting INSTALL to $INSTALL" +echo "$ac_t""$INSTALL" 1>&6 -# Use test -z because SunOS4 sh mishandles ${INSTALL_PROGRAM-'${INSTALL}'}. +# Use test -z because SunOS4 sh mishandles braces in ${var-val}. # It thinks the first close brace ends the variable substitution. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' -test -n "$verbose" && echo " setting INSTALL_PROGRAM to $INSTALL_PROGRAM" test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' -test -n "$verbose" && echo " setting INSTALL_DATA to $INSTALL_DATA" -if test -z "$RANLIB"; then - # Extract the first word of `ranlib', so it can be a program name with args. - set ac_dummy ranlib; ac_word=$2 - test -n "$silent" || echo "checking for $ac_word" - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" - for ac_dir in $PATH; do - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$ac_word; then - RANLIB="ranlib" - break - fi - done - IFS="$ac_save_ifs" +echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 +# On Suns, sometimes $CPP names a directory. +if test -n "$CPP" && test -d "$CPP"; then + CPP= fi -test -z "$RANLIB" && RANLIB=":" -test -n "$RANLIB" && test -n "$verbose" && echo " setting RANLIB to $RANLIB" - -test -n "$silent" || echo "checking how to run the C preprocessor" if test -z "$CPP"; then - # This must be in double quotes, not single quotes, because CPP may get - # substituted into the Makefile and ``${CC-cc}'' will simply confuse - # make. It must be expanded now. +if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + # This must be in double quotes, not single quotes, because CPP may get + # substituted into the Makefile and "${CC-cc}" will confuse make. CPP="${CC-cc} -E" - cat > conftest.${ac_ext} < conftest.$ac_ext < +#include Syntax Error EOF -# Some shells (Coherent) do redirections in the wrong order, so need -# the parens. -ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` +eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then : else + echo "$ac_err" >&5 rm -rf conftest* CPP="${CC-cc} -E -traditional-cpp" - cat > conftest.${ac_ext} < conftest.$ac_ext < +#include Syntax Error EOF -# Some shells (Coherent) do redirections in the wrong order, so need -# the parens. -ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` +eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then : else + echo "$ac_err" >&5 rm -rf conftest* CPP=/lib/cpp fi rm -f conftest* fi rm -f conftest* + ac_cv_prog_CPP="$CPP" +fi fi -test -n "$verbose" && echo " setting CPP to $CPP" - test -n "$silent" || echo "checking for AIX" -cat > conftest.${ac_ext} <&6 + echo $ac_n "checking for AIX""... $ac_c" 1>&6 +cat > conftest.$ac_ext < conftest.out 2>&1" -if egrep "yes" conftest.out >/dev/null 2>&1; then +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "yes" >/dev/null 2>&1; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining _ALL_SOURCE" -echo "#define" _ALL_SOURCE "1" >> confdefs.h -DEFS="$DEFS -D_ALL_SOURCE=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}_ALL_SOURCE\${ac_dB}_ALL_SOURCE\${ac_dC}1\${ac_dD} -\${ac_uA}_ALL_SOURCE\${ac_uB}_ALL_SOURCE\${ac_uC}1\${ac_uD} -\${ac_eA}_ALL_SOURCE\${ac_eB}_ALL_SOURCE\${ac_eC}1\${ac_eD} -" -} - + echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF +#define _ALL_SOURCE 1 +EOF +else + rm -rf conftest* + echo "$ac_t""no" 1>&6 fi rm -f conftest* -test -n "$silent" || echo "checking for POSIXized ISC" +echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6 if test -d /etc/conf/kconfig.d && grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1 then - ISC=1 # If later tests want to check for ISC. - -{ -test -n "$verbose" && \ -echo " defining _POSIX_SOURCE" -echo "#define" _POSIX_SOURCE "1" >> confdefs.h -DEFS="$DEFS -D_POSIX_SOURCE=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}_POSIX_SOURCE\${ac_dB}_POSIX_SOURCE\${ac_dC}1\${ac_dD} -\${ac_uA}_POSIX_SOURCE\${ac_uB}_POSIX_SOURCE\${ac_uC}1\${ac_uD} -\${ac_eA}_POSIX_SOURCE\${ac_eB}_POSIX_SOURCE\${ac_eC}1\${ac_eD} -" -} + echo "$ac_t""yes" 1>&6 + ISC=yes # If later tests want to check for ISC. + cat >> confdefs.h <<\EOF +#define _POSIX_SOURCE 1 +EOF - if test -n "$GCC"; then + if test "$GCC" = yes; then CC="$CC -posix" else CC="$CC -Xp" fi +else + echo "$ac_t""no" 1>&6 + ISC= fi -test -n "$silent" || echo "checking for minix/config.h" -cat > conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < EOF -# Some shells (Coherent) do redirections in the wrong order, so need -# the parens. -ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` +eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - MINIX=1 - + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" fi rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + MINIX=yes +else + echo "$ac_t""no" 1>&6 +MINIX= +fi -# The Minix shell can't assign to the same variable on the same line! -if test -n "$MINIX"; then - -{ -test -n "$verbose" && \ -echo " defining _POSIX_SOURCE" -echo "#define" _POSIX_SOURCE "1" >> confdefs.h -DEFS="$DEFS -D_POSIX_SOURCE=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}_POSIX_SOURCE\${ac_dB}_POSIX_SOURCE\${ac_dC}1\${ac_dD} -\${ac_uA}_POSIX_SOURCE\${ac_uB}_POSIX_SOURCE\${ac_uC}1\${ac_uD} -\${ac_eA}_POSIX_SOURCE\${ac_eB}_POSIX_SOURCE\${ac_eC}1\${ac_eD} -" -} +if test "$MINIX" = yes; then + cat >> confdefs.h <<\EOF +#define _POSIX_SOURCE 1 +EOF - -{ -test -n "$verbose" && \ -echo " defining" _POSIX_1_SOURCE to be "2" -echo "#define" _POSIX_1_SOURCE "2" >> confdefs.h -DEFS="$DEFS -D_POSIX_1_SOURCE=2" -ac_sed_defs="${ac_sed_defs}\${ac_dA}_POSIX_1_SOURCE\${ac_dB}_POSIX_1_SOURCE\${ac_dC}2\${ac_dD} -\${ac_uA}_POSIX_1_SOURCE\${ac_uB}_POSIX_1_SOURCE\${ac_uC}2\${ac_uD} -\${ac_eA}_POSIX_1_SOURCE\${ac_eB}_POSIX_1_SOURCE\${ac_eC}2\${ac_eD} -" -} + cat >> confdefs.h <<\EOF +#define _POSIX_1_SOURCE 2 +EOF - -{ -test -n "$verbose" && \ -echo " defining _MINIX" -echo "#define" _MINIX "1" >> confdefs.h -DEFS="$DEFS -D_MINIX=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}_MINIX\${ac_dB}_MINIX\${ac_dC}1\${ac_dD} -\${ac_uA}_MINIX\${ac_uB}_MINIX\${ac_uC}1\${ac_uD} -\${ac_eA}_MINIX\${ac_eB}_MINIX\${ac_eC}1\${ac_eD} -" -} + cat >> confdefs.h <<\EOF +#define _MINIX 1 +EOF + +fi +# If we cannot run a trivial program, we must be cross compiling. +echo $ac_n "checking whether cross-compiling""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_c_cross'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test "$cross_compiling" = yes; then + ac_cv_c_cross=yes +else +cat > conftest.$ac_ext </dev/null; then + ac_cv_c_cross=no +else + ac_cv_c_cross=yes fi +fi +rm -fr conftest* +fi +cross_compiling=$ac_cv_c_cross +echo "$ac_t""$ac_cv_c_cross" 1>&6 -test -n "$silent" || echo "checking for ANSI C header files" -cat > conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < #include #include #include EOF -# Some shells (Coherent) do redirections in the wrong order, so need -# the parens. -ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` +eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* + ac_cv_header_stdc=yes +else + echo "$ac_err" >&5 + rm -rf conftest* + ac_cv_header_stdc=no +fi +rm -f conftest* + +if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. -echo '#include "confdefs.h" -#include ' > conftest.${ac_ext} -eval "$ac_cpp conftest.${ac_ext} > conftest.out 2>&1" -if egrep "memchr" conftest.out >/dev/null 2>&1; then +cat > conftest.$ac_ext < +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "memchr" >/dev/null 2>&1; then + : +else + rm -rf conftest* + ac_cv_header_stdc=no +fi +rm -f conftest* + +fi + +if test $ac_cv_header_stdc = yes; then + # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. +cat > conftest.$ac_ext < +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "free" >/dev/null 2>&1; then + : +else rm -rf conftest* - # SGI's /bin/cc from Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. -cat > conftest.${ac_ext} < conftest.$ac_ext < #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#define XOR(e,f) (((e) && !(f)) || (!(e) && (f))) +#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) int main () { int i; for (i = 0; i < 256; i++) if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); exit (0); } EOF -eval $ac_compile +eval $ac_link if test -s conftest && (./conftest; exit) 2>/dev/null; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. -echo '#include "confdefs.h" -#include ' > conftest.${ac_ext} -eval "$ac_cpp conftest.${ac_ext} > conftest.out 2>&1" -if egrep "free" conftest.out >/dev/null 2>&1; then - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining STDC_HEADERS" -echo "#define" STDC_HEADERS "1" >> confdefs.h -DEFS="$DEFS -DSTDC_HEADERS=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}STDC_HEADERS\${ac_dB}STDC_HEADERS\${ac_dC}1\${ac_dD} -\${ac_uA}STDC_HEADERS\${ac_uB}STDC_HEADERS\${ac_uC}1\${ac_uD} -\${ac_eA}STDC_HEADERS\${ac_eB}STDC_HEADERS\${ac_eC}1\${ac_eD} -" -} - - + : +else + ac_cv_header_stdc=no fi -rm -f conftest* - - fi rm -fr conftest* - fi -rm -f conftest* - +fi +echo "$ac_t""$ac_cv_header_stdc" 1>&6 +if test $ac_cv_header_stdc = yes; then + cat >> confdefs.h <<\EOF +#define STDC_HEADERS 1 +EOF fi -rm -f conftest* -test -n "$silent" || echo "checking for directory library header" -ac_dir_header= -if test -z "$ac_dir_header"; then - test -n "$silent" || echo "checking for dirent.h" -cat > conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < -#include +#include <$ac_hdr> int main() { return 0; } -int t() { DIR *dirp = 0;; return 0; } +int t() { +DIR *dirp = 0; +; return 0; } EOF if eval $ac_compile; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining DIRENT" -echo "#define" DIRENT "1" >> confdefs.h -DEFS="$DEFS -DDIRENT=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}DIRENT\${ac_dB}DIRENT\${ac_dC}1\${ac_dD} -\${ac_uA}DIRENT\${ac_uB}DIRENT\${ac_uC}1\${ac_uD} -\${ac_eA}DIRENT\${ac_eB}DIRENT\${ac_eC}1\${ac_eD} -" -} - ac_dir_header=dirent.h - + eval "ac_cv_header_dirent_$ac_safe=yes" +else + rm -rf conftest* + eval "ac_cv_header_dirent_$ac_safe=no" fi rm -f conftest* + fi -if test -z "$ac_dir_header"; then - test -n "$silent" || echo "checking for sys/ndir.h" -cat > conftest.${ac_ext} <&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./\055' '[A-Z]___'` + cat >> confdefs.h <&6 +fi +done +# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. +if test $ac_header_dirent = dirent.h; then +echo $ac_n "checking for -ldir""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_lib_dir'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-ldir $LIBS" +cat > conftest.$ac_ext < -#include + int main() { return 0; } -int t() { DIR *dirp = 0;; return 0; } +int t() { +opendir() +; return 0; } EOF -if eval $ac_compile; then +if eval $ac_link; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining SYSNDIR" -echo "#define" SYSNDIR "1" >> confdefs.h -DEFS="$DEFS -DSYSNDIR=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}SYSNDIR\${ac_dB}SYSNDIR\${ac_dC}1\${ac_dD} -\${ac_uA}SYSNDIR\${ac_uB}SYSNDIR\${ac_uC}1\${ac_uD} -\${ac_eA}SYSNDIR\${ac_eB}SYSNDIR\${ac_eC}1\${ac_eD} -" -} - ac_dir_header=sys/ndir.h - + eval "ac_cv_lib_dir=yes" +else + rm -rf conftest* + eval "ac_cv_lib_dir=no" fi rm -f conftest* +LIBS="$ac_save_LIBS" + fi -if test -z "$ac_dir_header"; then - test -n "$silent" || echo "checking for sys/dir.h" -cat > conftest.${ac_ext} <&6 + LIBS="$LIBS -ldir" +else + echo "$ac_t""no" 1>&6 +fi + +else +echo $ac_n "checking for -lx""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_lib_x'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lx $LIBS" +cat > conftest.$ac_ext < -#include + int main() { return 0; } -int t() { DIR *dirp = 0;; return 0; } +int t() { +opendir() +; return 0; } EOF -if eval $ac_compile; then +if eval $ac_link; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining SYSDIR" -echo "#define" SYSDIR "1" >> confdefs.h -DEFS="$DEFS -DSYSDIR=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}SYSDIR\${ac_dB}SYSDIR\${ac_dC}1\${ac_dD} -\${ac_uA}SYSDIR\${ac_uB}SYSDIR\${ac_uC}1\${ac_uD} -\${ac_eA}SYSDIR\${ac_eB}SYSDIR\${ac_eC}1\${ac_eD} -" -} - ac_dir_header=sys/dir.h - + eval "ac_cv_lib_x=yes" +else + rm -rf conftest* + eval "ac_cv_lib_x=no" fi rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'x`\" = yes"; then + echo "$ac_t""yes" 1>&6 + LIBS="$LIBS -lx" +else + echo "$ac_t""no" 1>&6 +fi + fi -if test -z "$ac_dir_header"; then - test -n "$silent" || echo "checking for ndir.h" -cat > conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < -#include -int main() { return 0; } -int t() { DIR *dirp = 0;; return 0; } EOF -if eval $ac_compile; then +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "uid_t" >/dev/null 2>&1; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining NDIR" -echo "#define" NDIR "1" >> confdefs.h -DEFS="$DEFS -DNDIR=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}NDIR\${ac_dB}NDIR\${ac_dC}1\${ac_dD} -\${ac_uA}NDIR\${ac_uB}NDIR\${ac_uC}1\${ac_uD} -\${ac_eA}NDIR\${ac_eB}NDIR\${ac_eC}1\${ac_eD} -" -} - ac_dir_header=ndir.h - + ac_cv_type_uid_t=yes +else + rm -rf conftest* + ac_cv_type_uid_t=no fi rm -f conftest* + fi +echo "$ac_t""$ac_cv_type_uid_t" 1>&6 +if test $ac_cv_type_uid_t = no; then + cat >> confdefs.h <<\EOF +#define uid_t int +EOF + + cat >> confdefs.h <<\EOF +#define gid_t int +EOF -test -n "$silent" || echo "checking for closedir return value" -cat > conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < -#include <$ac_dir_header> -int closedir(); main() { exit(closedir(opendir(".")) != 0); } +#if STDC_HEADERS +#include +#endif EOF -eval $ac_compile -if test -s conftest && (./conftest; exit) 2>/dev/null; then - : +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "pid_t" >/dev/null 2>&1; then + rm -rf conftest* + ac_cv_type_pid_t=yes else - -{ -test -n "$verbose" && \ -echo " defining VOID_CLOSEDIR" -echo "#define" VOID_CLOSEDIR "1" >> confdefs.h -DEFS="$DEFS -DVOID_CLOSEDIR=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}VOID_CLOSEDIR\${ac_dB}VOID_CLOSEDIR\${ac_dC}1\${ac_dD} -\${ac_uA}VOID_CLOSEDIR\${ac_uB}VOID_CLOSEDIR\${ac_uC}1\${ac_uD} -\${ac_eA}VOID_CLOSEDIR\${ac_eB}VOID_CLOSEDIR\${ac_eC}1\${ac_eD} -" -} - + rm -rf conftest* + ac_cv_type_pid_t=no fi -rm -fr conftest* +rm -f conftest* -test -n "$silent" || echo "checking for uid_t in sys/types.h" -echo '#include "confdefs.h" -#include ' > conftest.${ac_ext} -eval "$ac_cpp conftest.${ac_ext} > conftest.out 2>&1" -if egrep "uid_t" conftest.out >/dev/null 2>&1; then - : -else - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining" uid_t to be "int" -echo "#define" uid_t "int" >> confdefs.h -DEFS="$DEFS -Duid_t=int" -ac_sed_defs="${ac_sed_defs}\${ac_dA}uid_t\${ac_dB}uid_t\${ac_dC}int\${ac_dD} -\${ac_uA}uid_t\${ac_uB}uid_t\${ac_uC}int\${ac_uD} -\${ac_eA}uid_t\${ac_eB}uid_t\${ac_eC}int\${ac_eD} -" -} - -{ -test -n "$verbose" && \ -echo " defining" gid_t to be "int" -echo "#define" gid_t "int" >> confdefs.h -DEFS="$DEFS -Dgid_t=int" -ac_sed_defs="${ac_sed_defs}\${ac_dA}gid_t\${ac_dB}gid_t\${ac_dC}int\${ac_dD} -\${ac_uA}gid_t\${ac_uB}gid_t\${ac_uC}int\${ac_uD} -\${ac_eA}gid_t\${ac_eB}gid_t\${ac_eC}int\${ac_eD} -" -} +fi +echo "$ac_t""$ac_cv_type_pid_t" 1>&6 +if test $ac_cv_type_pid_t = no; then + cat >> confdefs.h <<\EOF +#define pid_t int +EOF fi -rm -f conftest* - test -n "$silent" || echo "checking for type of array argument to getgroups" -ac_prog='/* Thanks to Mike Rendell for this test. */ -#include -#define NGID 256 -#undef MAX -#define MAX(x,y) ((x) > (y) ? (x) : (y)) -main() -{ - gid_t gidset[NGID]; - int i, n; - union { gid_t gval; long lval; } val; - - val.lval = -1; - for (i = 0; i < NGID; i++) - gidset[i] = val.gval; - n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1, - gidset); - /* Exit non-zero if getgroups seems to require an array of ints. This - happens when gid_t is short but getgroups modifies an array of ints. */ - exit ((n > 0 && gidset[n] != val.gval) ? 1 : 0); -}' -cat > conftest.${ac_ext} </dev/null; then - -{ -test -n "$verbose" && \ -echo " defining" GETGROUPS_T to be "gid_t" -echo "#define" GETGROUPS_T "gid_t" >> confdefs.h -DEFS="$DEFS -DGETGROUPS_T=gid_t" -ac_sed_defs="${ac_sed_defs}\${ac_dA}GETGROUPS_T\${ac_dB}GETGROUPS_T\${ac_dC}gid_t\${ac_dD} -\${ac_uA}GETGROUPS_T\${ac_uB}GETGROUPS_T\${ac_uC}gid_t\${ac_uD} -\${ac_eA}GETGROUPS_T\${ac_eB}GETGROUPS_T\${ac_eC}gid_t\${ac_eD} -" -} - +echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 else - -{ -test -n "$verbose" && \ -echo " defining" GETGROUPS_T to be "int" -echo "#define" GETGROUPS_T "int" >> confdefs.h -DEFS="$DEFS -DGETGROUPS_T=int" -ac_sed_defs="${ac_sed_defs}\${ac_dA}GETGROUPS_T\${ac_dB}GETGROUPS_T\${ac_dC}int\${ac_dD} -\${ac_uA}GETGROUPS_T\${ac_uB}GETGROUPS_T\${ac_uC}int\${ac_uD} -\${ac_eA}GETGROUPS_T\${ac_eB}GETGROUPS_T\${ac_eC}int\${ac_eD} -" -} - -fi -rm -fr conftest* - -test -n "$silent" || echo "checking for pid_t in sys/types.h" -echo '#include "confdefs.h" -#include ' > conftest.${ac_ext} -eval "$ac_cpp conftest.${ac_ext} > conftest.out 2>&1" -if egrep "pid_t" conftest.out >/dev/null 2>&1; then - : -else - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining" pid_t to be "int" -echo "#define" pid_t "int" >> confdefs.h -DEFS="$DEFS -Dpid_t=int" -ac_sed_defs="${ac_sed_defs}\${ac_dA}pid_t\${ac_dB}pid_t\${ac_dC}int\${ac_dD} -\${ac_uA}pid_t\${ac_uB}pid_t\${ac_uC}int\${ac_uD} -\${ac_eA}pid_t\${ac_eB}pid_t\${ac_eC}int\${ac_eD} -" -} - -fi -rm -f conftest* - -test -n "$silent" || echo "checking for return type of signal handlers" -cat > conftest.${ac_ext} < conftest.$ac_ext < #include #ifdef signal #undef signal #endif -extern void (*signal ()) (); +#ifdef __cplusplus +extern "C" +#endif +void (*signal ()) (); int main() { return 0; } -int t() { int i;; return 0; } +int t() { +int i; +; return 0; } EOF if eval $ac_compile; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining" RETSIGTYPE to be "void" -echo "#define" RETSIGTYPE "void" >> confdefs.h -DEFS="$DEFS -DRETSIGTYPE=void" -ac_sed_defs="${ac_sed_defs}\${ac_dA}RETSIGTYPE\${ac_dB}RETSIGTYPE\${ac_dC}void\${ac_dD} -\${ac_uA}RETSIGTYPE\${ac_uB}RETSIGTYPE\${ac_uC}void\${ac_uD} -\${ac_eA}RETSIGTYPE\${ac_eB}RETSIGTYPE\${ac_eC}void\${ac_eD} -" -} - - + ac_cv_type_signal=void else rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining" RETSIGTYPE to be "int" -echo "#define" RETSIGTYPE "int" >> confdefs.h -DEFS="$DEFS -DRETSIGTYPE=int" -ac_sed_defs="${ac_sed_defs}\${ac_dA}RETSIGTYPE\${ac_dB}RETSIGTYPE\${ac_dC}int\${ac_dD} -\${ac_uA}RETSIGTYPE\${ac_uB}RETSIGTYPE\${ac_uC}int\${ac_uD} -\${ac_eA}RETSIGTYPE\${ac_eB}RETSIGTYPE\${ac_eC}int\${ac_eD} -" -} - + ac_cv_type_signal=int fi rm -f conftest* +fi +echo "$ac_t""$ac_cv_type_signal" 1>&6 +cat >> confdefs.h < conftest.${ac_ext} < -EOF -# Some shells (Coherent) do redirections in the wrong order, so need -# the parens. -ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` +ac_safe=`echo "$ac_hdr" | tr './\055' '___'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +EOF +eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining ${ac_tr_hdr}" -echo "#define" ${ac_tr_hdr} "1" >> confdefs.h -DEFS="$DEFS -D${ac_tr_hdr}=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}${ac_tr_hdr}\${ac_dB}${ac_tr_hdr}\${ac_dC}1\${ac_dD} -\${ac_uA}${ac_tr_hdr}\${ac_uB}${ac_tr_hdr}\${ac_uC}1\${ac_uD} -\${ac_eA}${ac_tr_hdr}\${ac_eB}${ac_tr_hdr}\${ac_eC}1\${ac_eD} -" -} - - + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" fi rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./\055' '[A-Z]___'` + cat >> confdefs.h <&6 +fi done -test -n "$silent" || echo "checking whether $CC and cc understand -c and -o together" +if test "x$CC" != xcc; then + echo $ac_n "checking whether $CC and cc understand -c and -o together""... $ac_c" 1>&6 +else + echo $ac_n "checking whether cc understands -c and -o together""... $ac_c" 1>&6 +fi +set dummy $CC; ac_cc="`echo $2 | + sed -e 's/[^a-zA-Z0-9_]/_/g' -e 's/^[0-9]/_/'`" +if eval "test \"`echo '$''{'ac_cv_prog_cc_${ac_cc}_c_o'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + eval ac_cv_prog_cc_${ac_cc}_c_o=no echo 'foo(){}' > conftest.c # Make sure it works both with $CC and with simple cc. # We do the test twice because some compilers refuse to overwrite an # existing .o file with -o, though they will create one. -if ${CC-cc} -c conftest.c -o conftest.o >/dev/null 2>&1 \ - && test -f conftest.o && ${CC-cc} -c conftest.c -o conftest.o >/dev/null 2>&1 +if ${CC-cc} -c conftest.c -o conftest.o 1>&5 2>&5 && + test -f conftest.o && ${CC-cc} -c conftest.c -o conftest.o 1>&5 2>&5 then - # Test first that cc exists at all. - if cc -c conftest.c >/dev/null 2>&1 - then - if cc -c conftest.c -o conftest2.o >/dev/null 2>&1 && \ - test -f conftest2.o && cc -c conftest.c -o conftest2.o >/dev/null 2>&1 + if test "x$CC" != xcc; then + # Test first that cc exists at all. + if cc -c conftest.c 1>&5 2>&5 then - : - else - -{ -test -n "$verbose" && \ -echo " defining NO_MINUS_C_MINUS_O" -echo "#define" NO_MINUS_C_MINUS_O "1" >> confdefs.h -DEFS="$DEFS -DNO_MINUS_C_MINUS_O=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}NO_MINUS_C_MINUS_O\${ac_dB}NO_MINUS_C_MINUS_O\${ac_dC}1\${ac_dD} -\${ac_uA}NO_MINUS_C_MINUS_O\${ac_uB}NO_MINUS_C_MINUS_O\${ac_uC}1\${ac_uD} -\${ac_eA}NO_MINUS_C_MINUS_O\${ac_eB}NO_MINUS_C_MINUS_O\${ac_eC}1\${ac_eD} -" -} - + if cc -c conftest.c -o conftest2.o 1>&5 2>&5 && + test -f conftest2.o && cc -c conftest.c -o conftest2.o 1>&5 2>&5 + then + eval ac_cv_prog_cc_${ac_cc}_c_o=yes + fi fi fi +fi +rm -f conftest* + +fi +if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" = yes"; then + echo "$ac_t""yes" 1>&6 else - -{ -test -n "$verbose" && \ -echo " defining NO_MINUS_C_MINUS_O" -echo "#define" NO_MINUS_C_MINUS_O "1" >> confdefs.h -DEFS="$DEFS -DNO_MINUS_C_MINUS_O=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}NO_MINUS_C_MINUS_O\${ac_dB}NO_MINUS_C_MINUS_O\${ac_dC}1\${ac_dD} -\${ac_uA}NO_MINUS_C_MINUS_O\${ac_uB}NO_MINUS_C_MINUS_O\${ac_uC}1\${ac_uD} -\${ac_eA}NO_MINUS_C_MINUS_O\${ac_eB}NO_MINUS_C_MINUS_O\${ac_eC}1\${ac_eD} -" -} + echo "$ac_t""no" 1>&6 + cat >> confdefs.h <<\EOF +#define NO_MINUS_C_MINUS_O 1 +EOF fi -rm -f conftest* -ac_prog='/* Ultrix mips cc rejects this. */ +echo $ac_n "checking for working const""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < conftest.${ac_ext} <> confdefs.h -DEFS="$DEFS -Dconst=" -ac_sed_defs="${ac_sed_defs}\${ac_dA}const\${ac_dB}const\${ac_dC}\${ac_dD} -\${ac_uA}const\${ac_uB}const\${ac_uC}\${ac_uD} -\${ac_eA}const\${ac_eB}const\${ac_eC}\${ac_eD} -" -} - + ac_cv_c_const=no fi rm -f conftest* - test -n "$silent" || echo "checking for broken stat file mode macros" -cat > conftest.${ac_ext} <&6 +if test $ac_cv_c_const = no; then + cat >> confdefs.h <<\EOF +#define const +EOF + +fi + echo $ac_n "checking whether stat file-mode macros are broken""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_header_stat_broken'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < #include -#ifdef S_ISBLK -#if S_ISBLK (S_IFDIR) + +#if defined(S_ISBLK) && defined(S_IFDIR) +# if S_ISBLK (S_IFDIR) You lose. +# endif #endif -#ifdef S_IFCHR -#if S_ISBLK (S_IFCHR) + +#if defined(S_ISBLK) && defined(S_IFCHR) +# if S_ISBLK (S_IFCHR) You lose. +# endif #endif -#endif /* S_IFCHR */ -#endif /* S_ISBLK */ -#ifdef S_ISLNK -#if S_ISLNK (S_IFREG) + +#if defined(S_ISLNK) && defined(S_IFREG) +# if S_ISLNK (S_IFREG) You lose. +# endif #endif -#endif /* S_ISLNK */ -#ifdef S_ISSOCK -#if S_ISSOCK (S_IFREG) + +#if defined(S_ISSOCK) && defined(S_IFREG) +# if S_ISSOCK (S_IFREG) You lose. +# endif #endif -#endif /* S_ISSOCK */ EOF -eval "$ac_cpp conftest.${ac_ext} > conftest.out 2>&1" -if egrep "You lose" conftest.out >/dev/null 2>&1; then +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "You lose" >/dev/null 2>&1; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining STAT_MACROS_BROKEN" -echo "#define" STAT_MACROS_BROKEN "1" >> confdefs.h -DEFS="$DEFS -DSTAT_MACROS_BROKEN=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}STAT_MACROS_BROKEN\${ac_dB}STAT_MACROS_BROKEN\${ac_dC}1\${ac_dD} -\${ac_uA}STAT_MACROS_BROKEN\${ac_uB}STAT_MACROS_BROKEN\${ac_uC}1\${ac_uD} -\${ac_eA}STAT_MACROS_BROKEN\${ac_eB}STAT_MACROS_BROKEN\${ac_eC}1\${ac_eD} -" -} + ac_cv_header_stat_broken=yes +else + rm -rf conftest* + ac_cv_header_stat_broken=no +fi +rm -f conftest* +fi +echo "$ac_t""$ac_cv_header_stat_broken" 1>&6 +if test $ac_cv_header_stat_broken = yes; then + cat >> confdefs.h <<\EOF +#define STAT_MACROS_BROKEN 1 +EOF fi -rm -f conftest* -for ac_func in getdtablesize psignal \ - dup2 getcwd sigsetmask getgroups setlinebuf \ - seteuid setegid setreuid setregid strerror + +for ac_func in getdtablesize psignal mktemp \ + dup2 getcwd sigsetmask getgroups setlinebuf \ + seteuid setegid setreuid setregid strerror strsignal do -ac_tr_func=HAVE_`echo $ac_func | tr '[a-z]' '[A-Z]'` -test -n "$silent" || echo "checking for ${ac_func}" -cat > conftest.${ac_ext} < +echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +/* Override any gcc2 internal prototype to avoid an error. */ +char $ac_func(); + int main() { return 0; } -int t() { +int t() { + /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ -#if defined (__stub_${ac_func}) || defined (__stub___${ac_func}) +#if defined (__stub_$ac_func) || defined (__stub___$ac_func) choke me #else -/* Override any gcc2 internal prototype to avoid an error. */ -extern char ${ac_func}(); ${ac_func}(); +$ac_func(); #endif + ; return 0; } EOF -if eval $ac_compile; then +if eval $ac_link; then rm -rf conftest* - { -test -n "$verbose" && \ -echo " defining ${ac_tr_func}" -echo "#define" ${ac_tr_func} "1" >> confdefs.h -DEFS="$DEFS -D${ac_tr_func}=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}${ac_tr_func}\${ac_dB}${ac_tr_func}\${ac_dC}1\${ac_dD} -\${ac_uA}${ac_tr_func}\${ac_uB}${ac_tr_func}\${ac_uC}1\${ac_uD} -\${ac_eA}${ac_tr_func}\${ac_eB}${ac_tr_func}\${ac_eC}1\${ac_eD} -" -} - - + eval "ac_cv_func_$ac_func=yes" +else + rm -rf conftest* + eval "ac_cv_func_$ac_func=no" fi rm -f conftest* + +fi +if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_func=HAVE_`echo $ac_func | tr '[a-z]' '[A-Z]'` + cat >> confdefs.h <&6 +fi done -test -n "$silent" || echo "checking for sys_siglist" -cat > conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'ac_cv_check_symbol_sys_siglist'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext <> confdefs.h -DEFS="$DEFS -DHAVE_SYS_SIGLIST=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_SYS_SIGLIST\${ac_dB}HAVE_SYS_SIGLIST\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_SYS_SIGLIST\${ac_uB}HAVE_SYS_SIGLIST\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_SYS_SIGLIST\${ac_eB}HAVE_SYS_SIGLIST\${ac_eC}1\${ac_eD} -" -} - - + ac_cv_check_symbol_sys_siglist=yes +else + rm -rf conftest* + ac_cv_check_symbol_sys_siglist=no fi rm -f conftest* -test -n "$silent" || echo "checking for _sys_siglist" -cat > conftest.${ac_ext} <> confdefs.h <&6 +echo $ac_n "checking for _sys_siglist""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_check_symbol__sys_siglist'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext <> confdefs.h -DEFS="$DEFS -DHAVE__SYS_SIGLIST=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE__SYS_SIGLIST\${ac_dB}HAVE__SYS_SIGLIST\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE__SYS_SIGLIST\${ac_uB}HAVE__SYS_SIGLIST\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE__SYS_SIGLIST\${ac_eB}HAVE__SYS_SIGLIST\${ac_eC}1\${ac_eD} -" -} - - + ac_cv_check_symbol__sys_siglist=yes +else + rm -rf conftest* + ac_cv_check_symbol__sys_siglist=no fi rm -f conftest* +fi + +if test "$ac_cv_check_symbol__sys_siglist" = yes; then + ac_tr_symbol=`echo _sys_siglist | tr '[a-z]' '[A-Z]'` + cat >> confdefs.h <&6 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works # for constant arguments. Useless! -test -n "$silent" || echo "checking for working alloca.h" -cat > conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < int main() { return 0; } -int t() { char *p = alloca(2 * sizeof(int));; return 0; } +int t() { +char *p = alloca(2 * sizeof(int)); +; return 0; } EOF -if eval $ac_compile; then +if eval $ac_link; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining HAVE_ALLOCA_H" -echo "#define" HAVE_ALLOCA_H "1" >> confdefs.h -DEFS="$DEFS -DHAVE_ALLOCA_H=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_ALLOCA_H\${ac_dB}HAVE_ALLOCA_H\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_ALLOCA_H\${ac_uB}HAVE_ALLOCA_H\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_ALLOCA_H\${ac_eB}HAVE_ALLOCA_H\${ac_eC}1\${ac_eD} -" -} - - + ac_cv_header_alloca_h=yes +else + rm -rf conftest* + ac_cv_header_alloca_h=no fi rm -f conftest* -ac_decl="#ifdef __GNUC__ -#define alloca __builtin_alloca -#else -#if HAVE_ALLOCA_H -#include -#else -#ifdef _AIX - #pragma alloca -#else -char *alloca (); -#endif -#endif -#endif -" -test -n "$silent" || echo "checking for alloca" -cat > conftest.${ac_ext} <&6 +if test $ac_cv_header_alloca_h = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_ALLOCA_H 1 EOF -if eval $ac_compile; then - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining HAVE_ALLOCA" -echo "#define" HAVE_ALLOCA "1" >> confdefs.h -DEFS="$DEFS -DHAVE_ALLOCA=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_ALLOCA\${ac_dB}HAVE_ALLOCA\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_ALLOCA\${ac_uB}HAVE_ALLOCA\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_ALLOCA\${ac_eB}HAVE_ALLOCA\${ac_eC}1\${ac_eD} -" -} +fi +echo $ac_n "checking for alloca""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_func_alloca'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 else - rm -rf conftest* - ac_alloca_missing=1 -cat > conftest.${ac_ext} < conftest.$ac_ext < +# else +# ifdef _AIX + #pragma alloca +# else +# ifndef alloca /* predefined by HP cc +Olibcalls */ +char *alloca (); +# endif +# endif +# endif #endif -EOF -eval "$ac_cpp conftest.${ac_ext} > conftest.out 2>&1" -if egrep "winnitude" conftest.out >/dev/null 2>&1; then - rm -rf conftest* - test -n "$silent" || echo "checking for _getb67" -cat > conftest.${ac_ext} < int main() { return 0; } -int t() { -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub__getb67) || defined (__stub____getb67) -choke me -#else -/* Override any gcc2 internal prototype to avoid an error. */ -extern char _getb67(); _getb67(); -#endif +int t() { +char *p = (char *) alloca(1); ; return 0; } EOF -if eval $ac_compile; then +if eval $ac_link; then rm -rf conftest* - { -test -n "$verbose" && \ -echo " defining" CRAY_STACKSEG_END to be "_getb67" -echo "#define" CRAY_STACKSEG_END "_getb67" >> confdefs.h -DEFS="$DEFS -DCRAY_STACKSEG_END=_getb67" -ac_sed_defs="${ac_sed_defs}\${ac_dA}CRAY_STACKSEG_END\${ac_dB}CRAY_STACKSEG_END\${ac_dC}_getb67\${ac_dD} -\${ac_uA}CRAY_STACKSEG_END\${ac_uB}CRAY_STACKSEG_END\${ac_uC}_getb67\${ac_uD} -\${ac_eA}CRAY_STACKSEG_END\${ac_eB}CRAY_STACKSEG_END\${ac_eC}_getb67\${ac_eD} -" -} + ac_cv_func_alloca=yes +else + rm -rf conftest* + ac_cv_func_alloca=no +fi +rm -f conftest* +fi +echo "$ac_t""$ac_cv_func_alloca" 1>&6 +if test $ac_cv_func_alloca = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_ALLOCA 1 +EOF + +fi +if test $ac_cv_func_alloca = no; then + # The SVR3 libPW and SVR4 libucb both contain incompatible functions + # that cause trouble. Some versions do not even contain alloca or + # contain a buggy version. If you still want to use their alloca, + # use ar to extract alloca.o from them instead of compiling alloca.c. + ALLOCA=alloca.o + cat >> confdefs.h <<\EOF +#define C_ALLOCA 1 +EOF + + +echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 else - rm -rf conftest* - test -n "$silent" || echo "checking for GETB67" -cat > conftest.${ac_ext} < conftest.$ac_ext < -int main() { return 0; } -int t() { -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_GETB67) || defined (__stub___GETB67) -choke me +#if defined(CRAY) && ! defined(CRAY2) +webecray #else -/* Override any gcc2 internal prototype to avoid an error. */ -extern char GETB67(); GETB67(); +wenotbecray #endif -; return 0; } + EOF -if eval $ac_compile; then +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "webecray" >/dev/null 2>&1; then rm -rf conftest* - { -test -n "$verbose" && \ -echo " defining" CRAY_STACKSEG_END to be "GETB67" -echo "#define" CRAY_STACKSEG_END "GETB67" >> confdefs.h -DEFS="$DEFS -DCRAY_STACKSEG_END=GETB67" -ac_sed_defs="${ac_sed_defs}\${ac_dA}CRAY_STACKSEG_END\${ac_dB}CRAY_STACKSEG_END\${ac_dC}GETB67\${ac_dD} -\${ac_uA}CRAY_STACKSEG_END\${ac_uB}CRAY_STACKSEG_END\${ac_uC}GETB67\${ac_uD} -\${ac_eA}CRAY_STACKSEG_END\${ac_eB}CRAY_STACKSEG_END\${ac_eC}GETB67\${ac_eD} -" -} - - + ac_cv_os_cray=yes else rm -rf conftest* - test -n "$silent" || echo "checking for getb67" -cat > conftest.${ac_ext} <&6 +if test $ac_cv_os_cray = yes; then +for ac_func in _getb67 GETB67 getb67; do + echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char $ac_func(); below. */ +#include +/* Override any gcc2 internal prototype to avoid an error. */ +char $ac_func(); + int main() { return 0; } -int t() { +int t() { + /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ -#if defined (__stub_getb67) || defined (__stub___getb67) +#if defined (__stub_$ac_func) || defined (__stub___$ac_func) choke me #else -/* Override any gcc2 internal prototype to avoid an error. */ -extern char getb67(); getb67(); +$ac_func(); #endif + ; return 0; } EOF -if eval $ac_compile; then +if eval $ac_link; then rm -rf conftest* - { -test -n "$verbose" && \ -echo " defining" CRAY_STACKSEG_END to be "getb67" -echo "#define" CRAY_STACKSEG_END "getb67" >> confdefs.h -DEFS="$DEFS -DCRAY_STACKSEG_END=getb67" -ac_sed_defs="${ac_sed_defs}\${ac_dA}CRAY_STACKSEG_END\${ac_dB}CRAY_STACKSEG_END\${ac_dC}getb67\${ac_dD} -\${ac_uA}CRAY_STACKSEG_END\${ac_uB}CRAY_STACKSEG_END\${ac_uC}getb67\${ac_uD} -\${ac_eA}CRAY_STACKSEG_END\${ac_eB}CRAY_STACKSEG_END\${ac_eC}getb67\${ac_eD} -" -} - - -fi -rm -f conftest* - -fi -rm -f conftest* - -fi -rm -f conftest* - - + eval "ac_cv_func_$ac_func=yes" +else + rm -rf conftest* + eval "ac_cv_func_$ac_func=no" fi rm -f conftest* - fi -rm -f conftest* - -if test -n "$ac_alloca_missing"; then - # The SVR3 libPW and SVR4 libucb both contain incompatible functions - # that cause trouble. Some versions do not even contain alloca or - # contain a buggy version. If you still want to use their alloca, - # use ar to extract alloca.o from them instead of compiling alloca.c. - ALLOCA=alloca.o - -{ -test -n "$verbose" && \ -echo " defining C_ALLOCA" -echo "#define" C_ALLOCA "1" >> confdefs.h -DEFS="$DEFS -DC_ALLOCA=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}C_ALLOCA\${ac_dB}C_ALLOCA\${ac_dC}1\${ac_dD} -\${ac_uA}C_ALLOCA\${ac_uB}C_ALLOCA\${ac_uC}1\${ac_uD} -\${ac_eA}C_ALLOCA\${ac_eB}C_ALLOCA\${ac_eC}1\${ac_eD} -" -} - - - test -n "$silent" || echo "checking stack direction for C alloca" - test -n "$silent" || echo "checking whether cross-compiling" -# If we cannot run a trivial program, we must be cross compiling. -cat > conftest.${ac_ext} <&6 + cat >> confdefs.h </dev/null; then - : + + break else - cross_compiling=1 + echo "$ac_t""no" 1>&6 fi -rm -fr conftest* -if test -n "$cross_compiling" -then - -{ -test -n "$verbose" && \ -echo " defining" STACK_DIRECTION to be "0" -echo "#define" STACK_DIRECTION "0" >> confdefs.h -DEFS="$DEFS -DSTACK_DIRECTION=0" -ac_sed_defs="${ac_sed_defs}\${ac_dA}STACK_DIRECTION\${ac_dB}STACK_DIRECTION\${ac_dC}0\${ac_dD} -\${ac_uA}STACK_DIRECTION\${ac_uB}STACK_DIRECTION\${ac_uC}0\${ac_uD} -\${ac_eA}STACK_DIRECTION\${ac_eB}STACK_DIRECTION\${ac_eC}0\${ac_eD} -" -} +done +fi +echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test "$cross_compiling" = yes; then + ac_cv_c_stack_direction=0 else -cat > conftest.${ac_ext} < conftest.$ac_ext </dev/null; then - -{ -test -n "$verbose" && \ -echo " defining" STACK_DIRECTION to be "1" -echo "#define" STACK_DIRECTION "1" >> confdefs.h -DEFS="$DEFS -DSTACK_DIRECTION=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}STACK_DIRECTION\${ac_dB}STACK_DIRECTION\${ac_dC}1\${ac_dD} -\${ac_uA}STACK_DIRECTION\${ac_uB}STACK_DIRECTION\${ac_uC}1\${ac_uD} -\${ac_eA}STACK_DIRECTION\${ac_eB}STACK_DIRECTION\${ac_eC}1\${ac_eD} -" -} - - + ac_cv_c_stack_direction=1 else - -{ -test -n "$verbose" && \ -echo " defining" STACK_DIRECTION to be "-1" -echo "#define" STACK_DIRECTION "-1" >> confdefs.h -DEFS="$DEFS -DSTACK_DIRECTION=-1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}STACK_DIRECTION\${ac_dB}STACK_DIRECTION\${ac_dC}-1\${ac_dD} -\${ac_uA}STACK_DIRECTION\${ac_uB}STACK_DIRECTION\${ac_uC}-1\${ac_uD} -\${ac_eA}STACK_DIRECTION\${ac_eB}STACK_DIRECTION\${ac_eC}-1\${ac_eD} -" -} - + ac_cv_c_stack_direction=-1 fi fi rm -fr conftest* fi +echo "$ac_t""$ac_cv_c_stack_direction" 1>&6 +cat >> confdefs.h < conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < EOF -# Some shells (Coherent) do redirections in the wrong order, so need -# the parens. -ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` +eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining HAVE_VFORK_H" -echo "#define" HAVE_VFORK_H "1" >> confdefs.h -DEFS="$DEFS -DHAVE_VFORK_H=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_VFORK_H\${ac_dB}HAVE_VFORK_H\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_VFORK_H\${ac_uB}HAVE_VFORK_H\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_VFORK_H\${ac_eB}HAVE_VFORK_H\${ac_eC}1\${ac_eD} -" -} - - + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" fi rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + cat >> confdefs.h <<\EOF +#define HAVE_VFORK_H 1 +EOF -test -n "$silent" || echo "checking for working vfork" +else + echo "$ac_t""no" 1>&6 +fi -cat > conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'ac_cv_func_vfork'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test "$cross_compiling" = yes; then + ac_cv_func_vfork=no +else +cat > conftest.$ac_ext < #include #include -#include #ifdef HAVE_UNISTD_H #include #endif #ifdef HAVE_VFORK_H #include #endif -static int signalled; -static RETSIGTYPE catch (s) int s; { signalled = 1; } +/* On some sparc systems, changes by the child to local and incoming + argument registers are propagated back to the parent. + The compiler is told about this with #include , + but some compilers (e.g. gcc -O) don't grok . + Test for this by using a static variable whose address + is put into a register that is clobbered by the vfork. */ +static +#ifdef __cplusplus +sparc_address_test (int arg) +#else +sparc_address_test (arg) int arg; +#endif +{ + static pid_t child; + if (!child) { + child = vfork (); + if (child < 0) + perror ("vfork"); + if (!child) { + arg = getpid(); + write(-1, "", 0); + _exit (arg); + } + } +} main() { pid_t parent = getpid (); pid_t child; - signal (SIGINT, catch); + sparc_address_test (); child = vfork (); if (child == 0) { - /* On sparc systems, changes by the child to local and incoming - argument registers are propagated back to the parent. - The compiler is told about this with #include , - but some compilers (e.g. gcc -O) don't grok . - Test for this by using lots of local variables, at least + /* Here is another test for sparc vfork register problems. + This test uses lots of local variables, at least as many local variables as main has allocated so far including compiler temporaries. 4 locals are enough for - gcc 1.40.3 on a sparc, but we use 8 to be safe. + gcc 1.40.3 on a Solaris 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should reuse the register of parent for one of the local variables, since it will think that parent can't possibly be used any more in this routine. @@ -1595,12 +1686,6 @@ || p != p5 || p != p6 || p != p7) _exit(1); - /* On some systems (e.g. SunOS 5.2), if the parent is catching - a signal, the child ignores the signal before execing, - and the parent later receives that signal, the parent dumps core. - Test for this by ignoring SIGINT in the child. */ - signal (SIGINT, SIG_IGN); - /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent from child file descriptors. If the child closes a descriptor before it execs or exits, @@ -1623,36 +1708,38 @@ /* Did the vfork/compiler bug occur? */ || parent != getpid() - /* Did the signal handling bug occur? */ - || kill(parent, SIGINT) != 0 - || signalled != 1 - /* Did the file descriptor bug occur? */ || fstat(fileno(stdout), &st) != 0 ); } } EOF -eval $ac_compile +eval $ac_link if test -s conftest && (./conftest; exit) 2>/dev/null; then - : + ac_cv_func_vfork=yes else - -{ -test -n "$verbose" && \ -echo " defining" vfork to be "fork" -echo "#define" vfork "fork" >> confdefs.h -DEFS="$DEFS -Dvfork=fork" -ac_sed_defs="${ac_sed_defs}\${ac_dA}vfork\${ac_dB}vfork\${ac_dC}fork\${ac_dD} -\${ac_uA}vfork\${ac_uB}vfork\${ac_uC}fork\${ac_uD} -\${ac_eA}vfork\${ac_eB}vfork\${ac_eC}fork\${ac_eD} -" -} - + ac_cv_func_vfork=no +fi fi rm -fr conftest* +fi +echo "$ac_t""$ac_cv_func_vfork" 1>&6 +if test $ac_cv_func_vfork = no; then + cat >> confdefs.h <<\EOF +#define vfork fork +EOF + +fi -cat > conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'ac_cv_func_setvbuf_reversed'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test "$cross_compiling" = yes; then + { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } +else +cat > conftest.$ac_ext < /* If setvbuf has the reversed format, exit 0. */ @@ -1666,475 +1753,551 @@ exit(0); /* Non-reversed systems segv here. */ } EOF -eval $ac_compile +eval $ac_link if test -s conftest && (./conftest; exit) 2>/dev/null; then - -{ -test -n "$verbose" && \ -echo " defining SETVBUF_REVERSED" -echo "#define" SETVBUF_REVERSED "1" >> confdefs.h -DEFS="$DEFS -DSETVBUF_REVERSED=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}SETVBUF_REVERSED\${ac_dB}SETVBUF_REVERSED\${ac_dC}1\${ac_dD} -\${ac_uA}SETVBUF_REVERSED\${ac_uB}SETVBUF_REVERSED\${ac_uC}1\${ac_uD} -\${ac_eA}SETVBUF_REVERSED\${ac_eB}SETVBUF_REVERSED\${ac_eC}1\${ac_eD} -" -} - - + ac_cv_func_setvbuf_reversed=yes +else + ac_cv_func_setvbuf_reversed=no +fi fi rm -fr conftest* -rm -f core +rm -f core core.* *.core +fi +echo "$ac_t""$ac_cv_func_setvbuf_reversed" 1>&6 +if test $ac_cv_func_setvbuf_reversed = yes; then + cat >> confdefs.h <<\EOF +#define SETVBUF_REVERSED 1 +EOF -# Some definitions of getloadavg require that the program be installed setgid. -NEED_SETGID=false -ac_need_func=true +fi -# Check for the 4.4BSD definition of getloadavg. -ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lutil" -ac_have_lib="" -test -n "$silent" || echo "checking for -lutil" -cat > conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'ac_cv_lib_elf'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lelf $LIBS" +cat > conftest.$ac_ext <&6 + LIBS="-lelf $LIBS" else - :; + echo "$ac_t""no" 1>&6 fi -# Some systems with -lutil have (and need) -lkvm as well, some do not. -ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lkvm" -ac_have_lib="" -test -n "$silent" || echo "checking for -lkvm" -cat > conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'ac_cv_lib_kvm'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lkvm $LIBS" +cat > conftest.$ac_ext <&6 + LIBS="-lkvm $LIBS" +else + echo "$ac_t""no" 1>&6 +fi + +# Check for the 4.4BSD definition of getloadavg. +echo $ac_n "checking for -lutil""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_lib_util'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lutil $LIBS" +cat > conftest.$ac_ext <&6 + LIBS="-lutil $LIBS" ac_have_func=yes ac_cv_func_getloadavg_setgid=yes else - :; + echo "$ac_t""no" 1>&6 fi -if $ac_need_func; then -# There is a commonly available library for RS/6000 AIX. -# Since it is not a standard part of AIX, it might be installed locally. -LIBS_old="$LIBS" -LIBS="-L/usr/local/lib $LIBS" -ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lgetloadavg" -ac_have_lib="" -test -n "$silent" || echo "checking for -lgetloadavg" -cat > conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'ac_cv_lib_getloadavg'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lgetloadavg $LIBS" +cat > conftest.$ac_ext <&6 + LIBS="-lgetloadavg $LIBS" else - :; LIBS="$LIBS_old" + echo "$ac_t""no" 1>&6 +LIBS="$ac_save_LIBS" fi fi -# Make sure it is really in the library, if we think we found it at all. +# Make sure it is really in the library, if we think we found it. for ac_func in getloadavg do -test -n "$silent" || echo "checking for ${ac_func}" -cat > conftest.${ac_ext} < +echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +/* Override any gcc2 internal prototype to avoid an error. */ +char $ac_func(); + int main() { return 0; } -int t() { +int t() { + /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ -#if defined (__stub_${ac_func}) || defined (__stub___${ac_func}) +#if defined (__stub_$ac_func) || defined (__stub___$ac_func) choke me #else -/* Override any gcc2 internal prototype to avoid an error. */ -extern char ${ac_func}(); ${ac_func}(); +$ac_func(); #endif + ; return 0; } EOF -if eval $ac_compile; then - : +if eval $ac_link; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" else rm -rf conftest* - LIBOBJS="$LIBOBJS ${ac_func}.o" -test -n "$verbose" && echo " using ${ac_func}.o instead" + eval "ac_cv_func_$ac_func=no" fi rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +LIBOBJS="$LIBOBJS ${ac_func}.o" +fi + done -case "$LIBOBJS" in -*getloadavg*) -ac_need_func=true -test -n "$silent" || echo "checking for sys/dg_sys_info.h" -cat > conftest.${ac_ext} <> confdefs.h <<\EOF +#define HAVE_GETLOADAVG 1 +EOF + + ac_have_func=yes +else + # Figure out what our getloadavg.c needs. + ac_have_func=no + ac_safe=`echo "sys/dg_sys_info.h" | tr './\055' '___'` +echo $ac_n "checking for sys/dg_sys_info.h""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < EOF -# Some shells (Coherent) do redirections in the wrong order, so need -# the parens. -ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` +eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining DGUX" -echo "#define" DGUX "1" >> confdefs.h -DEFS="$DEFS -DDGUX=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}DGUX\${ac_dB}DGUX\${ac_dC}1\${ac_dD} -\${ac_uA}DGUX\${ac_uB}DGUX\${ac_uC}1\${ac_uD} -\${ac_eA}DGUX\${ac_eB}DGUX\${ac_eC}1\${ac_eD} -" -} - ac_need_func=false -# Some versions of DGUX need -ldgc for dg_sys_info. -ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -ldgc" -ac_have_lib="" -test -n "$silent" || echo "checking for -ldgc" -cat > conftest.${ac_ext} <&5 rm -rf conftest* - ac_have_lib="1" - + eval "ac_cv_header_$ac_safe=no" fi rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - -{ -test -n "$verbose" && \ -echo " defining HAVE_LIBDGC" -echo "#define" HAVE_LIBDGC "1" >> confdefs.h -DEFS="$DEFS -DHAVE_LIBDGC=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_LIBDGC\${ac_dB}HAVE_LIBDGC\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_LIBDGC\${ac_uB}HAVE_LIBDGC\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_LIBDGC\${ac_eB}HAVE_LIBDGC\${ac_eC}1\${ac_eD} -" -} - - LIBS="${LIBS} -ldgc" -fi - - fi -rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_have_func=yes; cat >> confdefs.h <<\EOF +#define DGUX 1 +EOF -if $ac_need_func; then -# We cannot check for , because Solaris 2 does not use dwarf (it -# uses stabs), but it's still SVR4. We cannot check for because -# Irix 4.0.5F has the header but not the library. -ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lelf" -ac_have_lib="" -test -n "$silent" || echo "checking for -lelf" -cat > conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'ac_cv_lib_dgc'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-ldgc $LIBS" +cat > conftest.$ac_ext <> confdefs.h -DEFS="$DEFS -DSVR4=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}SVR4\${ac_dB}SVR4\${ac_dC}1\${ac_dD} -\${ac_uA}SVR4\${ac_uB}SVR4\${ac_uC}1\${ac_uD} -\${ac_eA}SVR4\${ac_eB}SVR4\${ac_eC}1\${ac_eD} -" -} - LIBS="$LIBS -lelf" ac_need_func=false - ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lkvm" -ac_have_lib="" -test -n "$silent" || echo "checking for -lkvm" -cat > conftest.${ac_ext} <&6 + ac_tr_lib=HAVE_LIB`echo dgc | tr '[a-z]' '[A-Z]'` + cat >> confdefs.h <&6 fi else - :; + echo "$ac_t""no" 1>&6 fi -fi -if $ac_need_func; then -test -n "$silent" || echo "checking for inq_stats/cpustats.h" -cat > conftest.${ac_ext} <, because Solaris 2 does not use dwarf (it + # uses stabs), but it is still SVR4. We cannot check for because + # Irix 4.0.5F has the header but not the library. + if test $ac_have_func = no && test $ac_cv_lib_elf = yes; then + ac_have_func=yes; cat >> confdefs.h <<\EOF +#define SVR4 1 +EOF + + fi + + if test $ac_have_func = no; then + ac_safe=`echo "inq_stats/cpustats.h" | tr './\055' '___'` +echo $ac_n "checking for inq_stats/cpustats.h""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < EOF -# Some shells (Coherent) do redirections in the wrong order, so need -# the parens. -ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` +eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining UMAX4_3" -echo "#define" UMAX4_3 "1" >> confdefs.h -DEFS="$DEFS -DUMAX4_3=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}UMAX4_3\${ac_dB}UMAX4_3\${ac_dC}1\${ac_dD} -\${ac_uA}UMAX4_3\${ac_uB}UMAX4_3\${ac_uC}1\${ac_uD} -\${ac_eA}UMAX4_3\${ac_eB}UMAX4_3\${ac_eC}1\${ac_eD} -" -} - -{ -test -n "$verbose" && \ -echo " defining UMAX" -echo "#define" UMAX "1" >> confdefs.h -DEFS="$DEFS -DUMAX=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}UMAX\${ac_dB}UMAX\${ac_dC}1\${ac_dD} -\${ac_uA}UMAX\${ac_uB}UMAX\${ac_uC}1\${ac_uD} -\${ac_eA}UMAX\${ac_eB}UMAX\${ac_eC}1\${ac_eD} -" -} - - ac_need_func=false - + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" fi rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_have_func=yes; cat >> confdefs.h <<\EOF +#define UMAX 1 +EOF + + cat >> confdefs.h <<\EOF +#define UMAX4_3 1 +EOF +else + echo "$ac_t""no" 1>&6 fi -if $ac_need_func; then -test -n "$silent" || echo "checking for sys/cpustats.h" -cat > conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < EOF -# Some shells (Coherent) do redirections in the wrong order, so need -# the parens. -ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` +eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining UMAX" -echo "#define" UMAX "1" >> confdefs.h -DEFS="$DEFS -DUMAX=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}UMAX\${ac_dB}UMAX\${ac_dC}1\${ac_dD} -\${ac_uA}UMAX\${ac_uB}UMAX\${ac_uC}1\${ac_uD} -\${ac_eA}UMAX\${ac_eB}UMAX\${ac_eC}1\${ac_eD} -" -} - ac_need_func=false - + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" fi rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_have_func=yes; cat >> confdefs.h <<\EOF +#define UMAX 1 +EOF +else + echo "$ac_t""no" 1>&6 fi -if $ac_need_func; then -for ac_hdr in mach/mach.h + + fi + + if test $ac_have_func = no; then + for ac_hdr in mach/mach.h do -ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./' '[A-Z]__'` -test -n "$silent" || echo "checking for ${ac_hdr}" -cat > conftest.${ac_ext} < -EOF -# Some shells (Coherent) do redirections in the wrong order, so need -# the parens. -ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` +ac_safe=`echo "$ac_hdr" | tr './\055' '___'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +EOF +eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining ${ac_tr_hdr}" -echo "#define" ${ac_tr_hdr} "1" >> confdefs.h -DEFS="$DEFS -D${ac_tr_hdr}=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}${ac_tr_hdr}\${ac_dB}${ac_tr_hdr}\${ac_dC}1\${ac_dD} -\${ac_uA}${ac_tr_hdr}\${ac_uB}${ac_tr_hdr}\${ac_uC}1\${ac_uD} -\${ac_eA}${ac_tr_hdr}\${ac_eB}${ac_tr_hdr}\${ac_eC}1\${ac_eD} -" -} - - + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" fi rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./\055' '[A-Z]___'` + cat >> confdefs.h <&6 +fi done -fi + fi -test -n "$silent" || echo "checking for nlist.h" -cat > conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < EOF -# Some shells (Coherent) do redirections in the wrong order, so need -# the parens. -ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` +eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining NLIST_STRUCT" -echo "#define" NLIST_STRUCT "1" >> confdefs.h -DEFS="$DEFS -DNLIST_STRUCT=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}NLIST_STRUCT\${ac_dB}NLIST_STRUCT\${ac_dC}1\${ac_dD} -\${ac_uA}NLIST_STRUCT\${ac_uB}NLIST_STRUCT\${ac_uC}1\${ac_uD} -\${ac_eA}NLIST_STRUCT\${ac_eB}NLIST_STRUCT\${ac_eC}1\${ac_eD} -" -} + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + cat >> confdefs.h <<\EOF +#define NLIST_STRUCT 1 +EOF -test -n "$silent" || echo "checking for n_un in struct nlist" -cat > conftest.${ac_ext} <&6 + if eval "test \"`echo '$''{'ac_cv_struct_nlist_n_un'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < int main() { return 0; } -int t() { struct nlist n; n.n_un.n_name = 0;; return 0; } +int t() { +struct nlist n; n.n_un.n_name = 0; +; return 0; } EOF if eval $ac_compile; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining NLIST_NAME_UNION" -echo "#define" NLIST_NAME_UNION "1" >> confdefs.h -DEFS="$DEFS -DNLIST_NAME_UNION=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}NLIST_NAME_UNION\${ac_dB}NLIST_NAME_UNION\${ac_dC}1\${ac_dD} -\${ac_uA}NLIST_NAME_UNION\${ac_uB}NLIST_NAME_UNION\${ac_uC}1\${ac_uD} -\${ac_eA}NLIST_NAME_UNION\${ac_eB}NLIST_NAME_UNION\${ac_eC}1\${ac_eD} -" -} - - + ac_cv_struct_nlist_n_un=yes +else + rm -rf conftest* + ac_cv_struct_nlist_n_un=no fi rm -f conftest* +fi + echo "$ac_t""$ac_cv_struct_nlist_n_un" 1>&6 + if test $ac_cv_struct_nlist_n_un = yes; then + cat >> confdefs.h <<\EOF +#define NLIST_NAME_UNION 1 +EOF + fi + +else + echo "$ac_t""no" 1>&6 fi -rm -f conftest* +fi # Do not have getloadavg in system libraries. -# Figure out whether we will need to install setgid. -cat > conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'ac_cv_func_getloadavg_setgid'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < conftest.out 2>&1" -if egrep "Yowza Am I SETGID yet" conftest.out >/dev/null 2>&1; then +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "Yowza Am I SETGID yet" >/dev/null 2>&1; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining GETLOADAVG_PRIVILEGED" -echo "#define" GETLOADAVG_PRIVILEGED "1" >> confdefs.h -DEFS="$DEFS -DGETLOADAVG_PRIVILEGED=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}GETLOADAVG_PRIVILEGED\${ac_dB}GETLOADAVG_PRIVILEGED\${ac_dC}1\${ac_dD} -\${ac_uA}GETLOADAVG_PRIVILEGED\${ac_uB}GETLOADAVG_PRIVILEGED\${ac_uC}1\${ac_uD} -\${ac_eA}GETLOADAVG_PRIVILEGED\${ac_eB}GETLOADAVG_PRIVILEGED\${ac_eC}1\${ac_eD} -" -} - NEED_SETGID=true - + ac_cv_func_getloadavg_setgid=yes +else + rm -rf conftest* + ac_cv_func_getloadavg_setgid=no fi rm -f conftest* -;; -*) -{ -test -n "$verbose" && \ -echo " defining HAVE_GETLOADAVG" -echo "#define" HAVE_GETLOADAVG "1" >> confdefs.h -DEFS="$DEFS -DHAVE_GETLOADAVG=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_GETLOADAVG\${ac_dB}HAVE_GETLOADAVG\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_GETLOADAVG\${ac_uB}HAVE_GETLOADAVG\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_GETLOADAVG\${ac_eB}HAVE_GETLOADAVG\${ac_eC}1\${ac_eD} -" -} - ;; -esac +fi +echo "$ac_t""$ac_cv_func_getloadavg_setgid" 1>&6 +if test $ac_cv_func_getloadavg_setgid = yes; then + NEED_SETGID=true; cat >> confdefs.h <<\EOF +#define GETLOADAVG_PRIVILEGED 1 +EOF + +else + NEED_SETGID=false +fi -if $NEED_SETGID; then - # Figure out what group owns /dev/kmem. - # The installed program will need to be setgid and owned by that group. - # On Solaris, /dev/kmem is a symlink. Get info on the real file. +if test $ac_cv_func_getloadavg_setgid = yes; then + echo $ac_n "checking group of /dev/kmem""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_group_kmem'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + # On Solaris, /dev/kmem is a symlink. Get info on the real file. ac_ls_output=`ls -lgL /dev/kmem 2>/dev/null` # If we got an error (system does not support symlinks), try without -L. test -z "$ac_ls_output" && ac_ls_output=`ls -lg /dev/kmem` - KMEM_GROUP=`echo $ac_ls_output \ + ac_cv_group_kmem=`echo $ac_ls_output \ | sed -ne 's/[ ][ ]*/ /g; s/^.[sSrwx-]* *[0-9]* *\([^0-9]*\) *.*/\1/; / /s/.* //;p;'` + +fi + KMEM_GROUP=$ac_cv_group_kmem + echo "$ac_t""$KMEM_GROUP" 1>&6 fi -test -n "$silent" || echo "checking for strcoll" -cat > conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'ac_cv_func_strcoll'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test "$cross_compiling" = yes; then + ac_cv_func_strcoll=no +else +cat > conftest.$ac_ext < main () @@ -2144,271 +2307,292 @@ strcoll ("123", "456") >= 0); } EOF -eval $ac_compile +eval $ac_link if test -s conftest && (./conftest; exit) 2>/dev/null; then - -{ -test -n "$verbose" && \ -echo " defining HAVE_STRCOLL" -echo "#define" HAVE_STRCOLL "1" >> confdefs.h -DEFS="$DEFS -DHAVE_STRCOLL=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_STRCOLL\${ac_dB}HAVE_STRCOLL\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_STRCOLL\${ac_uB}HAVE_STRCOLL\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_STRCOLL\${ac_eB}HAVE_STRCOLL\${ac_eC}1\${ac_eD} -" -} + ac_cv_func_strcoll=yes +else + ac_cv_func_strcoll=no +fi +fi +rm -fr conftest* +fi +echo "$ac_t""$ac_cv_func_strcoll" 1>&6 +if test $ac_cv_func_strcoll = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_STRCOLL 1 +EOF +fi + + +if test $ac_cv_func_getdtablesize = no; then + echo $ac_n "checking for sysconf (_SC_OPEN_MAX)""... $ac_c" 1>&6 + if eval "test \"`echo '$''{'make_cv_sysconf_open_max'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +int main() { return 0; } +int t() { +int max = sysconf (_SC_OPEN_MAX); +; return 0; } +EOF +if eval $ac_link; then + rm -rf conftest* + make_cv_sysconf_open_max=yes +else + rm -rf conftest* + make_cv_sysconf_open_max=no +fi +rm -f conftest* fi -rm -fr conftest* + if test $make_cv_sysconf_open_max = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_SYSCONF_OPEN_MAX 1 +EOF + + fi + echo "$ac_t""$make_cv_sysconf_open_max" 1>&6 +fi + +# Check out the wait reality. for ac_hdr in sys/wait.h do -ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./' '[A-Z]__'` -test -n "$silent" || echo "checking for ${ac_hdr}" -cat > conftest.${ac_ext} < -EOF -# Some shells (Coherent) do redirections in the wrong order, so need -# the parens. -ac_err=`eval "($ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` +ac_safe=`echo "$ac_hdr" | tr './\055' '___'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +EOF +eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining ${ac_tr_hdr}" -echo "#define" ${ac_tr_hdr} "1" >> confdefs.h -DEFS="$DEFS -D${ac_tr_hdr}=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}${ac_tr_hdr}\${ac_dB}${ac_tr_hdr}\${ac_dC}1\${ac_dD} -\${ac_uA}${ac_tr_hdr}\${ac_uB}${ac_tr_hdr}\${ac_uC}1\${ac_uD} -\${ac_eA}${ac_tr_hdr}\${ac_eB}${ac_tr_hdr}\${ac_eC}1\${ac_eD} -" -} - - + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" fi rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./\055' '[A-Z]___'` + cat >> confdefs.h <&6 +fi done for ac_func in waitpid wait3 do -ac_tr_func=HAVE_`echo $ac_func | tr '[a-z]' '[A-Z]'` -test -n "$silent" || echo "checking for ${ac_func}" -cat > conftest.${ac_ext} < +echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +/* Override any gcc2 internal prototype to avoid an error. */ +char $ac_func(); + int main() { return 0; } -int t() { +int t() { + /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ -#if defined (__stub_${ac_func}) || defined (__stub___${ac_func}) +#if defined (__stub_$ac_func) || defined (__stub___$ac_func) choke me #else -/* Override any gcc2 internal prototype to avoid an error. */ -extern char ${ac_func}(); ${ac_func}(); +$ac_func(); #endif + ; return 0; } EOF -if eval $ac_compile; then +if eval $ac_link; then rm -rf conftest* - { -test -n "$verbose" && \ -echo " defining ${ac_tr_func}" -echo "#define" ${ac_tr_func} "1" >> confdefs.h -DEFS="$DEFS -D${ac_tr_func}=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}${ac_tr_func}\${ac_dB}${ac_tr_func}\${ac_dC}1\${ac_dD} -\${ac_uA}${ac_tr_func}\${ac_uB}${ac_tr_func}\${ac_uC}1\${ac_uD} -\${ac_eA}${ac_tr_func}\${ac_eB}${ac_tr_func}\${ac_eC}1\${ac_eD} -" -} - - + eval "ac_cv_func_$ac_func=yes" +else + rm -rf conftest* + eval "ac_cv_func_$ac_func=no" fi rm -f conftest* + +fi +if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_func=HAVE_`echo $ac_func | tr '[a-z]' '[A-Z]'` + cat >> confdefs.h <&6 +fi done -test -n "$silent" || echo "checking for union wait" -cat > conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'make_cv_union_wait'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < #include int main() { return 0; } -int t() { union wait status; int pid; pid = wait (&status); +int t() { +union wait status; int pid; pid = wait (&status); #ifdef WEXITSTATUS /* Some POSIXoid systems have both the new-style macros and the old union wait type, and they do not work together. If union wait conflicts with WEXITSTATUS et al, we don't want to use it at all. */ if (WEXITSTATUS (status) != 0) pid = -1; +#ifdef WTERMSIG +/* If we have WEXITSTATUS and WTERMSIG, just use them on ints. */ +-- blow chunks here -- +#endif #endif #ifdef HAVE_WAITPID /* Make sure union wait works with waitpid. */ pid = waitpid (-1, &status, 0); #endif + ; return 0; } EOF -if eval $ac_compile; then +if eval $ac_link; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining HAVE_UNION_WAIT" -echo "#define" HAVE_UNION_WAIT "1" >> confdefs.h -DEFS="$DEFS -DHAVE_UNION_WAIT=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_UNION_WAIT\${ac_dB}HAVE_UNION_WAIT\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_UNION_WAIT\${ac_uB}HAVE_UNION_WAIT\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_UNION_WAIT\${ac_eB}HAVE_UNION_WAIT\${ac_eC}1\${ac_eD} -" -} - - + make_cv_union_wait=yes +else + rm -rf conftest* + make_cv_union_wait=no fi rm -f conftest* +fi + +if test "$make_cv_union_wait" = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_UNION_WAIT 1 +EOF + +fi +echo "$ac_t""$make_cv_union_wait" 1>&6 -test -n "$silent" || echo "checking for sys_siglist declaration in signal.h or unistd.h" -cat > conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'ac_cv_decl_sys_siglist'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < #include -/* NetBSD declares sys_siglist in . */ +/* NetBSD declares sys_siglist in unistd.h. */ #ifdef HAVE_UNISTD_H #include #endif int main() { return 0; } -int t() { char *msg = *(sys_siglist + 1);; return 0; } +int t() { +char *msg = *(sys_siglist + 1); +; return 0; } EOF if eval $ac_compile; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining SYS_SIGLIST_DECLARED" -echo "#define" SYS_SIGLIST_DECLARED "1" >> confdefs.h -DEFS="$DEFS -DSYS_SIGLIST_DECLARED=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}SYS_SIGLIST_DECLARED\${ac_dB}SYS_SIGLIST_DECLARED\${ac_dC}1\${ac_dD} -\${ac_uA}SYS_SIGLIST_DECLARED\${ac_uB}SYS_SIGLIST_DECLARED\${ac_uC}1\${ac_uD} -\${ac_eA}SYS_SIGLIST_DECLARED\${ac_eB}SYS_SIGLIST_DECLARED\${ac_eC}1\${ac_eD} -" -} + ac_cv_decl_sys_siglist=yes +else + rm -rf conftest* + ac_cv_decl_sys_siglist=no +fi +rm -f conftest* +fi +echo "$ac_t""$ac_cv_decl_sys_siglist" 1>&6 +if test $ac_cv_decl_sys_siglist = yes; then + cat >> confdefs.h <<\EOF +#define SYS_SIGLIST_DECLARED 1 +EOF fi -rm -f conftest* # The presence of the following is not meant to imply # that make necessarily works on those systems. -ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lseq" -ac_have_lib="" -test -n "$silent" || echo "checking for -lseq" -cat > conftest.${ac_ext} <&6 +if eval "test \"`echo '$''{'ac_cv_lib_sun'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lsun $LIBS" +cat > conftest.$ac_ext < conftest.${ac_ext} < conftest.out 2>&1" -if egrep "yes" conftest.out >/dev/null 2>&1; then rm -rf conftest* - XENIX=1 - + eval "ac_cv_lib_sun=no" fi rm -f conftest* +LIBS="$ac_save_LIBS" -if test -n "$XENIX"; then - LIBS="$LIBS -lx" - case "$DEFS" in - *SYSNDIR*) ;; - *) LIBS="-ldir $LIBS" ;; # Make sure -ldir precedes any -lx. - esac fi - -ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lsun" -ac_have_lib="" -test -n "$silent" || echo "checking for -lsun" -cat > conftest.${ac_ext} <&6 + ac_tr_lib=HAVE_LIB`echo sun | tr '[a-z]' '[A-Z]'` + cat >> confdefs.h <&6 fi - REMOTE=stub -# check whether --with-customs or --without-customs was given. +# Check whether --with-customs or --without-customs was given. withval="$with_customs" if test -n "$withval"; then - REMOTE=cstms -LIBS="$LIBS libcustoms.a" + REMOTE=cstms LIBS="$LIBS libcustoms.a" fi echo checking for location of SCCS get command if test -f /usr/sccs/get; then SCCS_GET=/usr/sccs/get - -{ -test -n "$verbose" && \ -echo " defining" SCCS_GET to be ""/usr/sccs/get"" -echo "#define" SCCS_GET ""/usr/sccs/get"" >> confdefs.h -DEFS="$DEFS -DSCCS_GET="/usr/sccs/get"" -ac_sed_defs="${ac_sed_defs}\${ac_dA}SCCS_GET\${ac_dB}SCCS_GET\${ac_dC}\"/usr/sccs/get\"\${ac_dD} -\${ac_uA}SCCS_GET\${ac_uB}SCCS_GET\${ac_uC}\"/usr/sccs/get\"\${ac_uD} -\${ac_eA}SCCS_GET\${ac_eB}SCCS_GET\${ac_eC}\"/usr/sccs/get\"\${ac_eD} -" -} + cat >> confdefs.h <<\EOF +#define SCCS_GET "/usr/sccs/get" +EOF else SCCS_GET=get - -{ -test -n "$verbose" && \ -echo " defining" SCCS_GET to be ""get"" -echo "#define" SCCS_GET ""get"" >> confdefs.h -DEFS="$DEFS -DSCCS_GET="get"" -ac_sed_defs="${ac_sed_defs}\${ac_dA}SCCS_GET\${ac_dB}SCCS_GET\${ac_dC}\"get\"\${ac_dD} -\${ac_uA}SCCS_GET\${ac_uB}SCCS_GET\${ac_uC}\"get\"\${ac_uD} -\${ac_eA}SCCS_GET\${ac_eB}SCCS_GET\${ac_eC}\"get\"\${ac_eD} -" -} + cat >> confdefs.h <<\EOF +#define SCCS_GET "get" +EOF fi ac_clean_files="$ac_clean_files s.conftest conftoast" # Remove these later. @@ -2418,35 +2602,53 @@ echo checking if SCCS get command understands -G if $SCCS_GET -Gconftoast s.conftest >/dev/null 2>&1 && test -f conftoast; then - -{ -test -n "$verbose" && \ -echo " defining SCCS_GET_MINUS_G" -echo "#define" SCCS_GET_MINUS_G "1" >> confdefs.h -DEFS="$DEFS -DSCCS_GET_MINUS_G=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}SCCS_GET_MINUS_G\${ac_dB}SCCS_GET_MINUS_G\${ac_dC}1\${ac_dD} -\${ac_uA}SCCS_GET_MINUS_G\${ac_uB}SCCS_GET_MINUS_G\${ac_uC}1\${ac_uD} -\${ac_eA}SCCS_GET_MINUS_G\${ac_eB}SCCS_GET_MINUS_G\${ac_eC}1\${ac_eD} -" -} + cat >> confdefs.h <<\EOF +#define SCCS_GET_MINUS_G 1 +EOF fi fi rm -f s.conftest conftoast - -# The preferred way to propogate these variables is regular @ substitutions. -if test -n "$prefix"; then - ac_prsub="s%^prefix\\([ ]*\\)=\\([ ]*\\).*$%prefix\\1=\\2$prefix%" -else - prefix=/usr/local -fi -if test -n "$exec_prefix"; then - ac_prsub="$ac_prsub -s%^exec_prefix\\([ ]*\\)=\\([ ]*\\).*$%exec_prefix\\1=\\2$exec_prefix%" +trap '' 1 2 15 +cat > confcache <<\EOF +# This file is a shell script that caches the results of configure +# tests run on this system so they can be shared between configure +# scripts and configure runs. It is not useful on other systems. +# If it contains results you don't want to keep, you may remove or edit it. +# +# By default, configure uses ./config.cache as the cache file, +# creating it if it does not exist already. You can give configure +# the --cache-file=FILE option to use a different cache file; that is +# what configure does when it calls configure scripts in +# subdirectories, so they share the cache. +# Giving --cache-file=/dev/null disables caching, for debugging configure. +# config.status only pays attention to the cache file if you give it the +# --recheck option to rerun configure. +# +EOF +# Ultrix sh set writes to stderr and can't be redirected directly, +# and sets the high bit in the cache file unless we assign to the vars. +(set) 2>&1 | + sed -n "s/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=\${\1='\2'}/p" \ + >> confcache +if cmp -s $cache_file confcache; then + : else - exec_prefix='${prefix}' # Let make expand it. + if test -w $cache_file; then + echo "updating cache $cache_file" + cat confcache > $cache_file + else + echo "not updating unwritable cache $cache_file" + fi fi +rm -f confcache + +trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 + +test "x$prefix" = xNONE && prefix=$ac_default_prefix +# Let make expand exec_prefix. +test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' # Any assignment to VPATH causes Sun make to only execute # the first set of double-colon rules, so remove it if not needed. @@ -2455,36 +2657,36 @@ ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' fi -# Quote sed substitution magic chars in DEFS. -cat >conftest.def < config.status < $CONFIG_STATUS </dev/null | sed 1q`: # -# $0 $configure_args +# $0 $ac_configure_args +# +# Compiler output produced by configure, useful for debugging +# configure, is in ./config.log if it exists. -ac_cs_usage="Usage: config.status [--recheck] [--version] [--help]" +ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" for ac_option do case "\$ac_option" in -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) - echo running \${CONFIG_SHELL-/bin/sh} $0 $configure_args --no-create - exec \${CONFIG_SHELL-/bin/sh} $0 $configure_args --no-create ;; + echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" + exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;; -version | --version | --versio | --versi | --vers | --ver | --ve | --v) - echo "config.status generated by autoconf version 1.11" + echo "$CONFIG_STATUS generated by autoconf version 2.3" exit 0 ;; -help | --help | --hel | --he | --h) echo "\$ac_cs_usage"; exit 0 ;; @@ -2492,51 +2694,69 @@ esac done -trap 'rm -fr Makefile build.sh glob/Makefile config.h conftest*; exit 1' 1 2 15 -CFLAGS='$CFLAGS' -LDFLAGS='$LDFLAGS' -SET_MAKE='$SET_MAKE' -CC='$CC' -INSTALL='$INSTALL' -INSTALL_PROGRAM='$INSTALL_PROGRAM' -INSTALL_DATA='$INSTALL_DATA' -RANLIB='$RANLIB' -CPP='$CPP' -LIBOBJS='$LIBOBJS' -ALLOCA='$ALLOCA' -NEED_SETGID='$NEED_SETGID' -KMEM_GROUP='$KMEM_GROUP' -REMOTE='$REMOTE' -LIBS='$LIBS' -srcdir='$srcdir' -top_srcdir='$top_srcdir' -prefix='$prefix' -exec_prefix='$exec_prefix' -ac_prsub='$ac_prsub' -ac_vpsub='$ac_vpsub' -extrasub='$extrasub' +ac_given_srcdir=$srcdir +ac_given_INSTALL="$INSTALL" + +trap 'rm -fr `echo "Makefile build.sh config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 + +# Protect against being on the right side of a sed subst in config.status. +sed 's/%@/@@/; s/@%/@@/; s/%g$/@g/; /@g$/s/[\\\\&%]/\\\\&/g; + s/@@/%@/; s/@@/@%/; s/@g$/%g/' > conftest.subs <<\CEOF +$ac_vpsub +$extrasub +s%@CFLAGS@%$CFLAGS%g +s%@CPPFLAGS@%$CPPFLAGS%g +s%@CXXFLAGS@%$CXXFLAGS%g +s%@DEFS@%$DEFS%g +s%@LDFLAGS@%$LDFLAGS%g +s%@LIBS@%$LIBS%g +s%@exec_prefix@%$exec_prefix%g +s%@prefix@%$prefix%g +s%@program_transform_name@%$program_transform_name%g +s%@subdirs@%$subdirs%g +s%@SET_MAKE@%$SET_MAKE%g +s%@CC@%$CC%g +s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g +s%@INSTALL_DATA@%$INSTALL_DATA%g +s%@CPP@%$CPP%g +s%@LIBOBJS@%$LIBOBJS%g +s%@ALLOCA@%$ALLOCA%g +s%@NEED_SETGID@%$NEED_SETGID%g +s%@KMEM_GROUP@%$KMEM_GROUP%g +s%@REMOTE@%$REMOTE%g + +CEOF EOF -cat >> config.status <<\EOF +cat >> $CONFIG_STATUS <> $CONFIG_STATUS <<\EOF +for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then + # Support "outfile[:infile]", defaulting infile="outfile.in". + case "$ac_file" in + *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'` + ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; + *) ac_file_in="${ac_file}.in" ;; + esac + + # Adjust relative srcdir, etc. for subdirectories. -CONFIG_FILES=${CONFIG_FILES-"Makefile build.sh glob/Makefile"} -for ac_file in .. ${CONFIG_FILES}; do if test "x$ac_file" != x..; then # Remove last slash and all that follows it. Not all systems have dirname. ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then # The file is in a subdirectory. test ! -d "$ac_dir" && mkdir "$ac_dir" - ac_dir_suffix="/$ac_dir" + ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" + # A "../" for each directory in $ac_dir_suffix. + ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` else - ac_dir_suffix= + ac_dir_suffix= ac_dots= fi - # A "../" for each directory in $ac_dir_suffix. - ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` case "$ac_given_srcdir" in .) srcdir=. - if test -z "$ac_dir_suffix"; then top_srcdir=. + if test -z "$ac_dots"; then top_srcdir=. else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; *) # Relative path. @@ -2544,130 +2764,115 @@ top_srcdir="$ac_dots$ac_given_srcdir" ;; esac + case "$ac_given_INSTALL" in + [/$]*) INSTALL="$ac_given_INSTALL" ;; + *) INSTALL="$ac_dots$ac_given_INSTALL" ;; + esac echo creating "$ac_file" rm -f "$ac_file" - comment_str="Generated automatically from `echo $ac_file|sed 's|.*/||'`.in by configure." + configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." case "$ac_file" in - *.c | *.h | *.C | *.cc | *.m ) echo "/* $comment_str */" > "$ac_file" ;; - * ) echo "# $comment_str" > "$ac_file" ;; + *Makefile*) ac_comsub="1i\\ +# $configure_input" ;; + *) ac_comsub= ;; esac - sed -e " -$ac_prsub -$ac_vpsub -$extrasub -s%@CFLAGS@%$CFLAGS%g -s%@LDFLAGS@%$LDFLAGS%g -s%@SET_MAKE@%$SET_MAKE%g -s%@CC@%$CC%g -s%@INSTALL@%$INSTALL%g -s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g -s%@INSTALL_DATA@%$INSTALL_DATA%g -s%@RANLIB@%$RANLIB%g -s%@CPP@%$CPP%g -s%@LIBOBJS@%$LIBOBJS%g -s%@ALLOCA@%$ALLOCA%g -s%@NEED_SETGID@%$NEED_SETGID%g -s%@KMEM_GROUP@%$KMEM_GROUP%g -s%@REMOTE@%$REMOTE%g -s%@LIBS@%$LIBS%g + sed -e "$ac_comsub +s%@configure_input@%$configure_input%g s%@srcdir@%$srcdir%g s%@top_srcdir@%$top_srcdir%g -s%@prefix@%$prefix%g -s%@exec_prefix@%$exec_prefix%g -s%@DEFS@%-DHAVE_CONFIG_H%" $ac_given_srcdir/${ac_file}.in >> $ac_file +s%@INSTALL@%$INSTALL%g +" -f conftest.subs $ac_given_srcdir/$ac_file_in > $ac_file fi; done +rm -f conftest.subs -# These sed commands are put into ac_sed_defs when defining a macro. -# They are broken into pieces to make the sed script easier to manage. -# They are passed to sed as "A NAME B NAME C VALUE D", where NAME -# is the cpp macro being defined and VALUE is the value it is being given. -# Each defining turns into a single global substitution command. -# Hopefully no one uses "!" as a variable value. -# Other candidates for the sed separators, like , and @, do get used. +# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where +# NAME is the cpp macro being defined and VALUE is the value it is being given. # # ac_d sets the value in "#define NAME VALUE" lines. -ac_dA='s!^\([ ]*\)#\([ ]*define[ ][ ]*\)' -ac_dB='\([ ][ ]*\)[^ ]*!\1#\2' +ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)' +ac_dB='\([ ][ ]*\)[^ ]*%\1#\2' ac_dC='\3' -ac_dD='!g' +ac_dD='%g' # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE". -ac_uA='s!^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' -ac_uB='\([ ]\)!\1#\2define\3' +ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' +ac_uB='\([ ]\)%\1#\2define\3' ac_uC=' ' -ac_uD='\4!g' +ac_uD='\4%g' # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE". -ac_eA='s!^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' -ac_eB='$!\1#\2define\3' +ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' +ac_eB='$%\1#\2define\3' ac_eC=' ' -ac_eD='!g' -rm -f conftest.sed +ac_eD='%g' + +CONFIG_HEADERS=${CONFIG_HEADERS-"config.h"} +for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then + # Support "outfile[:infile]", defaulting infile="outfile.in". + case "$ac_file" in + *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'` + ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; + *) ac_file_in="${ac_file}.in" ;; + esac + + echo creating $ac_file + + rm -f conftest.frag conftest.in conftest.out + cp $ac_given_srcdir/$ac_file_in conftest.in + EOF -# Turn off quoting long enough to insert the sed commands. -rm -f conftest.sh -cat > conftest.sh < conftest.hdr <<\EOF +s/[\\&%]/\\&/g +s%[\\$`]%\\&%g +s%#define \([A-Za-z_][A-Za-z0-9_]*\) \(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp +s%ac_d%ac_u%gp +s%ac_u%ac_e%gp EOF +sed -n -f conftest.hdr confdefs.h > conftest.vals +rm -f conftest.hdr -# Break up $ac_sed_defs (now in conftest.sh) because some shells have a limit -# on the size of here documents. +# This sed command replaces #undef with comments. This is necessary, for +# example, in the case of _POSIX_SOURCE, which is predefined and required +# on some systems where configure will not decide to define it. +cat >> conftest.vals <<\EOF +s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */% +EOF +# Break up conftest.vals because some shells have a limit on +# the size of here documents, and old seds have small limits too. # Maximum number of lines to put in a single here document. -ac_max_sh_lines=9 +ac_max_here_lines=12 +rm -f conftest.tail while : do - # wc gives bogus results for an empty file on some AIX systems. - ac_lines=`grep -c . conftest.sh` + ac_lines=`grep -c . conftest.vals` + # grep -c gives empty output for an empty file on some AIX systems. if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi - rm -f conftest.s1 conftest.s2 - sed ${ac_max_sh_lines}q conftest.sh > conftest.s1 # Like head -9. - sed 1,${ac_max_sh_lines}d conftest.sh > conftest.s2 # Like tail +10. - # Write a limited-size here document to append to conftest.sed. - echo 'cat >> conftest.sed <> config.status - cat conftest.s1 >> config.status - echo 'CONFEOF' >> config.status - rm -f conftest.s1 conftest.sh - mv conftest.s2 conftest.sh + # Write a limited-size here document to conftest.frag. + echo ' cat > conftest.frag <> $CONFIG_STATUS + sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS + echo 'CEOF + sed -f conftest.frag conftest.in > conftest.out + rm -f conftest.in + mv conftest.out conftest.in +' >> $CONFIG_STATUS + sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail + rm -f conftest.vals + mv conftest.tail conftest.vals done -rm -f conftest.sh - -# Now back to your regularly scheduled config.status. -cat >> config.status <<\EOF -# This sed command replaces #undef's with comments. This is necessary, for -# example, in the case of _POSIX_SOURCE, which is predefined and required -# on some systems where configure will not decide to define it in -# config.h. -cat >> conftest.sed <<\CONFEOF -s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */, -CONFEOF -rm -f conftest.h -# Break up the sed commands because old seds have small limits. -ac_max_sed_lines=20 - -CONFIG_HEADERS=${CONFIG_HEADERS-"config.h"} -for ac_file in .. ${CONFIG_HEADERS}; do if test "x$ac_file" != x..; then - echo creating $ac_file +rm -f conftest.vals - cp $ac_given_srcdir/$ac_file.in conftest.h1 - cp conftest.sed conftest.stm - while : - do - ac_lines=`grep -c . conftest.stm` - if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi - rm -f conftest.s1 conftest.s2 conftest.h2 - sed ${ac_max_sed_lines}q conftest.stm > conftest.s1 # Like head -20. - sed 1,${ac_max_sed_lines}d conftest.stm > conftest.s2 # Like tail +21. - sed -f conftest.s1 < conftest.h1 > conftest.h2 - rm -f conftest.s1 conftest.h1 conftest.stm - mv conftest.h2 conftest.h1 - mv conftest.s2 conftest.stm - done - rm -f conftest.stm conftest.h +cat >> $CONFIG_STATUS <<\EOF + rm -f conftest.frag conftest.h echo "/* $ac_file. Generated automatically by configure. */" > conftest.h - cat conftest.h1 >> conftest.h - rm -f conftest.h1 + cat conftest.in >> conftest.h + rm -f conftest.in if cmp -s $ac_file conftest.h 2>/dev/null; then - # The file exists and we would not be changing it. echo "$ac_file is unchanged" rm -f conftest.h else @@ -2675,7 +2880,6 @@ mv conftest.h $ac_file fi fi; done -rm -f conftest.sed @@ -2684,8 +2888,104 @@ touch stamp-config exit 0 EOF -chmod +x config.status -# Some shells look in PATH for config.status without the "./". -test -n "$no_create" || ${CONFIG_SHELL-/bin/sh} ./config.status +chmod +x $CONFIG_STATUS +rm -fr confdefs* $ac_clean_files +test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1 + +if test "$no_recursion" != yes; then + + # Remove --cache-file and --srcdir arguments so they do not pile up. + ac_sub_configure_args= + ac_prev= + for ac_arg in $ac_configure_args; do + if test -n "$ac_prev"; then + ac_prev= + continue + fi + case "$ac_arg" in + -cache-file | --cache-file | --cache-fil | --cache-fi \ + | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) + ac_prev=cache_file ;; + -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ + | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) + ;; + -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) + ac_prev=srcdir ;; + -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) + ;; + *) ac_sub_configure_args="$ac_sub_configure_args $ac_arg" ;; + esac + done + + for ac_config_dir in glob; do + + # Do not complain, so a configure script can configure whichever + # parts of a large source tree are present. + if test ! -d $srcdir/$ac_config_dir; then + continue + fi + + echo configuring in $ac_config_dir + + case "$srcdir" in + .) ;; + *) + if test -d ./$ac_config_dir || mkdir ./$ac_config_dir; then :; + else + { echo "configure: error: can not create `pwd`/$ac_config_dir" 1>&2; exit 1; } + fi + ;; + esac + + ac_popdir=`pwd` + cd $ac_config_dir + + case "$srcdir" in + .) # No --srcdir option. We are building in place. + ac_sub_srcdir=$srcdir ;; + /*) # Absolute path. + ac_sub_srcdir=$srcdir/$ac_config_dir ;; + *) # Relative path. + ac_sub_srcdir=../$srcdir/$ac_config_dir ;; + esac + + # Check for guested configure; otherwise get Cygnus style configure. + if test -f $ac_sub_srcdir/configure; then + ac_sub_configure=$ac_sub_srcdir/configure + elif test -f $ac_sub_srcdir/configure.in; then + ac_sub_configure=$ac_configure + else + echo "configure: warning: no configuration information is in $ac_config_dir" 1>&2 + ac_sub_configure= + fi + + # The recursion is here. + if test -n "$ac_sub_configure"; then + + # Make the cache file name correct relative to the subdirectory. + # A "../" for each directory in /$ac_config_dir. + ac_dots=`echo $ac_config_dir|sed -e 's%^\./%%' -e 's%[^/]$%&/%' -e 's%[^/]*/%../%g'` + case "$cache_file" in + /*) ac_sub_cache_file=$cache_file ;; + *) # Relative path. + ac_sub_cache_file="$ac_dots$cache_file" ;; + esac + case "$ac_given_INSTALL" in + [/$]*) INSTALL="$ac_given_INSTALL" ;; + *) INSTALL="$ac_dots$ac_given_INSTALL" ;; + esac + + echo "running ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir" + # The eval makes quoting arguments work. + if eval ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir + then : + else + { echo "configure: error: $ac_sub_configure failed for $ac_config_dir" 1>&2; exit 1; } + fi + fi + + cd $ac_popdir + done +fi diff -ruN make-3.72.1/configure.bat make-3.73/configure.bat --- make-3.72.1/configure.bat Wed Dec 31 19:00:00 1969 +++ make-3.73/configure.bat Fri Mar 17 15:56:53 1995 @@ -0,0 +1,44 @@ +@echo off +echo Configuring MAKE for go32 +rem This batch file assumes a unix-type "sed" program + +update configh.dos config.h + +echo # Makefile generated by "configure.bat"> Makefile + +if exist config.sed del config.sed + +echo ": try_sl ">> config.sed +echo "/\\$/ { ">> config.sed +echo " N ">> config.sed +echo " s/[ ]*\\\n[ ]*/ / ">> config.sed +echo " b try_sl ">> config.sed +echo "} ">> config.sed + +echo "s/@srcdir@/./ ">> config.sed +echo "s/@CC@/gcc/ ">> config.sed +echo "s/@CFLAGS@/-O2 -g/ ">> config.sed +echo "s/@CPPFLAGS@/-DHAVE_CONFIG_H/ ">> config.sed +echo "s/@LDFLAGS@// ">> config.sed +echo "s/@RANLIB@/ranlib/ ">> config.sed +echo "s/@DEFS@// ">> config.sed +echo "s/@REMOTE@/stub/ ">> config.sed +echo "s/@ALLOCA@// ">> config.sed +echo "s/@LIBS@// ">> config.sed +echo "s/@LIBOBJS@// ">> config.sed +echo "s/@SET_MAKE@// ">> config.sed +echo "s/^Makefile *:/_Makefile:/ ">> config.sed +echo "s/^config.h *:/_config.h:/ ">> config.sed +echo "s/^defines *=.*$/defines =/ ">> config.sed +echo "/mv -f make.new make/d ">> config.sed + +echo "s/cd glob; $(MAKE)/$(MAKE) -C glob/ ">> config.sed + +sed -e "s/^\"//" -e "s/\"$//" -e "s/[ ]*$//" config.sed > config2.sed +sed -f config2.sed Makefile.in >> Makefile +del config.sed +del config2.sed + +cd glob +call configure +cd .. diff -ruN make-3.72.1/default.c make-3.73/default.c --- make-3.72.1/default.c Tue Sep 6 20:15:23 1994 +++ make-3.73/default.c Tue Jan 10 19:14:53 1995 @@ -1,5 +1,5 @@ /* Data base of default implicit rules for GNU Make. -Copyright (C) 1988, 89, 90, 91, 92, 93, 94 Free Software Foundation, Inc. +Copyright (C) 1988, 89, 90, 91, 92, 93, 94, 1995 Free Software Foundation, Inc. This file is part of GNU Make. GNU Make is free software; you can redistribute it and/or modify @@ -209,13 +209,7 @@ static char *default_variables[] = { "AR", "ar", -#ifndef __hpux "ARFLAGS", "rv", -#else - /* HPUX ar's f flag says to truncate the file names to archive member - name length in comparisons, so replacement notices the equality. */ - "ARFLAGS", "rfv", -#endif "AS", "as", #ifdef GCC_IS_NATIVE "CC", "gcc", diff -ruN make-3.72.1/dir.c make-3.73/dir.c --- make-3.72.1/dir.c Mon Sep 26 18:20:56 1994 +++ make-3.73/dir.c Mon Nov 7 19:14:50 1994 @@ -18,26 +18,26 @@ #include "make.h" -#if defined (POSIX) || defined (DIRENT) || defined (__GNU_LIBRARY__) +#if defined (POSIX) || defined (HAVE_DIRENT_H) || defined (__GNU_LIBRARY__) #include #ifndef __GNU_LIBRARY__ #define D_NAMLEN(d) strlen((d)->d_name) #else /* GNU C library. */ #define D_NAMLEN(d) ((d)->d_namlen) #endif /* Not GNU C library. */ -#else /* Not POSIX or DIRENT. */ +#else /* Not POSIX or HAVE_DIRENT_H. */ #define direct dirent #define D_NAMLEN(d) ((d)->d_namlen) -#ifdef SYSNDIR +#ifdef HAVE_SYS_NDIR_H #include -#endif /* SYSNDIR */ -#ifdef SYSDIR +#endif /* HAVE_SYS_NDIR_H */ +#ifdef HAVE_SYS_DIR_H #include -#endif /* SYSDIR */ -#ifdef NDIR +#endif /* HAVE_SYS_DIR_H */ +#ifdef HAVE_NDIR_H #include -#endif /* NDIR */ -#endif /* POSIX or DIRENT or __GNU_LIBRARY__. */ +#endif /* HAVE_NDIR_H */ +#endif /* POSIX or HAVE_DIRENT_H or __GNU_LIBRARY__. */ #if defined (POSIX) && !defined (__GNU_LIBRARY__) /* Posix does not require that the d_ino field be present, and some diff -ruN make-3.72.1/expand.c make-3.73/expand.c --- make-3.72.1/expand.c Mon Aug 30 12:31:47 1993 +++ make-3.73/expand.c Mon Feb 6 17:36:43 1995 @@ -1,5 +1,5 @@ /* Variable expansion functions for GNU Make. -Copyright (C) 1988, 1989, 1991, 1992, 1993 Free Software Foundation, Inc. +Copyright (C) 1988, 89, 91, 92, 93, 95 Free Software Foundation, Inc. This file is part of GNU Make. GNU Make is free software; you can redistribute it and/or modify @@ -197,9 +197,9 @@ char openparen = *p; char closeparen = (openparen == '(') ? ')' : '}'; register char *beg = p + 1; + int free_beg = 0; char *op, *begp; - char *end; - char *colon = 0; + char *end, *colon; op = o; begp = p; @@ -213,10 +213,18 @@ /* Is there a variable reference inside the parens or braces? If so, expand it before expanding the entire reference. */ - p1 = index (beg, closeparen); + end = index (beg, closeparen); + if (end == 0) + { + /* Unterminated variable reference. */ + if (reading_filename != 0) + makefile_fatal (reading_filename, *reading_lineno_ptr, + "unterminated variable reference"); + else + fatal ("unterminated variable reference"); + } + p1 = lindex (beg, end, '$'); if (p1 != 0) - p1 = lindex (beg, p1, '$'); - if (p1 != 0 && lindex (beg, p1, ':') == 0) { /* BEG now points past the opening paren or brace. Count parens or braces until it is matched. */ @@ -227,133 +235,109 @@ ++count; else if (*p == closeparen && --count < 0) break; - else if (colon == 0 && count == 0 && *p == ':') - /* Record where we found a colon, which - indicates a substitution reference. - We want to expand the text before the - reference only. */ - colon = p; } /* If COUNT is >= 0, there were unmatched opening parens or braces, so we go to the simple case of a variable name such as `$($(a)'. */ if (count < 0) { - char *name = expand_argument (beg, colon == 0 ? p : colon); - unsigned int namelen = strlen (name); - if (colon == 0) - { - /* This is a simple reference to the expanded name. */ - o = reference_variable (o, name, namelen); - free (name); - break; - } - else - { - /* This is a substitution reference to the expanded - name. We replace the pending text with a copy - containing the expanded name in place of the - original name, and then fall through to - the normal substitution reference code below. */ - unsigned int restlen = strlen (colon) + 1; - beg = (char *) alloca (namelen + restlen); - bcopy (name, beg, namelen); - bcopy (colon, &beg[namelen], restlen); - /* Point COLON into the new copy. */ - colon = &beg[namelen]; - } + beg = expand_argument (beg, p); /* Expand the name. */ + free_beg = 1; /* Remember to free BEG when finished. */ + end = index (beg, '\0'); } } + else + /* Advance P to the end of this reference. After we are + finished expanding this one, P will be incremented to + continue the scan. */ + p = end; /* This is not a reference to a built-in function and - it does not contain any variable references inside. - There are several things it could be. */ + any variable references inside are now expanded. + Is the resultant text a substitution reference? */ - if (colon == 0) - colon = index (beg, ':'); - if (colon != 0 && lindex (beg, colon, closeparen) == 0) + colon = lindex (beg, end, ':'); + if (colon != 0) { - /* This is a substitution reference: $(FOO:A=B). */ - int count; + /* This looks like a substitution reference: $(FOO:A=B). */ char *subst_beg, *subst_end, *replace_beg, *replace_end; - v = lookup_variable (beg, colon - beg); - if (v == 0) - warn_undefined (beg, colon - beg); - subst_beg = colon + 1; - count = 0; - for (p = subst_beg; *p != '\0'; ++p) + subst_end = index (subst_beg, '='); + if (subst_end == 0) + /* There is no = in sight. Punt on the substitution + reference and treat this as a variable name containing + a colon, in the code below. */ + colon = 0; + else { - if (*p == openparen) - ++count; - else if (*p == closeparen) - --count; - else if (*p == '=' && count <= 0) - break; - } - if (count > 0) - /* There were unmatched opening parens. */ - return initialize_variable_output (); - subst_end = p; - - replace_beg = p + 1; - count = 0; - for (p = replace_beg; *p != '\0'; ++p) - { - if (*p == openparen) - ++count; - else if (*p == closeparen && --count < 0) - break; - } - if (count > 0) - /* There were unmatched opening parens. */ - return initialize_variable_output (); - end = p; - replace_end = p; + replace_beg = subst_end + 1; + replace_end = end; - p = expand_argument (subst_beg, subst_end); - p1 = expand_argument (replace_beg, replace_end); + /* Extract the variable name before the colon + and look up that variable. */ + v = lookup_variable (beg, colon - beg); + if (v == 0) + warn_undefined (beg, colon - beg); - if (v != 0 && *v->value != '\0') - { - char *value = (v->recursive ? recursively_expand (v) - : v->value); - char *percent = find_percent (p); - if (percent != 0) - o = patsubst_expand (o, value, p, p1, - percent, (char *) 0); - else - o = subst_expand (o, value, - p, p1, strlen (p), strlen (p1), - 0, 1); - if (v->recursive) - free (value); + if (v != 0 && *v->value != '\0') + { + char *value = (v->recursive ? recursively_expand (v) + : v->value); + char *pattern, *percent; + if (free_beg) + { + *subst_end = '\0'; + pattern = subst_beg; + } + else + { + pattern = (char *) alloca (subst_end - subst_beg + + 1); + bcopy (subst_beg, pattern, subst_end - subst_beg); + pattern[subst_end - subst_beg] = '\0'; + } + percent = find_percent (pattern); + if (percent != 0) + { + char *replace; + if (free_beg) + { + *replace_end = '\0'; + replace = replace_beg; + } + else + { + replace = (char *) alloca (replace_end + - replace_beg + + 1); + bcopy (replace_beg, replace, + replace_end - replace_beg); + replace[replace_end - replace_beg] = '\0'; + } + + o = patsubst_expand (o, value, pattern, replace, + percent, (char *) 0); + } + else + o = subst_expand (o, value, + pattern, replace_beg, + strlen (pattern), + end - replace_beg, + 0, 1); + if (v->recursive) + free (value); + } } - - free (p); - free (p1); } - /* No, this must be an ordinary variable reference. */ - else - { - /* Look up the value of the variable. */ - end = index (beg, closeparen); - if (end == 0) - { - /* Unterminated variable reference. */ - if (reading_filename != 0) - makefile_fatal (reading_filename, *reading_lineno_ptr, - "unterminated variable reference"); - else - fatal ("unterminated variable reference"); - } + if (colon == 0) + /* This is an ordinary variable reference. + Look up the value of the variable. */ o = reference_variable (o, beg, end - beg); - } - /* Advance p past the variable reference to resume scan. */ - p = end; + if (free_beg) + free (beg); } break; diff -ruN make-3.72.1/getloadavg.c make-3.73/getloadavg.c --- make-3.72.1/getloadavg.c Wed Oct 26 20:34:42 1994 +++ make-3.73/getloadavg.c Sat Jan 7 11:57:36 1995 @@ -1,5 +1,5 @@ /* Get the system load averages. - Copyright (C) 1985, 86, 87, 88, 89, 91, 92, 93, 1994 + Copyright (C) 1985, 86, 87, 88, 89, 91, 92, 93, 1994, 1995 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify @@ -59,6 +59,11 @@ We also #define LDAV_PRIVILEGED if a program will require special installation to be able to call getloadavg. */ +/* This should always be first. */ +#ifdef HAVE_CONFIG_H +#include +#endif + #include /* Both the Emacs and non-Emacs sections want this. Some @@ -68,10 +73,6 @@ #include #endif - -#ifdef HAVE_CONFIG_H -#include -#endif /* Exclude all the code except the test program at the end if the system has its own `getloadavg' function. diff -ruN make-3.72.1/getopt.c make-3.73/getopt.c --- make-3.72.1/getopt.c Wed Nov 2 16:16:08 1994 +++ make-3.73/getopt.c Fri Mar 24 00:57:32 1995 @@ -3,7 +3,7 @@ "Keep this file name-space clean" means, talk to roland@gnu.ai.mit.edu before changing it! - Copyright (C) 1987, 88, 89, 90, 91, 92, 93, 94 + Copyright (C) 1987, 88, 89, 90, 91, 92, 93, 94, 95 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it @@ -59,6 +59,14 @@ #include #endif /* GNU C library. */ +/* This is for other GNU distributions with internationalized messages. + The GNU C Library itself does not yet support such messages. */ +#if HAVE_LIBINTL_H +# include +#else +# define gettext(msgid) (msgid) +#endif + /* This version of `getopt' appears to the caller like standard Unix `getopt' but it behaves differently for the user, since it allows the user to intersperse the options with the other arguments. @@ -375,7 +383,10 @@ optarg = NULL; if (optind == 0) - optstring = _getopt_initialize (optstring); + { + optstring = _getopt_initialize (optstring); + optind = 1; /* Don't scan ARGV[0], the program name. */ + } if (nextchar == NULL || *nextchar == '\0') { @@ -505,7 +516,7 @@ if (ambig && !exact) { if (opterr) - fprintf (stderr, "%s: option `%s' is ambiguous\n", + fprintf (stderr, gettext ("%s: option `%s' is ambiguous\n"), argv[0], argv[optind]); nextchar += strlen (nextchar); optind++; @@ -525,18 +536,17 @@ else { if (opterr) - { - if (argv[optind - 1][1] == '-') - /* --option */ - fprintf (stderr, - "%s: option `--%s' doesn't allow an argument\n", - argv[0], pfound->name); - else - /* +option or -option */ - fprintf (stderr, - "%s: option `%c%s' doesn't allow an argument\n", - argv[0], argv[optind - 1][0], pfound->name); - } + if (argv[optind - 1][1] == '-') + /* --option */ + fprintf (stderr, + gettext ("%s: option `--%s' doesn't allow an argument\n"), + argv[0], pfound->name); + else + /* +option or -option */ + fprintf (stderr, + gettext ("%s: option `%c%s' doesn't allow an argument\n"), + argv[0], argv[optind - 1][0], pfound->name); + nextchar += strlen (nextchar); return '?'; } @@ -548,8 +558,9 @@ else { if (opterr) - fprintf (stderr, "%s: option `%s' requires an argument\n", - argv[0], argv[optind - 1]); + fprintf (stderr, + gettext ("%s: option `%s' requires an argument\n"), + argv[0], argv[optind - 1]); nextchar += strlen (nextchar); return optstring[0] == ':' ? ':' : '?'; } @@ -576,11 +587,11 @@ { if (argv[optind][1] == '-') /* --option */ - fprintf (stderr, "%s: unrecognized option `--%s'\n", + fprintf (stderr, gettext ("%s: unrecognized option `--%s'\n"), argv[0], nextchar); else /* +option or -option */ - fprintf (stderr, "%s: unrecognized option `%c%s'\n", + fprintf (stderr, gettext ("%s: unrecognized option `%c%s'\n"), argv[0], argv[optind][0], nextchar); } nextchar = (char *) ""; @@ -605,9 +616,11 @@ { if (posixly_correct) /* 1003.2 specifies the format of this message. */ - fprintf (stderr, "%s: illegal option -- %c\n", argv[0], c); + fprintf (stderr, gettext ("%s: illegal option -- %c\n"), + argv[0], c); else - fprintf (stderr, "%s: invalid option -- %c\n", argv[0], c); + fprintf (stderr, gettext ("%s: invalid option -- %c\n"), + argv[0], c); } optopt = c; return '?'; @@ -641,8 +654,9 @@ if (opterr) { /* 1003.2 specifies the format of this message. */ - fprintf (stderr, "%s: option requires an argument -- %c\n", - argv[0], c); + fprintf (stderr, + gettext ("%s: option requires an argument -- %c\n"), + argv[0], c); } optopt = c; if (optstring[0] == ':') diff -ruN make-3.72.1/glob/Makefile.in make-3.73/glob/Makefile.in --- make-3.72.1/glob/Makefile.in Fri Apr 22 17:34:16 1994 +++ make-3.73/glob/Makefile.in Mon Jan 16 15:49:01 1995 @@ -1,6 +1,6 @@ # Makefile for standalone distribution of libglob.a (fnmatch, glob). -# Copyright (C) 1991, 1992, 1993, 1994 Free Software Foundation, Inc. +# Copyright (C) 1991, 92, 93, 94, 95 Free Software Foundation, Inc. # This file is part of the GNU C Library. # This library is free software; you can redistribute it and/or @@ -23,10 +23,15 @@ # This must repeat the value, because configure will remove `VPATH = .'. srcdir = @srcdir@ -CPPFLAGS = @DEFS@ +CC = @CC@ +CPPFLAGS = @CPPFLAGS@ +CFLAGS = @CFLAGS@ -# How the invoke ar. -AR = ar +# Information determined by configure. +DEFS = @DEFS@ + +# How to invoke ar. +AR = @AR@ ARFLAGS = rv # How to invoke ranlib. @@ -46,13 +51,15 @@ fnmatch.o: $(srcdir)/fnmatch.h fnmatch.c .c.o: - $(CC) -I. -I$(srcdir) -c $(CPPFLAGS) $(CFLAGS) $< $(OUTPUT_OPTION) + $(CC) -I. -I$(srcdir) -c \ + $(DEFS) $(CPPFLAGS) $(CFLAGS) $< $(OUTPUT_OPTION) -.PHONY: clean realclean glob-clean glob-realclean +.PHONY: clean realclean glob-clean glob-realclean distclean clean glob-clean: -rm -f libglob.a *.o core -realclean glob-realclean: clean - -rm -f TAGS tags Makefile +distclean glob-realclean: clean + -rm -f TAGS tags Makefile config.status config.h config.log +realcean: distclean # For inside the C library. glob.tar glob.tar.Z: diff -ruN make-3.72.1/glob/configure.bat make-3.73/glob/configure.bat --- make-3.72.1/glob/configure.bat Wed Dec 31 19:00:00 1969 +++ make-3.73/glob/configure.bat Wed Mar 8 20:17:56 1995 @@ -0,0 +1,26 @@ +@echo off +echo Configuring glob for GO32 +rem This batch file assumes a unix-type "sed" program + +echo # Makefile generated by "configure.bat"> Makefile + +if exist config.sed del config.sed + +echo "s/@srcdir@/./ ">> config.sed +echo "s/@CC@/gcc/ ">> config.sed +echo "s/@CFLAGS@/-O2 -g/ ">> config.sed +echo "s/@CPPFLAGS@/-DHAVE_CONFIG_H -I../ ">> config.sed +echo "s/@AR@/ar/ ">> config.sed +echo "s/@RANLIB@/ranlib/ ">> config.sed +echo "s/@LDFLAGS@// ">> config.sed +echo "s/@DEFS@// ">> config.sed +echo "s/@ALLOCA@// ">> config.sed +echo "s/@LIBS@// ">> config.sed +echo "s/@LIBOBJS@// ">> config.sed +echo "s/^Makefile *:/_Makefile:/ ">> config.sed +echo "s/^config.h *:/_config.h:/ ">> config.sed + +sed -e "s/^\"//" -e "s/\"$//" -e "s/[ ]*$//" config.sed > config2.sed +sed -f config2.sed Makefile.in >> Makefile +del config.sed +del config2.sed diff -ruN make-3.72.1/glob/configure.in make-3.73/glob/configure.in --- make-3.72.1/glob/configure.in Wed Dec 31 19:00:00 1969 +++ make-3.73/glob/configure.in Wed Feb 22 21:29:09 1995 @@ -0,0 +1,19 @@ +dnl Process this file with autoconf to produce a configure script. +AC_INIT(fnmatch.c) dnl A distinctive file to look for in srcdir. +AC_PREREQ(2.1) dnl Minimum Autoconf version required. +AC_PROG_CC +AC_CHECK_PROG(AR, ar, ar, ar) +AC_PROG_RANLIB +AC_PROG_CPP dnl Later checks need this. +dnl These two want to come early. +AC_AIX +AC_MINIX +AC_ISC_POSIX +AC_CONST +AC_HEADER_STDC +AC_CHECK_HEADERS(memory.h unistd.h string.h) +AC_HEADER_DIRENT +AC_FUNC_CLOSEDIR_VOID +AC_FUNC_ALLOCA +AC_FUNC_STRCOLL +AC_OUTPUT(Makefile) diff -ruN make-3.72.1/glob/configure make-3.73/glob/configure --- make-3.72.1/glob/configure Wed Dec 31 19:00:00 1969 +++ make-3.73/glob/configure Fri Feb 24 20:23:09 1995 @@ -0,0 +1,1547 @@ +#! /bin/sh + +# Guess values for system-dependent variables and create Makefiles. +# Generated automatically using autoconf version 2.1.2 +# Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc. +# +# This configure script is free software; the Free Software Foundation +# gives unlimited permission to copy, distribute and modify it. + +# Defaults: +ac_help= +ac_default_prefix=/usr/local +# Any additions from configure.in: + +# Initialize some variables set by options. +# The variables have the same names as the options, with +# dashes changed to underlines. +build=NONE +cache_file=./config.cache +exec_prefix=NONE +host=NONE +no_create= +nonopt=NONE +no_recursion= +prefix=NONE +program_prefix=NONE +program_suffix=NONE +program_transform_name=s,x,x, +silent= +site= +srcdir= +target=NONE +verbose= +x_includes=NONE +x_libraries=NONE + +# Initialize some other variables. +subdirs= + +ac_prev= +for ac_option +do + + # If the previous option needs an argument, assign it. + if test -n "$ac_prev"; then + eval "$ac_prev=\$ac_option" + ac_prev= + continue + fi + + case "$ac_option" in + -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; + *) ac_optarg= ;; + esac + + # Accept the important Cygnus configure options, so we can diagnose typos. + + case "$ac_option" in + + -build | --build | --buil | --bui | --bu | --b) + ac_prev=build ;; + -build=* | --build=* | --buil=* | --bui=* | --bu=* | --b=*) + build="$ac_optarg" ;; + + -cache-file | --cache-file | --cache-fil | --cache-fi \ + | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) + ac_prev=cache_file ;; + -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ + | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) + cache_file="$ac_optarg" ;; + + -disable-* | --disable-*) + ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` + # Reject names that are not valid shell variable names. + if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then + { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } + fi + ac_feature=`echo $ac_feature| sed 's/-/_/g'` + eval "enable_${ac_feature}=no" ;; + + -enable-* | --enable-*) + ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` + # Reject names that are not valid shell variable names. + if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then + { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } + fi + ac_feature=`echo $ac_feature| sed 's/-/_/g'` + case "$ac_option" in + *=*) ;; + *) ac_optarg=yes ;; + esac + eval "enable_${ac_feature}='$ac_optarg'" ;; + + -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ + | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ + | --exec | --exe | --ex) + ac_prev=exec_prefix ;; + -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ + | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ + | --exec=* | --exe=* | --ex=*) + exec_prefix="$ac_optarg" ;; + + -gas | --gas | --ga | --g) + # Obsolete; use --with-gas. + with_gas=yes ;; + + -help | --help | --hel | --he) + # Omit some internal or obsolete options to make the list less imposing. + # This message is too long to be a string in the A/UX 3.1 sh. + cat << EOF +Usage: configure [options] [host] +Options: [defaults in brackets after descriptions] +Configuration: + --cache-file=FILE cache test results in FILE + --help print this message + --no-create do not create output files + --quiet, --silent do not print \`checking...' messages + --version print the version of autoconf that created configure +Directory and file names: + --prefix=PREFIX install architecture-independent files in PREFIX + [$ac_default_prefix] + --exec-prefix=PREFIX install architecture-dependent files in PREFIX + [same as prefix] + --srcdir=DIR find the sources in DIR [configure dir or ..] + --program-prefix=PREFIX prepend PREFIX to installed program names + --program-suffix=SUFFIX append SUFFIX to installed program names + --program-transform-name=PROGRAM run sed PROGRAM on installed program names +Host type: + --build=BUILD configure for building on BUILD [BUILD=HOST] + --host=HOST configure for HOST [guessed] + --target=TARGET configure for TARGET [TARGET=HOST] +Features and packages: + --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) + --enable-FEATURE[=ARG] include FEATURE [ARG=yes] + --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] + --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) + --x-includes=DIR X include files are in DIR + --x-libraries=DIR X library files are in DIR +--enable and --with options recognized:$ac_help +EOF + exit 0 ;; + + -host | --host | --hos | --ho) + ac_prev=host ;; + -host=* | --host=* | --hos=* | --ho=*) + host="$ac_optarg" ;; + + -nfp | --nfp | --nf) + # Obsolete; use --without-fp. + with_fp=no ;; + + -no-create | --no-create | --no-creat | --no-crea | --no-cre \ + | --no-cr | --no-c) + no_create=yes ;; + + -no-recursion | --no-recursion | --no-recursio | --no-recursi \ + | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) + no_recursion=yes ;; + + -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) + ac_prev=prefix ;; + -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) + prefix="$ac_optarg" ;; + + -program-prefix | --program-prefix | --program-prefi | --program-pref \ + | --program-pre | --program-pr | --program-p) + ac_prev=program_prefix ;; + -program-prefix=* | --program-prefix=* | --program-prefi=* \ + | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) + program_prefix="$ac_optarg" ;; + + -program-suffix | --program-suffix | --program-suffi | --program-suff \ + | --program-suf | --program-su | --program-s) + ac_prev=program_suffix ;; + -program-suffix=* | --program-suffix=* | --program-suffi=* \ + | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) + program_suffix="$ac_optarg" ;; + + -program-transform-name | --program-transform-name \ + | --program-transform-nam | --program-transform-na \ + | --program-transform-n | --program-transform- \ + | --program-transform | --program-transfor \ + | --program-transfo | --program-transf \ + | --program-trans | --program-tran \ + | --progr-tra | --program-tr | --program-t) + ac_prev=program_transform_name ;; + -program-transform-name=* | --program-transform-name=* \ + | --program-transform-nam=* | --program-transform-na=* \ + | --program-transform-n=* | --program-transform-=* \ + | --program-transform=* | --program-transfor=* \ + | --program-transfo=* | --program-transf=* \ + | --program-trans=* | --program-tran=* \ + | --progr-tra=* | --program-tr=* | --program-t=*) + program_transform_name="$ac_optarg" ;; + + -q | -quiet | --quiet | --quie | --qui | --qu | --q \ + | -silent | --silent | --silen | --sile | --sil) + silent=yes ;; + + -site | --site | --sit) + ac_prev=site ;; + -site=* | --site=* | --sit=*) + site="$ac_optarg" ;; + + -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) + ac_prev=srcdir ;; + -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) + srcdir="$ac_optarg" ;; + + -target | --target | --targe | --targ | --tar | --ta | --t) + ac_prev=target ;; + -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) + target="$ac_optarg" ;; + + -v | -verbose | --verbose | --verbos | --verbo | --verb) + verbose=yes ;; + + -version | --version | --versio | --versi | --vers) + echo "configure generated by autoconf version 2.1.2" + exit 0 ;; + + -with-* | --with-*) + ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` + # Reject names that are not valid shell variable names. + if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then + { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } + fi + ac_package=`echo $ac_package| sed 's/-/_/g'` + case "$ac_option" in + *=*) ;; + *) ac_optarg=yes ;; + esac + eval "with_${ac_package}='$ac_optarg'" ;; + + -without-* | --without-*) + ac_package=`echo $ac_option|sed -e 's/-*without-//'` + # Reject names that are not valid shell variable names. + if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then + { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } + fi + ac_package=`echo $ac_package| sed 's/-/_/g'` + eval "with_${ac_package}=no" ;; + + --x) + # Obsolete; use --with-x. + with_x=yes ;; + + -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ + | --x-incl | --x-inc | --x-in | --x-i) + ac_prev=x_includes ;; + -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ + | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) + x_includes="$ac_optarg" ;; + + -x-libraries | --x-libraries | --x-librarie | --x-librari \ + | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) + ac_prev=x_libraries ;; + -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ + | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) + x_libraries="$ac_optarg" ;; + + -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; } + ;; + + *) + if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then + echo "configure: warning: $ac_option: invalid host type" 1>&2 + fi + if test "x$nonopt" != xNONE; then + { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } + fi + nonopt="$ac_option" + ;; + + esac +done + +if test -n "$ac_prev"; then + { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; } +fi + +trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 + +# File descriptor usage: +# 0 standard input +# 1 file creation +# 2 errors and warnings +# 3 some systems may open it to /dev/tty +# 4 used on the Kubota Titan +# 6 checking for... messages and results +# 5 compiler messages saved in config.log +if test "$silent" = yes; then + exec 6>/dev/null +else + exec 6>&1 +fi +exec 5>./config.log + +echo "\ +This file contains any messages produced by compilers while +running configure, to aid debugging if configure makes a mistake. +" 1>&5 + +# Strip out --no-create and --no-recursion so they do not pile up. +# Also quote any args containing shell metacharacters. +ac_configure_args= +for ac_arg +do + case "$ac_arg" in + -no-create | --no-create | --no-creat | --no-crea | --no-cre \ + | --no-cr | --no-c) ;; + -no-recursion | --no-recursion | --no-recursio | --no-recursi \ + | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; + *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) + ac_configure_args="$ac_configure_args '$ac_arg'" ;; + *) ac_configure_args="$ac_configure_args $ac_arg" ;; + esac +done + +# NLS nuisances. +# Only set LANG and LC_ALL to C if already set. +# These must not be set unconditionally because not all systems understand +# e.g. LANG=C (notably SCO). +if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi +if test "${LANG+set}" = set; then LANG=C; export LANG; fi + +# confdefs.h avoids OS command line length limits that DEFS can exceed. +rm -rf conftest* confdefs.h +# AIX cpp loses on an empty file, so make sure it contains at least a newline. +echo > confdefs.h + +# A filename unique to this package, relative to the directory that +# configure is in, which we can look for to find out if srcdir is correct. +ac_unique_file=fnmatch.c + +# Find the source files, if location was not specified. +if test -z "$srcdir"; then + ac_srcdir_defaulted=yes + # Try the directory containing this script, then its parent. + ac_prog=$0 + ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` + test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. + srcdir=$ac_confdir + if test ! -r $srcdir/$ac_unique_file; then + srcdir=.. + fi +else + ac_srcdir_defaulted=no +fi +if test ! -r $srcdir/$ac_unique_file; then + if test "$ac_srcdir_defaulted" = yes; then + { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; } + else + { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; } + fi +fi +srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` + +# Prefer explicitly selected file to automatically selected ones. +if test -z "$CONFIG_SITE"; then + if test "x$prefix" != xNONE; then + CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" + else + CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" + fi +fi +for ac_site_file in $CONFIG_SITE; do + if test -r "$ac_site_file"; then + echo "loading site script $ac_site_file" + . "$ac_site_file" + fi +done + +if test -r "$cache_file"; then + echo "loading cache $cache_file" + . $cache_file +else + echo "creating cache $cache_file" + > $cache_file +fi + +ac_ext=c +# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. +ac_cpp='$CPP $CPPFLAGS' +ac_compile='${CC-cc} conftest.$ac_ext $CFLAGS $CPPFLAGS -c 1>&5 2>&5' +ac_link='${CC-cc} conftest.$ac_ext $CFLAGS $CPPFLAGS $LDFLAGS -o conftest $LIBS 1>&5 2>&5' + +if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then + # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. + if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then + ac_n= ac_c=' +' ac_t=' ' + else + ac_n=-n ac_c= ac_t= + fi +else + ac_n= ac_c='\c' ac_t= +fi + + # Extract the first word of "gcc", so it can be a program name with args. +set dummy gcc; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" + for ac_dir in $PATH; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_prog_CC="gcc" + break + fi + done + IFS="$ac_save_ifs" + test -z "$ac_cv_prog_CC" && ac_cv_prog_CC="cc" +fi +fi +CC="$ac_cv_prog_CC" +if test -n "$CC"; then + echo "$ac_t""$CC" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + + +echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.c <&5 | egrep yes >/dev/null 2>&1; then + ac_cv_prog_gcc=yes +else + ac_cv_prog_gcc=no +fi +fi +echo "$ac_t""$ac_cv_prog_gcc" 1>&6 +if test $ac_cv_prog_gcc = yes; then + GCC=yes + if test "${CFLAGS+set}" != set; then + echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_prog_gcc_g'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + echo 'void f(){}' > conftest.c +if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then + ac_cv_prog_gcc_g=yes +else + ac_cv_prog_gcc_g=no +fi +rm -f conftest* + +fi + echo "$ac_t""$ac_cv_prog_gcc_g" 1>&6 + if test $ac_cv_prog_gcc_g = yes; then + CFLAGS="-g -O" + else + CFLAGS="-O" + fi + fi +else + GCC= + test "${CFLAGS+set}" = set || CFLAGS="-g" +fi + +# Extract the first word of "ar", so it can be a program name with args. +set dummy ar; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test -n "$AR"; then + ac_cv_prog_AR="$AR" # Let the user override the test. +else + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" + for ac_dir in $PATH; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_prog_AR="ar" + break + fi + done + IFS="$ac_save_ifs" + test -z "$ac_cv_prog_AR" && ac_cv_prog_AR="ar" +fi +fi +AR="$ac_cv_prog_AR" +if test -n "$AR"; then + echo "$ac_t""$AR" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + +# Extract the first word of "ranlib", so it can be a program name with args. +set dummy ranlib; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test -n "$RANLIB"; then + ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. +else + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" + for ac_dir in $PATH; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_prog_RANLIB="ranlib" + break + fi + done + IFS="$ac_save_ifs" + test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" +fi +fi +RANLIB="$ac_cv_prog_RANLIB" +if test -n "$RANLIB"; then + echo "$ac_t""$RANLIB" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + +echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 +# On Suns, sometimes $CPP names a directory. +if test -n "$CPP" && test -d "$CPP"; then + CPP= +fi +if test -z "$CPP"; then +if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + # This must be in double quotes, not single quotes, because CPP may get + # substituted into the Makefile and "${CC-cc}" will confuse make. + CPP="${CC-cc} -E" + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. + cat > conftest.$ac_ext < +Syntax Error +EOF +eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + : +else + echo "$ac_err" >&5 + rm -rf conftest* + CPP="${CC-cc} -E -traditional-cpp" + cat > conftest.$ac_ext < +Syntax Error +EOF +eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + : +else + echo "$ac_err" >&5 + rm -rf conftest* + CPP=/lib/cpp +fi +rm -f conftest* +fi +rm -f conftest* + ac_cv_prog_CPP="$CPP" +fi +fi +CPP="$ac_cv_prog_CPP" +echo "$ac_t""$CPP" 1>&6 + echo $ac_n "checking for AIX""... $ac_c" 1>&6 +cat > conftest.$ac_ext <&5 | + egrep "yes" >/dev/null 2>&1; then + rm -rf conftest* + echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF +#define _ALL_SOURCE 1 +EOF + +else + rm -rf conftest* + echo "$ac_t""no" 1>&6 +fi +rm -f conftest* + + +ac_safe=`echo "minix/config.h" | tr './\055' '___'` +echo $ac_n "checking for minix/config.h""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +EOF +eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + MINIX=yes +else + echo "$ac_t""no" 1>&6 +MINIX= +fi + +if test "$MINIX" = yes; then + cat >> confdefs.h <<\EOF +#define _POSIX_SOURCE 1 +EOF + + cat >> confdefs.h <<\EOF +#define _POSIX_1_SOURCE 2 +EOF + + cat >> confdefs.h <<\EOF +#define _MINIX 1 +EOF + +fi + +echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6 +if test -d /etc/conf/kconfig.d && + grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1 +then + echo "$ac_t""yes" 1>&6 + ISC=yes # If later tests want to check for ISC. + cat >> confdefs.h <<\EOF +#define _POSIX_SOURCE 1 +EOF + + if test "$GCC" = yes; then + CC="$CC -posix" + else + CC="$CC -Xp" + fi +else + echo "$ac_t""no" 1>&6 + ISC= +fi + +echo $ac_n "checking for working const""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext <j = 5; +} +{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ + const int foo = 10; +} + +; return 0; } +EOF +if eval $ac_compile; then + rm -rf conftest* + ac_cv_c_const=yes +else + rm -rf conftest* + ac_cv_c_const=no +fi +rm -f conftest* + +fi +echo "$ac_t""$ac_cv_c_const" 1>&6 +if test $ac_cv_c_const = no; then + cat >> confdefs.h <<\EOF +#define const +EOF + +fi + +# If we cannot run a trivial program, we must be cross compiling. +echo $ac_n "checking whether cross-compiling""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_c_cross'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test "$cross_compiling" = yes; then + ac_cv_c_cross=yes +else +cat > conftest.$ac_ext </dev/null; then + ac_cv_c_cross=no +else + ac_cv_c_cross=yes +fi +fi +rm -fr conftest* +fi +cross_compiling=$ac_cv_c_cross +echo "$ac_t""$ac_cv_c_cross" 1>&6 + +echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +#include +#include +#include +EOF +eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + rm -rf conftest* + ac_cv_header_stdc=yes +else + echo "$ac_err" >&5 + rm -rf conftest* + ac_cv_header_stdc=no +fi +rm -f conftest* + +if test $ac_cv_header_stdc = yes; then + # SunOS 4.x string.h does not declare mem*, contrary to ANSI. +cat > conftest.$ac_ext < +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "memchr" >/dev/null 2>&1; then + : +else + rm -rf conftest* + ac_cv_header_stdc=no +fi +rm -f conftest* + +fi + +if test $ac_cv_header_stdc = yes; then + # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. +cat > conftest.$ac_ext < +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "free" >/dev/null 2>&1; then + : +else + rm -rf conftest* + ac_cv_header_stdc=no +fi +rm -f conftest* + +fi + +if test $ac_cv_header_stdc = yes; then + # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. +if test "$cross_compiling" = yes; then + ac_cv_header_stdc=no +else +cat > conftest.$ac_ext < +#define ISLOWER(c) ('a' <= (c) && (c) <= 'z') +#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) +#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) +int main () { int i; for (i = 0; i < 256; i++) +if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); +exit (0); } + +EOF +eval $ac_link +if test -s conftest && (./conftest; exit) 2>/dev/null; then + : +else + ac_cv_header_stdc=no +fi +fi +rm -fr conftest* +fi +fi +echo "$ac_t""$ac_cv_header_stdc" 1>&6 +if test $ac_cv_header_stdc = yes; then + cat >> confdefs.h <<\EOF +#define STDC_HEADERS 1 +EOF + +fi + +for ac_hdr in memory.h unistd.h string.h +do +ac_safe=`echo "$ac_hdr" | tr './\055' '___'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +EOF +eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./\055' '[A-Z]___'` + cat >> confdefs.h <&6 +fi +done + +ac_header_dirent=no +for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h +do +ac_safe=`echo "$ac_hdr" | tr './\055' '___'` +echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +#include <$ac_hdr> +int main() { return 0; } +int t() { +DIR *dirp = 0; +; return 0; } +EOF +if eval $ac_compile; then + rm -rf conftest* + eval "ac_cv_header_dirent_$ac_safe=yes" +else + rm -rf conftest* + eval "ac_cv_header_dirent_$ac_safe=no" +fi +rm -f conftest* + +fi +if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./\055' '[A-Z]___'` + cat >> confdefs.h <&6 +fi +done +# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. +if test $ac_header_dirent = dirent.h; then +echo $ac_n "checking for -ldir""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_lib_dir'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-ldir $LIBS" +cat > conftest.$ac_ext <&6 + LIBS="$LIBS -ldir" +else + echo "$ac_t""no" 1>&6 +fi + +else +echo $ac_n "checking for -lx""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_lib_x'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lx $LIBS" +cat > conftest.$ac_ext <&6 + LIBS="$LIBS -lx" +else + echo "$ac_t""no" 1>&6 +fi + +fi + +echo $ac_n "checking whether closedir returns void""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_func_closedir_void'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test "$cross_compiling" = yes; then + { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } +else +cat > conftest.$ac_ext < +#include <$ac_header_dirent> +int closedir(); main() { exit(closedir(opendir(".")) != 0); } +EOF +eval $ac_link +if test -s conftest && (./conftest; exit) 2>/dev/null; then + ac_cv_func_closedir_void=no +else + ac_cv_func_closedir_void=yes +fi +fi +rm -fr conftest* +fi +echo "$ac_t""$ac_cv_func_closedir_void" 1>&6 +if test $ac_cv_func_closedir_void = yes; then + cat >> confdefs.h <<\EOF +#define CLOSEDIR_VOID 1 +EOF + +fi + +# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works +# for constant arguments. Useless! +echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +int main() { return 0; } +int t() { +char *p = alloca(2 * sizeof(int)); +; return 0; } +EOF +if eval $ac_link; then + rm -rf conftest* + ac_cv_header_alloca_h=yes +else + rm -rf conftest* + ac_cv_header_alloca_h=no +fi +rm -f conftest* + +fi +echo "$ac_t""$ac_cv_header_alloca_h" 1>&6 +if test $ac_cv_header_alloca_h = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_ALLOCA_H 1 +EOF + +fi + +echo $ac_n "checking for alloca""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_func_alloca'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +# else +# ifdef _AIX + #pragma alloca +# else +# ifndef alloca /* predefined by HP cc +Olibcalls */ +char *alloca (); +# endif +# endif +# endif +#endif + +int main() { return 0; } +int t() { +char *p = (char *) alloca(1); +; return 0; } +EOF +if eval $ac_link; then + rm -rf conftest* + ac_cv_func_alloca=yes +else + rm -rf conftest* + ac_cv_func_alloca=no +fi +rm -f conftest* + +fi +echo "$ac_t""$ac_cv_func_alloca" 1>&6 +if test $ac_cv_func_alloca = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_ALLOCA 1 +EOF + +fi + +if test $ac_cv_func_alloca = no; then + # The SVR3 libPW and SVR4 libucb both contain incompatible functions + # that cause trouble. Some versions do not even contain alloca or + # contain a buggy version. If you still want to use their alloca, + # use ar to extract alloca.o from them instead of compiling alloca.c. + ALLOCA=alloca.o + cat >> confdefs.h <<\EOF +#define C_ALLOCA 1 +EOF + + +echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext <&5 | + egrep "webecray" >/dev/null 2>&1; then + rm -rf conftest* + ac_cv_os_cray=yes +else + rm -rf conftest* + ac_cv_os_cray=no +fi +rm -f conftest* + +fi +echo "$ac_t""$ac_cv_os_cray" 1>&6 +if test $ac_cv_os_cray = yes; then +echo $ac_n "checking for _getb67""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_func__getb67'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < /* Arbitrary system header to define __stub macros. */ +/* Override any gcc2 internal prototype to avoid an error. */ +char _getb67(); + +int main() { return 0; } +int t() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub__getb67) || defined (__stub____getb67) +choke me +#else +_getb67(); +#endif + +; return 0; } +EOF +if eval $ac_link; then + rm -rf conftest* + eval "ac_cv_func__getb67=yes" +else + rm -rf conftest* + eval "ac_cv_func__getb67=no" +fi +rm -f conftest* + +fi +if eval "test \"`echo '$ac_cv_func_'_getb67`\" = yes"; then + echo "$ac_t""yes" 1>&6 + cat >> confdefs.h <<\EOF +#define CRAY_STACKSEG_END _getb67 +EOF + +else + echo "$ac_t""no" 1>&6 +echo $ac_n "checking for GETB67""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_func_GETB67'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < /* Arbitrary system header to define __stub macros. */ +/* Override any gcc2 internal prototype to avoid an error. */ +char GETB67(); + +int main() { return 0; } +int t() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_GETB67) || defined (__stub___GETB67) +choke me +#else +GETB67(); +#endif + +; return 0; } +EOF +if eval $ac_link; then + rm -rf conftest* + eval "ac_cv_func_GETB67=yes" +else + rm -rf conftest* + eval "ac_cv_func_GETB67=no" +fi +rm -f conftest* + +fi +if eval "test \"`echo '$ac_cv_func_'GETB67`\" = yes"; then + echo "$ac_t""yes" 1>&6 + cat >> confdefs.h <<\EOF +#define CRAY_STACKSEG_END GETB67 +EOF + +else + echo "$ac_t""no" 1>&6 +echo $ac_n "checking for getb67""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_func_getb67'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < /* Arbitrary system header to define __stub macros. */ +/* Override any gcc2 internal prototype to avoid an error. */ +char getb67(); + +int main() { return 0; } +int t() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_getb67) || defined (__stub___getb67) +choke me +#else +getb67(); +#endif + +; return 0; } +EOF +if eval $ac_link; then + rm -rf conftest* + eval "ac_cv_func_getb67=yes" +else + rm -rf conftest* + eval "ac_cv_func_getb67=no" +fi +rm -f conftest* + +fi +if eval "test \"`echo '$ac_cv_func_'getb67`\" = yes"; then + echo "$ac_t""yes" 1>&6 + cat >> confdefs.h <<\EOF +#define CRAY_STACKSEG_END getb67 +EOF + +else + echo "$ac_t""no" 1>&6 +fi + +fi + +fi + +fi + +echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test "$cross_compiling" = yes; then + ac_cv_c_stack_direction=0 +else +cat > conftest.$ac_ext < addr) ? 1 : -1; +} +main () +{ + exit (find_stack_direction() < 0); +} +EOF +eval $ac_link +if test -s conftest && (./conftest; exit) 2>/dev/null; then + ac_cv_c_stack_direction=1 +else + ac_cv_c_stack_direction=-1 +fi +fi +rm -fr conftest* +fi +echo "$ac_t""$ac_cv_c_stack_direction" 1>&6 +cat >> confdefs.h <&6 +if eval "test \"`echo '$''{'ac_cv_func_strcoll'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test "$cross_compiling" = yes; then + ac_cv_func_strcoll=no +else +cat > conftest.$ac_ext < +main () +{ + exit (strcoll ("abc", "def") >= 0 || + strcoll ("ABC", "DEF") >= 0 || + strcoll ("123", "456") >= 0); +} +EOF +eval $ac_link +if test -s conftest && (./conftest; exit) 2>/dev/null; then + ac_cv_func_strcoll=yes +else + ac_cv_func_strcoll=no +fi +fi +rm -fr conftest* +fi +echo "$ac_t""$ac_cv_func_strcoll" 1>&6 +if test $ac_cv_func_strcoll = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_STRCOLL 1 +EOF + +fi + +trap '' 1 2 15 +if test -w $cache_file; then +echo "updating cache $cache_file" +cat > $cache_file <<\EOF +# This file is a shell script that caches the results of configure +# tests run on this system so they can be shared between configure +# scripts and configure runs. It is not useful on other systems. +# If it contains results you don't want to keep, you may remove or edit it. +# +# By default, configure uses ./config.cache as the cache file, +# creating it if it does not exist already. You can give configure +# the --cache-file=FILE option to use a different cache file; that is +# what configure does when it calls configure scripts in +# subdirectories, so they share the cache. +# Giving --cache-file=/dev/null disables caching, for debugging configure. +# config.status only pays attention to the cache file if you give it the +# --recheck option to rerun configure. +# +EOF +# Ultrix sh set writes to stderr and can't be redirected directly, +# and sets the high bit in the cache file unless we assign to the vars. +(set) 2>&1 | + sed -n "s/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=\${\1='\2'}/p" \ + >> $cache_file +else +echo "not updating unwritable cache $cache_file" +fi + +trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 + +test "x$prefix" = xNONE && prefix=$ac_default_prefix +# Let make expand exec_prefix. +test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' + +# Any assignment to VPATH causes Sun make to only execute +# the first set of double-colon rules, so remove it if not needed. +# If there is a colon in the path, we need to keep it. +if test "x$srcdir" = x.; then + ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' +fi + +trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 + +# Transform confdefs.h into DEFS. +# Protect against shell expansion while executing Makefile rules. +# Protect against Makefile macro expansion. +cat > conftest.defs <<\EOF +s%#define \([A-Za-z_][A-Za-z0-9_]*\) \(.*\)%-D\1=\2%g +s%[ `~#$^&*(){}\\|;'"<>?]%\\&%g +s%\[%\\&%g +s%\]%\\&%g +s%\$%$$%g +EOF +DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '` +rm -f conftest.defs + + +# Without the "./", some shells look in PATH for config.status. +: ${CONFIG_STATUS=./config.status} + +echo creating $CONFIG_STATUS +rm -f $CONFIG_STATUS +cat > $CONFIG_STATUS </dev/null | sed 1q`: +# +# $0 $ac_configure_args +# +# Compiler output produced by configure, useful for debugging +# configure, is in ./config.log if it exists. + +ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" +for ac_option +do + case "\$ac_option" in + -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) + echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" + exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;; + -version | --version | --versio | --versi | --vers | --ver | --ve | --v) + echo "$CONFIG_STATUS generated by autoconf version 2.1.2" + exit 0 ;; + -help | --help | --hel | --he | --h) + echo "\$ac_cs_usage"; exit 0 ;; + *) echo "\$ac_cs_usage"; exit 1 ;; + esac +done + +ac_given_srcdir=$srcdir + +trap 'rm -f Makefile; exit 1' 1 2 15 + +# Protect against being on the right side of a sed subst in config.status. +sed 's/%@/@@/; s/@%/@@/; s/%g$/@g/; /@g$/s/[\\\\&%]/\\\\&/g; + s/@@/%@/; s/@@/@%/; s/@g$/%g/' > conftest.subs <<\CEOF +$ac_vpsub +$extrasub +s%@CFLAGS@%$CFLAGS%g +s%@CPPFLAGS@%$CPPFLAGS%g +s%@CXXFLAGS@%$CXXFLAGS%g +s%@DEFS@%$DEFS%g +s%@LDFLAGS@%$LDFLAGS%g +s%@LIBS@%$LIBS%g +s%@exec_prefix@%$exec_prefix%g +s%@prefix@%$prefix%g +s%@program_transform_name@%$program_transform_name%g +s%@CC@%$CC%g +s%@AR@%$AR%g +s%@RANLIB@%$RANLIB%g +s%@CPP@%$CPP%g +s%@ALLOCA@%$ALLOCA%g + +CEOF +EOF +cat >> $CONFIG_STATUS <> $CONFIG_STATUS <<\EOF +for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then + # Support "outfile[:infile]", defaulting infile="outfile.in". + case "$ac_file" in + *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'` + ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; + *) ac_file_in="${ac_file}.in" ;; + esac + + # Adjust relative srcdir, etc. for subdirectories. + + # Remove last slash and all that follows it. Not all systems have dirname. + ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` + if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then + # The file is in a subdirectory. + test ! -d "$ac_dir" && mkdir "$ac_dir" + ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" + # A "../" for each directory in $ac_dir_suffix. + ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` + else + ac_dir_suffix= ac_dots= + fi + + case "$ac_given_srcdir" in + .) srcdir=. + if test -z "$ac_dots"; then top_srcdir=. + else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; + /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; + *) # Relative path. + srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" + top_srcdir="$ac_dots$ac_given_srcdir" ;; + esac + + echo creating "$ac_file" + rm -f "$ac_file" + configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." + case "$ac_file" in + *Makefile*) ac_comsub="1i\\ +# $configure_input" ;; + *) ac_comsub= ;; + esac + sed -e "$ac_comsub +s%@configure_input@%$configure_input%g +s%@srcdir@%$srcdir%g +s%@top_srcdir@%$top_srcdir%g +" -f conftest.subs $ac_given_srcdir/$ac_file_in > $ac_file +fi; done +rm -f conftest.subs + + + +exit 0 +EOF +chmod +x $CONFIG_STATUS +rm -fr confdefs* $ac_clean_files +test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1 + diff -ruN make-3.72.1/glob/fnmatch.c make-3.73/glob/fnmatch.c --- make-3.72.1/glob/fnmatch.c Sun Oct 9 01:20:13 1994 +++ make-3.73/glob/fnmatch.c Fri Jan 27 17:50:30 1995 @@ -35,7 +35,7 @@ #if defined (_LIBC) || !defined (__GNU_LIBRARY__) -#if !defined(__GNU_LIBRARY__) && !defined(STDC_HEADERS) +#ifndef errno extern int errno; #endif diff -ruN make-3.72.1/glob/glob.c make-3.73/glob/glob.c --- make-3.72.1/glob/glob.c Tue Sep 6 19:03:42 1994 +++ make-3.73/glob/glob.c Sun Feb 5 18:41:28 1995 @@ -1,4 +1,4 @@ -/* Copyright (C) 1991, 1992, 1993, 1994 Free Software Foundation, Inc. +/* Copyright (C) 1991, 1992, 1993, 1994, 1995 Free Software Foundation, Inc. This library is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as @@ -60,26 +60,27 @@ #define NULL 0 #endif -#if defined (POSIX) || defined (DIRENT) || defined (__GNU_LIBRARY__) + +#if defined (POSIX) || defined (HAVE_DIRENT_H) || defined (__GNU_LIBRARY__) #include #ifndef __GNU_LIBRARY__ #define D_NAMLEN(d) strlen((d)->d_name) #else /* GNU C library. */ #define D_NAMLEN(d) ((d)->d_namlen) #endif /* Not GNU C library. */ -#else /* Not POSIX or DIRENT. */ +#else /* Not POSIX or HAVE_DIRENT_H. */ #define direct dirent #define D_NAMLEN(d) ((d)->d_namlen) -#ifdef SYSNDIR +#ifdef HAVE_SYS_NDIR_H #include -#endif /* SYSNDIR */ -#ifdef SYSDIR +#endif /* HAVE_SYS_NDIR_H */ +#ifdef HAVE_SYS_DIR_H #include -#endif /* SYSDIR */ -#ifdef NDIR +#endif /* HAVE_SYS_DIR_H */ +#ifdef HAVE_NDIR_H #include -#endif /* NDIR */ -#endif /* POSIX or DIRENT or __GNU_LIBRARY__. */ +#endif /* HAVE_NDIR_H */ +#endif /* POSIX or HAVE_DIRENT_H or __GNU_LIBRARY__. */ #if defined (POSIX) && !defined (__GNU_LIBRARY__) /* Posix does not require that the d_ino field be present, and some @@ -262,10 +263,10 @@ if (filename[0] == '\0' && dirlen > 1) /* "pattern/". Expand "pattern", appending slashes. */ { - int ret = glob (dirname, flags | GLOB_MARK, errfunc, pglob); - if (ret == 0) + int val = glob (dirname, flags | GLOB_MARK, errfunc, pglob); + if (val == 0) pglob->gl_flags = (pglob->gl_flags & ~GLOB_MARK) | (flags & GLOB_MARK); - return ret; + return val; } if (!(flags & GLOB_APPEND)) @@ -446,7 +447,7 @@ prefix_array (dirname, array, n) const char *dirname; char **array; - const size_t n; + size_t n; { register size_t i; size_t dirlen = strlen (dirname); @@ -483,7 +484,7 @@ static int glob_pattern_p (pattern, quote) const char *pattern; - const int quote; + int quote; { register const char *p; int open = 0; diff -ruN make-3.72.1/install-sh make-3.73/install-sh --- make-3.72.1/install-sh Wed Dec 31 19:00:00 1969 +++ make-3.73/install-sh Wed Feb 8 10:03:05 1995 @@ -0,0 +1,238 @@ +#! /bin/sh +# +# install - install a program, script, or datafile +# This comes from X11R5. +# +# Calling this script install-sh is preferred over install.sh, to prevent +# `make' implicit rules from creating a file called install from it +# when there is no Makefile. +# +# This script is compatible with the BSD install script, but was written +# from scratch. +# + + +# set DOITPROG to echo to test this script + +# Don't use :- since 4.3BSD and earlier shells don't like it. +doit="${DOITPROG-}" + + +# put in absolute paths if you don't have them in your path; or use env. vars. + +mvprog="${MVPROG-mv}" +cpprog="${CPPROG-cp}" +chmodprog="${CHMODPROG-chmod}" +chownprog="${CHOWNPROG-chown}" +chgrpprog="${CHGRPPROG-chgrp}" +stripprog="${STRIPPROG-strip}" +rmprog="${RMPROG-rm}" +mkdirprog="${MKDIRPROG-mkdir}" + +tranformbasename="" +transform_arg="" +instcmd="$mvprog" +chmodcmd="$chmodprog 0755" +chowncmd="" +chgrpcmd="" +stripcmd="" +rmcmd="$rmprog -f" +mvcmd="$mvprog" +src="" +dst="" +dir_arg="" + +while [ x"$1" != x ]; do + case $1 in + -c) instcmd="$cpprog" + shift + continue;; + + -d) dir_arg=true + shift + continue;; + + -m) chmodcmd="$chmodprog $2" + shift + shift + continue;; + + -o) chowncmd="$chownprog $2" + shift + shift + continue;; + + -g) chgrpcmd="$chgrpprog $2" + shift + shift + continue;; + + -s) stripcmd="$stripprog" + shift + continue;; + + -t=*) transformarg=`echo $1 | sed 's/-t=//'` + shift + continue;; + + -b=*) transformbasename=`echo $1 | sed 's/-b=//'` + shift + continue;; + + *) if [ x"$src" = x ] + then + src=$1 + else + # this colon is to work around a 386BSD /bin/sh bug + : + dst=$1 + fi + shift + continue;; + esac +done + +if [ x"$src" = x ] +then + echo "install: no input file specified" + exit 1 +else + true +fi + +if [ x"$dir_arg" != x ]; then + dst=$src + src="" + + if [ -d $dst ]; then + instcmd=: + else + instcmd=mkdir + fi +else + +# Waiting for this to be detected by the "$instcmd $src $dsttmp" command +# might cause directories to be created, which would be especially bad +# if $src (and thus $dsttmp) contains '*'. + + if [ -f $src -o -d $src ] + then + true + else + echo "install: $src does not exist" + exit 1 + fi + + if [ x"$dst" = x ] + then + echo "install: no destination specified" + exit 1 + else + true + fi + +# If destination is a directory, append the input filename; if your system +# does not like double slashes in filenames, you may need to add some logic + + if [ -d $dst ] + then + dst="$dst"/`basename $src` + else + true + fi +fi + +## this sed command emulates the dirname command +dstdir=`echo $dst | sed -e 's,[^/]*$,,;s,/$,,;s,^$,.,'` + +# Make sure that the destination directory exists. +# this part is taken from Noah Friedman's mkinstalldirs script + +# Skip lots of stat calls in the usual case. +if [ ! -d "$dstdir" ]; then +defaultIFS=' +' +IFS="${IFS-${defaultIFS}}" + +oIFS="${IFS}" +# Some sh's can't handle IFS=/ for some reason. +IFS='%' +set - `echo ${dstdir} | sed -e 's@/@%@g' -e 's@^%@/@'` +IFS="${oIFS}" + +pathcomp='' + +while [ $# -ne 0 ] ; do + pathcomp="${pathcomp}${1}" + shift + + if [ ! -d "${pathcomp}" ] ; + then + $mkdirprog "${pathcomp}" + else + true + fi + + pathcomp="${pathcomp}/" +done +fi + +if [ x"$dir_arg" != x ] +then + $doit $instcmd $dst && + + if [ x"$chowncmd" != x ]; then $doit $chowncmd $dst; else true ; fi && + if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dst; else true ; fi && + if [ x"$stripcmd" != x ]; then $doit $stripcmd $dst; else true ; fi && + if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dst; else true ; fi +else + +# If we're going to rename the final executable, determine the name now. + + if [ x"$transformarg" = x ] + then + dstfile=`basename $dst` + else + dstfile=`basename $dst $transformbasename | + sed $transformarg`$transformbasename + fi + +# don't allow the sed command to completely eliminate the filename + + if [ x"$dstfile" = x ] + then + dstfile=`basename $dst` + else + true + fi + +# Make a temp file name in the proper directory. + + dsttmp=$dstdir/#inst.$$# + +# Move or copy the file name to the temp name + + $doit $instcmd $src $dsttmp && + + trap "rm -f ${dsttmp}" 0 && + +# and set any options; do chmod last to preserve setuid bits + +# If any of these fail, we abort the whole thing. If we want to +# ignore errors from any of these, just make sure not to ignore +# errors from the above "$doit $instcmd $src $dsttmp" command. + + if [ x"$chowncmd" != x ]; then $doit $chowncmd $dsttmp; else true;fi && + if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dsttmp; else true;fi && + if [ x"$stripcmd" != x ]; then $doit $stripcmd $dsttmp; else true;fi && + if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dsttmp; else true;fi && + +# Now rename the file to the real destination. + + $doit $rmcmd -f $dstdir/$dstfile && + $doit $mvcmd $dsttmp $dstdir/$dstfile + +fi && + + +exit 0 diff -ruN make-3.72.1/install.sh make-3.73/install.sh --- make-3.72.1/install.sh Tue Sep 13 00:32:22 1994 +++ make-3.73/install.sh Wed Dec 31 19:00:00 1969 @@ -1,238 +0,0 @@ -#!/bin/sh -# -# install - install a program, script, or datafile -# This comes from X11R5. -# -# Calling this script install-sh is preferred over install.sh, to prevent -# `make' implicit rules from creating a file called install from it -# when there is no Makefile. -# -# This script is compatible with the BSD install script, but was written -# from scratch. -# - - -# set DOITPROG to echo to test this script - -# Don't use :- since 4.3BSD and earlier shells don't like it. -doit="${DOITPROG-}" - - -# put in absolute paths if you don't have them in your path; or use env. vars. - -mvprog="${MVPROG-mv}" -cpprog="${CPPROG-cp}" -chmodprog="${CHMODPROG-chmod}" -chownprog="${CHOWNPROG-chown}" -chgrpprog="${CHGRPPROG-chgrp}" -stripprog="${STRIPPROG-strip}" -rmprog="${RMPROG-rm}" -mkdirprog="${MKDIRPROG-mkdir}" - -tranformbasename="" -transform_arg="" -instcmd="$mvprog" -chmodcmd="$chmodprog 0755" -chowncmd="" -chgrpcmd="" -stripcmd="" -rmcmd="$rmprog -f" -mvcmd="$mvprog" -src="" -dst="" -dir_arg="" - -while [ x"$1" != x ]; do - case $1 in - -c) instcmd="$cpprog" - shift - continue;; - - -d) dir_arg=true - shift - continue;; - - -m) chmodcmd="$chmodprog $2" - shift - shift - continue;; - - -o) chowncmd="$chownprog $2" - shift - shift - continue;; - - -g) chgrpcmd="$chgrpprog $2" - shift - shift - continue;; - - -s) stripcmd="$stripprog" - shift - continue;; - - -t=*) transformarg=`echo $1 | sed 's/-t=//'` - shift - continue;; - - -b=*) transformbasename=`echo $1 | sed 's/-b=//'` - shift - continue;; - - *) if [ x"$src" = x ] - then - src=$1 - else - # this colon is to work around a 386BSD /bin/sh bug - : - dst=$1 - fi - shift - continue;; - esac -done - -if [ x"$src" = x ] -then - echo "install: no input file specified" - exit 1 -else - true -fi - -if [ x"$dir_arg" != x ]; then - dst=$src - src="" - - if [ -d $dst ]; then - instcmd=: - else - instcmd=mkdir - fi -else - -# Waiting for this to be detected by the "$instcmd $src $dsttmp" command -# might cause directories to be created, which would be especially bad -# if $src (and thus $dsttmp) contains '*'. - - if [ -f $src -o -d $src ] - then - true - else - echo "install: $src does not exist" - exit 1 - fi - - if [ x"$dst" = x ] - then - echo "install: no destination specified" - exit 1 - else - true - fi - -# If destination is a directory, append the input filename; if your system -# does not like double slashes in filenames, you may need to add some logic - - if [ -d $dst ] - then - dst="$dst"/`basename $src` - else - true - fi -fi - -## this sed command emulates the dirname command -dstdir=`echo $dst | sed -e 's,[^/]*$,,;s,/$,,;s,^$,.,'` - -# Make sure that the destination directory exists. -# this part is taken from Noah Friedman's mkinstalldirs script - -# Skip lots of stat calls in the usual case. -if [ ! -d "$dstdir" ]; then -defaultIFS=' -' -IFS="${IFS-${defaultIFS}}" - -oIFS="${IFS}" -# Some sh's can't handle IFS=/ for some reason. -IFS='%' -set - `echo ${dstdir} | sed -e 's@/@%@g' -e 's@^%@/@'` -IFS="${oIFS}" - -pathcomp='' - -while [ $# -ne 0 ] ; do - pathcomp="${pathcomp}${1}" - shift - - if [ ! -d "${pathcomp}" ] ; - then - $mkdirprog "${pathcomp}" - else - true - fi - - pathcomp="${pathcomp}/" -done -fi - -if [ x"$dir_arg" != x ] -then - $doit $instcmd $dst && - - if [ x"$chowncmd" != x ]; then $doit $chowncmd $dst; else true ; fi && - if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dst; else true ; fi && - if [ x"$stripcmd" != x ]; then $doit $stripcmd $dst; else true ; fi && - if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dst; else true ; fi -else - -# If we're going to rename the final executable, determine the name now. - - if [ x"$transformarg" = x ] - then - dstfile=`basename $dst` - else - dstfile=`basename $dst $transformbasename | - sed $transformarg`$transformbasename - fi - -# don't allow the sed command to completely eliminate the filename - - if [ x"$dstfile" = x ] - then - dstfile=`basename $dst` - else - true - fi - -# Make a temp file name in the proper directory. - - dsttmp=$dstdir/#inst.$$# - -# Move or copy the file name to the temp name - - $doit $instcmd $src $dsttmp && - - trap "rm -f ${dsttmp}" 0 && - -# and set any options; do chmod last to preserve setuid bits - -# If any of these fail, we abort the whole thing. If we want to -# ignore errors from any of these, just make sure not to ignore -# errors from the above "$doit $instcmd $src $dsttmp" command. - - if [ x"$chowncmd" != x ]; then $doit $chowncmd $dsttmp; else true;fi && - if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dsttmp; else true;fi && - if [ x"$stripcmd" != x ]; then $doit $stripcmd $dsttmp; else true;fi && - if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dsttmp; else true;fi && - -# Now rename the file to the real destination. - - $doit $rmcmd -f $dstdir/$dstfile && - $doit $mvcmd $dsttmp $dstdir/$dstfile - -fi && - - -exit 0 diff -ruN make-3.72.1/job.c make-3.73/job.c --- make-3.72.1/job.c Tue Nov 1 03:34:10 1994 +++ make-3.73/job.c Fri Mar 24 00:31:37 1995 @@ -1,5 +1,5 @@ /* Job execution and handling for GNU Make. -Copyright (C) 1988, 89, 90, 91, 92, 93, 94 Free Software Foundation, Inc. +Copyright (C) 1988, 89, 90, 91, 92, 93, 94, 1995 Free Software Foundation, Inc. This file is part of GNU Make. GNU Make is free software; you can redistribute it and/or modify @@ -23,9 +23,6 @@ #include "variable.h" #include -/* Default path to search for executables. */ -static char default_path[] = ":/bin:/usr/bin"; - /* Default shell to use. */ char default_shell[] = "/bin/sh"; @@ -125,6 +122,9 @@ #ifdef HAVE_GETDTABLESIZE extern int getdtablesize (); #else +#ifdef HAVE_SYSCONF_OPEN_MAX +#define getdtablesize() ((int) sysconf (_SC_OPEN_MAX)) +#else #include #define getdtablesize() NOFILE #if !defined (NOFILE) && defined (NOFILES_MAX) @@ -133,6 +133,7 @@ #endif #endif #endif +#endif extern int getloadavg (); extern int start_remote_job_p (); @@ -173,14 +174,9 @@ "*** [%s] Error %d", target_name, exit_code); else - { - char *coredump_string = coredump ? " (core dumped)" : ""; - if (exit_sig > 0 && exit_sig < NSIG) - error ("*** [%s] %s%s", - target_name, sys_siglist[exit_sig], coredump_string); - else - error ("*** [%s] Signal %d%s", target_name, exit_sig, coredump_string); - } + error ("*** [%s] %s%s", + target_name, strsignal (exit_sig), + coredump ? " (core dumped)" : ""); } static unsigned int dead_children = 0; @@ -381,7 +377,7 @@ delete non-precious targets, and abort. */ static int delete_on_error = -1; child_error (c->file->name, exit_code, exit_sig, coredump, 0); - c->file->update_status = 1; + c->file->update_status = 2; if (delete_on_error == -1) { struct file *f = lookup_file (".DELETE_ON_ERROR"); @@ -409,7 +405,7 @@ Since there are more commands that wanted to be run, the target was not completely remade. So we treat this as if a command had failed. */ - c->file->update_status = 1; + c->file->update_status = 2; } else { @@ -437,7 +433,7 @@ } /* When we get here, all the commands for C->file are finished - (or aborted) and C->file->update_status contains 0 or 1. But + (or aborted) and C->file->update_status contains 0 or 2. But C->file->command_state is still cs_running if all the commands ran; notice_finish_file looks for cs_running to tell it that it's interesting to check the file's modtime again now. */ @@ -591,6 +587,7 @@ if (argv == 0) { + next_command: /* This line has no commands. Go to the next. */ if (job_next_command (child)) start_job_command (child); @@ -623,10 +620,7 @@ { free (argv[0]); free ((char *) argv); - if (job_next_command (child)) - start_job_command (child); - child->file->update_status = 0; - return; + goto next_command; } /* Flush the output streams so they won't have things written twice. */ @@ -689,6 +683,8 @@ { /* Fork the child process. */ + char **parent_environ; + #ifdef POSIX (void) sigprocmask (SIG_BLOCK, &fatal_signal_set, (sigset_t *) 0); #else @@ -698,7 +694,9 @@ #endif child->remote = 0; + parent_environ = environ; child->pid = vfork (); + environ = parent_environ; /* Restore value child may have clobbered. */ if (child->pid == 0) { /* We are the child side. */ @@ -768,7 +766,7 @@ { /* Put this child on the chain of children waiting for the load average to go down. */ - c->file->command_state = cs_running; + set_command_state (c->file, cs_running); c->next = waiting_jobs; waiting_jobs = c; return 0; @@ -1073,105 +1071,6 @@ exec_command (argv, envp); } -/* Search PATH for FILE. - If successful, store the full pathname in PROGRAM and return 1. - If not sucessful, return zero. */ - -static int -search_path (file, path, program) - char *file, *path, *program; -{ - if (path == 0 || path[0] == '\0') - path = default_path; - - if ( -#ifdef __MSDOS__ - strpbrk (file, "/\\:") -#else - index (file, '/') -#endif - != 0) - { - strcpy (program, file); - return 1; - } - else - { - unsigned int len; - -#ifdef HAVE_GETGROUPS -#ifndef HAVE_UNISTD_H - extern int getgroups (); -#endif - static int ngroups = -1; -#ifdef NGROUPS_MAX - static GETGROUPS_T groups[NGROUPS_MAX]; -#define ngroups_max NGROUPS_MAX -#else - static GETGROUPS_T *groups = 0; - static int ngroups_max; - if (groups == 0) - { - ngroups_max = GET_NGROUPS_MAX; - groups = (GETGROUPS_T *) malloc (ngroups_max * sizeof (GETGROUPS_T)); - } -#endif - if (groups != 0 && ngroups == -1) - ngroups = getgroups (ngroups_max, groups); -#endif /* Have getgroups. */ - - len = strlen (file) + 1; - do - { - struct stat st; - int perm; - char *p; - - p = index (path, PATH_SEPARATOR_CHAR); - if (p == 0) - p = path + strlen (path); - - if (p == path) - bcopy (file, program, len); - else - { - bcopy (path, program, p - path); - program[p - path] = '/'; - bcopy (file, program + (p - path) + 1, len); - } - - if (safe_stat (program, &st) == 0 - && S_ISREG (st.st_mode)) - { - if (st.st_uid == geteuid ()) - perm = (st.st_mode & 0100); - else if (st.st_gid == getegid ()) - perm = (st.st_mode & 0010); - else - { -#ifdef HAVE_GETGROUPS - register int i; - for (i = 0; i < ngroups; ++i) - if (groups[i] == st.st_gid) - break; - if (i < ngroups) - perm = (st.st_mode & 0010); - else -#endif /* Have getgroups. */ - perm = (st.st_mode & 0001); - } - - if (perm != 0) - return 1; - } - - path = p + 1; - } while (*path != '\0'); - } - - return 0; -} - /* Replace the current process with one running the command in ARGV, with environment ENVP. This function does not return. */ @@ -1179,82 +1078,65 @@ exec_command (argv, envp) char **argv, **envp; { - char *shell, *path; - PATH_VAR (program); - register char **ep; - - shell = path = 0; - for (ep = envp; *ep != 0; ++ep) - { - if (shell == 0 && !strncmp(*ep, "SHELL=", 6)) - shell = &(*ep)[6]; - else if (path == 0 && !strncmp(*ep, "PATH=", 5)) - path = &(*ep)[5]; - else if (path != 0 && shell != 0) - break; - } - /* Be the user, permanently. */ child_access (); - if (!search_path (argv[0], path, program)) - error ("%s: Command not found", argv[0]); - else + /* Run the program. */ + environ = envp; + execvp (argv[0], argv); + + switch (errno) { - /* Run the program. */ - execve (program, argv, envp); - - if (errno == ENOEXEC) - { - PATH_VAR (shell_program); - char *shell_path; - if (shell == 0) - shell_path = default_shell; - else - { - if (search_path (shell, path, shell_program)) - shell_path = shell_program; - else - { - shell_path = 0; - error ("%s: Shell program not found", shell); - } - } - - if (shell_path != 0) - { - char **new_argv; - int argc; + case ENOENT: + error ("%s: Command not found", argv[0]); + break; + case ENOEXEC: + { + /* The file is not executable. Try it as a shell script. */ + extern char *getenv (); + char *shell; + char **new_argv; + int argc; + + shell = getenv ("SHELL"); + if (shell == 0) + shell = default_shell; + + argc = 1; + while (argv[argc] != 0) + ++argc; + + new_argv = (char **) alloca ((1 + argc + 1) * sizeof (char *)); + new_argv[0] = shell; + new_argv[1] = program; + while (argc > 0) + { + new_argv[1 + argc] = argv[argc]; + --argc; + } - argc = 1; - while (argv[argc] != 0) - ++argc; - - new_argv = (char **) alloca ((1 + argc + 1) * sizeof (char *)); - new_argv[0] = shell_path; - new_argv[1] = program; - while (argc > 0) - { - new_argv[1 + argc] = argv[argc]; - --argc; - } + execvp (shell, new_argv); + if (errno == ENOENT) + error ("%s: Shell program not found", shell); + else + perror_with_name ("execvp: ", shell); + break; + } - execve (shell_path, new_argv, envp); - perror_with_name ("execve: ", shell_path); - } - } - else - perror_with_name ("execve: ", program); + default: + perror_with_name ("execvp: ", argv[0]); + break; } _exit (127); } -/* Figure out the argument list necessary to run LINE as a command. - Try to avoid using a shell. This routine handles only ' quoting. - Starting quotes may be escaped with a backslash. If any of the - characters in sh_chars[] is seen, or any of the builtin commands - listed in sh_cmds[] is the first word of a line, the shell is used. +/* Figure out the argument list necessary to run LINE as a command. Try to + avoid using a shell. This routine handles only ' quoting, and " quoting + when no backslash, $ or ` characters are seen in the quotes. Starting + quotes may be escaped with a backslash. If any of the characters in + sh_chars[] is seen, or any of the builtin commands listed in sh_cmds[] + is the first word of a line, the shell is used. If RESTP is not NULL, *RESTP is set to point to the first newline in LINE. If *RESTP is NULL, newlines will be ignored. @@ -1332,7 +1214,7 @@ string_char: /* Inside a string, just copy any char except a closing quote or a backslash-newline combination. */ - if (*p == '\'') + if (*p == instring) instring = 0; else if (*p == '\\' && p[1] == '\n') goto swallow_escaped_newline; @@ -1342,6 +1224,10 @@ *restp = p; goto end_of_line; } + /* Backslash, $, and ` are special inside double quotes. + If we see any of those, punt. */ + else if (instring == '"' && index ("\\$`", *p) != 0) + goto slow; else *ap++ = *p; } @@ -1399,7 +1285,8 @@ break; case '\'': - instring = 1; + case '"': + instring = *p; break; case '\n': @@ -1505,7 +1392,7 @@ strcat (dos_bname, ".bat"); strcat (dos_bename, ".err"); } - batch = fopen(bename, "w"); /* Create a file. */ + batch = fopen (dos_bename, "w"); /* Create a file. */ if (batch != NULL) fclose (batch); batch = fopen (dos_bname, "w"); @@ -1514,7 +1401,7 @@ fprintf (batch, "\nif errorlevel 1 del %s\n", dos_bename); fclose (batch); new_argv = (char **) xmalloc(2 * sizeof(char *)); - new_argv[0] = strdup (bname); + new_argv[0] = strdup (dos_bname); new_argv[1] = 0; } #else /* Not MSDOS. */ @@ -1564,7 +1451,7 @@ continue; } - if (*p == '\\' || *p == '\'' + if (*p == '\\' || *p == '\'' || *p == '"' || isspace (*p) || index (sh_chars, *p) != 0) *ap++ = '\\'; @@ -1580,11 +1467,12 @@ return new_argv; } -/* Figure out the argument list necessary to run LINE as a command. - Try to avoid using a shell. This routine handles only ' quoting. - Starting quotes may be escaped with a backslash. If any of the - characters in sh_chars[] is seen, or any of the builtin commands - listed in sh_cmds[] is the first word of a line, the shell is used. +/* Figure out the argument list necessary to run LINE as a command. Try to + avoid using a shell. This routine handles only ' quoting, and " quoting + when no backslash, $ or ` characters are seen in the quotes. Starting + quotes may be escaped with a backslash. If any of the characters in + sh_chars[] is seen, or any of the builtin commands listed in sh_cmds[] + is the first word of a line, the shell is used. If RESTP is not NULL, *RESTP is set to point to the first newline in LINE. If *RESTP is NULL, newlines will be ignored. diff -ruN make-3.72.1/main.c make-3.73/main.c --- make-3.72.1/main.c Sun Nov 6 18:29:21 1994 +++ make-3.73/main.c Tue Mar 28 13:59:07 1995 @@ -1,5 +1,5 @@ /* Argument parsing and main program of GNU Make. -Copyright (C) 1988, 89, 90, 91, 94 Free Software Foundation, Inc. +Copyright (C) 1988, 89, 90, 91, 94, 1995 Free Software Foundation, Inc. This file is part of GNU Make. GNU Make is free software; you can redistribute it and/or modify @@ -23,6 +23,7 @@ #include "variable.h" #include "job.h" #include "getopt.h" +#include extern void print_variable_data_base (); @@ -397,6 +398,15 @@ return enter_file (savestring (name, strlen (name))); } +/* Toggle -d on receipt of SIGUSR1. */ + +static RETSIGTYPE +debug_signal_handler (sig) + int sig; +{ + debug_flag = ! debug_flag; +} + int main (argc, argv, envp) int argc; @@ -415,7 +425,7 @@ reading_filename = 0; reading_lineno_ptr = 0; -#ifndef HAVE_SYS_SIGLIST +#if !defined (HAVE_STRSIGNAL) && !defined (HAVE_SYS_SIGLIST) signame_init (); #endif @@ -589,7 +599,7 @@ } /* Now allocate a buffer big enough and fill it. */ - p = value = alloca (len); + p = value = (char *) alloca (len); for (cv = command_variables; cv != 0; cv = cv->next) { v = cv->variable; @@ -691,11 +701,16 @@ /* This makefile is standard input. Since we may re-exec and thus re-read the makefiles, we read standard input into a temporary file and read from that. */ - static char name[] = "/tmp/GmXXXXXX"; FILE *outfile; /* Make a unique filename. */ +#ifdef HAVE_MKTEMP + static char name[] = "/tmp/GmXXXXXX"; (void) mktemp (name); +#else + static char name[L_tmpnam]; + (void) tmpnam (name); +#endif outfile = fopen (name, "w"); if (outfile == 0) @@ -744,6 +759,11 @@ (void) signal (SIGCLD, child_handler); #endif + /* Let the user send us SIGUSR1 to toggle the -d flag during the run. */ +#ifdef SIGUSR1 + (void) signal (SIGUSR1, debug_signal_handler); +#endif + /* Define the initial list of suffixes for old-style rules. */ set_default_suffixes (); @@ -904,14 +924,17 @@ switch (update_goal_chain (read_makefiles, 1)) { + case 1: default: - abort (); +#define BOGUS_UPDATE_STATUS 0 + assert (BOGUS_UPDATE_STATUS); + break; case -1: /* Did nothing. */ break; - case 1: + case 2: /* Failed to update. Figure out if we care. */ { /* Nonzero if any makefile was successfully remade. */ @@ -1179,6 +1202,51 @@ long_options[i].name = 0; } +static void +handle_non_switch_argument (arg, env) + char *arg; + int env; +{ + /* Non-option argument. It might be a variable definition. */ + struct variable *v; + if (arg[0] == '-' && arg[1] == '\0') + /* Ignore plain `-' for compatibility. */ + return; + v = try_variable_definition ((char *) 0, 0, arg, o_command); + if (v != 0) + { + /* It is indeed a variable definition. Record a pointer to + the variable for later use in define_makeflags. */ + struct command_variable *cv + = (struct command_variable *) xmalloc (sizeof (*cv)); + cv->variable = v; + cv->next = command_variables; + command_variables = cv; + } + else if (! env) + { + /* Not an option or variable definition; it must be a goal + target! Enter it as a file and add it to the dep chain of + goals. */ + struct file *f = enter_command_line_file (arg); + f->cmd_target = 1; + + if (goals == 0) + { + goals = (struct dep *) xmalloc (sizeof (struct dep)); + lastgoal = goals; + } + else + { + lastgoal->next + = (struct dep *) xmalloc (sizeof (struct dep)); + lastgoal = lastgoal->next; + } + lastgoal->name = 0; + lastgoal->file = f; + } +} + /* Decode switches from ARGC and ARGV. They came from the environment if ENV is nonzero. */ @@ -1204,64 +1272,16 @@ /* Reset getopt's state. */ optind = 0; - c = 0; while (optind < argc) { + /* Parse the next argument. */ + c = getopt_long (argc, argv, options, long_options, (int *) 0); if (c == EOF) - { - /* There are no more options according to getting getopt, but - there are some arguments left. Since we have asked for - non-option arguments to be returned in order, I think this - only happens when there is a "--" argument to prevent later - argument from being options. Since getopt has finished its - job, just update its state variables for the next argument and - set C as if it had returned 1, indicating a non-option - argument. */ - optarg = argv[optind++]; - c = 1; - } - else - /* Parse the next argument. */ - c = getopt_long (argc, argv, options, long_options, (int *) 0); - - if (c == 1) - { - /* Non-option argument. It might be a variable definition. */ - struct variable *v; - v = try_variable_definition ((char *) 0, 0, optarg, o_command); - if (v != 0) - { - /* It is indeed a variable definition. Record a pointer to - the variable for later use in define_makeflags. */ - struct command_variable *cv - = (struct command_variable *) xmalloc (sizeof (*cv)); - cv->variable = v; - cv->next = command_variables; - command_variables = cv; - } - else if (! env) - { - /* Not an option or variable definition; it must be a goal - target! Enter it as a file and add it to the dep chain of - goals. */ - struct file *f = enter_command_line_file (optarg); - f->cmd_target = 1; - - if (goals == 0) - { - goals = (struct dep *) xmalloc (sizeof (struct dep)); - lastgoal = goals; - } - else - { - lastgoal->next - = (struct dep *) xmalloc (sizeof (struct dep)); - lastgoal = lastgoal->next; - } - lastgoal->name = 0; - lastgoal->file = f; - } - } + /* End of arguments, or "--" marker seen. */ + break; + else if (c == 1) + /* An argument not starting with a dash. */ + handle_non_switch_argument (optarg, env); else if (c == '?') /* Bad option. We will print a usage message and die later. But continue to parse the other options so the user can @@ -1364,16 +1384,27 @@ } } + /* There are no more options according to getting getopt, but there may + be some arguments left. Since we have asked for non-option arguments + to be returned in order, this only happens when there is a "--" + argument to prevent later arguments from being options. */ + while (optind < argc) + handle_non_switch_argument (argv[optind++], env); + + if (!env && (bad || print_usage_flag)) { /* Print a nice usage message. */ + FILE *usageto; if (print_version_flag) print_version (); - fprintf (stderr, "Usage: %s [options] [target] ...\n", program); + usageto = bad ? stderr : stdout; - fputs ("Options:\n", stderr); + fprintf (usageto, "Usage: %s [options] [target] ...\n", program); + + fputs ("Options:\n", usageto); for (cs = switches; cs->c != '\0'; ++cs) { char buf[1024], shortarg[50], longarg[50], *p; @@ -1444,11 +1475,11 @@ line with the description, leaving at least two spaces. Print it on its own line instead. */ { - fprintf (stderr, "%s\n", buf); + fprintf (usageto, "%s\n", buf); buf[0] = '\0'; } - fprintf (stderr, "%*s%s.\n", + fprintf (usageto, "%*s%s.\n", - DESCRIPTION_COLUMN, buf, cs->description); } @@ -1782,7 +1813,10 @@ } } else if (p == &flagstring[1]) - --p; + { + words = 0; + --p; + } else if (p[-1] == '-') /* Kill the final space and dash. */ p -= 2; @@ -1831,7 +1865,7 @@ printf ("-%s", remote_description); printf (", by Richard Stallman and Roland McGrath.\n\ -%sCopyright (C) 1988, 89, 90, 91, 92, 93, 94 Free Software Foundation, Inc.\n\ +%sCopyright (C) 1988, 89, 90, 91, 92, 93, 94, 95 Free Software Foundation, Inc.\n\ %sThis is free software; see the source for copying conditions.\n\ %sThere is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A\n\ %sPARTICULAR PURPOSE.\n\n", precede, precede, precede, precede); diff -ruN make-3.72.1/make-stds.texi make-3.73/make-stds.texi --- make-3.72.1/make-stds.texi Sun Aug 21 13:29:57 1994 +++ make-3.73/make-stds.texi Tue Feb 7 18:45:48 1995 @@ -163,6 +163,11 @@ simple test to verify that a program is properly installed, this target should run that test. +If possible, write the @code{install} target rule so that it does not +modify anything in the directory where the program was built, provided +@samp{make all} has just been done. This is convenient for building the +program under one user name and installing it under another. + The commands should create all the directories in which files are to be installed, if they don't already exist. This includes the directories specified as the values of the variables @code{prefix} and @@ -205,6 +210,9 @@ create (but not the noninstalled files such as @samp{make all} would create). +This rule should not modify the directories where compilation is done, +only the directories where files are installed. + @comment The gratuitous blank line here is to make the table look better @comment in the printed Make manual. Please leave it in. @item clean @@ -228,17 +236,34 @@ target for GCC does not delete @file{libgcc.a}, because recompiling it is rarely necessary and takes a lot of time. -@item realclean -Delete everything from the current directory that can be reconstructed -with this Makefile. This typically includes everything deleted by -@code{distclean}, plus more: C source files produced by Bison, tags tables, -Info files, and so on. - -One exception, however: @samp{make realclean} should not delete -@file{configure} even if @file{configure} can be remade using a rule in -the Makefile. More generally, @samp{make realclean} should not delete -anything that needs to exist in order to run @file{configure} -and then begin to build the program. +@item maintainer-clean +Delete almost everything from the current directory that can be +reconstructed with this Makefile. This typically includes everything +deleted by @code{distclean}, plus more: C source files produced by +Bison, tags tables, Info files, and so on. + +The reason we say ``almost everything'' is that @samp{make +maintainer-clean} should not delete @file{configure} even if +@file{configure} can be remade using a rule in the Makefile. More +generally, @samp{make maintainer-clean} should not delete anything that +needs to exist in order to run @file{configure} and then begin to build +the program. This is the only exception; @code{maintainer-clean} should +delete everything else that can be rebuilt. + +The @samp{maintainer-clean} is intended to be used by a maintainer of +the package, not by ordinary users. You may need special tools to +reconstruct some of the files that @samp{make maintainer-clean} deletes. +Since these files are normally included in the distribution, we don't +take care to make them easy to reconstruct. If you find you need to +unpack the full distribution again, don't blame us. + +To help make users aware of this, the commands for +@code{maintainer-clean} should start with these two: + +@example +@@echo "This command is intended for maintainers to use;" +@@echo "it deletes files that may require special tools to rebuild." +@end example @item TAGS Update a tags table for this program. @@ -327,6 +352,9 @@ $(libdir) $(infodir) \ $(mandir) @end smallexample + +This rule should not modify the directories where compilation is done. +It should do nothing but create installation directories. @end table @node Command Variables @@ -401,7 +429,9 @@ Installation directories should always be named by variables, so it is easy to install in a nonstandard place. The standard names for these -variables are as follows. +variables are described below. They are based on a standard filesystem +layout; variants of it are used in SVR4, 4.4BSD, Linux, Ultrix v4, and +other modern operating systems. These two variables set the root for the installation. All the other installation directories should be subdirectories of one of these two, @@ -411,7 +441,8 @@ @item prefix A prefix used in constructing the default values of the variables listed below. The default value of @code{prefix} should be @file{/usr/local} -(at least for now). +When building the complete GNU system, the prefix will be empty and +@file{/usr} will be a symbolic link to @file{/}. @item exec_prefix A prefix used in constructing the default values of some of the diff -ruN make-3.72.1/make.h make-3.73/make.h --- make-3.72.1/make.h Mon Oct 24 19:11:57 1994 +++ make-3.73/make.h Tue Feb 7 13:36:00 1995 @@ -1,5 +1,5 @@ /* Miscellaneous global declarations and portability cruft for GNU Make. -Copyright (C) 1988, 89, 90, 91, 92, 93, 94 Free Software Foundation, Inc. +Copyright (C) 1988, 89, 90, 91, 92, 93, 94, 95 Free Software Foundation, Inc. This file is part of GNU Make. GNU Make is free software; you can redistribute it and/or modify @@ -173,7 +173,6 @@ extern char *malloc (), *realloc (); extern void free (); -extern void qsort (); extern void abort (), exit (); #endif /* Standard headers. */ diff -ruN make-3.72.1/make.texinfo make-3.73/make.texinfo --- make-3.72.1/make.texinfo Fri Nov 4 15:23:23 1994 +++ make-3.73/make.texinfo Tue Apr 4 23:32:21 1995 @@ -7,11 +7,12 @@ @c FSF publishers: format makebook.texi instead of using this file directly. -@set RCSID $Id: make.texinfo,v 2.149 1994/11/04 20:23:23 roland Beta $ -@set EDITION 0.47 -@set VERSION 3.72 Beta -@set UPDATED 1 November 1994 -@set UPDATE-MONTH November 1994 +@set RCSID $Id: make.texinfo,v 2.152 1995/04/05 03:32:21 roland Exp $ +@set EDITION 0.48 +@set VERSION 3.73 Beta +@set UPDATED 4 April 1995 +@set UPDATE-MONTH April 1995 +@comment The ISBN number might need to change on next publication. @set ISBN 1-882114-50-7 @c finalout @@ -31,7 +32,8 @@ This is Edition @value{EDITION}, last updated @value{UPDATED}, of @cite{The GNU Make Manual}, for @code{make}, Version @value{VERSION}. -Copyright (C) 1988, '89, '90, '91, '92, '93, '94 Free Software Foundation, Inc. +Copyright (C) 1988, '89, '90, '91, '92, '93, '94, '95 + Free Software Foundation, Inc. Permission is granted to make and distribute verbatim copies of this manual provided the copyright notice and this permission notice @@ -66,7 +68,7 @@ @author Richard M. Stallman and Roland McGrath @page @vskip 0pt plus 1filll -Copyright @copyright{} 1988, '89, '90, '91, '92, '93, '94 Free Software Foundation, Inc. +Copyright @copyright{} 1988, '89, '90, '91, '92, '93, '94, '95 Free Software Foundation, Inc. @sp 2 Published by the Free Software Foundation @* 675 Massachusetts Avenue, @* @@ -3294,23 +3296,20 @@ @cindex @code{-C}, and recursion @cindex @code{-f}, and recursion -@cindex @code{-I}, and recursion @cindex @code{-o}, and recursion @cindex @code{-W}, and recursion @cindex @code{--directory}, and recursion @cindex @code{--file}, and recursion -@cindex @code{--include-dir}, and recursion @cindex @code{--old-file}, and recursion @cindex @code{--assume-old}, and recursion @cindex @code{--assume-new}, and recursion @cindex @code{--new-file}, and recursion @cindex recursion, and @code{-C} @cindex recursion, and @code{-f} -@cindex recursion, and @code{-I} @cindex recursion, and @code{-o} @cindex recursion, and @code{-W} -The options @samp{-C}, @samp{-f}, @samp{-I}, @samp{-o}, and @samp{-W} -are not put into @code{MAKEFLAGS}; these options are not passed down.@refill +The options @samp{-C}, @samp{-f}, @samp{-o}, and @samp{-W} are not put +into @code{MAKEFLAGS}; these options are not passed down.@refill @cindex @code{-j}, and recursion @cindex @code{--jobs}, and recursion @@ -5400,12 +5399,12 @@ are probably not what you intended. For example, @smallexample -files := $(foreach Es escrito en espanol!,b c ch,$(find_files)) +files := $(foreach Esta escrito en espanol!,b c ch,$(find_files)) @end smallexample @noindent might be useful if the value of @code{find_files} references the variable -whose name is @samp{Es escrito en espanol!} (es un nombre bastante largo, +whose name is @samp{Esta escrito en espanol!} (es un nombre bastante largo, no?), but it is more likely to be a mistake. @node Origin Function, Shell Function, Foreach Function, Functions diff -ruN make-3.72.1/misc.c make-3.73/misc.c --- make-3.72.1/misc.c Mon Jul 4 17:46:58 1994 +++ make-3.73/misc.c Fri Mar 10 15:24:19 1995 @@ -1,5 +1,5 @@ /* Miscellaneous generic support functions for GNU Make. -Copyright (C) 1988, 89, 90, 91, 92, 93, 94 Free Software Foundation, Inc. +Copyright (C) 1988, 89, 90, 91, 92, 93, 94, 1995 Free Software Foundation, Inc. This file is part of GNU Make. GNU Make is free software; you can redistribute it and/or modify @@ -126,7 +126,7 @@ { char *comment; - comment = find_char_unquote (line, '#', 0); + comment = find_char_unquote (line, "#", 0); if (comment != 0) /* Cut off the line at the #. */ @@ -260,7 +260,7 @@ if (errno < sys_nerr) return sys_errlist[errnum]; - sprintf ("Unknown error %d", buf, errnum); + sprintf (buf, "Unknown error %d", errnum); return buf; } #endif diff -ruN make-3.72.1/mkinstalldirs make-3.73/mkinstalldirs --- make-3.72.1/mkinstalldirs Fri Mar 25 23:01:14 1994 +++ make-3.73/mkinstalldirs Wed Feb 8 09:59:55 1995 @@ -1,4 +1,4 @@ -#!/bin/sh +#! /bin/sh # mkinstalldirs --- make directory hierarchy # Author: Noah Friedman # Created: 1993-05-16 diff -ruN make-3.72.1/read.c make-3.73/read.c --- make-3.72.1/read.c Mon Jul 25 18:07:41 1994 +++ make-3.73/read.c Mon Mar 13 00:38:52 1995 @@ -1,5 +1,5 @@ /* Reading and parsing of makefiles for GNU Make. -Copyright (C) 1988, 89, 90, 91, 92, 93, 94 Free Software Foundation, Inc. +Copyright (C) 1988, 89, 90, 91, 92, 93, 94, 1995 Free Software Foundation, Inc. This file is part of GNU Make. GNU Make is free software; you can redistribute it and/or modify @@ -631,7 +631,7 @@ ; else if (lb.buffer[0] == '\t') { - p = lb.buffer; + p = collapsed; /* Ignore comments. */ while (isblank (*p)) ++p; if (*p == '\0') @@ -723,6 +723,11 @@ else break; } +#ifdef __MSDOS__ + /* For MS-DOS, skip a "C:\...". */ + if (p != 0 && p[1] == '\\' && isalpha (p[-1])) + p = 0; +#endif if (p != 0) { struct nameseq *target; @@ -1432,9 +1437,9 @@ one, or nil if there are none. */ char * -find_char_unquote (string, stopchar, blank) +find_char_unquote (string, stopchars, blank) char *string; - int stopchar; + char *stopchars; int blank; { unsigned int string_len = strlen (string); @@ -1442,19 +1447,12 @@ while (1) { - if (blank) - { - while (*p != '\0' && *p != stopchar && !isblank (*p)) - ++p; - if (*p == '\0') - break; - } - else - { - p = index (p, stopchar); - if (p == 0) - break; - } + while (*p != '\0' && index (stopchars, *p) == 0 + && (!blank || !isblank (*p))) + ++p; + if (*p == '\0') + break; + if (p > string && p[-1] == '\\') { /* Search for more backslashes. */ @@ -1488,7 +1486,7 @@ find_percent (pattern) char *pattern; { - return find_char_unquote (pattern, '%', 0); + return find_char_unquote (pattern, "%", 0); } /* Search STRING for an unquoted ; that is not after an unquoted #. */ @@ -1497,8 +1495,11 @@ find_semicolon (string) char *string; { - return (find_char_unquote (string, '#', 0) == 0 - ? find_char_unquote (string, ';', 0) : 0); + char *match = find_char_unquote (string, ";#", 0); + if (match != 0 && *match == '#') + /* We found a comment before a semicolon. No match. */ + match = 0; + return match; } /* Parse a string into a sequence of filenames represented as a @@ -1526,6 +1527,9 @@ register char *p = *stringp; char *q; char *name; + char stopchars[2]; + stopchars[0] = stopchar; + stopchars[1] = '\0'; while (1) { @@ -1537,7 +1541,12 @@ break; /* Yes, find end of next name. */ q = p; - p = find_char_unquote (q, stopchar, 1); + p = find_char_unquote (q, stopchars, 1); +#ifdef __MSDOS__ + /* For MS-DOS, skip a "C:\...". */ + if (stopchar == ':' && p != 0 && p[1] == '\\' && isalpha (p[-1])) + p = 0; +#endif if (p == 0) p = q + strlen (q); @@ -1573,7 +1582,9 @@ an elt further down the chain (i.e., previous in the file list) with an unmatched `(' (e.g., "lib(mem"). */ - for (new1 = new, lastnew1 = 0; new1 != 0; lastnew1 = new1, new1 = new1->next) + new1 = new; + lastnew1 = 0; + while (new1 != 0) if (new1->name[0] != '(' /* Don't catch "(%)" and suchlike. */ && new1->name[strlen (new1->name) - 1] == ')' && index (new1->name, '(') == 0) @@ -1654,14 +1665,21 @@ name = concat (libname, new1->name, ")"); free (new1->name); new1->name = name; + lastnew1 = new1; new1 = new1->next; } - - if (new1 == 0) - /* We might have slurped up the whole list, - and continuing the loop would dereference NEW1. */ - break; } + else + { + /* No frobnication happening. Just step down the list. */ + lastnew1 = new1; + new1 = new1->next; + } + } + else + { + lastnew1 = new1; + new1 = new1->next; } #endif diff -ruN make-3.72.1/remake.c make-3.73/remake.c --- make-3.72.1/remake.c Sat Sep 10 11:04:57 1994 +++ make-3.73/remake.c Fri Mar 24 00:39:48 1995 @@ -1,5 +1,5 @@ /* Basic dependency engine for GNU Make. -Copyright (C) 1988, 89, 90, 91, 92, 93, 94 Free Software Foundation, Inc. +Copyright (C) 1988, 89, 90, 91, 92, 93, 94, 1995 Free Software Foundation, Inc. This file is part of GNU Make. GNU Make is free software; you can redistribute it and/or modify @@ -491,7 +491,16 @@ return dep_status; } - set_command_state (file, cs_not_started); + if (file->command_state == cs_deps_running) + /* The commands for some deps were running on the last iteration, but + they have finished now. Reset the command_state to not_started to + simplify later bookkeeping. It is important that we do this only + when the prior state was cs_deps_running, because that prior state + was definitely propagated to FILE's also_make's by set_command_state + (called above), but in another state an also_make may have + independently changed to finished state, and we would confuse that + file's bookkeeping (updated, but not_started is bogus state). */ + set_command_state (file, cs_not_started); /* Now record which dependencies are more recent than this file, so we can define $?. */ @@ -547,7 +556,6 @@ if (!must_make) { DEBUGPR ("No need to remake target `%s'.\n"); - file->update_status = 0; notice_finished_file (file); return 0; } @@ -565,14 +573,17 @@ switch (file->update_status) { - case 1: + case 2: DEBUGPR ("Failed to remake target file `%s'.\n"); break; case 0: DEBUGPR ("Successfully remade target file `%s'.\n"); break; + case 1: + DEBUGPR ("Target file `%s' needs remade under -q.\n"); + break; default: - assert (file->update_status == 0 || file->update_status == 1); + assert (file->update_status >= 0 && file->update_status <= 2); break; } @@ -596,12 +607,12 @@ if (touch_flag /* The update status will be: - -1 if no commands were run; - 0 if some commands (+ or ${MAKE}) were run and won; + -1 if this target was not remade; + 0 if 0 or more commands (+ or ${MAKE}) were run and won; 1 if some commands were run and lost. - The only time we don't want to touch the target is if - it had some recursive commands, and they lost. */ - && file->update_status != 1) + We touch the target if it has commands which either were not run + or won when they ran (i.e. status is 0). */ + && file->update_status == 0) { if (file->cmds != 0 && file->cmds->any_recurse) { @@ -639,7 +650,7 @@ f->last_mtime = file->last_mtime; } - if (file->update_status != -1) + if (ran && file->update_status != -1) /* We actually tried to update FILE, which has updated its also_make's as well (if it worked). If it didn't work, it wouldn't work again for them. @@ -825,15 +836,29 @@ else { /* This is a dependency file we cannot remake. Fail. */ - static char noway[] = "No rule to make target"; + static const char msg_noparent[] + = "%sNo rule to make target `%s'%s"; + static const char msg_parent[] + = "%sNo rule to make target `%s', needed by `%s'%s"; if (keep_going_flag || file->dontcare) { if (!file->dontcare) - error ("*** %s `%s'.", noway, file->name); - file->update_status = 1; + { + if (file->parent == 0) + error (msg_noparent, "*** ", file->name, "."); + else + error (msg_parent, "*** ", + file->name, file->parent->name, "."); + } + file->update_status = 2; } else - fatal ("%s `%s'", noway, file->name); + { + if (file->parent == 0) + fatal (msg_noparent, "", file->name, ""); + else + fatal (msg_parent, "", file->name, file->parent->name, ""); + } } } else @@ -845,6 +870,9 @@ execute_file_commands (file); return; } + else + /* This tells notice_finished_file it is ok to touch the file. */ + file->update_status = 0; } /* This does the touching under -t. */ diff -ruN make-3.72.1/signame.c make-3.73/signame.c --- make-3.72.1/signame.c Mon Sep 26 17:57:40 1994 +++ make-3.73/signame.c Fri Mar 24 00:42:40 1995 @@ -1,5 +1,5 @@ /* Convert between signal names and numbers. - Copyright (C) 1990, 1992, 1993 Free Software Foundation, Inc. + Copyright (C) 1990, 1992, 1993, 1995 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -216,6 +216,9 @@ #if defined (SIGDANGER) init_sig (SIGDANGER, "DANGER", "Danger signal"); #endif +#if defined (SIGINFO) + init_sig (SIGINFO, "INFO", "Information request"); +#endif } /* Return the abbreviation for signal NUMBER. */ @@ -271,5 +274,22 @@ fprintf (stderr, "%s: unknown signal", message); else fprintf (stderr, "%s: %s\n", message, sys_siglist[signal]); +} +#endif + +#ifndef HAVE_STRSIGNAL +/* Return the string associated with the signal number. */ + +char * +strsignal (signal) + int signal; +{ + static char buf[] = "Signal 12345678901234567890"; + + if (signal > 0 || signal < NSIG) + return (char *) sys_siglist[signal]; + + sprintf (buf, "Signal %d", signal); + return buf; } #endif diff -ruN make-3.72.1/signame.h make-3.73/signame.h --- make-3.72.1/signame.h Mon May 9 22:12:43 1994 +++ make-3.73/signame.h Thu Feb 23 18:42:12 1995 @@ -1,5 +1,5 @@ /* Convert between signal names and numbers. - Copyright (C) 1990, 1992, 1993 Free Software Foundation, Inc. + Copyright (C) 1990, 1992, 1993, 1995 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -29,7 +29,7 @@ signal by that name. */ int sig_number (const char *abbrev); -/* Avoid conflicts with a system header file that might define these two. */ +/* Avoid conflicts with a system header file that might define these three. */ #ifndef HAVE_PSIGNAL /* Print to standard error the name of SIGNAL, preceded by MESSAGE and @@ -37,6 +37,11 @@ void psignal (int signal, const char *message); #endif +#ifndef HAVE_STRSIGNAL +/* Return the name of SIGNAL. */ +char *strsignal (int signal); +#endif + #if !defined (HAVE_SYS_SIGLIST) /* Names for signals from 0 to NSIG-1. */ extern const char *sys_siglist[]; @@ -49,6 +54,9 @@ int sig_number (); #if !defined (HAVE_SYS_SIGLIST) && !defined (HAVE_PSIGNAL) void psignal (); +#endif +#ifndef HAVE_STRSIGNAL +char *strsignal (); #endif #if !defined (HAVE_SYS_SIGLIST) extern char *sys_siglist[]; diff -ruN make-3.72.1/texinfo.tex make-3.73/texinfo.tex --- make-3.72.1/texinfo.tex Mon Oct 31 22:24:22 1994 +++ make-3.73/texinfo.tex Sun Feb 5 05:46:17 1995 @@ -22,13 +22,26 @@ %You are forbidden to forbid anyone else to use, share and improve %what you give them. Help stamp out software-hoarding! + +% Send bug reports to bug-texinfo@prep.ai.mit.edu. +% Please include a *precise* test case in each bug report. + + +% Make it possible to create a .fmt file just by loading this file: +% if the underlying format is not loaded, start by loading it now. +% Added by gildea November 1993. +\expandafter\ifx\csname fmtname\endcsname\relax\input plain\fi + % This automatically updates the version number based on RCS. \def\deftexinfoversion$#1: #2 ${\def\texinfoversion{#2}} -\deftexinfoversion$Revision: 2.136 $ +\deftexinfoversion$Revision: 2.145 $ \message{Loading texinfo package [Version \texinfoversion]:} -% Print the version number if in a .fmt file. -\everyjob{\message{[Texinfo version \texinfoversion]}\message{}} +% If in a .fmt file, print the version number +% and turn on active characters that we couldn't do earlier because +% they might have appeared in the input file name. +\everyjob{\message{[Texinfo version \texinfoversion]}\message{} + \catcode`+=\active \catcode`\_=\active} % Save some parts of plain tex whose names we will redefine. @@ -759,7 +772,10 @@ \else \setzzz{#1}#2\endsetzzz % Remove the trailing space \setxxx inserted. \fi } -\def\setzzz#1#2 \endsetzzz{\expandafter\xdef\csname SET#1\endcsname{#2}} +% Can't use \xdef to pre-expand #2 and save some time, since \temp or +% \next or other control sequences that we've defined might get us into +% an infinite loop. Consider `@set foo @cite{bar}'. +\def\setzzz#1#2 \endsetzzz{\expandafter\gdef\csname SET#1\endcsname{#2}} % @clear VAR clears (i.e., unsets) the variable VAR. % @@ -951,7 +967,7 @@ \let\indtt=\ninett \let\indsf=\indrm \let\indbf=\indrm -\let\indsc=\indrm +\setfont\indsc{csc10 at 9pt} \font\indi=cmmi9 \font\indsy=cmsy9 @@ -2038,6 +2054,7 @@ \let\indexbackslash=0 %overridden during \printindex. +\let\SETmarginindex=\relax %initialize! % workhorse for all \fooindexes % #1 is name of index, #2 is stuff to put there \def\doind #1#2{% @@ -3340,6 +3357,9 @@ \gdef\functionparens{\boldbrax\let&=\amprm\parencount=0 } \gdef\boldbrax{\let(=\opnr\let)=\clnr\let[=\lbrb\let]=\rbrb} +% This is used to turn on special parens +% but make & act ordinary (given that it's active). +\gdef\boldbraxnoamp{\let(=\opnr\let)=\clnr\let[=\lbrb\let]=\rbrb\let&=\ampnr} % Definitions of (, ) and & used in args for functions. % This is the definition of ( outside of all parentheses. @@ -3548,7 +3568,8 @@ \def\deftypefunargs #1{% % Expand, preventing hyphenation at `-' chars. % Note that groups don't affect changes in \hyphenchar. -\functionparens +% Use \boldbraxnoamp, not \functionparens, so that & is not special. +\boldbraxnoamp \tclose{#1}% avoid \code because of side effects on active chars \interlinepenalty=10000 \advance\rightskip by 0pt plus 1fil @@ -4240,6 +4261,10 @@ \def\afourlatex{\changepagesizes{22cm}{15cm}{7mm}{4.6mm}{5mm}} +% Use @afourwide to print on European A4 paper in wide format. +\def\afourwide{\afourpaper +\changepagesizes{9.5in}{6.5in}{\hoffset}{\normaloffset}{\bindingoffset}} + % Define macros to output various characters with catcode for normal text. \catcode`\"=\other \catcode`\~=\other @@ -4313,6 +4338,15 @@ {\catcode`\==\active \global\def={{\tt \char 61}}} +\catcode`+=\active +\catcode`\_=\active + +% If a .fmt file is being used, characters that might appear in a file +% name cannot be active until we have parsed the command line. +% So turn them off again, and have \everyjob (or @setfilename) turn them on. +% \otherifyactive is called near the end of this file. +\def\otherifyactive{\catcode`+=\other \catcode`\_=\other} + \catcode`\@=0 % \rawbackslashxx output one backslash character in current font @@ -4355,6 +4389,10 @@ @let>=@normalgreater @let+=@normalplus} +% Make _ and + \other characters, temporarily. +% This is canceled by @fixbackslash. +@otherifyactive + % If a .fmt file is being used, we don't want the `\input texinfo' to show up. % That is what \eatinput is for; after that, the `\' should revert to printing % a backslash. @@ -4365,8 +4403,11 @@ % On the other hand, perhaps the file did not have a `\input texinfo'. Then % the first `\{ in the file would cause an error. This macro tries to fix % that, assuming it is called before the first `\' could plausibly occur. +% Also back turn on active characters that might appear in the input +% file name, in case not using a pre-dumped format. % -@gdef@fixbackslash{@ifx\@eatinput @let\ = @normalbackslash @fi} +@gdef@fixbackslash{@ifx\@eatinput @let\ = @normalbackslash @fi + @catcode`+=@active @catcode`@_=@active} %% These look ok in all fonts, so just make them not special. The @rm below %% makes sure that the current font starts out as the newly loaded cmr10 diff -ruN make-3.72.1/version.c make-3.73/version.c --- make-3.72.1/version.c Sun Nov 6 18:33:26 1994 +++ make-3.73/version.c Wed Apr 5 00:20:20 1995 @@ -1,4 +1,4 @@ -char *version_string = "3.72.1"; +char *version_string = "3.73"; /* Local variables: