Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
add a new stressing test to GRAS. Yeah, it actually breaks things quite often...
[simgrid.git] / buildtools / Cmake / Distrib.cmake
index d3d3ab1..6ef4705 100644 (file)
@@ -95,12 +95,12 @@ foreach(file ${HEADERS})
 endforeach(file ${HEADERS})
 
 # example files
-foreach(file ${examples_to_install_in_doc})
+foreach(file ${examples_to_install})
   string(REPLACE "${CMAKE_CURRENT_SOURCE_DIR}/examples/" "" file ${file})
   get_filename_component(location ${file} PATH)
   install(FILES "examples/${file}"
           DESTINATION $ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/doc/simgrid/examples/${location})
-endforeach(file ${examples_to_install_in_doc})
+endforeach(file ${examples_to_install})
 
 # bindings cruft
 
@@ -155,6 +155,8 @@ COMMAND ${CMAKE_COMMAND} -E remove -f ${CMAKE_INSTALL_PREFIX}/include/simgrid_co
 COMMAND ${CMAKE_COMMAND} -E    remove -f ${CMAKE_INSTALL_PREFIX}/include/gras.h 
 COMMAND ${CMAKE_COMMAND} -E    remove -f ${CMAKE_INSTALL_PREFIX}/include/xbt.h
 COMMAND ${CMAKE_COMMAND} -E    echo "uninstall include ok"
+COMMAND ${CMAKE_COMMAND} -E    remove -f ${CMAKE_INSTALL_PREFIX}/share/man/man1/simgrid_update_xml.1
+COMMAND ${CMAKE_COMMAND} -E    echo "uninstall man ok"
 WORKING_DIRECTORY "${CMAKE_INSTALL_PREFIX}"
 )
 
@@ -172,6 +174,49 @@ endif(HAVE_LUA)
 ##   (instead of any cruft laying on my disk as CPack does)  ###
 ################################################################
 
+# This is the complete list of what will be added to the source archive
+set(source_to_pack  
+  ${headers_to_install}
+  ${source_of_generated_headers}
+  ${XBT_RL_SRC}
+  ${EXTRA_DIST}
+  ${SMPI_SRC}
+  ${GRAS_RL_SRC}
+  ${XBT_SRC}
+  ${GTNETS_SRC}
+  ${NS3_SRC}
+  ${SURF_SRC}
+  ${SIMIX_SRC}
+  ${TRACING_SRC}
+  ${MSG_SRC}
+  ${SIMDAG_SRC}
+  ${GRAS_COMMON_SRC}
+  ${GRAS_SG_SRC}
+  ${AMOK_SRC}
+  ${LUA_SRC}
+  ${MC_SRC}
+  ${JEDULE_SRC}
+  ${RNGSTREAM_SRC}
+  ${BINDINGS_FILES}
+  ${CMAKE_SOURCE_FILES}
+  ${EXAMPLES_CMAKEFILES_TXT}
+  ${TESHSUITE_CMAKEFILES_TXT}
+  ${TOOLS_CMAKEFILES_TXT}
+  ${TESTSUITE_CMAKEFILES_TXT}
+  ${DOC_SOURCES}
+  ${DOC_FIGS}
+  ${README_files}
+  ${xml_files}
+  ${tesh_files}
+  ${txt_files}
+  ${bin_files}
+  ${examples_src}
+  ${teshsuite_src}
+  ${tools_src}
+  ${testsuite_src}
+  ${PLATFORMS_EXAMPLES}
+)
+
 ##########################################
 ### Fill in the "make dist-dir" target ###
 ##########################################
@@ -212,7 +257,7 @@ foreach(file ${source_to_pack})
    
    add_custom_command(
      TARGET dist-dir
-     COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_HOME_DIRECTORY}/buildtools/Cmake/Makefile.default ${PROJECT_NAME}-${release_version}/Makefile
+     COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_HOME_DIRECTORY}/buildtools/Cmake/Scripts/Makefile.default ${PROJECT_NAME}-${release_version}/Makefile
    )
 endforeach(file ${source_to_pack})
 
@@ -223,6 +268,7 @@ endforeach(file ${source_to_pack})
 add_custom_target(dist
   DEPENDS ${CMAKE_BINARY_DIR}/${PROJECT_NAME}-${release_version}.tar.gz
 )
+
 add_custom_command(
        OUTPUT ${CMAKE_BINARY_DIR}/${PROJECT_NAME}-${release_version}.tar.gz    
        COMMENT "Compressing the archive from the distribution directory"
@@ -232,6 +278,15 @@ add_custom_command(
 )
 add_dependencies(dist dist-dir)
 
+if(NOT enable_maintainer_mode)
+  add_custom_target(echo-dist
+    COMMAND ${CMAKE_COMMAND} -E echo "WARNING: ----------------------------------------------------"
+    COMMAND ${CMAKE_COMMAND} -E echo "WARNING: Distrib is generated without option maintainer mode "
+    COMMAND ${CMAKE_COMMAND} -E echo "WARNING: ----------------------------------------------------"
+  )
+   add_dependencies(dist echo-dist)
+endif(NOT enable_maintainer_mode)
+
 ###########################################
 ### Fill in the "make distcheck" target ###
 ###########################################
@@ -328,15 +383,17 @@ WORKING_DIRECTORY "${CMAKE_HOME_DIRECTORY}"
 add_custom_target(sync-gforge-doc
 COMMAND chmod g+rw -R doc/
 COMMAND chmod a+rX -R doc/
+COMMAND ssh scm.gforge.inria.fr mkdir /home/groups/simgrid/htdocs/simgrid/${release_version}/ || true 
 COMMAND rsync --verbose --cvs-exclude --compress --delete --delete-excluded --rsh=ssh --ignore-times --recursive --links --perms --times --omit-dir-times 
 doc/html/ scm.gforge.inria.fr:/home/groups/simgrid/htdocs/simgrid/${release_version}/doc/ || true
-COMMAND scp doc/html/simgrid_modules2.png doc/html/simgrid_modules.png doc/webcruft/simgrid_logo.png  doc/webcruft/simgrid_logo_small.png scm.gforge.inria.fr:/home/groups/simgrid/htdocs/simgrid/${release_version}/
+COMMAND scp doc/html/simgrid_modules2.png doc/html/simgrid_modules.png doc/webcruft/simgrid_logo_2011.png  doc/webcruft/simgrid_logo_small.png scm.gforge.inria.fr:/home/groups/simgrid/htdocs/simgrid/${release_version}/
 WORKING_DIRECTORY "${CMAKE_HOME_DIRECTORY}"
 )
 add_dependencies(sync-gforge-doc simgrid_documentation)
 
 add_custom_target(sync-gforge-dtd
-COMMAND scp src/surf/simgrid.dtd scm.gforge.inria.fr:/home/groups/simgrid/htdocs/${release_version}/
+COMMAND scp src/surf/simgrid.dtd scm.gforge.inria.fr:/home/groups/simgrid/htdocs/simgrid/${release_version}/simgrid.dtd
+COMMAND scp src/surf/simgrid.dtd scm.gforge.inria.fr:/home/groups/simgrid/htdocs/simgrid.dtd
 WORKING_DIRECTORY "${CMAKE_HOME_DIRECTORY}"
 )