docs: Remove directory prerequisites from make rules

Make expects prerequisites to be files with valid timestamps, and
directories are treated as always being out of date. Thus, any targets
depending on directories will always be rebuilt.

Instead, the doc rules are changed to always create the target's leading
directory. This should prevent the documentation from being rebuilt when
"make install" is run.

Signed-off-by: Dan Nicholson <dbn.lists@gmail.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
This commit is contained in:
Dan Nicholson 2010-10-09 16:00:47 -07:00 committed by Alan Coopersmith
parent d0cbf38891
commit 81d1d9a6bd
2 changed files with 4 additions and 11 deletions

View file

@ -26,4 +26,5 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \
-e '/\@\@$$/s/\@\@$$/\\/'
.pre:
@$(MKDIR_P) $(@D)
$(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@

View file

@ -1,3 +1,4 @@
x11localedir = $(X11_LOCALEDATADIR)
specdir = $(docdir)/Compose
@ -101,13 +102,11 @@ locale.dir: locale.dir.pre
if HAVE_PERL
doc_sources = Compose/index.xml
Compose/index.xml: Compose
Compose/index.xml:
@$(MKDIR_P) $(@D)
$(AM_V_GEN)$(PERL) $(srcdir)/compose-chart.pl \
--index --output="$@" $(locales)
Compose:
$(MKDIR_P) $@
clean-local: clean-Compose-dir
clean-Compose-dir:
-rm -rf Compose
@ -122,11 +121,6 @@ nobase_x11locale_DATA = $(locales:%=%/XLC_LOCALE) $(locales:%=%/Compose)
EXTRA_DIST += $(nobase_x11locale_DATA:%=%.pre)
CLEANFILES += $(nobase_x11locale_DATA)
$(nobase_x11locale_DATA): builddirs
builddirs:
$(MKDIR_P) $(locales)
if HAVE_PERL
TESTS_ENVIRONMENT = $(PERL)
TESTS = $(srcdir)/compose-check.pl
@ -144,6 +138,4 @@ XMLTO_FLAGS += -o $(@D)
Compose/%.xml: %/Compose.xml
$(AM_V_GEN)cp $< $@
$(doc_sources): Compose
endif HAVE_PERL