Salome HOME
Merge from rnv/geom_plugin_imp branch
[plugins/dxfplugin.git] / doc / salome / gui / DXFPLUGIN / CMakeLists.txt
index 598bde79a3283b1d314da4e9acdba296a85b9d9f..6a72dd1b9ec6cece003345e285de500764387014 100755 (executable)
@@ -1,4 +1,4 @@
-# Copyright (C) 2014  CEA/DEN, EDF R&D, OPEN CASCADE
+# Copyright (C) 2014-2015  OPEN CASCADE
 #
 # This library is free software; you can redistribute it and/or
 # modify it under the terms of the GNU Lesser General Public
@@ -22,6 +22,12 @@ SALOME_CONFIGURE_FILE(doxyfile_py.in doxyfile_py)
 SALOME_CONFIGURE_FILE(static/header.html.in ${CMAKE_CURRENT_BINARY_DIR}/static/header.html)
 SALOME_CONFIGURE_FILE(static/header_py.html.in ${CMAKE_CURRENT_BINARY_DIR}/static/header_py.html)
 
+# Generate a temporary python file, needed for the generation of the documentation
+# of the plugin.
+SALOME_ACCUMULATE_ENVIRONMENT(GEOM_PluginsList NOCHECK DXFPlugin)
+SET(_plugins_cmd_options ${GEOM_ROOT_DIR}/bin/salome/collect_geom_methods.py -d -o tmp/geomBuilder.py DXFPlugin)
+SALOME_GENERATE_ENVIRONMENT_SCRIPT(_plugins_cmd env_script "${PYTHON_EXECUTABLE}" "${_plugins_cmd_options}")
+
 SET(kernel_file "$ENV{KERNEL_ROOT_DIR}/bin/salome/prepare_generating_doc.py")
 IF(WIN32)
   STRING(REPLACE "/" "\\" kernel_file ${kernel_file})
@@ -29,6 +35,7 @@ ENDIF(WIN32)
 
 ADD_CUSTOM_TARGET(usr_docs ${CMAKE_COMMAND} -E make_directory tmp
   COMMAND ${PYTHON_EXECUTABLE} ${kernel_file} -o tmp/DXFPluginBuilder.py ${CMAKE_SOURCE_DIR}/src/DXFPluginBuilder.py
+  COMMAND ${_plugins_cmd}
   COMMAND ${DOXYGEN_EXECUTABLE} doxyfile_py
   COMMAND ${DOXYGEN_EXECUTABLE} doxyfile
   COMMAND ${CMAKE_COMMAND} -E remove_directory tmp