3 # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
4 # $ac_aux_dir to ${srcdir}/foo. In other projects, it is set to `.'.
5 # Of course, Automake must honor this variable whenever it calls a tool
6 # from the auxiliary directory. The problem is that $srcdir (and therefore
7 # $ac_aux_dir as well) can be either an absolute path or a path relative to
8 # $top_srcdir, depending on how configure is run. This is pretty annoying,
9 # since it makes $ac_aux_dir quite unusable in subdirectories: in the top
10 # source directory, any form will work fine, but in subdirectories a relative
11 # path needs to be adjusted first.
12 # - calling $top_srcdir/$ac_aux_dir/missing would succeed if $ac_aux_dir was
13 # relative, but fail if it was absolute.
14 # - conversly, calling $ac_aux_dir/missing would fail if $ac_aux_dir was
15 # relative, and succeed on absolute paths.
17 # Consequently, we define and use $am_aux_dir, the "always absolute"
18 # version of $ac_aux_dir.
20 AC_DEFUN([AM_AUX_DIR_EXPAND], [
21 # expand $ac_aux_dir to an absolute path
22 am_aux_dir=`CDPATH=:; cd $ac_aux_dir && pwd`