I have finally (almost) managed to compile freeciv with Mingw and Msys(I'll post a thread to tell others what is needed) and everything works fine until the creation of civserver.exe and civclient.exe. The reason is the following error:
"In function 'handle_readline_input_callback' [...]/sernet.c:160: undefined reference to 'handle_stdin_close' "
Here's the function's code:
#ifdef HAVE_LIBREADLINE
/************************************************** **************************/
#define HISTORY_FILENAME ".civserver_history"
#define HISTORY_LENGTH 100
static char *history_file = NULL;
static bool readline_handled_input = FALSE;
static bool readline_initialized = FALSE;
/************************************************** ***************************
...
************************************************** ***************************/
static void handle_readline_input_callback(char *line)
{
if (no_input)
return;
if (!line) {
handle_stdin_close(); /* maybe print an 'are you sure?' message? */
return;
}
if (line[0] != '\0')
add_history(line);
con_prompt_enter(); /* just got an 'Enter' hit */
handle_stdin_input((struct connection*)NULL, line);
readline_handled_input = TRUE;
}
#endif /* HAVE_LIBREADLINE */
My guess is that it's something going on with
#ifdef HAVE_LIBREADLINE ; I mean maybe this variable is not defined and so the compiler doesn't recognizes that function.
Here's the definition of it:
#ifndef SOCKET_ZERO_ISNT_STDIN
static void handle_stdin_close(void)
{
freelog(LOG_NORMAL, _("Server cannot read standard input. Ignoring input."));
no_input = TRUE;
}
#endif
Again it can be something wrong with "#ifndef ...".
I could've tried to modify these things on my on but the consequences might be desatrous since those variables are used in many other .c files (I think) and so I wouldn't have done anything but make things worse!
If anyone knows what is wrong please give me a hand. This is all the info I can provide about this error...
LAST QUESTION: Is freeciv 1.15 ready for download? (if yes, where from?(the source and the compiled program pls))
"In function 'handle_readline_input_callback' [...]/sernet.c:160: undefined reference to 'handle_stdin_close' "
Here's the function's code:
#ifdef HAVE_LIBREADLINE
/************************************************** **************************/
#define HISTORY_FILENAME ".civserver_history"
#define HISTORY_LENGTH 100
static char *history_file = NULL;
static bool readline_handled_input = FALSE;
static bool readline_initialized = FALSE;
/************************************************** ***************************
...
************************************************** ***************************/
static void handle_readline_input_callback(char *line)
{
if (no_input)
return;
if (!line) {
handle_stdin_close(); /* maybe print an 'are you sure?' message? */
return;
}
if (line[0] != '\0')
add_history(line);
con_prompt_enter(); /* just got an 'Enter' hit */
handle_stdin_input((struct connection*)NULL, line);
readline_handled_input = TRUE;
}
#endif /* HAVE_LIBREADLINE */
My guess is that it's something going on with
#ifdef HAVE_LIBREADLINE ; I mean maybe this variable is not defined and so the compiler doesn't recognizes that function.
Here's the definition of it:
#ifndef SOCKET_ZERO_ISNT_STDIN
static void handle_stdin_close(void)
{
freelog(LOG_NORMAL, _("Server cannot read standard input. Ignoring input."));
no_input = TRUE;
}
#endif
Again it can be something wrong with "#ifndef ...".
I could've tried to modify these things on my on but the consequences might be desatrous since those variables are used in many other .c files (I think) and so I wouldn't have done anything but make things worse!
If anyone knows what is wrong please give me a hand. This is all the info I can provide about this error...
LAST QUESTION: Is freeciv 1.15 ready for download? (if yes, where from?(the source and the compiled program pls))
Comment