[RFT PATCH 2/5] Add font installation check

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

 



>From 9720d1856b2b695c34648ca566a4afdcdcb86abb Mon Sep 17 00:00:00 2001
From: Akira Yokosawa <akiysw@xxxxxxxxx>
Date: Mon, 2 May 2016 19:03:11 +0900
Subject: [RFT PATCH 2/5] Add font installation check

This commit adds tests in eps2pdf.sh and runlatex.sh which check
the presence of the Steel City Comic font in the font cache and
in PDF files generated from .svg files.
If either of the tests fails, a message referring the user to
items 1 and 1.1 in FAQ.txt will be displayed.

Signed-off-by: Akira Yokosawa <akiysw@xxxxxxxxx>
---
 utilities/eps2pdf.sh  | 12 ++++++++++++
 utilities/runlatex.sh |  8 ++++++++
 2 files changed, 20 insertions(+)

diff --git a/utilities/eps2pdf.sh b/utilities/eps2pdf.sh
index c0fcdf9..b72f1a5 100644
--- a/utilities/eps2pdf.sh
+++ b/utilities/eps2pdf.sh
@@ -18,6 +18,18 @@
 # http://www.gnu.org/licenses/gpl-2.0.html.
 #
 # Copyright (c) 2010 Paul E. McKenney, IBM Corporation.
+# Copyright (c) 2016 Akira Yokosawa
+
+if ! fc-list | grep -q steel
+then
+	echo "#######################################################################"
+	echo "## Steel City Comic font is not found in the font cache!             ##"
+	echo "## Some speech baloons in the cartoons would be rendered awkwardly.  ##"
+	echo "## See item 1 in FAQ.txt for how to install the font.                ##"
+	echo "## Nevertheless, this build will resume in a short while.            ##"
+	echo "#######################################################################"
+	sleep 5
+fi
 
 epsfiles=`find . -name '*.eps' -print`
 for i in $epsfiles
diff --git a/utilities/runlatex.sh b/utilities/runlatex.sh
index 228d320..3e46e6f 100644
--- a/utilities/runlatex.sh
+++ b/utilities/runlatex.sh
@@ -111,4 +111,12 @@ fi
 rm -f $basename-warning.log $basename-warning-prev.log
 touch $basename.pdf
 echo "No 'LaTeX Warning' found. '$basename.pdf' is ready."
+if ! grep -q -i "steel city comic" cartoons/*.pdf
+then
+	echo "#######################################################################"
+	echo "## Steel City Comic font is not found in the resulting PDF!          ##"
+	echo "## Some speech baloons in the cartoons have been rendered awkwardly. ##"
+	echo "## See items 1 and 1.1 in FAQ.txt for the solution.                  ##"
+	echo "#######################################################################"
+fi
 exit 0
-- 
1.9.1


--
To unsubscribe from this list: send the line "unsubscribe perfbook" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux