[Adding libtool to Cc:, in case people there care about the aux_dir discussion at the end of this mail.]
>>> "Robert" == Robert Boehne <[EMAIL PROTECTED]> writes: Robert> Alexandre: Robert> The "dir" file in ${prefix}/info is created by this command: Robert> install-info --info-dir=/net/testme/info /net/testme/info/libtool.info Robert> It makes sense that this file still exists after "make uninstall" Robert> because unless it is alone in the directory, it should still exist. Ah, right. I was stupid. I can see this too. distcheck explicitly allows *one* file to remain after uninstall for this reason. Since config.sub and cousins weren't an issue for me (see below), this lone `dir' file was ignored and distcheck completed. [...] Robert> The rule itself has a tell-tale "FIXME:" in it, which I Robert> would have found if this rule was run by "make install" Robert> in the libltdl subdir, but instead it is run by Robert> install-data-hook in the top-level Makefile. I presume the point for using a remote hook instead of a local install rule is that libltdl shouldn't install itself when embedded in other applications. Robert> ## This allows us to install libltdl without using ln and without Robert> creating Robert> ## a world writeable directory. Robert> ## FIXME: Removed this rule once automake can do this properly by I have no idea what the above comment and the ChangeLog entry are referring to, tho. (Earlier implementations of this rules using ln and 777 directories? What is Automake expected to support exactly?) [...] Robert> Because $(DISTFILES) contains ../config.guess ../config.sub Robert> ../install-sh Robert> ../mkinstalldirs" ../ltmain.sh and ../missing, these files are installed Now I see why I couldn't reproduce this. I have all these files in the libltdl/ directory in my source tree (now idea how they came here, I just recall I had a hard time ./bootstraping Libtool; I probably typed something wrong.) Therefore my libltdl/Makefile.in's DIST_COMMON (hence DISTFILES) contains DIST_COMMON = README $(include_HEADERS) $(noinst_HEADERS) COPYING.LIB \ Makefile.am Makefile.in acinclude.m4 aclocal.m4 config-h.in \ config.guess config.sub configure configure.ac install-sh \ ltmain.sh missing mkinstalldirs and nothing like a `../' Consequently, everything was installed under the $(pkgdatadir)/libltdl/ directory, and cleaned by the `rm -rf $(DESTDIR)$(pkgdatadir)/libltdl' command. [...] Robert> The simplest way I can get around this trouble would be Robert> to add the three files that don't get cleaned by Robert> uninstall to the uninstall-local rule, but is there a Robert> cleaner way for Automake to handle all this itself? I Robert> could also use "basename" in the local-install-files Robert> rule to transform ../foo to foo but is that portable Robert> enough to use? My understanding is that you don't want these files installed at all (so they don't end up in embeded libltdl libraries). Probably you just need something like case $file in ../*) ;; # Don't install out-tree files. *) [... install code ...] ;; esace in your local-install-files rule. If you consider installing these configury files (something earlier versions of Libtool didn't do AFAICT), one easy way seems to have these files in the source tree of libltdl, as it happened to me. This seems the safest solution to me, as it will also lift out and the following issue related to aux_dir. (But I'm probably missing some drawbacks.) Automake needs to know where the aux_dir files are to generate its rules and to add missing files at the right place. That's the reason why calling AC_CONFIG_AUX_DIR with a variable cannot be supported. Apparently this restriction led to the following workaround in libltdl/configure.ac: | # We shouldn't be using these internal macros of autoconf, | # but CONFIG_AUX_DIR($with_auxdir) breaks automake. | AC_ARG_WITH([auxdir], | [AC_HELP_STRING([--with-auxdir=DIR], [path to autoconf auxiliary files])], | [AC_CONFIG_AUX_DIRS($with_auxdir)], | [AC_CONFIG_AUX_DIR_DEFAULT]) The above code doesn't really solve anything [*]: since you don't use AC_CONFIG_AUX_DIR Automake will assume its default value, and search files in `.', `..', and `../..'. If the parent package is using something like AC_CONFIG_AUX_DIR([tools]), then Automake will fail to spot the auxiliary files using the default search path, and it will complain. In the sole project where I use libltdl, I have to edit libltdl/configure.in, and replace the above code by AC_CONFIG_AUX_DIR([../tools]) so that Automake find its files. If you decide to start shipping auxiliary files with libltdl, then this code can be changed to AC_CONFIG_AUX_DIR([.]). I suppose some people will mind about the extra kilobytes, though. [*] To be fair, I guess it's harmless if you don't rerun automake in the libltdl directory embeded in a package. However I think it's quite common to do so, for instance `autoreconf' will work recursively. -- Alexandre Duret-Lutz