/[escript]/trunk/doc/user/SConscript
ViewVC logotype

Contents of /trunk/doc/user/SConscript

Parent Directory Parent Directory | Revision Log Revision Log


Revision 3271 - (show annotations)
Thu Oct 14 02:16:00 2010 UTC (10 years, 3 months ago) by caltinay
File size: 2013 byte(s)
-use existing scons pdflatex target for user's guide
-create temporary files in build directory rather than source directory
-make latex less verbose if verbosity option is off
This fixes #291 for user's guide.

1
2 ########################################################
3 #
4 # Copyright (c) 2003-2010 by University of Queensland
5 # Earth Systems Science Computational Center (ESSCC)
6 # http://www.uq.edu.au/esscc
7 #
8 # Primary Business: Queensland, Australia
9 # Licensed under the Open Software License version 3.0
10 # http://www.opensource.org/licenses/osl-3.0.php
11 #
12 ########################################################
13
14 import os
15 Import('*')
16 local_env = env.Clone(tools=['pdflatex'])
17
18 tex_src = Glob('*.tex')+Glob('*.bib')+Glob('*.sty')+Glob('*.cfg')+Glob('*.cls')
19 fig_src = Glob('figures/*.eps')
20
21 # Convert eps figures to pdf
22 figures=local_env.EpsToPDF(source=fig_src)
23
24 if local_env['verbose']:
25 interaction='-interaction=nonstopmode'
26 else:
27 interaction='-interaction=batchmode'
28
29 # Define command to include SVN revision
30 local_env.Append(PDFLATEXFLAGS=[interaction,'\\\\newcommand{\\\\RepVersion}{%s\\\\xspace}\\\\input{guide.tex}'%(local_env['svn_revision'])])
31 pdf=local_env.PDF(target='guide.pdf', source='guide.tex')
32 Depends(pdf, figures+tex_src)
33
34 pdf_inst=local_env.InstallAs(target=env['prefix']+'/release/doc/user/guide.pdf', source=pdf)
35
36 env.Alias('guide_pdf', pdf_inst)
37
38 html_dir=os.path.join(env['prefix'],'release','doc','user','html')
39
40 html=local_env.Command(Dir(html_dir), tex_src+figures,
41 ["cd %s && latex2html -top_navigation \
42 -bottom_navigation \
43 -index_in_navigation \
44 -contents_in_navigation \
45 -next_page_in_navigation \
46 -previous_page_in_navigation \
47 -title \"esys users guide\" \
48 -noshow_section_numbers \
49 -dir %s -mkdir \
50 -address \"esys@esscc.uq.edu.au\" \
51 -antialias_text -antialias -transparent \
52 -noshort_extn \
53 -up_url \"https://launchpad.net/escript-finley\" \
54 -up_title \"escript\" guide.tex"%(Dir('.').abspath, html_dir)])
55
56 env.Alias('guide_html', html)
57

  ViewVC Help
Powered by ViewVC 1.1.26