/[ascend]/trunk/SConstruct
ViewVC logotype

Diff of /trunk/SConstruct

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2674 by jpye, Fri Jan 18 01:06:06 2013 UTC revision 2675 by jpye, Thu Jan 24 08:16:44 2013 UTC
# Line 1975  def CheckLatex2HTML(context): Line 1975  def CheckLatex2HTML(context):
1975      return r      return r
1976    
1977  #----------------  #----------------
 # 'lmodern' package for LaTeX available?  
   
 lmodern_test_text = r"""  
 \documentclass{article}  
 \usepackage{lmodern}  
 \title{Cartesian closed categories and the price of eggs}  
 \author{Jane Doe}  
 \date{September 2012}  
 \begin{document}  
    \maketitle  
    Hello world!  
 \end{document}  
 """;  
   
 def CheckLModern(context):  
     context.Message("Checking for lmodern...")  
     b = context.env.get("DVI")  
     if not b:  
         context.Result(False)  
         return False  
     ff = context.env.get('LATEXFLAGS')  
     context.env.Append(LATEXFLAGS=['-interaction=nonstopmode','-halt-on-error'])  
     is_ok = context.TryBuild(builder=b,text=lmodern_test_text,extension=".latex")  
     print "is_ok=",is_ok  
     if ff is not None:  
         context.env['LATEXFLAGS'] = ff  
     else:  
         del context.env['LATEXFLAGS']  
     context.Result(is_ok)  
     return is_ok  
   
 #----------------  
1978  # GCC Version sniffing  # GCC Version sniffing
1979    
1980  # TODO FIXME  # TODO FIXME
# Line 2030  conf = Configure(env Line 1998  conf = Configure(env
1998          , 'CheckDMalloc' : CheckDMalloc          , 'CheckDMalloc' : CheckDMalloc
1999          , 'CheckLyx' : CheckLyx          , 'CheckLyx' : CheckLyx
2000          , 'CheckLatex2HTML' : CheckLatex2HTML          , 'CheckLatex2HTML' : CheckLatex2HTML
         , 'CheckLModern' : CheckLModern  
2001          , 'CheckGraphViz' : CheckGraphViz          , 'CheckGraphViz' : CheckGraphViz
2002          , 'CheckGraphVizBoolean' : CheckGraphVizBoolean          , 'CheckGraphVizBoolean' : CheckGraphVizBoolean
2003          , 'CheckUFSparse' : CheckUFSparse          , 'CheckUFSparse' : CheckUFSparse
# Line 2384  if with_doc_build: Line 2351  if with_doc_build:
2351          with_doc_build = False          with_doc_build = False
2352          without_doc_build_reason="unable to locate LyX"          without_doc_build_reason="unable to locate LyX"
2353    
     if with_doc_build:  
         with_latex2html = conf.CheckLatex2HTML()  
   
         if conf.CheckLModern() is False:  
             with_doc_build = False  
             without_doc_build_reason="'lmodern' is not available"  
   
2354  # TODO: -D_HPUX_SOURCE is needed  # TODO: -D_HPUX_SOURCE is needed
2355    
2356  # TODO: detect if dynamic libraries are possible or not  # TODO: detect if dynamic libraries are possible or not

Legend:
Removed from v.2674  
changed lines
  Added in v.2675

john.pye@anu.edu.au
ViewVC Help
Powered by ViewVC 1.1.22