From bcdfe9f2731f378e9706d2455e765b3d79a454ee Mon Sep 17 00:00:00 2001 From: "Gary V. Vaughan" Date: Thu, 27 Oct 2011 18:29:50 +0700 Subject: libtoolize: rename `libltdl/m4' directory to standard `m4'. In addition to moving the autoconf macro directory into the place expected by GNU developers ($top_srcdir/m4), we also simplify libtoolize somewhat by having libltdl use whatever directory was specified by the parent project. This is much more flexible, allows libltdl client projects to also use a single canonical `$top_srcdir/m4' macro directory, and maintains backward compatibility with existing projects that wish to continue using $ltdl_dir/m4. * libltdl/m4: Moved to it's parent directory. * Makefile.am (ACLOCAL_AMFLAGS, BUILDCHECK_ENVIRONMENT) (libltdl/Makefile.am, libltdl/aclocal.m4): Adjust. * configure.ac (AC_CONFIG_MACRO_DIR): Adjust. * libltdl/configure.ac (AC_CONFIG_MACRO_DIR): Remove. The libtoolize script can pick up the project macro directory from ACLOCAL_AMFLAGS in libltdl/Makefile.am, saving us from needing to regenerate configure for the sake of a different macro directory declared in the libltdl using client project. * libtoolize.m4sh (func_install_pkgmacro_subproject): Remove. (func_install_pkgmacro_parent): Remove. (subproject_macro_dir): Remove. (require_libltdl_Makefile_am, require_ltdl_aclocal_amflags) (require_ltdl_am_macro_dir): New functions, generated at runtime by adding libltdl/Makefile.am to the generation loop. (func_install_pkgmacro_files): Considerably simplified now that we have only a single macro directory to worry about. (require_ltdl_relative_macro_dir): New function. Calculate the relative path from $ltdl_dir to the parent project macro_dir. (require_Makefile_am_filter): Depending on $ltdl_mode, edit Makefile.am ACLOCAL_AMFLAGS to use the parent project macro directory if necessary. (require_aclocal_m4_filter): Make sure m4_includes point to the correct macro directory by editing the file as it is copied into the parent project. (func_install_pkgltdl_files): Use the filters. (func_check_macros): Remove various advice that no longer applies with an always shared macro directory. (func_require_ltdl_dir): Don't default ltdl_dir to subproject when `--ltdl' was not given. (func_require_ltdl_mode): Leave ltdl_mode empty when ltdl_dir is not set. (func_require_macro_dir): Default to $ltdl_dir/m4 in subproject mode with no other directory implied by AC_CONFIG_MACRO_DIR or ACLOCAL_AMFLAGS, otherwise m4 as before. * tests/libtoolize.at: Match new "creating file `Makefile.am'" messages correctly. (subproject ltdl with non-shared directories): This test no longer makes sense, so repurposed... (subproject ltdl with non-canonical macro dir): ...this, to ensure subproject ltdl continues to automatically share the parent macro directory. * tests/cdemo/Makefile.am, tests/demo/Makefile.am, tests/depdemo/Makefile.am, tests/f77demo/Makefile.am, tests/fcdemo/Makefile.am, tests/mdemo/Makefile.am, tests/mdemo2/Makefile.am, tests/pdemo/Makefile.am, tests/tagdemo/Makefile.am (ACLOCAL_AMFLAGS): Use new location of macro_dir. * NEWS: Updated. Signed-off-by: Gary V. Vaughan --- configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index d6906d1b..f524b558 100644 --- a/configure.ac +++ b/configure.ac @@ -52,7 +52,7 @@ AC_CONFIG_HEADERS([config.h:config-h.in]) AC_CONFIG_SRCDIR([libtoolize.m4sh]) LT_CONFIG_LTDL_DIR([libltdl], [nonrecursive]) AC_CONFIG_AUX_DIR([libltdl/config]) -AC_CONFIG_MACRO_DIR([libltdl/m4]) +AC_CONFIG_MACRO_DIR([m4]) AC_CONFIG_LIBOBJ_DIR([libltdl]) package_revision=`$SHELL $ac_aux_dir/git-version-gen .tarball-version` -- cgit v1.2.1