1 # Copyright (C) 2007-2008 CEA/DEN, EDF R&D, OPEN CASCADE
3 # Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 # CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
6 # This library is free software; you can redistribute it and/or
7 # modify it under the terms of the GNU Lesser General Public
8 # License as published by the Free Software Foundation; either
9 # version 2.1 of the License.
11 # This library is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 # Lesser General Public License for more details.
16 # You should have received a copy of the GNU Lesser General Public
17 # License along with this library; if not, write to the Free Software
18 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
24 MESSAGE(STATUS "Check for doxygen ...")
28 IF(DOXYGEN_IS_MANDATORY STREQUAL 0)
29 SET(DOXYGEN_IS_MANDATORY 0)
30 SET(DOXYGEN_IS_OPTIONAL 1)
31 ENDIF(DOXYGEN_IS_MANDATORY STREQUAL 0)
32 IF(DOXYGEN_IS_OPTIONAL STREQUAL 0)
33 SET(DOXYGEN_IS_MANDATORY 1)
34 SET(DOXYGEN_IS_OPTIONAL 0)
35 ENDIF(DOXYGEN_IS_OPTIONAL STREQUAL 0)
36 IF(NOT DOXYGEN_IS_MANDATORY AND NOT DOXYGEN_IS_OPTIONAL)
37 SET(DOXYGEN_IS_MANDATORY 0)
38 SET(DOXYGEN_IS_OPTIONAL 1)
39 ENDIF(NOT DOXYGEN_IS_MANDATORY AND NOT DOXYGEN_IS_OPTIONAL)
44 IF(WITHOUT_DOXYGEN OR WITH_DOXYGEN STREQUAL 0)
46 MESSAGE(STATUS "doxygen disabled from command line.")
47 ENDIF(WITHOUT_DOXYGEN OR WITH_DOXYGEN STREQUAL 0)
53 SET(DOXYGEN_ROOT_USER ${WITH_DOXYGEN})
55 IF(NOT DOXYGEN_ROOT_USER)
56 SET(DOXYGEN_ROOT_USER $ENV{DOXYGEN_ROOT})
57 ENDIF(NOT DOXYGEN_ROOT_USER)
58 IF(NOT DOXYGEN_ROOT_USER)
59 SET(DOXYGEN_ROOT_USER $ENV{DOXYGENHOME})
60 ENDIF(NOT DOXYGEN_ROOT_USER)
66 SET(DOXYGEN_EXECUTABLE_TO_FIND doxygen)
68 FIND_PROGRAM(DOXYGEN_EXECUTABLE ${DOXYGEN_EXECUTABLE_TO_FIND} PATHS ${DOXYGEN_ROOT_USER}/bin NO_DEFAULT_PATH)
69 ELSE(DOXYGEN_ROOT_USER)
70 FIND_PROGRAM(DOXYGEN_EXECUTABLE ${DOXYGEN_EXECUTABLE_TO_FIND})
71 ENDIF(DOXYGEN_ROOT_USER)
72 IF(DOXYGEN_EXECUTABLE)
73 MESSAGE(STATUS "${DOXYGEN_EXECUTABLE_TO_FIND} found: ${DOXYGEN_EXECUTABLE}")
74 ELSE(DOXYGEN_EXECUTABLE)
75 MESSAGE(STATUS "${DOXYGEN_EXECUTABLE_TO_FIND} not found, try to use WITH_DOXYGEN option or DOXYGEN_ROOT (or DOXYGENHOME) environment variable")
77 ENDIF(DOXYGEN_EXECUTABLE)
86 IF(DOXYGEN_IS_MANDATORY)
87 MESSAGE(FATAL_ERROR "doxygen not found ... mandatory ... abort")
88 ELSE(DOXYGEN_IS_MANDATORY)
89 MESSAGE(STATUS "doxygen not found ... optional ... disabled")
90 ENDIF(DOXYGEN_IS_MANDATORY)