]> rtime.felk.cvut.cz Git - coffee/buildroot.git/commitdiff
manual: add a make target 'manual-update-lists'
authorSamuel Martin <s.martin49@gmail.com>
Mon, 25 Mar 2013 13:28:08 +0000 (13:28 +0000)
committerPeter Korsgaard <jacmet@sunsite.dk>
Sat, 4 May 2013 10:39:27 +0000 (12:39 +0200)
The generated lists are automatically updated when building the manual.

[Peter: fix typos]
Signed-off-by: Samuel Martin <s.martin49@gmail.com>
[yann.morin.1998@free.fr: indentation, remove temp dir, intro to host utils]
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
docs/manual/appendix.txt
docs/manual/manual.mk

index 486d82fabdd6c706518203ca6fabf328b8eef1ac..721c96c35902e40af6e845ed92690f24dd206a31 100644 (file)
@@ -20,6 +20,8 @@ include::package-list.txt[]
 Host utilities
 --------------
 
+The following packages are all available in the menu +Host utilities+.
+
 include::host-package-list.txt[]
 
 [[deprecated-list]]
index aa205341dae054d0b1ae0afd49671f49518b089e..4906bc871f1e5b7ec2b9ed6b2bcd2823df255aa7 100644 (file)
@@ -1,3 +1,8 @@
+manual-update-lists:
+       $(Q)$(call MESSAGE,"Updating the manual lists...")
+       $(Q)BR2_DEFCONFIG="" TOPDIR=$(TOPDIR) O=$(O)/docs/manual/.build \
+               $(TOPDIR)/support/scripts/gen-manual-lists.py
+
 ################################################################################
 # GENDOC -- generates the make targets needed to build a specific type of
 #           asciidoc documentation.
@@ -17,11 +22,15 @@ $(1): $(1)-$(3)
 .PHONY: $(1)-$(3)
 $(1)-$(3): $$(O)/docs/$(1)/$(1).$(4)
 
-$$(O)/docs/$(1)/$(1).$(4): docs/$(1)/$(1).txt $$($(call UPPERCASE,$(1))_SOURCES)
-       @$(call MESSAGE,"Generating $(5) $(1)...")
-       $(Q)mkdir -p $$(@D)
+$$(O)/docs/$(1)/$(1).$(4): docs/$(1)/$(1).txt \
+                          $$($(call UPPERCASE,$(1))_SOURCES) \
+                          manual-update-lists
+       $(Q)$(call MESSAGE,"Generating $(5) $(1)...")
+       $(Q)mkdir -p $$(@D)/.build
+       $(Q)rsync -au docs/$(1)/*.txt $$(@D)/.build
        $(Q)a2x $(6) -f $(2) -d book -L -r $(TOPDIR)/docs/images \
-         -D $$(@D) $$<
+               -D $$(@D) $$(@D)/.build/$(1).txt
+       -$(Q)rm -rf $$(@D)/.build
 endef
 
 ################################################################################
@@ -41,7 +50,7 @@ $(call GENDOC_INNER,$(1),epub,epub,epub,EPUB)
 clean: $(1)-clean
 $(1)-clean:
        $(Q)$(RM) -rf $(O)/docs/$(1)
-.PHONY: $(1) $(1)-clean
+.PHONY: $(1) $(1)-clean manual-update-lists
 endef
 
 MANUAL_SOURCES = $(wildcard docs/manual/*.txt) $(wildcard docs/images/*)