[LON-CAPA-cvs] cvs: loncom /build Makefile doc/loncapafiles buildfiles.lpml latex_fmtutil.piml picins_check.piml

raeburn raeburn@source.lon-capa.org
Sat, 03 Apr 2010 01:13:47 -0000


raeburn		Sat Apr  3 01:13:47 2010 EDT

  Added files:                 
    /doc/loncapafiles	latex_fmtutil.piml 

  Modified files:              
    /doc/loncapafiles	picins_check.piml buildfiles.lpml 
    /loncom/build	Makefile 
  Log:
  - Bug 6213.
    - Always run /usr/bin/fmtutil-sys --missing during postinstall.
    - Eliminate distro-specific call in picins_check.piml.
  
  
Index: doc/loncapafiles/picins_check.piml
diff -u doc/loncapafiles/picins_check.piml:1.6 doc/loncapafiles/picins_check.piml:1.7
--- doc/loncapafiles/picins_check.piml:1.6	Fri Jan  1 16:13:13 2010
+++ doc/loncapafiles/picins_check.piml	Sat Apr  3 01:13:44 2010
@@ -3,7 +3,7 @@
 <!-- picins_check.piml -->
 <!-- Stuart Raeburn -->
 
-<!-- $Id: picins_check.piml,v 1.6 2010/01/01 16:13:13 raeburn Exp $ -->
+<!-- $Id: picins_check.piml,v 1.7 2010/04/03 01:13:44 raeburn Exp $ -->
 
 <!--
 
@@ -52,7 +52,7 @@
             if (-e $picinspath.'/'.$file) {
                 system('/usr/bin/texconfig rehash  1>/dev/null 2>/dev/null');
                 die("Can't run /usr/bin/texconfig rehash") if $?;
-                system("/usr/bin/fmtutil-sys --missing  1>/dev/null 2>/dev/null");                print "$picinspath/$file created and /usr/bin/texconfig rehash ran successfully.\n";
+                print "$picinspath/$file created and /usr/bin/texconfig rehash ran successfully.\n";
             } else {
                 die("Can't find $picinspath/$file");
             }
Index: doc/loncapafiles/buildfiles.lpml
diff -u doc/loncapafiles/buildfiles.lpml:1.26 doc/loncapafiles/buildfiles.lpml:1.27
--- doc/loncapafiles/buildfiles.lpml:1.26	Mon Aug 24 13:44:50 2009
+++ doc/loncapafiles/buildfiles.lpml	Sat Apr  3 01:13:44 2010
@@ -2,7 +2,7 @@
  "http://lpml.sourceforge.net/DTD/lpml.dtd">
 <!-- buildfiles.lpml -->
 
-<!-- $Id: buildfiles.lpml,v 1.26 2009/08/24 13:44:50 raeburn Exp $ -->
+<!-- $Id: buildfiles.lpml,v 1.27 2010/04/03 01:13:44 raeburn Exp $ -->
 
 <!--
 
@@ -367,6 +367,16 @@
   </note>
 </file>
 <file>
+  <source>doc/loncapafiles/latex_fmtutil.piml</source>
+  <target dist='default'>latex_fmtutil.piml</target>
+  <categoryname>system file</categoryname>
+  <description>
+Runs "/usr/bin/fmtutil-sys --missing" to create any missing TeX format files.
+  </description>
+  <note>
+  </note>
+</file>
+<file>
 <source>doc/loncapafiles/valid_hosts.xfml</source>
 <target dist='default'>valid_hosts.xfml</target>
 <categoryname>system file</categoryname>
Index: loncom/build/Makefile
diff -u loncom/build/Makefile:1.190 loncom/build/Makefile:1.191
--- loncom/build/Makefile:1.190	Mon Aug 24 13:44:56 2009
+++ loncom/build/Makefile	Sat Apr  3 01:13:47 2010
@@ -1,6 +1,6 @@
 # The LearningOnline Network with CAPA
 
-# $Id: Makefile,v 1.190 2009/08/24 13:44:56 raeburn Exp $
+# $Id: Makefile,v 1.191 2010/04/03 01:13:47 raeburn Exp $
 
 # TYPICAL USAGE of this Makefile is primarily for two targets:
 # "make build" and "make install".
@@ -138,6 +138,7 @@
 	@echo "             filename databases used by LaTeX"
 	@echo "mimetex_version_check: check if mimetex.cgi version has changed,"
 	@echo "                      if so remove files from mimetexcache."
+	@echo "latex_fmtutil: run utility to maintain TeX format files system-wide."
 	@echo "updatequery: solicit the user for machine configuration"
 	@echo "             information; to be incorporated during an update"
 	@echo "             procedure (via the UPDATE command)"
@@ -504,6 +505,11 @@
 	perl piml_parse.pl  $(CATEGORY) $(DIST) "$(TARGET)" $(LAUNCH) | \
 	tee -a WARNINGS
 
+latex_fmtutil:
+	cat $(SOURCE)/doc/loncapafiles/latex_fmtutil.piml | \
+	perl piml_parse.pl  $(CATEGORY) $(DIST) "$(TARGET)" $(LAUNCH) | \
+	tee -a WARNINGS
+
 postinstall:
 	make webserverconf
 	make reseval_fixup
@@ -526,6 +532,7 @@
 	make picins_check
 	make mimetex_version_check
 	make verify_domconfiguser
+	make latex_fmtutil 
 VERSION:
 	install -d $(TARGET)/etc
 	echo -n "LON-CAPA release $(VERSION)-" > $(TARGET)/etc/loncapa-release

Index: doc/loncapafiles/latex_fmtutil.piml
+++ doc/loncapafiles/latex_fmtutil.piml
<!DOCTYPE piml PUBLIC "-//TUX/DTD piml 1.0 Final//EN" 
	"http://lpml.sourceforge.net/DTD/piml.dtd">
<!-- latex_fmtutil.piml -->
<!-- Stuart Raeburn -->

<!-- $Id: latex_fmtutil.piml,v 1.1 2010/04/03 01:13:44 raeburn Exp $ -->

<!--

This file is part of the LearningOnline Network with CAPA (LON-CAPA).

LON-CAPA is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.

LON-CAPA is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with LON-CAPA; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA

/home/httpd/html/adm/gpl.txt

http://www.lon-capa.org/

-->

<piml>
<files>
<file>
<perlscript mode="fg">
    system("/usr/bin/fmtutil-sys --missing > /dev/null 2>&1");
    if ($?) {
        print "Failed to run fmtutil-sys to check for missing TeX format files.  Try running /usrbin/fmtutil-sys --missing manually\n";
    } else {
        print "Check for missing TeX format files with fmtutil-sys completed successfully.\n";
    }
</perlscript>
</file>
</files>
</piml>