Small improvements from TODO.

This commit is contained in:
David MacKenzie 1995-06-23 03:39:38 +00:00
parent 7ebb48dfca
commit 52da270341
8 changed files with 109 additions and 76 deletions

View File

@ -1,3 +1,10 @@
Thu Jun 22 22:33:23 1995 David J. MacKenzie <djm@catapult.va.pubnix.com>
* acspecific.m4 (AC_PROG_INSTALL): Don't cache a shell script path.
* acgeneral.m4 (AC_CHECK_LIB): Allow lib name to contain a . or /,
by fixing the cache variable name.
Wed Jun 14 23:07:20 1995 David J. MacKenzie <djm@geech.gnu.ai.mit.edu>
* Version 2.4.

56
TODO
View File

@ -219,7 +219,7 @@ From Roland McGrath.
ls -lt configure configure.in | sort
doesn't work right if configure.in is from a symlink farm, where the
symlink has either a timestamp of it's own, or under BSD 4.4, it has
symlink has either a timestamp of its own, or under BSD 4.4, it has
the timestamp of the current directory, neither of which
helps. Changing it to
ls -Llt configure configure.in | sort
@ -261,8 +261,8 @@ From: Randall Winchester
AC_C_CROSS assumes that configure was
called like 'CC=target-gcc; ./configure'. I want to write a package
that has target dependend libraries and host dependend tools. So I
dont't like to lose the distinction between CC and [G]CC_FOR_TARGET.
that has target dependent libraries and host dependent tools. So I
don't like to lose the distinction between CC and [G]CC_FOR_TARGET.
AC_C_CROSS should check for equality of target and host.
It would be great if
@ -317,25 +317,6 @@ Make easy macros for checking for X functions and libraries.
------------------------------------------------------------------------------
We probably shouldn't cache a path for INSTALL within a source
directory, because that will break other packages using the cache if
that directory is removed.
------------------------------------------------------------------------------
Document this trick:
>> Half my time these days seems to be spent porting
>> configure.in files to new OS releases.) Alas, there doesn't seem to
>> be any way to turn off caching (with a configure.in directive).
define([AC_CACHE_LOAD], )dnl
define([AC_CACHE_SAVE], )dnl
AC_INIT(whatever)
... rest of configure.in ...
------------------------------------------------------------------------------
Testing for ANSI header files (AC_HEADER_STDC) fails under linux when
using the latest libraries (libc-4.6.30, at least libc-4.6.27 works
ok) when LC_CTYPE is set to ISO-8859-1. The islower/toupper test
@ -347,25 +328,24 @@ From: tom@vlsivie.tuwien.ac.AT (Thomas Winder)
------------------------------------------------------------------------------
A number of people have tried to fix configuration problems by editing
acconfig.h. (Despite comments at the top of the file.) I think they're
confused because anything.h looks like a regular source file name.
Maybe acconfig.h could be called acconfig.extra or something?
From: kb@cs.umb.edu (K. Berry)
------------------------------------------------------------------------------
Using the macro AC_CHECK_LIB, if the library name contains a dot (which is
the case of the library complib.sgimath on Irix 5.x) a syntax error occurs
because the corresponding cache variable name contains a dot.
Should dots be converted to underlines in variable names by autoconf?
From: Frederic.DEvernay@sophia.inria.fr (Frederic Devernay)
------------------------------------------------------------------------------
* Test suite: more things to test:
** That the shell scripts produce correct output on some simple data.
** Configuration header files. That autoheader does the right thing,
and so does AC_CONFIG_HEADER when autoconf is run.
------------------------------------------------------------------------------
On Sun, 18 Jun 1995 12:59:01 -0400, Richard Stallman <rms@gnu.ai.mit.edu> said:
> When a configure script includes nonstandard tests,
> is there an easy way to arrange to cache the result?
Yes, such a shorthand macro is possible. Here's a definition for it.
dnl AC_CHECK_CACHE(cache-var, message, check)
AC_DEFUN([AC_CHECK_CACHE],
[AC_MSG_CHECKING($2)
AC_CACHE_VAL($1, $3)
AC_MSG_RESULT([$]$1)])
------------------------------------------------------------------------------

View File

@ -1222,13 +1222,17 @@ dnl AC_CHECK_LIB(LIBRARY, FUNCTION [, ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND
dnl [, OTHER-LIBRARIES]]])
AC_DEFUN(AC_CHECK_LIB,
[AC_MSG_CHECKING([for -l$1])
AC_CACHE_VAL(ac_cv_lib_$1,
changequote(, )dnl
ac_lib_var=`echo $1 | tr '[./]' '[__]'`
changequote([, ])dnl
AC_CACHE_VAL(ac_cv_lib_$ac_lib_var,
[ac_save_LIBS="$LIBS"
LIBS="-l$1 $5 $LIBS"
AC_TRY_LINK(, [$2()], eval "ac_cv_lib_$1=yes", eval "ac_cv_lib_$1=no")dnl
AC_TRY_LINK(, [$2()], eval "ac_cv_lib_$ac_lib_var=yes",
eval "ac_cv_lib_$ac_lib_var=no")dnl
LIBS="$ac_save_LIBS"
])dnl
if eval "test \"`echo '$ac_cv_lib_'$1`\" = yes"; then
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
AC_MSG_RESULT(yes)
ifelse([$3], ,
[changequote(, )dnl

View File

@ -384,7 +384,7 @@ AC_CACHE_VAL(ac_cv_path_install,
/|./|.//|/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 ginstall 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
@ -401,12 +401,16 @@ AC_CACHE_VAL(ac_cv_path_install,
esac
done
IFS="$ac_save_ifs"
# As a last resort, use the slow shell script.
dnl FIXME We probably shouldn't cache a path within a source directory,
dnl because that will break other packages using the cache if
dnl that directory is removed.
test -z "$ac_cv_path_install" && ac_cv_path_install="$ac_install_sh"])dnl
INSTALL="$ac_cv_path_install"
])dnl
if test "${ac_cv_path_install+set}" = set; then
INSTALL="$ac_cv_path_install"
else
# As a last resort, use the slow shell script. We don't cache a
# path for INSTALL within a source directory, because that will
# break other packages using the cache if that directory is
# removed, or if the path is relative.
INSTALL="$ac_install_sh"
fi
fi
dnl We do special magic for INSTALL instead of AC_SUBST, to get
dnl relative paths right.

View File

@ -8,7 +8,7 @@
@set EDITION 2.3
@set VERSION 2.3
@set UPDATED March 1995
@set UPDATED June 1995
@iftex
@finalout
@ -1585,11 +1585,16 @@ might not be in the user's @code{PATH}, you can temporarily add to it:
@example
ac_save_path="$PATH"
PATH=/usr/libexec:/usr/sbin:/usr/etc:/etc
PATH=/usr/libexec:/usr/sbin:/usr/etc:/etc:/usr/bin:/bin
AC_PATH_PROG(INETD, inetd, /usr/libexec/inetd)
PATH="$ac_save_path"
@end example
@noindent
Keep @file{/usr/bin:/bin} in the @code{PATH} so if if the @code{echo} or
@code{test} command is in one of those directories, @code{configure} can
still find it.
@defmac AC_CHECK_PROG (@var{variable}, @var{prog-to-check-for}, @var{value-if-found} @r{[}, @var{value-if-not-found}@r{]})
@maindex CHECK_PROG
Check whether program @var{prog-to-check-for} exists in @code{PATH}. If
@ -3334,13 +3339,23 @@ By default, configure uses @file{./config.cache} as the cache file,
creating it if it does not exist already. @code{configure} accepts the
@samp{--cache-file=@var{file}} option to use a different cache file;
that is what @code{configure} does when it calls @code{configure}
scripts in subdirectories, so they share the cache. Giving
@samp{--cache-file=/dev/null} disables caching, for debugging
@code{configure}. @xref{Subdirectories}, for information on configuring
subdirectories with the @code{AC_CONFIG_SUBDIRS} macro.
@file{config.status} only pays attention to the cache file if it is
given the @samp{--recheck} option, which makes it rerun
@code{configure}.
scripts in subdirectories, so they share the cache.
@xref{Subdirectories}, for information on configuring subdirectories
with the @code{AC_CONFIG_SUBDIRS} macro.
Giving @samp{--cache-file=/dev/null} disables caching, for debugging
@code{configure}. @file{config.status} only pays attention to the cache
file if it is given the @samp{--recheck} option, which makes it rerun
@code{configure}. If you are anticipating a long debugging period, you
can also disable cache loading and saving for a @code{configure} script
by redefining the cache macros at the start of @file{configure.in}:
@example
define([AC_CACHE_LOAD], )dnl
define([AC_CACHE_SAVE], )dnl
AC_INIT(@r{whatever})
@r{ ... rest of configure.in ...}
@end example
It is wrong to try to distribute cache files for particular system types.
There is too much room for error in doing that, and too much

View File

@ -8,7 +8,7 @@
@set EDITION 2.3
@set VERSION 2.3
@set UPDATED March 1995
@set UPDATED June 1995
@iftex
@finalout
@ -1585,11 +1585,16 @@ might not be in the user's @code{PATH}, you can temporarily add to it:
@example
ac_save_path="$PATH"
PATH=/usr/libexec:/usr/sbin:/usr/etc:/etc
PATH=/usr/libexec:/usr/sbin:/usr/etc:/etc:/usr/bin:/bin
AC_PATH_PROG(INETD, inetd, /usr/libexec/inetd)
PATH="$ac_save_path"
@end example
@noindent
Keep @file{/usr/bin:/bin} in the @code{PATH} so if if the @code{echo} or
@code{test} command is in one of those directories, @code{configure} can
still find it.
@defmac AC_CHECK_PROG (@var{variable}, @var{prog-to-check-for}, @var{value-if-found} @r{[}, @var{value-if-not-found}@r{]})
@maindex CHECK_PROG
Check whether program @var{prog-to-check-for} exists in @code{PATH}. If
@ -3334,13 +3339,23 @@ By default, configure uses @file{./config.cache} as the cache file,
creating it if it does not exist already. @code{configure} accepts the
@samp{--cache-file=@var{file}} option to use a different cache file;
that is what @code{configure} does when it calls @code{configure}
scripts in subdirectories, so they share the cache. Giving
@samp{--cache-file=/dev/null} disables caching, for debugging
@code{configure}. @xref{Subdirectories}, for information on configuring
subdirectories with the @code{AC_CONFIG_SUBDIRS} macro.
@file{config.status} only pays attention to the cache file if it is
given the @samp{--recheck} option, which makes it rerun
@code{configure}.
scripts in subdirectories, so they share the cache.
@xref{Subdirectories}, for information on configuring subdirectories
with the @code{AC_CONFIG_SUBDIRS} macro.
Giving @samp{--cache-file=/dev/null} disables caching, for debugging
@code{configure}. @file{config.status} only pays attention to the cache
file if it is given the @samp{--recheck} option, which makes it rerun
@code{configure}. If you are anticipating a long debugging period, you
can also disable cache loading and saving for a @code{configure} script
by redefining the cache macros at the start of @file{configure.in}:
@example
define([AC_CACHE_LOAD], )dnl
define([AC_CACHE_SAVE], )dnl
AC_INIT(@r{whatever})
@r{ ... rest of configure.in ...}
@end example
It is wrong to try to distribute cache files for particular system types.
There is too much room for error in doing that, and too much

View File

@ -1222,13 +1222,17 @@ dnl AC_CHECK_LIB(LIBRARY, FUNCTION [, ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND
dnl [, OTHER-LIBRARIES]]])
AC_DEFUN(AC_CHECK_LIB,
[AC_MSG_CHECKING([for -l$1])
AC_CACHE_VAL(ac_cv_lib_$1,
changequote(, )dnl
ac_lib_var=`echo $1 | tr '[./]' '[__]'`
changequote([, ])dnl
AC_CACHE_VAL(ac_cv_lib_$ac_lib_var,
[ac_save_LIBS="$LIBS"
LIBS="-l$1 $5 $LIBS"
AC_TRY_LINK(, [$2()], eval "ac_cv_lib_$1=yes", eval "ac_cv_lib_$1=no")dnl
AC_TRY_LINK(, [$2()], eval "ac_cv_lib_$ac_lib_var=yes",
eval "ac_cv_lib_$ac_lib_var=no")dnl
LIBS="$ac_save_LIBS"
])dnl
if eval "test \"`echo '$ac_cv_lib_'$1`\" = yes"; then
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
AC_MSG_RESULT(yes)
ifelse([$3], ,
[changequote(, )dnl

View File

@ -384,7 +384,7 @@ AC_CACHE_VAL(ac_cv_path_install,
/|./|.//|/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 ginstall 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
@ -401,12 +401,16 @@ AC_CACHE_VAL(ac_cv_path_install,
esac
done
IFS="$ac_save_ifs"
# As a last resort, use the slow shell script.
dnl FIXME We probably shouldn't cache a path within a source directory,
dnl because that will break other packages using the cache if
dnl that directory is removed.
test -z "$ac_cv_path_install" && ac_cv_path_install="$ac_install_sh"])dnl
INSTALL="$ac_cv_path_install"
])dnl
if test "${ac_cv_path_install+set}" = set; then
INSTALL="$ac_cv_path_install"
else
# As a last resort, use the slow shell script. We don't cache a
# path for INSTALL within a source directory, because that will
# break other packages using the cache if that directory is
# removed, or if the path is relative.
INSTALL="$ac_install_sh"
fi
fi
dnl We do special magic for INSTALL instead of AC_SUBST, to get
dnl relative paths right.