Salome HOME
fix warnings on tutorial build
[modules/hydro.git] / doc / salome / tutorial / english / CMakeLists.txt
1 #  Copyright (C) 2012-2013 EDF
2 #
3 #  This file is part of SALOME HYDRO module.
4 #
5 #  SALOME HYDRO module is free software: you can redistribute it and/or modify
6 #  it under the terms of the GNU General Public License as published by
7 #  the Free Software Foundation, either version 3 of the License, or
8 #  (at your option) any later version.
9 #
10 #  SALOME HYDRO module is distributed in the hope that it will be useful,
11 #  but WITHOUT ANY WARRANTY; without even the implied warranty of
12 #  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13 #  GNU General Public License for more details.
14 #
15 #  You should have received a copy of the GNU General Public License
16 #  along with SALOME HYDRO module.  If not, see <http://www.gnu.org/licenses/>.
17
18 SET(RSTFILES
19   index.rst
20   english_casCalcul.rst
21   english_depouillementCalcul.rst
22   english_donneesPrealables.rst
23   english_format_sinusx.rst
24   english_geometrie.rst
25   english_import.rst
26   english_importBathy.rst
27   english_installationLancementSalome.rst
28   english_interpolationZ.rst
29   english_introCloudCompare.rst
30   english_introQgis.rst
31   english_lancementCalcul.rst
32   english_landCoverMap.rst
33   english_maillage.rst
34   english_manipsPolys.rst
35   english_miseEnDonneesTelemac.rst
36   english_objetsArtificiels.rst
37   english_objetsNaturels.rst
38   english_piegesAEviter.rst
39   english_polylignes.rst
40   english_preliminaires.rst
41   english_sinusX_Format.rst
42   english_streams.rst
43 )
44
45 SET(SPHINXOPTS )
46 SET(SOURCEDIR ${CMAKE_CURRENT_SOURCE_DIR})
47 SET(ALLSPHINXOPTS -d doctrees ${SPHINXOPTS} ${SOURCEDIR})
48
49 # install user's documentation
50
51 SALOME_CONFIGURE_FILE(conf.py.in conf.py)
52
53 ADD_CUSTOM_TARGET(BUILD_HTML2 ALL
54   COMMAND ${CMAKE_COMMAND} -E make_directory html 
55   COMMAND ${CMAKE_COMMAND} -E make_directory doctrees
56   COMMAND ${SPHINX_EXECUTABLE} -c ${CMAKE_BINARY_DIR}/doc/salome/tutorial/english -b html ${ALLSPHINXOPTS} html
57   DEPENDS ${RSTFILES}
58   WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
59 )
60   
61 ADD_CUSTOM_TARGET(BUILD_PDF2 ALL
62   COMMAND ${CMAKE_COMMAND} -E make_directory latex 
63   COMMAND ${SPHINX_EXECUTABLE} -c ${CMAKE_BINARY_DIR}/doc/salome/tutorial/english -b latex ${ALLSPHINXOPTS} latex
64   COMMAND make -C latex all-pdf
65   DEPENDS ${RSTFILES}
66   WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
67 )
68
69 INSTALL(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/html/ 
70   DESTINATION ${SALOME_INSTALL_DOC}/gui/HYDRO_English_tutorial
71   PATTERN ".buildinfo" EXCLUDE
72 )
73
74 INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/latex/moduleHYDRO_tutorial.pdf DESTINATION ${SALOME_INSTALL_DOC}/gui/HYDRO_English_tutorial)