[nautilus-actions] docs/nact/Makefile.am: work-around against #664768



commit c2d0b9fe1e81fa5068ef27a85130453382b83e8e
Author: Pierre Wieser <pwieser trychlos org>
Date:   Sun Dec 4 15:42:40 2011 +0100

    docs/nact/Makefile.am: work-around against #664768
    
    When a bug is detected in dblatex, we re-run it in debug mode, so that
    we may be able to get the .pdf from temp directory.

 ChangeLog             |    5 +++++
 docs/nact/Makefile.am |    9 +++++++++
 2 files changed, 14 insertions(+), 0 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index a803f82..ee6e875 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
 2011-12-04 Pierre Wieser <pwieser trychlos org>
 
+	* docs/nact/Makefile.am: Work-around against #664768.
+
+	When a bug is detected in dblatex, we re-run it in debug mode, so that
+	we may be able to get the .pdf from temp directory.
+
 	* docs/nact/Makefile.am: Fix User's Manual generation.
 
 	* docs/reference/nautilus-actions-docs.xml: API only changes on minor versions.
diff --git a/docs/nact/Makefile.am b/docs/nact/Makefile.am
index cd387fb..da97eec 100644
--- a/docs/nact/Makefile.am
+++ b/docs/nact/Makefile.am
@@ -346,6 +346,10 @@ endif
 # _DOC_LC_DOCS is the list of the translated (not C) DOC_MODULE.xml files
 # we so are sure that they exist and are up to date
 # (path is .po ->[msgfmt]-> .mo ->[xml2po]-> .xml)
+#
+# workaround against l10n bug #664768
+# pdflatex cannot generate some localized pdf
+
 $(MANUALS_PDF): %.pdf: %.xml
 	@if test "$(opt_verbose)" = ""; then echo "  PDF    $@"; fi; \
 	( \
@@ -362,6 +366,11 @@ $(MANUALS_PDF): %.pdf: %.xml
 		fi; \
 	 done; \
 	 cmd="dblatex $$fxml"; eval $$cmd; \
+	 if ! test -f $(DOC_MODULE).pdf; then \
+	 	tmpdir=`dblatex -d $$fxml 2>&1 | grep 'not removed' | awk '{ print $$1 }'`; \
+	 	cp $$tmpdir/$(DOC_MODULE).pdf . || :; \
+	 	rm -fr $$tmpdir; \
+	 fi; \
 	 find figures -type l | xargs rm -f; \
 	 rmdir figures 2>/dev/null || :; \
 	)



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]