I'm now investigating why the latest CVS version of Automake doesn't
work with GRUB nicely. I've already sent some patches to bug-automake,
but I encountered another problem; "make distclean" doesn't work.

  After looking into it by "make -d distclean", this turned out:

1. The target `distclean' updates the target `Makefile'.
2. The target `Makefile' depends on $(BUILT_SOURCES).
3. $(BUILT_SOURCES) is "stage2_size.h" in our case and it depends on
   "pre_stage2" which is a data file.
4. "pre_stage2" depends on "pre_stage2.exec" which is an executable.
5. Overall, "make distclean" tries to build the executable, but it
   never succeed, because every source files for "pre_stage2.exec"
   includes the header file "config.h" under the top directory, which
   has already been removed when the target "distclean" was executed
   under the top directory.

  The solution may be to get rid of the dependency in the item 2, so
my question is why Makefile must depend on BUILT_SOURCES. Is there
some good reason?

Thanks,
Okuji

Reply via email to