Declare them "extern" in include file.
Found by compiling with "-fno-common".
/*** Options ***/
int timeout_value = 5; /* child timeout value */
int sort_len = 19; /* length of the prefix to sort */
/*** Options ***/
int timeout_value = 5; /* child timeout value */
int sort_len = 19; /* length of the prefix to sort */
const char *testsuite_name;
const char *testsuite_name;
static void handle_line(const char *filepos, char *line)
{
/* Search end */
static void handle_line(const char *filepos, char *line)
{
/* Search end */
#include "run_context.h"
/*** Options ***/
#include "run_context.h"
/*** Options ***/
-int timeout_value; /* child timeout value */
-int sort_len; /* length of the prefix to sort */
-char* option; /* cfg for command line */
+extern int timeout_value; /* child timeout value */
+extern int sort_len; /* length of the prefix to sort */
+extern char* option; /* cfg for command line */
#define SORT_LEN_DEFAULT 19
#define SORT_LEN_DEFAULT 19
-rctx_t rctx;
-const char *testsuite_name;
+extern rctx_t rctx;
+extern const char *testsuite_name;
/* Environment related definitions */
/* Environment related definitions */
extern char **environ;
# endif
extern char **environ;
# endif
-xbt_dict_t env; /* the environment, stored as a dict (for variable substitution) */
+extern xbt_dict_t env; /* the environment, stored as a dict (for variable substitution) */