1f8cff
/* simple test program to see if we can link the embedded server library */
1f8cff
1f8cff
#include <stdio.h>
1f8cff
#include <stdlib.h>
1f8cff
#include <stdarg.h>
1f8cff
1f8cff
#include "mysql.h"
1f8cff
1f8cff
MYSQL *mysql;
1f8cff
1f8cff
static char *server_options[] = \
1f8cff
       { "mysql_test", "--defaults-file=my.cnf", NULL };
1f8cff
int num_elements = (sizeof(server_options) / sizeof(char *)) - 1;
1f8cff
1f8cff
static char *server_groups[] = { "libmysqld_server", 
1f8cff
                                 "libmysqld_client", NULL };
1f8cff
1f8cff
int main(int argc, char **argv)
1f8cff
{
1f8cff
   mysql_library_init(num_elements, server_options, server_groups);
1f8cff
   mysql = mysql_init(NULL);
1f8cff
   mysql_close(mysql);
1f8cff
   mysql_library_end();
1f8cff
1f8cff
   return 0;
1f8cff
}