diff options
-rw-r--r-- | ChangeLog | 8 | ||||
-rw-r--r-- | basicdefs.h | 24 | ||||
-rwxr-xr-x | bootstrap.sh | 9 | ||||
-rwxr-xr-x | bootstrap.sh.in | 9 | ||||
-rw-r--r-- | configure.ac | 5 | ||||
-rw-r--r-- | lib/.gitignore | 26 | ||||
-rw-r--r-- | m4/.gitignore | 8 | ||||
-rw-r--r-- | sed/execute.c | 2 |
8 files changed, 25 insertions, 66 deletions
@@ -1,3 +1,11 @@ +2008-09-28 Paolo Bonzini <bonzini@gnu.org> + + * basicdefs.h: Replace alloca cruft with alloca.h. + * bootstrap.sh.in: Update for new gnulib. + * bootstrap.sh: Update for new gnulib. + * configure.ac: Move gnulib macros earlier. + * sed/execute.c: Do not include acl.h when bootstrapping. + 2008-08-27 Paolo Bonzini <bonzini@gnu.org> * sed/execute.c (closedown): Close the input file! diff --git a/basicdefs.h b/basicdefs.h index b39df2d..eca9916 100644 --- a/basicdefs.h +++ b/basicdefs.h @@ -18,29 +18,7 @@ #ifndef BASICDEFS_H #define BASICDEFS_H -#if defined(_AIX) -#pragma alloca -#else -# if !defined(alloca) /* predefined by HP cc +Olibcalls */ -# ifdef __GNUC__ -# define alloca(size) __builtin_alloca(size) -# else -# if HAVE_ALLOCA_H -# include <alloca.h> -# else -# if defined(__hpux) - void *alloca (); -# else -# if !defined(__OS2__) && !defined(WIN32) - char *alloca (); -# else -# include <malloc.h> /* OS/2 defines alloca in here */ -# endif -# endif -# endif -# endif -# endif -#endif +#include <alloca.h> #ifdef HAVE_WCHAR_H # include <wchar.h> diff --git a/bootstrap.sh b/bootstrap.sh index 9d48ac0..0a29963 100755 --- a/bootstrap.sh +++ b/bootstrap.sh @@ -111,10 +111,12 @@ set -x -e rm -f lib/*.o sed/*.o sed/sed cd lib || exit 1 -${CC} -DHAVE_CONFIG_H -I.. -I. -c acl.c || exit 1 +cp alloca.in.h alloca.h || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c alloca.c || exit 1 +${CC} -DHAVE_CONFIG_H -I.. -I. -c copy-acl.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c error.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c exitfail.c || exit 1 +${CC} -DHAVE_CONFIG_H -I.. -I. -c file-has-acl.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c getdelim.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c getline.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c getopt.c || exit 1 @@ -125,16 +127,13 @@ ${CC} -DHAVE_CONFIG_H -I.. -I. -c memcmp.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c memmove.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c mkstemp.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c obstack.c || exit 1 -${CC} -DHAVE_CONFIG_H -I.. -I. -c printf-args.c || exit 1 -${CC} -DHAVE_CONFIG_H -I.. -I. -c printf-parse.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c quote.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c quotearg.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c regex.c || exit 1 -${CC} -DHAVE_CONFIG_H -I.. -I. -c snprintf.c || exit 1 +${CC} -DHAVE_CONFIG_H -I.. -I. -c set-mode-acl.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c strerror.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c strverscmp.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c tempname.c || exit 1 -${CC} -DHAVE_CONFIG_H -I.. -I. -c vasnprintf.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c xalloc-die.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c xmalloc.c || exit 1 diff --git a/bootstrap.sh.in b/bootstrap.sh.in index af15c11..6233157 100755 --- a/bootstrap.sh.in +++ b/bootstrap.sh.in @@ -111,10 +111,12 @@ set -x -e rm -f lib/*.o sed/*.o sed/sed cd lib || exit 1 -${CC} -DHAVE_CONFIG_H -I.. -I. -c acl.c || exit 1 +cp alloca.in.h alloca.h || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c alloca.c || exit 1 +${CC} -DHAVE_CONFIG_H -I.. -I. -c copy-acl.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c error.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c exitfail.c || exit 1 +${CC} -DHAVE_CONFIG_H -I.. -I. -c file-has-acl.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c getdelim.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c getline.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c getopt.c || exit 1 @@ -125,16 +127,13 @@ ${CC} -DHAVE_CONFIG_H -I.. -I. -c memcmp.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c memmove.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c mkstemp.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c obstack.c || exit 1 -${CC} -DHAVE_CONFIG_H -I.. -I. -c printf-args.c || exit 1 -${CC} -DHAVE_CONFIG_H -I.. -I. -c printf-parse.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c quote.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c quotearg.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c regex.c || exit 1 -${CC} -DHAVE_CONFIG_H -I.. -I. -c snprintf.c || exit 1 +${CC} -DHAVE_CONFIG_H -I.. -I. -c set-mode-acl.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c strerror.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c strverscmp.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c tempname.c || exit 1 -${CC} -DHAVE_CONFIG_H -I.. -I. -c vasnprintf.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c xalloc-die.c || exit 1 ${CC} -DHAVE_CONFIG_H -I.. -I. -c xmalloc.c || exit 1 diff --git a/configure.ac b/configure.ac index 4181e12..d7a6a1a 100644 --- a/configure.ac +++ b/configure.ac @@ -13,11 +13,13 @@ AC_SUBST(SED_FEATURE_VERSION) AC_PROG_CC gl_DISABLE_THREADS +AC_USE_SYSTEM_EXTENSIONS +AC_GNU_SOURCE gl_EARLY -AC_ISC_POSIX AC_SYS_LARGEFILE AC_SYS_LONG_FILE_NAMES +gl_INIT AC_CACHE_CHECK([whether -lcP is needed], [sed_cv_libcp_needed], [ AC_TRY_RUN([ #include <stdio.h> @@ -55,7 +57,6 @@ AC_DEFUN([AM_MKINSTALLDIRS], [MKINSTALLDIRS="$mkdir_p" AC_SUBST(MKINSTALLDIRS)]) AM_GNU_GETTEXT_VERSION(0.15) AM_GNU_GETTEXT(no-libtool, need-ngettext, ../intl) -gl_INIT AC_CHECK_FUNCS_ONCE(isatty bcopy bzero isascii memcpy memset strchr strtoul popen pathconf isblank fchown fchmod setlocale wcrtomb wcscoll btowc) diff --git a/lib/.gitignore b/lib/.gitignore index a5b3f4b..b818438 100644 --- a/lib/.gitignore +++ b/lib/.gitignore @@ -1,28 +1,24 @@ acl-internal.h -acl.c acl.h acl_entries.c alloca.c alloca.h alloca.in.h -alloca_.h -asnprintf.c config.charset copy-acl.c +errno.h +errno.in.h error.c error.h exitfail.c exitfail.h file-has-acl.c -float+.h -float_.h getdelim.c getline.c getopt.c getopt.h getopt.in.h getopt1.c -getopt_.h getopt_int.h gettext.h gettimeofday.c @@ -38,10 +34,6 @@ mkstemp.c obstack.c obstack.h pathmax.h -printf-args.c -printf-args.h -printf-parse.c -printf-parse.h quote.c quote.h quotearg.c @@ -58,21 +50,15 @@ regex_internal.c regex_internal.h regexec.c set-mode-acl.c -size_max.h -snprintf.c stat-macros.h stdbool.h stdbool.in.h -stdbool_.h stdint.h stdint.in.h -stdint_.h stdio.h stdio.in.h -stdio_.h stdlib.h stdlib.in.h -stdlib_.h strerror.c string.h string.in.h @@ -80,26 +66,18 @@ strverscmp.c sys sys_stat.h sys_stat.in.h -sys_stat_.h sys_time.h sys_time.in.h -sys_time_.h tempname.c tempname.h unistd.h unistd.in.h -unistd_.h unlocked-io.h -vasnprintf.c -vasnprintf.h verify.h wchar.h wchar.in.h -wchar_.h wctype.h wctype.in.h -wctype_.h xalloc-die.c xalloc.h xmalloc.c -xsize.h diff --git a/m4/.gitignore b/m4/.gitignore index dee9d6e..e8f720a 100644 --- a/m4/.gitignore +++ b/m4/.gitignore @@ -1,12 +1,10 @@ -absolute-header.m4 acl.m4 alloca.m4 codeset.m4 -eoverflow.m4 +errno_h.m4 error.m4 exitfail.m4 extensions.m4 -float_h.m4 getdelim.m4 getline.m4 getopt.m4 @@ -26,7 +24,6 @@ intl.m4 intldir.m4 intlmacosx.m4 intmax.m4 -intmax_t.m4 inttypes-h.m4 inttypes-pri.m4 inttypes_h.m4 @@ -49,7 +46,6 @@ nls.m4 pathmax.m4 po.m4 printf-posix.m4 -printf.m4 progtest.m4 quote.m4 quotearg.m4 @@ -57,7 +53,6 @@ realloc.m4 regex.m4 signed.m4 size_max.m4 -snprintf.m4 ssize_t.m4 stdbool.m4 stdint.m4 @@ -75,7 +70,6 @@ uintmax_t.m4 ulonglong.m4 unistd_h.m4 unlocked-io.m4 -vasnprintf.m4 visibility.m4 wchar.m4 wchar_t.m4 diff --git a/sed/execute.c b/sed/execute.c index 8d948e1..c4ff1fd 100644 --- a/sed/execute.c +++ b/sed/execute.c @@ -35,7 +35,9 @@ extern int errno; # include <unistd.h> #endif +#ifndef BOOTSTRAP #include "acl.h" +#endif #ifdef __GNUC__ # if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__-0 >= 7) |