* lib/Automake/Config.in: Let AUTOMAKE_LIBDIR environment variable
override the default location for '$libdir'.
* doc/automake.texi (automake Invocation): Document AUTOMAKE_LIBDIR.
* pre-inst-env.in (AUTOMAKE_LIBDIR): Set AUTOMAKE_LIBDIR.
* bin/wrap-automake.in: Don't use "--libdir" option.
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
-BEGIN
-{
- use strict;
- unshift @ARGV, '--libdir=@abs_top_srcdir@/lib';
-}
require '@abs_top_builddir@/bin/automake';
Look for Automake data files in directory @var{dir} instead of in the
installation directory. This is typically used for debugging.
+@vindex AUTOMAKE_LIBDIR
+The environment variable @env{AUTOMAKE_LIBDIR} provides another way to
+set the directory containing Automake data files. However
+@option{--libdir} takes precedence over it.
+
@item --print-libdir
@opindex --print-libdir
Print the path of the installation directory containing Automake-provided
our $PACKAGE_BUGREPORT = '@PACKAGE_BUGREPORT@';
our $VERSION = '@VERSION@';
our $RELEASE_YEAR = '@RELEASE_YEAR@';
-our $libdir = '@datadir@/@PACKAGE@-@APIVERSION@';
+our $libdir = $ENV{"AUTOMAKE_LIBDIR"} || '@datadir@/@PACKAGE@-@APIVERSION@';
our $perl_threads = 0;
# We need at least this version for CLONE support.
AUTOMAKE_UNINSTALLED=1
export AUTOMAKE_UNINSTALLED
+AUTOMAKE_LIBDIR="$abs_top_srcdir/lib"
+export AUTOMAKE_LIBDIR
+
exec "$@"