Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
[From Arnaud Giersch] In standard C, we are allowed to initialize a variable with...
[simgrid.git] / buildtools / Cmake / Option.cmake
index 2177b3f..5650bbd 100644 (file)
@@ -1,8 +1,23 @@
 ### ARGs use -D[var]=[ON/OFF] or [1/0] or [true/false](see after)
 ### ex: cmake -Denable_java=ON -Denable_gtnets=ON ./
 
+if(APPLE AND NOT CGRAPH_PATH)
+       set(CGRAPH_PATH "/opt/local/include/graphviz" CACHE PATH "Path to cgraph.h")
+else(APPLE AND NOT CGRAPH_PATH)
+
+       if(EXISTS "/usr/include/graphviz")
+               set(include_graphviz "/usr/include/graphviz")
+       endif(EXISTS "/usr/include/graphviz")
+       if(EXISTS "/usr/local/include/graphviz")
+               set(include_graphviz "/usr/local/include/graphviz")
+       endif(EXISTS "/usr/local/include/graphviz")
+       
+       set(CGRAPH_PATH ${include_graphviz} CACHE PATH "Path to cgraph.h")
+endif(APPLE AND NOT CGRAPH_PATH)
+
 set(BIBTEX2HTML ${BIBTEX2HTML} CACHE PATH "Path to bibtex2html")
 set(gtnets_path ${gtnets_path} CACHE PATH "Path to gtnets lib")
+set(custom_flags ${custom_flags} CACHE FORCE "Customers flags add to cmake_c_flag")
 
 if(NOT prefix)
        set(prefix "/usr/local/simgrid/" CACHE PATH "Path where to install project")
@@ -25,7 +40,7 @@ option(enable_gtnets "This variable set the gtnets context." on)
 option(enable_java "This variable set the java context." off)
 option(enable_lua "This variable set lua use." on)
 option(enable_ruby "This variable set ruby use." on)
-
+option(enable_doc "Setting true this variable enable making the simgrid documentation." off)
 option(enable_compile_optimizations "" off)
 option(enable_compile_warnings "" off)
 option(enable_maintainer_mode "Permit to make flex and flexml files." off)
@@ -42,9 +57,14 @@ if(WIN32) #actually not enable with windows
        set(enable_maintainer_mode false CACHE TYPE INTERNAL FORCE)
 endif(WIN32)
 
+if(enable_supernovae AND enable_model-checking)
+       set(enable_model-checking false CACHE TYPE INTERNAL FORCE)
+       message("\n\nWith supernovae mode the model checking must be disable.!!!\n\n")
+endif(enable_supernovae AND enable_model-checking)
+
 mark_as_advanced(enable_coverage)
 mark_as_advanced(enable_memcheck)
-mark_as_advanced(enable_print_message)
+#mark_as_advanced(enable_print_message)
 mark_as_advanced(BIBTEX2HTML_PATH)
 mark_as_advanced(LUA_LIB_PATH_1)                                                                                                                      
 mark_as_advanced(LUA_LIB_PATH_2)