Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Download doc with wget on windows and add a target for nsis.
authorunknown <pierre@.(none)>
Wed, 11 Jan 2012 12:20:48 +0000 (13:20 +0100)
committerunknown <pierre@.(none)>
Wed, 11 Jan 2012 12:20:48 +0000 (13:20 +0100)
CMakeLists.txt
buildtools/Cmake/GenerateDocWin.cmake [new file with mode: 0644]

index ab7cb25..54b68d1 100644 (file)
@@ -226,10 +226,13 @@ include(${CMAKE_HOME_DIRECTORY}/buildtools/Cmake/Distrib.cmake)
 ### Pipol compilation
 include(${CMAKE_HOME_DIRECTORY}/buildtools/Cmake/Pipol.cmake)
 
-if(NOT WIN32)
 ### Build the doc
+if(NOT WIN32)
 include(${CMAKE_HOME_DIRECTORY}/buildtools/Cmake/GenerateDoc.cmake)
+else(NOT WIN32)
+include(${CMAKE_HOME_DIRECTORY}/buildtools/Cmake/GenerateDocWin.cmake)  
 endif(NOT WIN32)
+
 ### Print ARGS
 include(${CMAKE_HOME_DIRECTORY}/buildtools/Cmake/PrintArgs.cmake)
 
diff --git a/buildtools/Cmake/GenerateDocWin.cmake b/buildtools/Cmake/GenerateDocWin.cmake
new file mode 100644 (file)
index 0000000..46ef1c6
--- /dev/null
@@ -0,0 +1,23 @@
+#### Generate the html documentation
+find_path(WGET_PATH    NAMES wget.exe  PATHS NO_DEFAULT_PATHS)
+find_path(NSIS_PATH NAMES makensis.exe  PATHS NO_DEFAULT_PATHS)
+
+message(STATUS "wget: ${WGET_PATH}")
+message(STATUS "nsis: ${NSIS_PATH}")
+
+if(WGET_PATH)
+       ADD_CUSTOM_TARGET(simgrid_documentation
+               COMMENT "Downloading the SimGrid documentation..."
+               COMMAND ${WGET_PATH}/wget.exe -r -np -nH -nd http://simgrid.gforge.inria.fr/simgrid/${release_version}/doc/
+               WORKING_DIRECTORY ${CMAKE_HOME_DIRECTORY}/doc/html
+       )
+endif(WGET_PATH)
+
+if(NSIS_PATH)
+ADD_CUSTOM_TARGET(nsis
+       COMMENT "Generating the SimGrid installor for Windows..."
+       DEPENDS simgrid gras graphicator gras_stub_generator tesh simgrid-colorizer simgrid_update_xml
+       COMMAND ${NSIS_PATH}/makensis.exe simgrid.nsi
+       WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/
+)
+endif(NSIS_PATH)
\ No newline at end of file