-const char *SIM_PREEMBULE =
-"#include <stdlib.h>\n"
-"#include <stdio.h>\n"
-"#include \"msg/msg.h\"\n"
-"#include <gras.h>\n"
-"\n"
-"char *gras_log=NULL;\n";
-
-
-const char *SIM_LAUNCH_FUNC =
-"int launch_%s(int argc, char **argv) {\n"
-" char **myargv=argv;\n"
-" int myargc=argc;\n"
-" int i;\n"
-" int retcode;\n"
-" \n"
-" if (gras_log) {\n"
-" myargv=malloc((argc+1) * sizeof(char**));\n"
-" for (i=0; i<argc; i++)\n"
-" myargv[i] = argv[i];\n"
-" myargv[myargc++] = gras_log;\n"
-" }\n"
-" retcode = %s(myargc,myargv);\n"
-" if (myargv != argv)\n"
-" free(myargv);\n"
-" return retcode;\n"
-"}\n";
-
-const char* SIM_MAIN_PREEMBULE =
-"int main (int argc,char *argv[]) {\n"
-" int i,j;\n"
-"\n"
-" /* Save the gras-log argument of real command line to pass it to all processes */\n"
-" for (i=1; i<argc; i++) {\n"
-" if (!strncmp(argv[i],\"--gras-log=\",strlen(\"--gras-log=\"))) {\n"
-" if (gras_log) {\n"
-" char *tmp=malloc(strlen(gras_log)+strlen(argv[i])+2);\n"
-" sprintf(tmp,\"%%s %%s\",gras_log, argv[i]);\n"
-" free(gras_log);\n"
-" gras_log=tmp;\n"
-" } else {\n"
-" gras_log = strdup(argv[i]);\n"
-" }\n"
-" for (j=i+1; j<argc; j++) {\n"
-" argv[j-1] = argv[j];\n"
-" } \n"
-" argv[j-1] = NULL;\n"
-" argc--;\n"
-" i--; /* compensate effect of next loop incrementation */\n"
-" }\n"
-" }\n"
-"\n"
-" if (argc != 3) {\n"
-" fprintf(stderr, \"Usage: %%s platform_file application_description.txt [--gras-log=...]\\n\",argv[0]);\n"
-" exit(1);\n"
-" }\n"
-"\n"
-" /* Simulation setup */\n"
-" MSG_global_init();\n"
-" MSG_set_verbosity(MSG_SILENT);\n"
-" MSG_set_channel_number(10); // GRAS_MAX_CHANNEL hardcoded since Alvin killed its definition\n"
-" MSG_create_environment(argv[1]);\n"
-"\n"
-" /* Application deployment */\n";
-
-const char *SIM_MAIN_POSTEMBULE = "\n"
-"\n"
-" MSG_launch_application(argv[2]);\n"
-"\n"
-" /* Run the simulation */\n"
-" MSG_main();\n"
-"\n"
-" /* cleanup the place */\n"
-" MSG_clean();\n"
-" if (gras_log)\n"
-" free(gras_log);\n"
-" return 0;\n"
-"}\n";
-
-/**********************************************/
-/**** Generate the file for the real life *****/
-/**********************************************/
-
-const char *RL_CODE =
-"#include <stdio.h>\n"
-"#include <signal.h>\n"
-"#include <gras.h>\n"
-"\n"
-"/* user code */\n"
-"int %s(int argc, char *argv[]);\n"
-"\n"
-"int main(int argc, char *argv[]){\n"
-" int errcode;\n"
-"\n"
-" errcode=%s(argc,argv);\n"
-" \n"
-" return errcode;\n"
-"}\n";