diff options
author | Kelley Cook <kelleycook@wideopenwest.com> | 2003-08-12 22:35:22 +0000 |
---|---|---|
committer | R. Kelley Cook <kcook@gcc.gnu.org> | 2003-08-12 22:35:22 +0000 |
commit | 3a000df0e677ca9a9fc6a17e95f20ef312b718e7 (patch) | |
tree | 6c5aa4b2b905b67311a369a7b7b55d265ed4e28f /gcc/aclocal.m4 | |
parent | 560ad596bdde2ca44f9890e9e1399b29736c63ea (diff) | |
download | gcc-3a000df0e677ca9a9fc6a17e95f20ef312b718e7.zip gcc-3a000df0e677ca9a9fc6a17e95f20ef312b718e7.tar.gz gcc-3a000df0e677ca9a9fc6a17e95f20ef312b718e7.tar.bz2 |
configure.in (make_compare_target): Move test to ...
2003-08-08 Kelley Cook <kelleycook@wideopenwest.com>
* configure.in (make_compare_target): Move test to ...
* aclocal.m4 (gcc_AC_PROG_CMP_IGNORE_INITIAL): here.
* configure: Regenerate.
From-SVN: r70392
Diffstat (limited to 'gcc/aclocal.m4')
-rw-r--r-- | gcc/aclocal.m4 | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/gcc/aclocal.m4 b/gcc/aclocal.m4 index ebdb5b2..d772ee9 100644 --- a/gcc/aclocal.m4 +++ b/gcc/aclocal.m4 @@ -101,6 +101,29 @@ if test x = y ; then fi ]) +dnl 'make compare' can be significantly faster, if cmp itself can +dnl skip bytes instead of using tail. The test being performed is +dnl "if cmp --ignore-initial=2 t1 t2 && ! cmp --ignore-initial=1 t1 t2" +dnl but we need to sink errors and handle broken shells. +AC_DEFUN(gcc_AC_PROG_CMP_IGNORE_INITIAL, +[AC_CACHE_CHECK([for cmp's capabilities], gcc_cv_prog_cmp_skip, +[ echo abfoo >t1 + echo cdfoo >t2 + if cmp --ignore-initial=2 t1 t2 > /dev/null 2>&1; then + if cmp --ignore-initial=1 t1 t2 > /dev/null 2>&1; then + gcc_cv_prog_cmp_skip=slowcompare + else + gcc_cv_prog_cmp_skip=gnucompare + fi + else + gcc_cv_prog_cmp_skip=slowcompare + fi + rm t1 t2 +]) +make_compare_target=$gcc_cv_prog_cmp_skip +AC_SUBST(make_compare_target) +]) + dnl See if the printf functions in libc support %p in format strings. AC_DEFUN(gcc_AC_FUNC_PRINTF_PTR, [AC_CACHE_CHECK(whether the printf functions support %p, |