From: Martin Quinson Date: Thu, 20 Dec 2012 15:17:07 +0000 (+0100) Subject: improve the doc to include MSG_config X-Git-Tag: v3_9_rc1~86^2~78 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/3805620a2f78c59fe285a1bf9ea2411a35d7f0b4?hp=88425d917174073213cea8943fa31eb0049cb84d;ds=sidebyside improve the doc to include MSG_config --- diff --git a/doc/doxygen/options.doc b/doc/doxygen/options.doc index 31dff235f8..66d988e7d2 100644 --- a/doc/doxygen/options.doc +++ b/doc/doxygen/options.doc @@ -38,23 +38,28 @@ file: \verbatim \endverbatim A last solution is to pass your configuration directly using the C -interface. Unfortunately, this path is not really easy to use right -now, and you mess directly with surf internal variables as follows. Check the -\ref XBT_config "relevant page" for details on all the functions you -can use in this context, \c _surf_cfg_set being the only configuration set -currently used in SimGrid. \code +interface. If you happen to use the MSG interface, this is very easy +with the MSG_config() function. If you do not use MSG, that's a bit +more complex, as you have to mess with the internal configuration set +directly as follows. Check the \ref XBT_config "relevant page" for +details on all the functions you can use in this context, \c +_surf_cfg_set being the only configuration set currently used in +SimGrid. + +@code #include -extern xbt_cfg_t _surf_cfg_set; +extern xbt_cfg_t _sg_cfg_set; int main(int argc, char *argv[]) { - MSG_init(&argc, argv); + SD_init(&argc, argv); - xbt_cfg_set_parse(_surf_cfg_set,"Item:Value"); + /* Prefer MSG_config() if you use MSG!! */ + xbt_cfg_set_parse(_sg_cfg_set,"Item:Value"); // Rest of your code } -\endcode +@endcode \section options_model Configuring the platform models