[dpdk-dev,v2] mk: fix pdf doc rules order

Message ID 1427891478-26398-1-git-send-email-thomas.monjalon@6wind.com (mailing list archive)
State Accepted, archived
Headers

Commit Message

Thomas Monjalon April 1, 2015, 12:31 p.m. UTC
  From: John McNamara <john.mcnamara@intel.com>

Re-ordered the guide-pdf-% and guide-% rules to allow
the doc-guides-pdf target to build with make 3.81. It
builds unmodified with all later versions of make.

Reported-by: Tetsuya Mukawa <mukawa@igel.co.jp>
Signed-off-by: John McNamara <john.mcnamara@intel.com>
Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
---
v2: reorder also clean rules

 mk/rte.sdkdoc.mk | 20 ++++++++++----------
 1 file changed, 10 insertions(+), 10 deletions(-)
  

Comments

John McNamara April 1, 2015, 1:29 p.m. UTC | #1
> -----Original Message-----
> From: Thomas Monjalon [mailto:thomas.monjalon@6wind.com]
> Sent: Wednesday, April 1, 2015 1:31 PM
> To: dev@dpdk.org
> Cc: mukawa@igel.co.jp; Mcnamara, John; De Lara Guarch, Pablo
> Subject: [PATCH v2] mk: fix pdf doc rules order
> 
> From: John McNamara <john.mcnamara@intel.com>
> 
> Re-ordered the guide-pdf-% and guide-% rules to allow the doc-guides-pdf
> target to build with make 3.81. It builds unmodified with all later
> versions of make.
> 
> Reported-by: Tetsuya Mukawa <mukawa@igel.co.jp>
> Signed-off-by: John McNamara <john.mcnamara@intel.com>
> Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
> ---


> v2: reorder also clean rules

Hi Thomas,

That is fine for consistency but there weren't any issues with "make doc-clean" and "make doc-guides-pdf-clean" in the V1 patch/original.

But I'm fine with it like this as well.

John.
  
Thomas Monjalon April 1, 2015, 7:22 p.m. UTC | #2
2015-04-01 13:29, Mcnamara, John:
> > -----Original Message-----
> > From: Thomas Monjalon [mailto:thomas.monjalon@6wind.com]
> > Sent: Wednesday, April 1, 2015 1:31 PM
> > To: dev@dpdk.org
> > Cc: mukawa@igel.co.jp; Mcnamara, John; De Lara Guarch, Pablo
> > Subject: [PATCH v2] mk: fix pdf doc rules order
> > 
> > From: John McNamara <john.mcnamara@intel.com>
> > 
> > Re-ordered the guide-pdf-% and guide-% rules to allow the doc-guides-pdf
> > target to build with make 3.81. It builds unmodified with all later
> > versions of make.
> > 
> > Reported-by: Tetsuya Mukawa <mukawa@igel.co.jp>
> > Signed-off-by: John McNamara <john.mcnamara@intel.com>
> > Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
> > ---
> > v2: reorder also clean rules
> 
> Hi Thomas,
> 
> That is fine for consistency but there weren't any issues with "make doc-clean" and "make doc-guides-pdf-clean" in the V1 patch/original.
> 
> But I'm fine with it like this as well.
> 
> John.

Fixes: ebf8050afd44 ("doc: add pdf output")

Applied, thanks
  

Patch

diff --git a/mk/rte.sdkdoc.mk b/mk/rte.sdkdoc.mk
index 5b44083..f91e079 100644
--- a/mk/rte.sdkdoc.mk
+++ b/mk/rte.sdkdoc.mk
@@ -85,21 +85,15 @@  api-html-clean:
 	$(Q)rm -f $(RTE_OUTPUT)/doc/html/api/*
 	$(Q)rmdir -p --ignore-fail-on-non-empty $(RTE_OUTPUT)/doc/html/api 2>&- || true
 
-guides-%-clean:
-	$(Q)rm -rf $(RTE_OUTPUT)/doc/$*/guides
-	$(Q)rmdir -p --ignore-fail-on-non-empty $(RTE_OUTPUT)/doc/$* 2>&- || true
-
 guides-pdf-clean: guides-pdf-img-clean
 guides-pdf-img-clean:
 	$(Q)rm -f $(RTE_SDK)/doc/guides/*/img/*.pdf
 
-guides-pdf: $(addprefix guides-pdf-, $(notdir $(RTE_GUIDES:/=))) ;
-guides-%:
-	@echo 'sphinx processing $@...'
-	$(Q)$(RTE_SPHINX_BUILD) -b $* $(RTE_SPHINX_VERBOSE) \
-		-c $(RTE_SDK)/doc/guides $(RTE_SDK)/doc/guides \
-		$(RTE_OUTPUT)/doc/$*/guides
+guides-%-clean:
+	$(Q)rm -rf $(RTE_OUTPUT)/doc/$*/guides
+	$(Q)rmdir -p --ignore-fail-on-non-empty $(RTE_OUTPUT)/doc/$* 2>&- || true
 
+guides-pdf: $(addprefix guides-pdf-, $(notdir $(RTE_GUIDES:/=))) ;
 guides-pdf-%:
 	@echo 'sphinx processing $@...'
 	$(Q)$(RTE_SPHINX_BUILD) -b latex $(RTE_SPHINX_VERBOSE) \
@@ -112,6 +106,12 @@  guides-pdf-%:
 	$(Q)mv $(RTE_OUTPUT)/doc/pdf/guides/$*/doc.pdf \
 		$(RTE_OUTPUT)/doc/pdf/guides/$*.pdf
 
+guides-%:
+	@echo 'sphinx processing $@...'
+	$(Q)$(RTE_SPHINX_BUILD) -b $* $(RTE_SPHINX_VERBOSE) \
+		-c $(RTE_SDK)/doc/guides $(RTE_SDK)/doc/guides \
+		$(RTE_OUTPUT)/doc/$*/guides
+
 # Each PDF depends on generated images *.pdf from *.svg
 $(foreach guide, $(RTE_GUIDES), $(foreach img, $(wildcard $(guide)img/*.svg), \
 	$(eval guides-pdf-$(notdir $(guide:/=)): $(img:svg=pdf))))